Henry Jen wrote:
> Hi,
> 
> I try to do image-update from opensolaris 2008.05(nv86), but the command 
> failed, and the cause seems to be cannot create/copy BE.
>  
> $ pfexec pkg image-update
> pkg: unable to create an auto snapshot. pkg recovery is disabled.
> pkg: image-update cannot be done on live image
> 
> The last couple lines of image-update -v are:
> 
> pkg:/[EMAIL PROTECTED],5.11-0.86:20080426T174943Z -> 
> pkg:/[EMAIL PROTECTED],5.11-0.91:20080613T174335Z
> None -> pkg:/[EMAIL PROTECTED],5.11-0.91:20080613T182501Z
> None -> pkg:/[EMAIL PROTECTED],5.11-0.91:20080613T174340Z
> None -> pkg:/[EMAIL PROTECTED],5.11-0.91:20080613T182505Z
> None
> pkg: unable to create BE None
> pkg: attempt to mount opensolaris failed.
> pkg: image-update cannot be done on live image

Looks like it fails to create a snapshot of the running BE, which
causes all the other errors coming from pkg.  Unfortunately, the
version of beadm in 2008.05 doesn't allow for any workarounds for
providing better error or debug messages from beadm.

Can you provide the output of 'zfs list', and 'beadm list'

Does <pool>/boot/grub/menu.lst exist?  If not, see below.

> 
> It might worth note that I installed OpenSolaris in a partition with a 
> process roughly described at 
> http://blogs.sun.com/slowhog/entry/install_opensolaris_side_by_side.
> 
> I did some experiment on beadm command, and found that I cannot use the 
> same pool, but has to copy the BE to another pool. I.e, 'pfexec beadm 
> create test' says cannot create, but 'pfexec beadm create -p pool create 
> test' succeed. However, I cannot activate the new BE on other pool:
> 
> $ pfexec beadm activate opensolaris-1
> beadm: Unable to activate opensolaris-1
> 
> Any ideas?

What device are you actually booting from?  From the instructions
listed in that blog, I don't see an installgrub ever done on the
slice containing the pool you created for OpenSolaris.  This tells
me that you're still booting the UFS slice with your existing LU BE.
While this works in allowing you to choose to boot the OpenSolaris
BE, beadm won't be happy because it expects the OpenSolaris BE to be
in bootable root pool with its own menu.lst   In a bootable root pool
the menu.lst is stored in "pool dataset" of the pool.  If you're
currently booted to your OpenSolaris BE, try this:

Mount the slice containing your UFS BE somewhere, e.g. /mnt

Copy the menu.lst from that slice into the pool dataset:

    cp /mnt/boot/grub/menu.lst <pool>/boot/grub/menu.lst

Install grub into the slice used for you pool.  (This will make your
pool the default device that's booted, no longer your UFS slice, but
you can still boot your UFS BE by selecting it from the menu)

    installgrub /boot/grub/stage1 /boot/grub/stage2 <vdev_used_for_pool>


Now, depending on what your menu entry looks like for your OpenSolaris
BE, beadm should start to work.  As long as your menu entry contains
the 'bootfs' directive with the correct dataset value, beadm should be
happy.

Let me know if this works.

> 
> PS. After destroy the /opt zfs filesystem, beadm create now simply 
> segment fault. Is there an assumption there must be a /opt filesystem?

No, there's no assumption that there must be any subordinate file
systems.  I have an instance of OpenSolaris installed with just a
root file system and things work fine.  If you send me the core
file, I'll take a look.


thanks,
-ethan

> 
> Cheers,
> Henry
> 
> 
> ------------------------------------------------------------------------
> 
> _______________________________________________
> pkg-discuss mailing list
> [email protected]
> http://mail.opensolaris.org/mailman/listinfo/pkg-discuss
_______________________________________________
pkg-discuss mailing list
[email protected]
http://mail.opensolaris.org/mailman/listinfo/pkg-discuss

Reply via email to