Archive for Solaris

Upgrade Sun Microsystems OBP (OpenBoot PROM) with tftp

Why is this soo cool? Because the default way to upgrade the OBP is to have a running system. But some times

If you have a working jump start enviroment most of the work is already done, yaha. You actully dont even have to use a solaris box to act as the upgrade server any tftp server will do.

So basically what I did here is used a already set up jump start server to upgrade the OBP on a Sun Fire v240. I deleted the link to the solaris kernel and created a symlink from the mac address to the upgrade binary.

bash-3.00# pwd
/tftpboot
bash-3.00# ls -l
total 458
lrwxrwxrwx 1 root root 27 Jun 6 11:40 0A2483F9 -> inetboot.SUN4U.Solaris_10-1
lrwxrwxrwx 1 root root 27 Jun 6 11:40 0A2483F9.SUN4U -> inetboot.SUN4U.Solaris_10-1
-rwxr-xr-x 1 root root 217016 Jun 6 11:40 inetboot.SUN4U.Solaris_10-1
drwxr-xr-x 2 root root 512 Jun 5 12:07 ODBUpgrade
-rw-r–r– 1 root root 321 Jun 6 11:40 rm.10.36.131.249
lrwxrwxrwx 1 root root 1 Jun 5 10:23 tftpboot -> .

bash-3.00# ls -l ODBUpgrade/
total 7888
-rw-r–r– 1 root root 1482292 Jun 5 12:07 flash-update-Blade100
-rw-r–r– 1 root root 2534420 Jun 5 12:07 flash-update-SunFire240

Comments

Solaris’s version of top

Solaris’s version of top is called prstat /usr/bin/prstat

Example output

PID USERNAME SIZE RSS STATE PRI NICE TIME CPU PROCESS/NLWP
15934 root 2208K 1680K sleep 10 0 0:00:41 12% tar/1
15933 root 1552K 1392K sleep 54 0 0:00:10 3.5% tar/1
15951 ch132182 3376K 3128K cpu0 59 0 0:00:00 0.1% prstat/1
753 noaccess 211M 126M sleep 59 0 0:36:31 0.0% java/35
15938 ch132182 8480K 3104K sleep 59 0 0:00:00 0.0% sshd/1
337 root 2328K 1560K sleep 100 - 0:02:52 0.0% xntpd/1
147 root 3920K 3104K sleep 59 0 0:04:03 0.0% picld/6
158 root 4576K 3896K sleep 59 0 0:02:15 0.0% nscd/26
166 root 2520K 1416K sleep 59 0 0:00:00 0.0% powerd/3
225 daemon 2832K 1808K sleep 59 0 0:00:00 0.0% rpcbind/1
258 daemon 2416K 1784K sleep 60 -20 0:00:00 0.0% lockd/2
235 root 2560K 1896K sleep 59 0 0:00:00 0.0% keyserv/4
237 root 2360K 1680K sleep 59 0 0:00:00 0.0% ypbind/1
153 daemon 4720K 2760K sleep 59 0 0:00:01 0.0% kcfd/5
15809 ch132182 3472K 2144K sleep 59 0 0:00:09 0.0% sftp-server/1
236 daemon 2712K 2088K sleep 59 0 0:00:00 0.0% statd/1
114 root 2520K 1664K sleep 59 0 0:00:11 0.0% snmpdx/1
65 root 9472K 6856K sleep 59 0 0:41:43 0.0% snmpd/1
257 root 2288K 1528K sleep 59 0 0:00:01 0.0% ttymon/1
Total: 75 processes, 237 lwps, load averages: 0.33, 0.25, 0.15

 

Comments

Solaris Patch Cluster Error Codes

 Ever wonder what those codes mean when you are applying a solaris patch cluster

With regular programs a 0 is good and a 1 is bad.  Same basic theory, but you get diffrent error codes for diffrent reasons.  Most of the time you will get a 0 when the package is patch/upgraded and a 1 when you don’t even have the package, or it is already at the same level.  So a 1 is not as bad as it sounds.

Exit code     Meaning
0     No error
1     Usage error
2     Attempt to apply a patch that’s already been applied
3     Effective UID is not root
4     Attempt to save original files failed
5     pkgadd failed
6     Patch is obsoleted
7     Invalid package directory
8     Attempting to patch a package that is not installed
9     Cannot access /usr/sbin/pkgadd (client problem)
10     Package validation errors
11     Error adding patch to root template
12     Patch script terminated due to signal
13     Symbolic link included in patch
14     NOT USED
15     The prepatch script had a return code other than 0.
16     The postpatch script had a return code other than 0.
17     Mismatch of the -d option between a previous patch install and the current one.
18     Not enough space in the file systems that are targets of the patch.
19     $SOFTINFO/INST_RELEASE file not found
20     A direct instance patch was required but not found
21     The required patches have not been installed on the manager
22     A progressive instance patch was required but not found
23     A restricted patch is already applied to the package
24     An incompatible patch is applied
25     A required patch is not applied
26     The user specified backout data can’t be found
27     The relative directory supplied can’t be found
28     A pkginfo file is corrupt or missing
29     Bad patch ID format
30     Dryrun failure(s)
31     Path given for -C option is invalid
32     Must be running Solaris 2.6 or greater
33     Bad formatted patch file or patch file not found
34     The appropriate kernel jumbo patch needs to be installed

Comments

Get solaris to reconize new disk’s

Find the controler number that the HBA is using using.  The C$ is the controller number

cfgadm -al

please note, this is a lot more devices then most people would have

# cfgadm -al
Ap_Id                          Type         Receptacle   Occupant     Condition
c0                             scsi-bus     connected    configured   unknown
c0::dsk/c0t0d0                 CD-ROM       connected    configured   unknown
c1                             fc-private   connected    configured   unknown
c1::500000e010ad1f11           disk         connected    configured   unknown
c1::500000e010ad2011           disk         connected    configured   unknown
c2                             scsi-bus     connected    configured   unknown
c2::lus9                       unknown      connected    configured   unknown
c3                             scsi-bus     connected    configured   unknown
c3::lus10                      unknown      connected    configured   unknown
c4                             scsi-bus     connected    configured   unknown
c4::lus11                      unknown      connected    configured   unknown
c5                             scsi-bus     connected    configured   unknown
c5::lus12                      unknown      connected    configured   unknown
c6                             fc-fabric    connected    configured   unknown
c6::2101000d77bdf35a           disk         connected    unconfigured unknown
c6::500104f000600b7b           tape         connected    configured   unknown
c7                             fc-fabric    connected    configured   unknown
c7::2101000d77bdf15a           disk         connected    unconfigured unknown
c7::500104f000600b7e           tape         connected    configured   unknown
c7::500104f000600b84           tape         connected    configured   unknown
c7::5006016130601ac1           disk         connected    configured   unknown
c7::5006016830601ac1           disk         connected    configured   unknown
c8                             fc-fabric    connected    configured   unknown
c8::2103000d77fd8f5a           disk         connected    unconfigured unknown
c8::500104f000600b8d           tape         connected    configured   unknown
c8::500104f000600ba2           tape         connected    configured   unknown
c9                             fc-fabric    connected    configured   unknown
c9::2101000d77bd8f5a           disk         connected    unconfigured unknown
c9::500104f000600b81           tape         connected    configured   unknown
c9::500104f000600b87           tape         connected    configured   unknown
c9::5006016030601ac1           disk         connected    configured   unknown
c9::5006016930601ac1           disk         connected    configured   unknown
usb0/1                         unknown      empty        unconfigured ok
usb0/2                         unknown      empty        unconfigured ok
usb0/3                         unknown      empty        unconfigured ok
usb0/4                         unknown      empty        unconfigured ok

Rescan the HBA using cfgadm


cfgadm -c configure c$

Then run devfsadm -C to create the devicenodes for your newly discovered targets. 

Run format to verify that the new disks show up in the list - You should see four paths for each device as long as you have dual pathing on each of two controllers. 

Format output, snipet

–snip–

      26. c9t5006016930601AC1d5 <drive not available>
/pci@8,600000/SUNW,qlc@2/fp@0,0/ssd@w5006016930601ac1,5
27. c9t5006016030601AC1d5 <drive not available>
/pci@8,600000/SUNW,qlc@2/fp@0,0/ssd@w5006016030601ac1,5
28. c9t5006016030601AC1d6 <DGC-RAID5-0219 cyl 51198 alt 2 hd 256 sec 16>
/pci@8,600000/SUNW,qlc@2/fp@0,0/ssd@w5006016030601ac1,6
29. c9t5006016930601AC1d6 <DGC-RAID5-0219 cyl 51198 alt 2 hd 256 sec 16>
/pci@8,600000/SUNW,qlc@2/fp@0,0/ssd@w5006016930601ac1,6
30. emcpower0a <DGC-RAID10-0216 cyl 51198 alt 2 hd 256 sec 16>
/pseudo/emcp@0
31. emcpower1a <DGC-RAID10-0216 cyl 61438 alt 2 hd 256 sec 10>
/pseudo/emcp@1
32. emcpower2a <DGC-RAID5-0216 cyl 40958 alt 2 hd 256 sec 10>
/pseudo/emcp@2
33. emcpower3a <DGC-RAID10-0216 cyl 40958 alt 2 hd 128 sec 10>
/pseudo/emcp@3
34. emcpower4a <DGC-RAID5-0216 cyl 40958 alt 2 hd 128 sec 10>
/pseudo/emcp@4
35. emcpower5a <DGC-RAID5-0219 cyl 51198 alt 2 hd 256 sec 16>
/pseudo/emcp@5
If you can see the disks in format you could start using them right away.  You should always use power path and not the direct path because if you do you will not be taking advantage of the power pathing benfits of EMC powerpath.

Run the fowling command to clear out old and dead paths to devices

/etc/powercf -q and /etc/powermt check

To discover and new dievices
/etc/powermt config

- Run /etc/powermt display dev=all and verify that you now have a new emcpower device that points to the LUN ID you configured on the EMC.

run the fowling command to verify that you see all path’s.

/etc/powermt display dev=all

 # /etc/powermt display dev=all
Pseudo name=emcpower4a
CLARiiON ID=APM00050704294 [nepuinf020]
Logical device ID=600601606032140044F6BCBAB53DDB11 [LUN 322]
state=alive; policy=CLAROpt; priority=0; queued-IOs=0
Owner: default=SP A, current=SP A
==============================================================================
—————- Host —————   - Stor -   — I/O Path -  — Stats —
### HW Path                 I/O Paths    Interf.   Mode    State  Q-IOs Errors
==============================================================================
3074 pci@8/SUNW,qlc@3          c7t5006016130601AC1d2s0 SP A1     active  alive      0      1
3074 pci@8/SUNW,qlc@3          c7t5006016830601AC1d2s0 SP B0     active  alive      0      1
3076 pci@8/SUNW,qlc@2          c9t5006016030601AC1d2s0 SP A0     active  alive      0      1
3076 pci@8/SUNW,qlc@2          c9t5006016930601AC1d2s0 SP B1     active  alive      0      1

–Snip–

Now finish partitioning the disk using the format utility.

Comments

how to log into a soalris zone from the global zone

root@solaris# zlogin zone1
[Connected to zone 'zone1' pts/2]
Last login: Mon Dec 10 10:24:53 on pts/2
Sun Microsystems Inc. SunOS 5.10 Generic January 2005
You have new mail.
#

Comments

« Previous entries · Next entries »