unable to halt the zone

Hi Experts,

I have to delete the non- global zone from one of the server.

As per my understanding we need to halt the zone , then uninstall and later delete it with zoneadm however once I am trying to halt the zone the screen is getting hanged, after canceling the process and restarting again the same thing is happening

I am using below command to halt the zone

#zoneadm -z content-server-zone halt

Please shade some light as what could be reason for this

Thanks in anticipation

Are you halting from the global zone? you must use the global zone to halt the local zones

Yes i am in global zone.

You can enter in the console zone?

Now I can�t login to console zone also, I tried executing the below and there is no response, screen is getting hanged

# zlogin �C content-server-zone

No luck !

Does it print any error messages?
What does output of

# zoneadm list -cv

look like?

No there is no error while listing the zone , please see the output below

That explains it. Your zone is in a state ready. From zoneadm(1M) man page:

     ready

         Prepares a zone for running applications  but  does  not
         start any user processes in the zone

Boot it and then halt:

# zoneadm -z content-server-zone boot
# zoneadm -z content-server-zone halt

That should do the trick.

Thanks Luka,

However when I am trying to boot the zone ia m facing the same problem the screen is getting hanged.

All I want to do is to remove this zone from system

What exactly do you mean by "the screen is getting hanged"? The command never finishes and you have to kill it?
Maybe you could try to force the uninstallation:

# zoneadm -z content-server-zone uninstall -F

What i mean to say is nothing is happening after giving the command

and when i try to uninstall with

i am getting error as

What version of Solaris are you using? Check the zones log file (/var/svc/log/system-zones:default.log).

Hi Luka

please see the version detail

Also I cant see any thing unusual in log file

Have you tried to restart the zones service? Or reboot the machine if it is possible?
Maybe the whole zone system isn't working properly. Is it possible to create a test zone and see if it works?
I really haven't been able to reproduce your problem. I allways get an error from zoneadm and it never hangs (sometimes it takes a few seconds to finish it's job, but it never hangs).

Thanks Luka and I appreciate you help !

I did disabled the service and enabling it however there no luck as still once I am trying to boot the zone the screen is getting hanged I mean there is nothing happening after that.

And what happened when you tried to create a new zone?

Hi friend,

As I understand you try to uninstall non-global zone that's in ready state.

Before do it, you should move the zone into installed state.

Can you try this:
zonecfg -z zone_name info

zoneadm -z zone_name verify

zoneadm -z zone_name reboot

zoneadm -z zone_name shutdown

zoneadm -z zone_name halt

if it doesn't work try to force the zone into ready state:
zoneadm -z zone_name ready

BR,

Thanks

zone is in ready state only see the below output

kumarmani, in the 7th post your zoneadm list -cv output looks like this:

#zoneadm list �cv 

ID NAME STATUS PATH BRAND IP
0 global running / native shared
3 content-server-zone ready /zones/ content-server-zone native shared

and in the 18th (the last one) it looks like this:

bash-3.00# zoneadm list -cv
ID NAME STATUS PATH BRAND IP
0 global running / native shared
3 test-zone ready /zones/content-server-zone native shared

Zone names differ. Argument to zoneadm is zone name and not zone path.
Which zone name is right?

Apologies Luka

It's content-server-zone