Solaris 8 Zone — etude/BrandZ trial run
Thursday, January 10th, 2008Solaris8 BrandZ pre-requisites
Requires kernel patch 127111-05 (or latest version) for sparc. Find all dependencies and fulfill then (ie patch requirements).
# lsSUNWs8brandr SUNWs8brandu SUNWs8p2v# pwd/mypool/software/sol8p2v/s8ma-1_0-rr/Product# pkgadd -d .The following packages are available: 1 SUNWs8brandr Solaris 8 Migration Assistant: solaris8 brand support (Root) (sparc) 11.10.0,REV=2007.10.08.16.51 2 SUNWs8brandu Solaris 8 Migration Assistant: solaris8 brand support (Usr) (sparc) 11.10.0,REV=2007.10.08.16.51 3 SUNWs8p2v Solaris 8 p2v Tool (sparc) 11.10.0,REV=2007.10.08.16.51Select package(s) you wish to process (or 'all' to processall packages). (default: all) [?,??,q]:
The SUNWs8brandr and SUNWs8brandu packages need to be added to the Solaris 10 Host OS (Global Zone).
Zone configuration
Then configure the Zone —
# zonecfg -z s8-zones8-zone: No such zone configuredUse 'create' to begin configuring a new zone.zonecfg:s8-zone> create -t SUNWsolaris8zonecfg:s8-zone> set zonepath=/mypool/zones/s8-zonezonecfg:s8-zone>zonecfg:s8-zone> set autoboot=truezonecfg:s8-zone> add netzonecfg:s8-zone:net> set address=192.168.99.100zonecfg:s8-zone:net> set physical=bge1zonecfg:s8-zone:net> endzonecfg:s8-zone> add fszonecfg:s8-zone:fs> set type=zfszonecfg:s8-zone:fs> set dir=/mypool/vol1zonecfg:s8-zone:fs> endspecial not specifiedzonecfg:s8-zone:fs> set special=share/zone/s8-zonezonecfg:s8-zone:fs> endzonecfg:s8-zone>zonecfg:sol8zone> add attrzonecfg:sol8zone:attr> set name=hostidzonecfg:sol8zone:attr> set type=stringzonecfg:sol8zone:attr> set value=8325f14dzonecfg:sol8zone:attr> endzonecfg:sol8zone> verifyzonecfg:sol8zone> commitzonecfg:sol8zone> exitdwailsun:$() # zonecfg -z sol8zone infozonename: sol8zonezonepath: /mypool/zones/sol8zonebrand: solaris8autoboot: falsebootargs:pool:limitpriv:scheduling-class:ip-type: sharedfs: dir: /mypool/vol1 special: share/zone/sol8zone raw not specified type: zfs options: []net: address: 192.168.99.100 physical: bge1attr: name: hostid type: string value: 8325f14ddwailsun:$() # zonecfg -z sol8zone info attrattr: name: hostid type: string value: 8325f14ddwailsun:$() #
Install the zone
dwailsun:$() # zonecfg -z sol8zone export > /var/tmp/safe/sol8zone.configdwailsun:$(safe) # zoneadm -z s8-zone install -u -a /mypool/software/sol8p2v/solaris8-image.flarcould not verify fs /mypool/vol1: could not access zfs dataset 'share/zone/s8-zone'zoneadm: zone s8-zone failed to verifydwailsun:$(safe) # zfs listNAME USED AVAIL REFER MOUNTPOINTmypool 3.75G 15.4G 39.3K /mypoolmypool/software 3.22G 6.78G 3.22G /mypool/softwaremypool/vol1 66.6K 5.00G 34.0K /mypool/vol1mypool/vol1/s8-zone 32.6K 5.00G 32.6K /mypool/vol1/s8-zonemypool/www 544M 3.47G 544M /mypool/wwwmypool/zones 34.0K 5.00G 34.0K /mypool/zonesdwailsun:$(safe) # zfs set mountpoint=legacy mypool/vol1/s8-zonedwailsun:$(safe) # zfs listNAME USED AVAIL REFER MOUNTPOINTmypool 3.75G 15.4G 39.3K /mypoolmypool/software 3.22G 6.78G 3.22G /mypool/softwaremypool/vol1 65.3K 5.00G 32.6K /mypool/vol1mypool/vol1/s8-zone 32.6K 5.00G 32.6K legacymypool/www 544M 3.47G 544M /mypool/wwwmypool/zones 34.0K 5.00G 34.0K /mypool/zonesdwailsun:$(safe) # zoneadm -z s8-zone install -u -a /mypool/software/sol8p2v/solaris8-image.flar Log File: /var/tmp/s8-zone.install.987.log Source: /mypool/software/sol8p2v/solaris8-image.flar Installing: This may take several minutes...Postprocessing: This may take several minutes... Result: Installation completed successfully. Log File: /mypool/zones/sol8zone/root/var/log/s8-zone.install.987.log
Solaris8 P2V
Run sol8-p2v —
dwailsun:$(safe) # /usr/lib/brand/solaris8/s8_p2v s8-zone[Fri Dec 28 12:36:01 PST 2007] S20_apply_patches: Unpacking patch: 109 147-44[Fri Dec 28 12:36:01 PST 2007] S20_apply_patches: Installing patch: 109 147-44Checking installed patches...Patch 109147-44 has already been applied.See patchadd(1M) for instructions.Patchadd is terminating.[Fri Dec 28 12:36:09 PST 2007] S20_apply_patches: Unpacking patch: 111 023-03[Fri Dec 28 12:36:09 PST 2007] S20_apply_patches: Installing patch: 111 023-03Checking installed patches...Patch 111023-03 has already been applied.See patchadd(1M) for instructions.Patchadd is terminating.[Fri Dec 28 12:36:11 PST 2007] S20_apply_patches: Unpacking patch: 111 431-01[Fri Dec 28 12:36:11 PST 2007] S20_apply_patches: Installing patch: 111 431-01Checking installed patches...This patch is obsoleted by patch 108993-67 which has alreadybeen applied to this system.Patchadd is terminating.[Fri Dec 28 12:36:13 PST 2007] S20_apply_patches: Unpacking patch: 112 605-04[Fri Dec 28 12:36:13 PST 2007] S20_apply_patches: Installing patch: 112 605-04Checking installed patches...This patch is obsoleted by patch 108993-67 which has alreadybeen applied to this system.Patchadd is terminating.[Fri Dec 28 12:36:15 PST 2007] S20_apply_patches: Unpacking patch: 112 050-04[Fri Dec 28 12:36:15 PST 2007] S20_apply_patches: Installing patch: 112 050-04Checking installed patches...Patch 112050-04 has already been applied.See patchadd(1M) for instructions.Patchadd is terminating.[Fri Dec 28 12:36:17 PST 2007] S20_apply_patches: Unpacking patch: 109 221-01[Fri Dec 28 12:36:17 PST 2007] S20_apply_patches: Installing patch: 109 221-01Checking installed patches...This patch is obsoleted by patch 109318-39 which has alreadybeen applied to this system.Patchadd is terminating.dwailsun:$(safe) #
dwailsun:$(safe) # zoneadm -z s8-zone bootdwailsun:$(safe) # zoneadm list -v ID NAME STATUS PATH BRAND IP 0 global running / native shared 3 s8-zone running /mypool/zones/sol8zone solaris8 shareddwailsun:$(safe) # zlogin -C s8-zone[Connected to zone 's8-zone' console]You did not enter a selection.What type of terminal are you using? 1) ANSI Standard CRT 2) DEC VT52 3) DEC VT100 4) Heathkit 19 5) Lear Siegler ADM31 6) PC Console 7) Sun Command ToolSun Workstation 9) Televideo 910 10) Televideo 925 11) Wyse Model 50 12) X Terminal Emulator (xterms) 13) OtherType the number of your choice and press Return: 12Configuring network interface addresses: bge1.RPC: Timed out
Then it goes through and does the sysidcfg bit…
System identification is completed.rebooting system due to change(s) in /etc/default/initDec 28 12:41:25 rpcbind: rpcbind terminating on signal.System identification is completed.[NOTICE: Zone rebooting]SunOS Release 5.8 Version Generic_Virtual 64-bitCopyright 1983-2000 Sun Microsystems, Inc. All rights reservedHostname: sol8virtThe system is coming up. Please wait.starting rpc services: rpcbind done.syslog service starting.Print services started.Dec 28 14:41:37 sol8virt sendmail[4102]: My unqualified host name (sol8virt) unknown; sleeping for retryThe system is ready.sol8virt console login:
# uname -aSunOS sol8virt 5.8 Generic_Virtual sun4u sparc SUNW,A70# exit[Connection to zone 's8-zone' pts/5 closed]dwailsun:$(safe) # uname -aSunOS dwailsun 5.10 Generic_127111-05 sun4u sparc SUNW,A70dwailsun:$(safe) # zlogin s8-zone[Connected to zone 's8-zone' pts/5]Last login: Fri Dec 28 14:43:35 on pts/5Sun Microsystems Inc. SunOS 5.8 Generic Patch February 2004# uname -aSunOS sol8virt 5.8 Generic_Virtual sun4u sparc SUNW,A70## cat /etc/release Solaris 8 2/04 s28s_hw4wos_05a SPARC Copyright 2004 Sun Microsystems, Inc. All Rights Reserved. Assembled 08 January 2004#
Think of a optimal battery of tests that can help us determine whether this virtualized solaris 8 is a viable platform for servers that cannot be migrated….
-
Adding packages — pkgadd works
# uname -aSunOS sol8virt 5.8 Generic_Virtual sun4u sparc SUNW,A70# pkginfo|grep -i smcapplication SMCgcc gccapplication SMCliconv libiconvapplication SMClintl libintlapplication SMCosh471 opensshapplication SMCossl opensslapplication SMCzlib zlib
Set up sshd after adding these packages, complete with start up scripts, sshd privsep user id in the system accounts files (passwd and shadow).
# /etc/init.d/sshd startCould not load host key: /usr/local/etc/ssh_host_keyCould not load host key: /usr/local/etc/ssh_host_dsa_keyDisabling protocol version 1. Could not load host key# ps -ef|grep sshd root 5086 4609 0 15:18:13 ? 0:00 /usr/local/sbin/sshd
Installing Oracle 8i
Setting up Oracle 8i was a breeze. Simply dumped the 2 cds of Oracle 8i 64-bit installation media onto a solaris8 zone visible fileystem and ran the runInstaller with all defaults and the demo database (scott/tiger) getting created as the end step.
Make sure to copy the media to local disk when installing inside the zone. The reason being, even though the cdrom can be exported to the local zone from the Global zone this way —
add fsset dir=/mntset special=/cdromset type=lofsadd options roadd options nodevicesend
We would have issues ejecting and inserting new cdroms, etc.
dwailsun:$() # ssh oracle@sol8virtoracle@sol8virt's password:Last login: Thu Jan 3 11:27:25 2008 from 10.119.10.4Sun Microsystems Inc. SunOS 5.8 Generic Patch February 2004Sun Microsystems Inc. SunOS 5.8 Generic Patch February 2004$ ps -ef|grep ora oracle 22608 22152 0 11:25:48 ? 0:00 ora_reco_brandz oracle 22610 22152 0 11:25:48 ? 0:00 ora_snp0_brandz oracle 22626 22152 0 11:26:55 ? 0:00 /export/shared/oracle/OraHome1/bin/tnslsnr LISTENER -inherit oracle 22614 22152 0 11:25:48 ? 0:00 ora_snp2_brandz oracle 22687 22685 0 11:56:04 ? 0:00 /usr/local/sbin/sshd -R oracle 22695 22689 0 11:56:09 pts/6 0:00 grep ora oracle 22689 22687 0 11:56:04 pts/6 0:00 -ksh oracle 22604 22152 4 11:25:48 ? 1:04 ora_ckpt_brandz oracle 22600 22152 0 11:25:48 ? 0:00 ora_dbw0_brandz oracle 22598 22152 0 11:25:48 ? 0:00 ora_pmon_brandz oracle 22620 22152 0 11:25:48 ? 0:00 ora_d000_brandz oracle 22602 22152 0 11:25:48 ? 0:02 ora_lgwr_brandz oracle 22618 22152 0 11:25:48 ? 0:00 ora_s000_brandz oracle 22616 22152 0 11:25:48 ? 0:00 ora_snp3_brandz oracle 22612 22152 0 11:25:48 ? 0:00 ora_snp1_brandz oracle 22606 22152 0 11:25:48 ? 0:00 ora_smon_brandz$