Skip to content

Instantly share code, notes, and snippets.

@citrus-it
Last active January 20, 2021 11:01
Show Gist options
  • Save citrus-it/7ef7415d12bf4acad9da8330764fb261 to your computer and use it in GitHub Desktop.
Save citrus-it/7ef7415d12bf4acad9da8330764fb261 to your computer and use it in GitHub Desktop.

Streamlined upgrade from r151014 to r151030

Create a new boot environment (BE)

beadm create r151030

Mount the new BE on /a

/a is a temporary mount point

beadm mount r151030 /a

Install the certificates for the certificate signing authorities

OmniOSce and OmniTI since r151022 has packages signed by each of these.

wget -P /a/etc/ssl/pkg https://downloads.omniosce.org/ssl/omniosce-ca.cert.pem
wget -P /a/etc/ssl/pkg https://github.com/omniosorg/omnios-build/raw/r151022/build/ca-bundle/files/OmniTI_CA2_OmniOS.pem

Configure the publisher to point to the OmniOS r151022 repo

pkg -R /a set-publisher \
        -G \* -g https://pkg.omnios.org/r151022/core \
        -M \* -m  https://us-east.mirror.omnios.org/r151022/core \
        omnios

And set the publisher to require signed packages

pkg -R /a \
        set-publisher --set-property signature-policy=require-signatures omnios

Run the first update to r151022

pkg -R /a update -f

Expect the following error which is due to the 32-bit kernel being removed in r151022 (a later step resolves this)

pkg: '/sbin/bootadm update-archive -R /a' failed. with a return code of 1.

Set the publishers to r151030

pkg -R /a set-publisher \
        -G \* -g https://pkg.omnios.org/r151030/core \
        -M \* -m https://us-east.mirror.omnios.org/r151030/core \
        omnios

pkg -R /a set-publisher \
        -O https://pkg.omnios.org/r151030/extra \
        extra.omnios

And enable signatures for the extra repository

pkg -R /a \
        set-publisher --set-property signature-policy=require-signatures extra.omnios

and run an update

pkg -R /a update -f

Repair the openssl package

This may report that no changes are required, but it makes sure that the 1.0 -> 1.1 transition is successful.

pkg -R /a fix openssl

Manually create the boot archive:

This handles the 32-bit kernel removal

/a/boot/solaris/bin/create_ramdisk -R /a

Unmount the BE

beadm umount /a

Activate the new BE

beadm activate r151030

and reboot

init 6
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment