Search This Blog

Sunday 11 October 2009

Proceedure for Upgrading M4000/M5000/M9000 firmware

For proceeding with this proceedure, there should be one ip for the console of Mxxx machine.
I have mapped this ip in /etc/hosts file as M4000-sc
Here we are upgrading from 1080 to 1082
Befor you are going to updrade please note,
1. Download and keep the firware in the console machine, (eg: with the path /fw/FFXCP1082.tar.gz)
2. Enble ftp server and root ftp login to console machine
root@console # ssh sun@M4000-sc
sun@M4000-sc's password:
Last login: Wed Jul 8 10:27:18 2009 from 10.14.48.26
#To see the status of the current running domain
XSCF> showdomainstatus -a
DID Domain Status
00 Running
01 -
#To see the the current firware verion
XSCF> version -c xcp
XSCF#0 (Active )
XCP0 (Current): 1080
XCP1 (Reserve): 1080
XSCF> version -c xcp -v
XSCF#0 (Active )
XCP0 (Current): 1080
OpenBoot PROM : 02.07.0000
XSCF : 01.08.0003
XCP1 (Reserve): 1080
OpenBoot PROM : 02.07.0000
XSCF : 01.08.0003
OpenBoot PROM BACKUP
#0: 02.03.0000
#1: 02.07.0000
XSCF> version -c xscf
XSCF#0 (Active )
01.08.0003(Current) 01.08.0003(Reserve)
XSCF> version -c xcp -v
XSCF#0 (Active )
XCP0 (Current): 1080
OpenBoot PROM : 02.07.0000
XSCF : 01.08.0003
XCP1 (Reserve): 1080
OpenBoot PROM : 02.07.0000
XSCF : 01.08.0003
OpenBoot PROM BACKUP
#0: 02.03.0000
#1: 02.07.0000
Downloading patch to the controller from console machine
XSCF> getflashimage -u root ftp://192.168.1.56/fw/FFXCP1082.tar.gz #-> this is the ip of my console machine
Existing versions:
Version Size Date
FFXCP1080.tar.gz 51299678 Thu Dec 11 07:07:20 AST 2008
Warning: About to delete existing versions.
Continue? [y|n]: y
Removing FFXCP1080.tar.gz.
Password:
0MB received
1MB received
2MB received
3MB received
4MB received
5MB received
6MB received
7MB received
8MB received
9MB received
10MB received
11MB received
12MB received
13MB received
14MB received
15MB received
16MB received
17MB received
18MB received
19MB received
20MB received
21MB received
22MB received
23MB received
24MB received
25MB received
26MB received
27MB received
28MB received
29MB received
30MB received
31MB received
32MB received
33MB received
34MB received
35MB received
36MB received
37MB received
38MB received
39MB received
40MB received
Download successful: 41468 Kbytes in 74 secs (586.778 Kbytes/sec)
Checking file...
MD5: 131259c1347204c1150592f8447833ae
Download completed, still the version is as old, ie, 1080
XSCF> version -c xcp -v
XSCF#0 (Active )
XCP0 (Current): 1080
OpenBoot PROM : 02.07.0000
XSCF : 01.08.0003
XCP1 (Reserve): 1080
OpenBoot PROM : 02.07.0000
XSCF : 01.08.0003
OpenBoot PROM BACKUP
#0: 02.03.0000
#1: 02.07.0000
Checking whther this is upgradable or not
XSCF> flashupdate -c check -m xcp -s 1082
XCP update is possible with domains up
Starting to upgarade
XSCF> flashupdate -c update -m xcp -s 1082
The XSCF will be reset. Continue? [y|n] :y
Checking the XCP image file, please wait a minute
XCP update is started (XCP version=1082:last version=1080)
OpenBoot PROM update is started (OpenBoot PROM version=02090000)
OpenBoot PROM update has been completed (OpenBoot PROM version=02090000)
XSCF update is started (XSCFU=0,bank=1,XCP version=1082:last version=1080)
XSCF download is started (XSCFU=0,bank=1,XCP version=1082:last version=1080, Firmware Element ID=00:version=01080001:last version=01080000)
XSCF download has been completed (XSCFU=0,bank=1,XCP version=1082:last version=1080, Firmware Element ID=00:version=01080001:last version=01080000)
XSCF download is started (XSCFU=0,bank=1,XCP version=1082:last version=1080, Firmware Element ID=01:version=01080005:last version=01080003)
XSCF download has been completed (XSCFU=0,bank=1,XCP version=1082:last version=1080, Firmware Element ID=01:version=01080005:last version=01080003)
XSCF download is started (XSCFU=0,bank=1,XCP version=1082:last version=1080, Firmware Element ID=02:version=01080001:last version=01080000)
XSCF download has been completed (XSCFU=0,bank=1,XCP version=1082:last version=1080, Firmware Element ID=02:version=01080001:last version=01080000)
XSCF download is started (XSCFU=0,bank=1,XCP version=1082:last version=1080, Firmware Element ID=03:version=01080004:last version=01080000)
XSCF download has been completed (XSCFU=0,bank=1,XCP version=1082:last version=1080, Firmware Element ID=03:version=01080004:last version=01080000)
XSCF download is started (XSCFU=0,bank=1,XCP version=1082:last version=1080, Firmware Element ID=04:version=01080005:last version=01080003)
XSCF download has been completed (XSCFU=0,bank=1,XCP version=1082:last version=1080, Firmware Element ID=04:version=01080005:last version=01080003)
XSCF download is started (XSCFU=0,bank=1,XCP version=1082:last version=1080, Firmware Element ID=05:version=01080001:last version=01080000)
XSCF download has been completed (XSCFU=0,bank=1,XCP version=1082:last version=1080, Firmware Element ID=05:version=01080001:last version=01080000)
XSCF download is started (XSCFU=0,bank=1,XCP version=1082:last version=1080, Firmware Element ID=07:version=01080004:last version=01080000)
XSCF download has been completed (XSCFU=0,bank=1,XCP version=1082:last version=1080, Firmware Element ID=07:version=01080004:last version=01080000)
XSCF update has been completed (XSCFU=0,bank=1,XCP version=1082:last version=1080)
XSCF is rebooting to update the reserve bank
XSCF> Connection to M4000-sc closed by remote host.
Connection to M4000-sc closed.
sc got colsed here, we have waite some time, the sc to come up. after login to sc again, it will take some time to get the lastes verion updated
root@console # ssh sun@M4000-sc
sun@M4000-sc's password:
flashupdate now in progress.
please wait for flashupdate complete
Last login: Sat Jul 11 09:09:13 2009 from 10.14.48.26
flashupdate now in progress.
please wait for flashupdate complete
XSCF> getflashimage -l
Existing versions:
Version Size Date
FFXCP1082.tar.gz 42463513 Sat Jul 11 09:19:11 AST 2009
Firware is graded succesfully with 1082 version.
XSCF> version -c xcp -v
XSCF#0 (Active )
XCP0 (Reserve): 1082
OpenBoot PROM : 02.09.0000
XSCF : 01.08.0005
XCP1 (Current): 1082
OpenBoot PROM : 02.09.0000
XSCF : 01.08.0005
OpenBoot PROM BACKUP
#0: 02.09.0000
#1: 02.07.0000
XSCF> version -c xscf
XSCF#0 (Active )
01.08.0005(Reserve) 01.08.0005(Current)
XSCF> console -d 0
Connect to DomainID 0?[y|n] :y
{19} ok
{19} ok
{19} ok
{19} ok
{19} ok
{19} ok banner
Sun SPARC Enterprise M4000 Server, using Domain console
Copyright 2008 Sun Microsystems, Inc. All rights reserved.
Copyright 2008 Sun Microsystems, Inc. and Fujitsu Limited. All rights reserved.
OpenBoot 4.24.10, 32768 MB memory installed, Serial #86366072.
Ethernet address 0:21:28:25:d7:78, Host ID: 8525d778.
{19} ok reset-all
Resetting...

Script for moving system logs to another machine by using with time stamp using crontab

#this is the simple script which run depends on crontab entry
#/bin/sh
HOST=`hostname`
TIMESTAMP=`date +"%b_%d_%y_%H-%M%p"`
cd /var/adm
cp messages.1 messages.$HOST.$TIMESTAMP
sleep 6
gzip /var/adm/messages.$HOST.$TIMESTAMP
scp /var/adm/messages.$HOST.$TIMESTAMP.gz root@10.2.171.101:/home/root/logs #ssh key must be instlled on remote machine, else, it will ask for the password everytime.
rm /var/adm/messages.$HOST.$TIMESTAMP.gz

How to remove metaset in Solaris

This is the proceedure for removing a metaset in Solaris. Here my disk set name is test-set and owned by two nodes node1 and node2. Do all this command from /tmp directory.

1. Create new vfstab by removing the entry related to test-set
#cp /etc/vfstab /etc/vfstab.prereclaim
#cat /etc/vfstab.prereclaim|grep -v "/dev/md/test-set/" >/etc/vfatb

2.unmount all the filesystems from test-set forcefully
#for i in `cat /etc/vfstab.prereclaim |grep "/dev/md/smsc-ms/" |awk {'print $3'}`; do umount -f $i; done
The above 2 two steps are requied on all the nodes. For doing below steps, this node should have the ownership to the meta-set. you can get the ownership using metaset -s test-set -t command

3. Get all the logical drive in test-set
#metastat -s test-set -p|grep test-set|awk {'print $1 '}|cut -d \/ -f 2>metadevices

4. Removing the logincal drive one by one
#for i in `cat metadevices`; do metaclear -s smsc-ms -f $i; done

5. Getting all the physical disk name included in the test-set
#metaset |awk {'print $1'}|grep -v "^$"|grep dev>diskname

6. Removing the physcial disks from the test-set
#for i in `cat diskname`; do metaset -s smsc-ms -d -f $i; done

7. Now we can remove mediator and host from this metaset
metaset -s test-set -d -m node1 node2
metaset -s test-set -d -f -h node1
metaset -s test-set -d -f -h node2