Tag Archives: Aix

File System shows 100% occupied but du tells different and still has Unused Spaces.

We have faced an issue as below mentioned – found /oracle mount-point showing 100% as Used. But getting different size values for folders under /oracle mount-point, when we executed du -gs .

bash-4.4# df -g
Filesystem GB blocks Free %Used Iused %Iused Mounted on
/dev/hd4 4.00 1.39 66% 20686 6% /
/dev/hd2 4.00 1.02 75% 45679 16% /usr
/dev/hd9var 2.00 1.01 50% 16318 7% /var
/dev/hd3 2.00 1.83 9% 407 1% /tmp
/dev/hd1 1.00 0.16 85% 6124 12% /home
/dev/hd11admin 0.25 0.25 1% 5 1% /admin
/proc – – – – – /proc
/dev/hd10opt 0.50 0.07 87% 12979 44% /opt
/dev/livedump 0.25 0.25 1% 4 1% /var/adm/ras/livedump
/dev/fslv00 198.00 0.01 100% 440205 16% /oracle

bash-4.4# cd /oracle/
bash-4.4# du -gs *
0.00 AutoDeployment
5.45 Oracle
0.03 Patch
7.54 data01
11.67 fmw_12.1.3.0.0_wls
0.01 jboss
0.20 jdk
0.00 lost+found
0.92 wls1221

You may notice 100 % utilization for /oracle mount-point on the “df -g” output , but with “du -gs ” We found the files did not occupy the entire space.

It may be because of open files in the file-system. These open files hold space on the file-system to complete there execution, once the write operation is completed. 

To overcome, from this issue, We need to follow below two steps:-

  1. We need to find all such processes still running but using deleted files, in result – /oracle mount-point is showing 100% as Used.

bash-4.4# fuser -dV /oracle/
/oracle/:
inode=670047 size=5242722 fd=389 5570776
inode=1165305 size=20278 fd=1 8061106
inode=1165313 size=182335565824 fd=1 8716486
inode=1165305 size=20278 fd=1 9044152
inode=1165313 size=182335565824 fd=1 9371672
inode=1165305 size=20278 fd=1 11141354
inode=669981 size=5514335 fd=1 13041898


2. We have to kill all such processes as found in above command.

bash-4.4# kill -9 5570776
bash-4.4# kill -9 8061106
bash-4.4# kill -9 8716486
bash-4.4# kill -9 9044152
bash-4.4# kill -9 9371672
bash-4.4# kill -9 11141354
bash-4.4# kill -9 13041898

bash-4.4# fuser -dV /oracle/
/oracle/:

bash-4.4# df -g
Filesystem GB blocks Free %Used Iused %Iused Mounted on
/dev/hd4 4.00 1.39 66% 20686 6% /
/dev/hd2 4.00 1.02 75% 45679 16% /usr
/dev/hd9var 2.00 1.01 50% 16318 7% /var
/dev/hd3 2.00 1.83 9% 407 1% /tmp
/dev/hd1 1.00 0.16 85% 6124 12% /home
/dev/hd11admin 0.25 0.25 1% 5 1% /admin
/proc – – – – – /proc
/dev/hd10opt 0.50 0.07 87% 12979 44% /opt
/dev/livedump 0.25 0.25 1% 4 1% /var/adm/ras/livedump
/dev/fslv00 198.00 170.01 15% 440205 1% /oracle
bash-4.4# cd /oracle/
bash-4.4# du -gs *
0.00 AutoDeployment
5.45 Oracle
0.03 Patch
7.54 data01
11.67 fmw_12.1.3.0.0_wls
0.01 jboss
0.20 jdk
0.00 lost+found
0.92 wls1221

How to recover a deleted file in aix / jfs?

It is possible to recover the file using the “fsdb” command (filesystem debugger). when,

No new files have been created on the filesystem.

No files have been extended.

The filesystem is able to be unmounted.

Warning: I have test this in my test server. This is undocumented one. You may facing the critical problem when you follow the below steps on your systems. So try this at your own risk. Please avoid directly try this with your production servers. Here is the output for your reference.

You can get deleted files inode if you don’t have.

#fuser -dV

inode=68     size=34358697984  fd=6
inode=76     size=16106135552  fd=7
inode=65     size=34358697984  fd=16
inode=68     size=34358697984  fd=11
inode=68     size=34358697984  fd=7
inode=68     size=34358697984  fd=6

# lsvg -l testvg

testvg:

LV NAME             TYPE       LPs   PPs   PVs  LV STATE      MOUNT POINT

loglv00             jfs2log    1     1     1    closed/syncd  N/A

#

# crfs -a size=256M -v jfs2 -g testvg -m /new            à create a “/new” FS

File system created successfully.

261932 kilobytes total disk space.

New File System size is 524288

#

# lsvg -l testvg

testvg:

LV NAME             TYPE       LPs   PPs   PVs  LV STATE      MOUNT POINT

loglv00             jfs2log    1     1     1    closed/syncd  N/A

fslv00              jfs2       16    16    1    closed/syncd  /new

#

# mount /new         à mount the /new FS

#

# lsvg -l testvg

testvg:

LV NAME             TYPE       LPs   PPs   PVs  LV STATE      MOUNT POINT

loglv00             jfs2log    1     1     1    open/syncd    N/A

fslv00              jfs2       16    16    1    open/syncd    /new

#

# cd /new

#

# ls -l

total 0

drwxr-xr-x   2 root     system          256 Apr 03 16:47 lost+found

#

# cat >> film         à Create a file named “film”

Hi this is the test file. I want to use this file for recovery test

^C#

#

# cat film

Hi this is the test file. I want to use this file for recovery test

#

# ls –il        à check the inode number of the file “film”. That is 4

total 8

4 -rw-r–r–   1 root     system           68 Apr 03 16:49 film

3 drwxr-xr-x   2 root     system          256 Apr 03 16:47 lost+found

#

#

# rm film     à remove the file “film”

#

# ls -l

total 0

drwxr-xr-x   2 root     system          256 Apr 03 16:47 lost+found

#

# cd ~

#

# umount /new     à unmount the /new FS

#

# lsvg -l testvg

testvg:

LV NAME             TYPE       LPs   PPs   PVs  LV STATE      MOUNT POINT

loglv00             jfs2log    1     1     1    closed/syncd  N/A

fslv00              jfs2       16    16    1    closed/syncd  /new

#

# fsdb /dev/fslv00       à use the “fsdb <lv_name>” to recover the deleted  file.

File System:                    /dev/fslv00

File System Size:               523864  (512 byte blocks)

Aggregate Block Size:           4096

Allocation Group Size:          8192    (aggregate blocks)

> dir 2

idotdot = 2

3      lost+found

>

> i 4     à provide the inode number of our deleted file. That is 4

Inode 4 at block 33, offset 0x800:

[1] di_fileset:         16                 [18] di_inostamp:       0x4d98ead4

[2] di_number:          4               [19] di_gen:            3940655789

[3] di_size:    0x0000000000000044      [20] di_ixpxd.len:      4

[4] di_nblocks: 0x0000000000000001      [21] di_ixpxd.addr1:    0x00

[5] di_nlink:           0               [22] di_ixpxd.addr2:    0x00000021

[6] di_mode:            0x000081a4           di_ixpxd.address:  33

0100644 -rw-r–r–      [24] di_uid:            0

[25] di_gid:            0

[9] di_atime.tj_nsec:   0x1e8a1025      [26] di_atime.tj_sec:0x000000004d98eb7d

[10] di_ctime.tj_nsec:  0x0ca85614      [27] di_ctime.tj_sec:0x000000004d98ebac

[11] di_mtime.tj_nsec:  0x1af63892      [28] di_mtime.tj_sec:0x000000004d98eb77

[12] di_otime.tj_nsec:  0x03b74a9a      [29] di_otime.tj_sec:0x000000004d98eb24

[13] di_ea.flag:        0x00            [30] di_ea.len:         0

EAv1                               [31] di_ea.addr1:       0x00

[15] di_ea.nEntry:      0x00            [32] di_ea.addr2:       0x00000000

[16] di_ea.type:        0x0000               di_ea.address:     0

[34] di_ea.nblocks:     0

change_inode: [m]odify, [e]a, [t]ree, or e[x]it > m     à choose “m” to modify

Please enter: field-number value > 5  1   à  put the field number is 5, change the di_nlink value to 1

Inode 4 at block 33, offset 0x800:

[1] di_fileset:         16              [18] di_inostamp:       0x4d98ead4

[2] di_number:          4               [19] di_gen:            3940655789

[3] di_size:    0x0000000000000044      [20] di_ixpxd.len:      4

[4] di_nblocks: 0x0000000000000001      [21] di_ixpxd.addr1:    0x00

[5] di_nlink:           1               [22] di_ixpxd.addr2:    0x00000021

[6] di_mode:            0x000081a4           di_ixpxd.address:  33

0100644 -rw-r–r–      [24] di_uid:            0

[25] di_gid:            0

[9] di_atime.tj_nsec:   0x1e8a1025      [26] di_atime.tj_sec:0x000000004d98eb7d

[10] di_ctime.tj_nsec:  0x0ca85614      [27] di_ctime.tj_sec:0x000000004d98ebac

[11] di_mtime.tj_nsec:  0x1af63892      [28] di_mtime.tj_sec:0x000000004d98eb77

[12] di_otime.tj_nsec:  0x03b74a9a      [29] di_otime.tj_sec:0x000000004d98eb24

[13] di_ea.flag:        0x00            [30] di_ea.len:         0

EAv1                               [31] di_ea.addr1:       0x00

[15] di_ea.nEntry:      0x00            [32] di_ea.addr2:       0x00000000

[16] di_ea.type:        0x0000               di_ea.address:     0

[34] di_ea.nblocks:     0

change_inode: [m]odify, [e]a, [t]ree, or e[x]it > x    à exit

> quit

#

# fsck -yp /dev/fslv00     à run fsck to repaired the  inconsistencies.

The current volume is: /dev/fslv00

Primary superblock is valid.

J2_LOGREDO:log redo processing for /dev/fslv00

logredo start at: 1301867616 sec and end at 1301867616 sec

Primary superblock is valid.

*** Phase 1 – Initial inode scan

*** Phase 2 – Process remaining directories

*** Phase 3 – Process remaining files

*** Phase 4 – Check and repair inode allocation map

File system inode map is corrupt (FIXED)

Superblock marked dirty because repairs are about to be written.

*** Phase 5 – Check and repair block allocation map

Block allocation map is corrupt (FIXED)

Inodes not connected to the root directory

tree have been detected.  Will reconnect.

File system is clean.

Superblock is marked dirty (FIXED)

All observed inconsistencies have been repaired.

#

# mount /new   à mount the /new FS

# lsvg -l testvg

testvg:

LV NAME             TYPE       LPs   PPs   PVs  LV STATE      MOUNT POINT

loglv00             jfs2log    1     1     1    open/syncd    N/A

fslv00              jfs2       16    16    1    open/syncd    /new

#

# cd /new  à goto the /new FS

#

# ls -l

total 0

drwxr-xr-x   2 root     system          256 Apr 03 16:47 lost+found

#

# cd lost+found   à go to lost+found dir

#

# pwd

/new/lost+found

#

# ls -l

total 8

-rw-r–r–   1 root     system           68 Apr 03 16:49 4     à you can see the deleted file in the name of your inode number

#

# cat 4   à confirm the file content

Hi this is the test file. I want to use this file for recovery test

#

# mv 4 /new/.      à move the file to the exact place where it was before

#

# pwd

/new/lost+found

# cd ..

#

# pwd

/new

# ls -l

total 8

-rw-r–r–   1 root     system           68 Apr 03 16:49 4

drwxr-xr-x   2 root     system          256 Apr 03 16:55 lost+found

#

# cat 4

Hi this is the test file. I want to use this file for recovery test

#

# mv 4 film  à change the name of the recovered file to the old one.

#

# ls -l

total 8

-rw-r–r–   1 root     system           68 Apr 03 16:49 film   à the deleted file has been recovered.

drwxr-xr-x   2 root     system          256 Apr 03 16:55 lost+found

#

#

 

AIX: rootvg/disk mirroring

bash-4.2# bootinfo -s hdisk0
140013
bash-4.2# bootinfo -s hdisk1
140013
bash-4.2# bootinfo -s hdisk2
140013

bash-4.2# lspv
hdisk0 002b012f397c20ce None
hdisk1 002afe4f2b4c3fdb rootvg active
hdisk2 002b016f09313544 ppmvg active
bash-4.2#

bash-4.2# lsvg -p rootvg
rootvg:
PV_NAME PV STATE TOTAL PPs FREE PPs FREE DISTRIBUTION
hdisk1 active 546 187 10..00..00..85..92

bash-4.2# extendvg rootvg hdisk0
0516-1398 extendvg: The physical volume hdisk0, appears to belong to
another volume group. Use the force option to add this physical volume
to a volume group.
0516-792 extendvg: Unable to extend volume group.

bash-4.2# extendvg -f rootvg hdisk0

bash-4.2# lsvg -p rootvg
rootvg:
PV_NAME PV STATE TOTAL PPs FREE PPs FREE DISTRIBUTION
hdisk1 active 546 187 10..00..00..85..92
hdisk0 active 546 546 110..109..109..109..109

bash-4.2# mirrorvg rootvg hdisk0
0516-1804 chvg: The quorum change takes effect immediately.
0516-1296 lresynclv: Unable to completely resynchronize volume.
The logical volume has bad-block relocation policy turned off.
This may have caused the command to fail.
0516-934 /usr/sbin/syncvg: Unable to synchronize logical volume hd5.
0516-934 /usr/sbin/syncvg: Unable to synchronize logical volume hd2.
0516-934 /usr/sbin/syncvg: Unable to synchronize logical volume dppmiaslv.
0516-934 /usr/sbin/syncvg: Unable to synchronize logical volume data01lv.
0516-932 /usr/sbin/syncvg: Unable to synchronize volume group rootvg.
0516-1126 mirrorvg: rootvg successfully mirrored, user should perform
bosboot of system to initialize boot records. Then, user must modify
bootlist to include: hdisk1 hdisk0.

bash-4.2# bosboot -ad /dev/hdisk0

bosboot: Boot image is 55324 512 byte blocks.

bash-4.2# bootlist -m normal -o
hdisk1 pathid=0

bash-4.2# bootlist -m normal hdisk1 hdisk0

bash-4.2# bootlist -m normal -o
hdisk1 blv=hd5 pathid=0
hdisk0 blv=hd5 pathid=0

bash-4.2# lspv
hdisk0 002b012f397c20ce rootvg active
hdisk1 002afe4f2b4c3fdb rootvg active
hdisk2 002b016f09313544 ppmvg active

To verify, rootvg is mirrored. We should have a 1:2 ratio between LP and PP except for the dumpdevices, like this.

bash-4.2# lsvg -l rootvg
rootvg:
LV NAME TYPE LPs PPs PVs LV STATE MOUNT POINT
hd5 boot 1 2 2 closed/stale N/A
hd6 paging 2 4 2 open/syncd N/A
hd8 jfs2log 1 2 2 open/syncd N/A
hd4 jfs2 2 4 2 open/syncd /
hd2 jfs2 10 20 2 open/stale /usr
hd9var jfs2 1 2 2 open/syncd /var
hd3 jfs2 13 26 2 open/syncd /tmp
hd1 jfs2 1 2 2 open/syncd /home
hd10opt jfs2 1 2 2 open/syncd /opt
hd11admin jfs2 1 2 2 open/syncd /admin
fwdump jfs2 2 4 2 open/syncd /var/adm/ras/platform
lg_dumplv sysdump 4 4 1 open/syncd N/A
dppmiaslv jfs2 120 240 2 open/stale /dppmias
data01lv jfs2 200 400 2 open/stale /data01

And we want to see exactly where a LV is mirrored:-

bash-4.2# lslv -m hd2
hd2:/usr
LP PP1 PV1 PP2 PV2 PP3 PV3
0001 0222 hdisk1 0223 hdisk0
0002 0228 hdisk1 0224 hdisk0
0003 0229 hdisk1 0225 hdisk0
0004 0230 hdisk1 0226 hdisk0
0005 0231 hdisk1 0227 hdisk0
0006 0232 hdisk1 0228 hdisk0
0007 0523 hdisk1 0229 hdisk0
0008 0524 hdisk1 0230 hdisk0
0009 0525 hdisk1 0231 hdisk0
0010 0527 hdisk1 0232 hdisk0

Now, check your bootlist. Does it have both physical disks in the bootlist or not.

bash-4.2# bootlist -m normal -o
hdisk1 blv=hd5 pathid=0
hdisk0 blv=hd5 pathid=0

IBM AIX LPAR & VIO Commands

Sorry for unstructured post….

mkvdev -vdev hdisk1 -vadapter vhost0 -dev rootvgos

 

mkvdev -vdev Client3_OSLV -vadapter vhost0 -dev Client3_rootvg

 

mkvdev -vdev Client4_OSLV -vadapter vhost1 -dev Client4_rootvg

 

mkvdev -vdev Client3_dataLV -vadapter vhost0 -dev Client3_datavg

 

mkvdev -vdev Client4_dataLV -vadapter vhost1 -dev Client4_datavg

 

 

lsmap -vadapter vhost0

 

 

rmvdev  -vtd rootvgos

 

loadopt -f -vtd vtopt0 -disk nimserver.vol1

unloadopt -vtd vtopt0

 

 

mkvg -s 1024 -y datavg hdisk1

 

mklv -t jfs2 -y data01lv datavg 510

mklv -t jfs2 -y data02lv datavg 510

 

crfs -v jfs2 -d data01lv -m /data01 -A yes

crfs -v jfs2 -d data02lv -m /data02 -A yes

 

chown -R oracle:dba /data01

chown -R oracle:dba /data02

chmod -R 775 /data01

chmod -R 775 /data02

 

mklv -t jfs2 -y LPAR3_OSLV rootvg 400

 

mkvg -s 1024 -y lparosvg hdisk1

 

mklv -t jfs2 -y LPAR3_OSLV lparosvg 30

mklv -t jfs2 -y LPAR4_OSLV lparosvg 30

mklv -t jfs2 -y LPAR5_OSLV lparosvg 30

mklv -t jfs2 -y LPAR6_OSLV lparosvg 30

mklv -t jfs2 -y LPAR7_OSLV lparosvg 30

mklv -t jfs2 -y LPAR8_OSLV lparosvg 30

mklv -t jfs2 -y LPAR9_OSLV lparosvg 30

mklv -t jfs2 -y LPAR10_OSLV lparosvg 30

 

mkvdev -vdev LPAR3_OSLV -vadapter vhost0 -dev LPAR3_OS

mkvdev -vdev LPAR4_OSLV -vadapter vhost1 -dev LPAR4_OS

mkvdev -vdev LPAR5_OSLV -vadapter vhost2 -dev LPAR5_OS

mkvdev -vdev LPAR6_OSLV -vadapter vhost3 -dev LPAR6_OS

mkvdev -vdev LPAR7_OSLV -vadapter vhost4 -dev LPAR7_OS

mkvdev -vdev LPAR8_OSLV -vadapter vhost5 -dev LPAR8_OS

mkvdev -vdev LPAR9_OSLV -vadapter vhost6 -dev LPAR9_OS

mkvdev -vdev LPAR10_OSLV -vadapter vhost7 -dev LPAR10_OS

 

rmvdev -vtd LPAR3_OS

rmvdev -vtd LPAR4_OS

rmvdev -vtd LPAR5_OS

rmvdev -vtd LPAR6_OS

rmvdev -vtd LPAR7_OS

rmvdev -vtd LPAR8_OS

rmvdev -vtd LPAR9_OS

rmvdev -vtd LPAR10_OS

 

mklv -t jfs2 -y LPAR3_OSLV lparosvg 50

mklv -t jfs2 -y LPAR4_OSLV lparosvg 50

mklv -t jfs2 -y LPAR5_OSLV lparosvg 50

mklv -t jfs2 -y LPAR6_OSLV lparosvg 50

mklv -t jfs2 -y LPAR7_OSLV lparosvg 50

mklv -t jfs2 -y LPAR8_OSLV lparosvg 50

mklv -t jfs2 -y LPAR9_OSLV lparosvg 50

mklv -t jfs2 -y LPAR10_OSLV lparosvg 50

 

 

rmdev -dl en0

rmdev -dl et0

rmdev -dl ent0

 

rmdev -dl en1

rmdev -dl et1

rmdev -dl ent1

 

rmdev -dl en2

rmdev -dl et2

rmdev -dl ent2

 

rmdev -dl en3

rmdev -dl et3

rmdev -dl ent3

 

rmdev -dl en4

rmdev -dl et4

rmdev -dl ent4

 

rmdev -dl en5

rmdev -dl et5

rmdev -dl ent5

 

rmdev -dl en6

rmdev -dl et6

rmdev -dl ent6

 

rmdev -dl en7

rmdev -dl et7

rmdev -dl ent7

 

rmdev -dl en8

rmdev -dl et8

rmdev -dl ent8

 

rmdev -dl en9

rmdev -dl et9

rmdev -dl ent9

 

rmdev -dl en10

rmdev -dl et10

rmdev -dl ent10

 

rmdev -dl en11

rmdev -dl et11

rmdev -dl ent11

 

rmdev -dl en9

rmdev -dl et9

rmdev -dl ent9

 

 

mkvdev -vdev LPAR3_OSLV -vadapter vhost0 -dev LPAR3_OS

 

 

mkvdev -sea ent0 -vadapter ent4 -default ent4 -defaultid 1 -attr ha_mode=auto ctl_chan=ent5

 

 

netstat -v | grep Speed

 

mkvdev -lnagg ent0 ent4

 

mkvdev -sea ent10 -vadapter ent8 -default ent8 -defaultid 1

 

rmfs /dev/fsfslv00

rmfs /dev/fsfslv01

rmfs /dev/fslv00

rmfs /dev/fsfslv03

 

 

ntpdate -d 10.0.50.14

 

lsnports

 

 

vfcmap -vadapter vfchost0 -fcp fcs0

vfcmap -vadapter vfchost1 -fcp fcs0

vfcmap -vadapter vfchost2 -fcp fcs0

vfcmap -vadapter vfchost3 -fcp fcs0

vfcmap -vadapter vfchost4 -fcp fcs0

vfcmap -vadapter vfchost5 -fcp fcs0

vfcmap -vadapter vfchost6 -fcp fcs0

vfcmap -vadapter vfchost7 -fcp fcs0

 

 

vfcmap -vadapter vfchost8 -fcp fcs2

vfcmap -vadapter vfchost9 -fcp fcs2

vfcmap -vadapter vfchost10 -fcp fcs2

vfcmap -vadapter vfchost11 -fcp fcs2

vfcmap -vadapter vfchost12 -fcp fcs2

vfcmap -vadapter vfchost13 -fcp fcs2

vfcmap -vadapter vfchost14 -fcp fcs2

vfcmap -vadapter vfchost15 -fcp fcs2

 

 

 

 

ls -ltr /etc/init.ohasd

ls -l /etc/rc.d/rc2.d/*ohasd

ls -l /etc/ohasd

rm -rf /etc/rc.d/rc2.d/K19ohasd

rm -rf /etc/rc.d/rc2.d/S96ohasd

rm -rf /etc/init.ohasd

rm -rf /etc/init.ohasd

rmitab “h1”

rm /etc/ohasd

errclear 0

mv /etc/log/HostIdFile.txt /etc/log/HostIdFile.txt.old

 

 

errclear 0

cat /etc/log/HostIdFile.txt

lsfs

rmfs /dev/fslv00

lsfs

 

mkrep -sp rootvg -size 8G

 

cd /var/vio/VMLibrary/

 

 

 

Etherchannel with SEA

DanielJMartin | Mar 21 2012 | Comments (2) | Visits (4030)

0 people like this

 

inShare

Configuring your SEA with Etherchannel.

 

First check the shared virtual ethernet adapters you have –

 

netstat -v | grep Speed

 

mkvdev -lnagg ent0 ent4

 

# lsmap -all -net

SVEA   Physloc

—— ——————————————–

ent3   U9117.MMB.101697P-V1-C2-T1

 

SEA                 NO SHARED ETHERNET ADAPTER FOUND

 

Then we need to check what adapters we can use, now in our case we will be using the first 2 adapters from a dual port 1Gb card –

 

# lsdev -type adapter

name             status      description

ent0             Available   2-Port 10/100/1000 Base-TX PCI-Express Adapter (14104003)

ent1             Available   2-Port 10/100/1000 Base-TX PCI-Express Adapter (14104003)

 

Then we need to create the Etherchannel device –

 

# mkvdev -lnagg ent0 ent1

ent2 Available

 

This creates the device in standard mode, though you can switch it over to round robin –

 

# chdev -l ent2 -a mode=round_robin

 

Then we can create a SEA “bridge” between the physical Etherchannel device ent2 and the virtual ent3

 

# mkvdev -sea ent2 -vadapter ent3 -default ent3 -defaultid  1

main:  86 Recived SEA events bytes 163

ent9 Available

 

Once that is done, you can set-up initial TCP/IP config (en9 is the interface for the SEA ent9)

 

# mktcpip -hostname <vio-name> -inetaddr <ip-address> -interface en9 -start -netmask <subnet> -gateway <gateway-ip>

 

Now your server ready to go.

 

Enter Number of Running Partition (q to quit): 10

10

Opening Virtual Terminal On Partition VIO-Server2 . . .

 

 

Open in progress

 

Open Completed.

ok

0 > show-devs

000000c95568: /ibm,serial

000000c96690: /chosen

000000c969c0: /packages

000000c96ab8:   /disassembler

000000c9ce90:   /assembler

000000cc76a0:   /dev-tree

000000cc7e60:   /lpevents

000000ccec08:   /fabric-mgr

000000ce51f8:   /deblocker

000000ce6330:   /disk-label

000000ceb528:   /tape-label

000000cec240:   /obp-tftp

000000cfd688:   /ipv4

000000d045e8:   /ipv6

000000d0bec8:   /udp

000000d12d10:   /tcp

000000d1a150:   /ping

000000d21f18:   /bootp

000000d2b580:   /dhcp

000000d37728:   /tftp

000000d41ab0:   /iscsi

000000d49270:   /gscsi

000000d4ede0:     /disk

000000d50c70:     /tape

000000d527d8:   /iptest

000000d582f8:   /prep-boot

000000d58b88:   /fat-files

000000d5af30:   /iso-13346-files

000000d647d8:   /gen-iso-13346-files

000000d6d6a8:   /utilities

000000d9abc8:     /trace

000000da7388:   /net

000000daf358:   /iso-9660-files

000000db07a0:   /boot-mgr

000000dc1960:   /chrp-loader

000000dc1b40:   /pe-loader

000000dc2630:   /elf-loader

000000dc5e68:   /nls-support

000000dc6c60:   /cas

000000dc9790:   /terminal-emulator

000000dc9888:   /dynamic-reconfig

000000ea2e00:   /gui

000000ec5010:     /iscsi

000000ed7888:   /post

000000caf6c8: /options

000000cb1068: /cpus

000000cb6c88:   /PowerPC,POWER7@0

000000cb80b0:   /l2-cache@200a

000000cb84a8:   /l3-cache@310a

000000cb8bf0: /memory@0

000000cc1ed0: /ibm,dynamic-reconfiguration-memory

000000cc25a8: /aliases

000000ce3c18: /openprom

000000dc9e80: /event-sources

000000dcbc80:   /epow-events

000000dcbdf0: /interrupt-controller@0

000000dcd860: /interrupt-controller@800000025000202

000000dd1df0: /interrupt-controller@800000025000205

000000dd6380: /rtas

000000ddfd90: /vdevice

000000de6350:   /vty@30000000

000000de7b38:   /l-lan@3000000c

000000df02b0:   /v-scsi-host@30000020

000000df0ea8:   /vfc-server@30000022

000000df1dc8:   /v-scsi-host@3000002a

000000df29c0:   /vfc-server@3000002c

000000df38e0:   /v-scsi-host@30000034

000000df44d8:   /vfc-server@30000036

000000df53f8:   /v-scsi-host@3000003e

000000df5ff0:   /vfc-server@30000040

000000df6f10:   /v-scsi-host@30000048

000000df7b08:   /vfc-server@3000004a

000000df8a28:   /v-scsi-host@30000052

000000df9620:   /vfc-server@30000054

000000dfa540:   /v-scsi-host@3000005c

000000dfb138:   /vfc-server@3000005e

000000dfc058:   /v-scsi-host@30000066

000000dfcc50:   /vfc-server@30000068

000000e033a0:   /IBM,sp@4000

000000e04310:   /rtc@4001

000000e04c20:   /nvram@4002

000000e04f10:   /gscsi@4004

000000e05808:     /disk

000000e14ba8: /pci@800000020000202

000000e32798:   /fibre-channel@0

000000e47448:     /fp

000000e47fa8:     /disk

000000e49b48:     /tape

000000e4afc8:   /fibre-channel@0,1

000000e5fc78:     /fp

000000e607d8:     /disk

000000e62378:     /tape

000000e21900: /pci@800000020000205

000000e63888:   /ethernet@0

000000e72708:   /ethernet@0,1

000000e81588:   /ethernet@0,2

000000e90408:   /ethernet@0,3

ok

0 > 000000e32798 to active-package  ok

0 > pwd /pci@800000020000202/fibre-channel@0 ok

0 > ” /pci@800000020000202/fibre-channel@0″select-dev bad quoted string ok

0 > show-settings show-settings, unknown word ok

0 >   ok

0 >   ok

0 > ioinfo

 

!!! IOINFO: FOR IBM INTERNAL USE ONLY !!!

This tool gives you information about SCSI,IDE,SATA,SAS,and USB devices attached to the system

 

Select a tool from the following

 

1. SCSIINFO

2. IDEINFO

3. SATAINFO

4. SASINFO

5. USBINFO

6. FCINFO

7. VSCSIINFO

 

q – quit/exit

 

==> 6

 

 

 

FCINFO Main Menu

Select a FC Node from the following list:

#  Location Code                Pathname

—————————————————————

1. U78AB.001.WZSJZK6-P1-C3-T1     /pci@800000020000202/fibre-channel@0

2. U78AB.001.WZSJZK6-P1-C3-T2     /pci@800000020000202/fibre-channel@0,1

 

q – Quit/Exit

 

==> 1

 

FC Node Menu

FC Node String: /pci@800000020000202/fibre-channel@0

FC Node WorldWidePortName: 10000090fa42fb1a

—————————————————————–

1. List Attached FC Devices

2. Select a FC Device

3. Enable/Disable FC Adapter Debug flags

 

q – Quit/Exit

 

==> 2

 

NO FC DEVICES FOUND

 

Hit a key to continue…

 

FC Node Menu

FC Node String: /pci@800000020000202/fibre-channel@0

FC Node WorldWidePortName: 10000090fa42fb1a

—————————————————————–

1. List Attached FC Devices

2. Select a FC Device

3. Enable/Disable FC Adapter Debug flags

 

q – Quit/Exit

 

==> 1

 

NO FC DEVICES FOUND

 

Hit a key to continue…

 

FC Node Menu

FC Node String: /pci@800000020000202/fibre-channel@0

FC Node WorldWidePortName: 10000090fa42fb1a

—————————————————————–

1. List Attached FC Devices

2. Select a FC Device

3. Enable/Disable FC Adapter Debug flags

 

q – Quit/Exit

 

==> q

 

FCINFO Main Menu

Select a FC Node from the following list:

#  Location Code                Pathname

—————————————————————

1. U78AB.001.WZSJZK6-P1-C3-T1     /pci@800000020000202/fibre-channel@0

2. U78AB.001.WZSJZK6-P1-C3-T2     /pci@800000020000202/fibre-channel@0,1

 

q – Quit/Exit

 

==> 2

 

FC Node Menu

FC Node String: /pci@800000020000202/fibre-channel@0,1

FC Node WorldWidePortName: 10000090fa42fb1b

—————————————————————–

1. List Attached FC Devices

2. Select a FC Device

3. Enable/Disable FC Adapter Debug flags

 

q – Quit/Exit

 

==>

Lost connection to the Managed System…

Attempting to reconnect

 

The open failed.

-The session may already be open on another management console

-The server may not be ready to accept connections.

 

Attempts to open the session failed. Please close the terminal and retry the open at a later time.

If the problem persists, Please contact IBM support.

 

 

 

 

VIO1_82_Client3_fcs0

 

VNX5300_SPB0_UNIT2_VIO1_82_Client3_fcs0

 

VNX5300_SPB1_UNIT2_VIO2_82_Client3_fcs0

 

VNX5300_SPA0_UNIT2_VIO1_82_Client3_fcs0

 

VNX5300_SPA1_UNIT2_VIO2_82_Client3_fcs0

 

 

 

VNX5300_SPB0_UNIT2_VIO1_82_Client4_fcs0

 

VNX5300_SPB1_UNIT2_VIO2_82_Client4_fcs0

 

VNX5300_SPA0_UNIT2_VIO1_82_Client4_fcs0

 

VNX5300_SPA1_UNIT2_VIO2_82_Client4_fcs0

 

 

 

# lsdev -c adapter

ent0     Available 03-00 4-Port Gigabit Ethernet PCI-Express Adapter (e414571614102004)

ent1     Available 03-01 4-Port Gigabit Ethernet PCI-Express Adapter (e414571614102004)

ent2     Available 03-02 4-Port Gigabit Ethernet PCI-Express Adapter (e414571614102004)

ent3     Available 03-03 4-Port Gigabit Ethernet PCI-Express Adapter (e414571614102004)

ent4     Available       Virtual I/O Ethernet Adapter (l-lan)

ent5     Available       Virtual I/O Ethernet Adapter (l-lan)

ent6     Available       Shared Ethernet Adapter

fcs0     Available 04-00 8Gb PCI Express Dual Port FC Adapter (df1000f114108a03)

fcs1     Available 04-01 8Gb PCI Express Dual Port FC Adapter (df1000f114108a03)

pkcs11   Available       PKCS#11 Device

sissas0  Available 00-00 PCIe x4 Planar 3Gb SAS RAID Adapter

sissas1  Available 02-00 PCIe x4 Internal 3Gb SAS RAID Adapter

usbhc0   Available 05-08 USB Host Controller (33103500)

usbhc1   Available 05-09 USB Host Controller (33103500)

usbhc2   Available 05-0a USB Enhanced Host Controller (3310e000)

vfchost0 Available       Virtual FC Server Adapter

vfchost1 Available       Virtual FC Server Adapter

vfchost2 Available       Virtual FC Server Adapter

vfchost3 Available       Virtual FC Server Adapter

vfchost4 Available       Virtual FC Server Adapter

vfchost5 Available       Virtual FC Server Adapter

vfchost6 Available       Virtual FC Server Adapter

vfchost7 Available       Virtual FC Server Adapter

vhost0   Available       Virtual SCSI Server Adapter

vhost1   Available       Virtual SCSI Server Adapter

vhost2   Available       Virtual SCSI Server Adapter

vhost3   Available       Virtual SCSI Server Adapter

vhost4   Available       Virtual SCSI Server Adapter

vhost5   Available       Virtual SCSI Server Adapter

vhost6   Available       Virtual SCSI Server Adapter

vhost7   Available       Virtual SCSI Server Adapter

vsa0     Available       LPAR Virtual Serial Adapter

 

# hostname

nimserver

# lscfg -vpl fcs* | grep Z8

Device Specific.(Z8)……..C050760714500000

Device Specific.(Z8)……..C050760714500002

#

 

 

# hostname

AIXLPAR4-104-112

# lscfg -vpl fcs* | grep Z8

Device Specific.(Z8)……..C050760714500006

Device Specific.(Z8)……..C050760714500004

#

 

hostname

 

 

lscfg -vpl fcs* | grep Z8 | cut -d . -f10 |  sed ‘s/../&:/g;s/:$//’

 

lscfg -vpl fcs* | grep Z8 | cut -d . -f10 |  sed ‘s/../&:/g;s/:$//’;hostname

 

 

C0:50:76:07:14:50:00:00

C0:50:76:07:14:50:00:02

nimserver

#

C0:50:76:07:14:50:00:1E

C0:50:76:07:14:50:00:1C

AIXLPAR10-104-118

 

C0:50:76:07:14:50:00:18

C0:50:76:07:14:50:00:1A

AIXLPAR9-104-117

 

C0:50:76:07:14:50:00:16

C0:50:76:07:14:50:00:14

AIXLPAR8-104-116

#

C0:50:76:07:14:50:00:10

C0:50:76:07:14:50:00:12

AIXLPAR7-104-115

#

C0:50:76:07:14:50:00:0E

C0:50:76:07:14:50:00:0C

AIXLPAR6-104-114

#

C0:50:76:07:14:50:00:08

C0:50:76:07:14:50:00:0A

AIXLPAR5-104-113

#

 

C0:50:76:07:14:50:00:06

C0:50:76:07:14:50:00:04

AIXLPAR4-104-112

#

 

C0:50:76:07:14:50:00:00

C0:50:76:07:14:50:00:02

nimserver

#

 

 

 

lsdev -c adapter

 

lscfg -vpl fcs0

 

lscfg -vpl vfchost1

 

 

 

vfchost1         U8231.E2D.06C83FT-V1-C43  Virtual FC Server Adapter

 

Hardware Location Code……U8231.E2D.06C83FT-V1-C43

 

 

PLATFORM SPECIFIC

 

Name:  vfc-server

Node:  vfc-server@3000002b

Device Type:  fcp

Physical Location: U8231.E2D.06C83FT-V1-C43

# exit

$ vfcmap -vadpater vfchost1 -fcp fcs0

Option flag is not valid.

 

Usage: vfcmap  -vadapter VFCServerAdapter -fcp [FCPName]

 

$

$

 

lsnports

 

 

vfcmap -vadapter vfchost0 -fcp fcs0

vfcmap -vadapter vfchost1 -fcp fcs0

vfcmap -vadapter vfchost2 -fcp fcs0

vfcmap -vadapter vfchost3 -fcp fcs0

vfcmap -vadapter vfchost4 -fcp fcs0

vfcmap -vadapter vfchost5 -fcp fcs0

vfcmap -vadapter vfchost6 -fcp fcs0

vfcmap -vadapter vfchost7 -fcp fcs0

 

 

vfcmap -vadapter vfchost8 -fcp fcs2

vfcmap -vadapter vfchost9 -fcp fcs2

vfcmap -vadapter vfchost10 -fcp fcs2

vfcmap -vadapter vfchost11 -fcp fcs2

vfcmap -vadapter vfchost12 -fcp fcs2

vfcmap -vadapter vfchost13 -fcp fcs2

vfcmap -vadapter vfchost14 -fcp fcs2

vfcmap -vadapter vfchost15 -fcp fcs2

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

$ cfgdev

 

 

 

# lscfg -vpl ent4

ent4             U8231.E2D.06C83FT-V1-C11-T1  Virtual I/O Ethernet Adapter (l-lan)

 

Network Address………….D26D148F6F0B

Displayable Message………Virtual I/O Ethernet Adapter (l-lan)

Hardware Location Code……U8231.E2D.06C83FT-V1-C11-T1

 

 

PLATFORM SPECIFIC

 

Name:  l-lan

Node:  l-lan@3000000b

Device Type:  network

Physical Location: U8231.E2D.06C83FT-V1-C11-T1

# lscfg -vpl ent5

ent5             U8231.E2D.06C83FT-V1-C12-T1  Virtual I/O Ethernet Adapter (l-lan)

 

Network Address………….D26D148F6F0C

Displayable Message………Virtual I/O Ethernet Adapter (l-lan)

Hardware Location Code……U8231.E2D.06C83FT-V1-C12-T1

 

 

PLATFORM SPECIFIC

 

Name:  l-lan

Node:  l-lan@3000000c

Device Type:  network

Physical Location: U8231.E2D.06C83FT-V1-C12-T1

 

 

#  scp 10.1.50.101:/data03/Unix-Software-Repository/AIX/IBM-ISO/AIX7.1TL02/* .

The authenticity of host ‘10.1.50.101 (10.1.50.101)’ can’t be established.

RSA key fingerprint is f7:9d:58:29:9c:1e:13:44:b3:a7:d5:b4:57:d7:21:c8.

Are you sure you want to continue connecting (yes/no)? yes

Warning: Permanently added ‘10.1.50.101’ (RSA) to the list of known hosts.

root@10.1.50.101’s password:

Permission denied, please try again.

root@10.1.50.101’s password:

AIX_7.1_TL02_02_DVD1.iso                                                               100% 3658MB  42.0MB/s   01:27

AIX_7.1_TL02_02_DVD2.iso                                                               100% 2601MB  45.6MB/s   00:57

# exit

$ mkvdev -fbo -vadapter vhost

$ lsmap -all

SVSA            Physloc                                      Client Partition ID

————— ——————————————– ——————

vhost0          U8231.E2D.06C83FT-V1-C31                     0x00000000

 

VTD                   NO VIRTUAL TARGET DEVICE FOUND

 

SVSA            Physloc                                      Client Partition ID

————— ——————————————– ——————

vhost1          U8231.E2D.06C83FT-V1-C41                     0x00000000

 

VTD                   NO VIRTUAL TARGET DEVICE FOUND

 

SVSA            Physloc                                      Client Partition ID

————— ——————————————– ——————

vhost2          U8231.E2D.06C83FT-V1-C51                     0x0000000

VTD                   NO VIRTUAL TARGET DEVICE FOUND

 

SVSA            Physloc                                      Client Partition ID

————— ——————————————– ——————

vhost3          U8231.E2D.06C83FT-V1-C61                     0x00000000

 

VTD                   NO VIRTUAL TARGET DEVICE FOUND

 

SVSA            Physloc                                      Client Partition ID

————— ——————————————– ——————

vhost4          U8231.E2D.06C83FT-V1-C71                     0x00000000

 

VTD                   NO VIRTUAL TARGET DEVICE FOUND

 

SVSA            Physloc                                      Client Partition ID

————— ——————————————– ——————

vhost5          U8231.E2D.06C83FT-V1-C81                     0x00000000

 

VTD                   NO VIRTUAL TARGET DEVICE FOUND

 

SVSA            Physloc                                      Client Partition ID

————— ——————————————– ——————

vhost6          U8231.E2D.06C83FT-V1-C91                     0x00000000

 

VTD                   NO VIRTUAL TARGET DEVICE FOUND

 

SVSA            Physloc                                      Client Partition ID

————— ——————————————– ——————

vhost7          U8231.E2D.06C83FT-V1-C101                    0x00000000

 

VTD                   NO VIRTUAL TARGET DEVICE FOUND

 

$ mkvdev -fbo -vadapter vhost0

vtopt0 Available

$ lsmap -vadapter vhost0

SVSA            Physloc                                      Client Partition ID

————— ——————————————– ——————

vhost0          U8231.E2D.06C83FT-V1-C31                     0x00000000

 

VTD                   vtopt0

Status                Available

LUN                   0x8100000000000000

Backing device

Physloc

Mirrored              N/A

 

$ lsrep

Size(mb) Free(mb) Parent Pool         Parent Size      Parent Free

8158     1899 rootvg                   544768           506880

 

Name                                                  File Size Optical         Access

AIX_7.1_TL02_02_DVD1.iso                                   3658 None            rw

AIX_7.1_TL02_02_DVD2.iso                                   2601 None            rw

$ loadopt -vtd vtopt0 -disk AIX_7.1_TL02_02_DVD1.iso

$ lsmap -vadapter vhost0

SVSA            Physloc                                      Client Partition ID

————— ——————————————– ——————

vhost0          U8231.E2D.06C83FT-V1-C31                     0x00000000

 

VTD                   vtopt0

Status                Available

LUN                   0x8100000000000000

Backing device        /var/vio/VMLibrary/AIX_7.1_TL02_02_DVD1.iso

Physloc

Mirrored              N/A

 

$ lspv

NAME             PVID                                 VG               STATUS

hdisk0           00f8c83f2effbda1                     rootvg           active

hdisk1           none                                 None

$ mkvdev -vdev hdisk1 -vadapter vhost0 -dev rootvgos

rootvgos Available

Please reboot the client partition to see the newly added disk.

 

$ lsmap -vadapter vhost0

SVSA            Physloc       SVSA            Physloc                                      Client Partition ID

————— ——————————————– ——————

vhost0          U8231.E2D.06C83FT-V1-C31                     0x00000003

 

VTD                   rootvgos

Status                Available

LUN                   0x8200000000000000

Backing device        hdisk1

Physloc               U78AB.001.WZSJZK6-P1-C18-T1-LFF0100-L0

Mirrored              false

 

VTD                   vtopt0

Status                Available

LUN                   0x8100000000000000

Backing device        /var/vio/VMLibrary/AIX_7.1_TL02_02_DVD1.iso

Physloc

Mirrored              N/A

IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM

IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM

IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM

IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM

IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM

IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM

IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM

IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM

IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM

IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM

IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM

IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM IBM

1 = SMS Menu                          5 = Default Boot List

8 = Open Firmware Prompt              6 = Stored Boot List

Memory      Keyboard     Network     SCSI     Speaker  ok

0 >   ok

0 > ininfo ininfo, unknown word ok

0 > IOINFO

!!! IOINFO: FOR IBM INTERNAL USE ONLY !!!

This tool gives you information about SCSI,IDE,SATA,SAS,and USB devices attached to t

 

q – Quit/Exit

==> 1

FC Node Menu

FC Node String: /pci@800000020000202/fibre-channel@0

FC Node WorldWidePortName: 10000090fa42f3cc

—————————————————————–

1. List Attached FC Devices

2. Select a FC Device

3. Enable/Disable FC Adapter Debug flags

q – Quit/Exit

==> 2

NO FC DEVICES FOUND

Hit a key to continue…

FC Node Menu

FC Node String: /pci@800000020000202/fibre-channel@0

FC Node WorldWidePortName: 10000090fa42f3cc

 

 

FCINFO Main Menu

Select a FC Node from the following list:

#  Location Code                Pathname

—————————————————————

1. U78AB.001.WZSJZJ5-P1-C3-T1     /pci@800000020000202/fibre-channel@0

2. U78AB.001.WZSJZJ5-P1-C3-T2     /pci@800000020000202/fibre-channel@0,1

q – Quit/Exit

==> 2

Cannot Init Link.

FC Node Menu

FC Node String: /pci@800000020000202/fibre-channel@0,1

FC Node WorldWidePortName: 10000090fa42f3cd

—————————————————————–

1. List Attached FC Devices

2. Select a FC Device

3. Enable/Disable FC Adapter Debug flags

q – Quit/Exit

==>  2

 

 

 

 

 

 

 

How to Rescan new LUN’s added in Linux, HP-UX, Aix, Solaris ?

HP-UX

1. Rescan the devices:

ioscan -fnC <disk|tape>

2. Generate device files:

 insf -e

3. Verify the new devices:

 ioscan -funC <disk|tape>

AIX

1. Rescan the devices ):

 cfgmgr -vl fcsx

Where x is FC adapter number

2. Verify the new devices:

 lsdev -Cc <disk|tape>

Linux

The rescan in Linux is HBA-specific.

For QLogic:

echo scsi-qlascan > /proc/scsi/qla<model#>/<adapter instance>

For Emulex:

 sh force_lpfc_scan.sh lpfc<adapter-instance>

For each identified device, run the following:

echo scsi add-single-device <host> <channel> <ID> <lun> >   /proc/scsi/scsi

Solaris

1. Determine the FC channels:

 cfgadm -al

2. Force rescan :

 cfgadm -o force_update -c configure cx

Where x is the FC channel number

3. Force rescan at HBA port level:

 luxadm -e forcelip /dev/fc/fpx

4. Force rescan on all FC devices:

 cfgadm -al -o show_FCP_dev

5. Install device files:

 devfsadm

6. Display all Qlogic HBA ports

 luxadm -e port

7. Display HBA port information

 luxadm -v display <WWPN>

8. Display HBA port information

 luxadm -e dump_map

Notes If one specific SANclient is missing a drive, please verify that your zoning is correct. Please also make sure the host initiator and VTL™s target ports are showing online via the Fibre Channel switch. (Check HBA link light and check the cable.)

 

Aix using mkcd and creating a bootable ISO image from mksysb images

Create an ISO image of AIXLPAR2 from an existing mksysb file. I had already created a mksysb file of AIXLPAR2 in /usr/sap/put/AIXLPAR2-mksysb.

root@AIXLPAR2 /usr/sap/put # mkcd -L -S -I /usr/sap/put/image -m /usr/sap/put/AIXLPAR2-mksysb

Initializing mkcd log: /var/adm/ras/mkcd.log…

Verifying command parameters…

Creating temporary file system: /mkcd/cd_fs…

Populating the CD or DVD file system…

Building chrp boot image…

Copying backup to the CD or DVD file system…

Creating Rock Ridge format image: /usr/sap/put/image/cd_image_712892

Running mkisofs …

….

mkrr_fs was successful.

Making the CD or DVD image bootable…

Removing temporary file system: /mkcd/cd_fs…

root@AIXLPAR2 /usr/sap/put # ls -ltr

total 4369112

drwxr-xr-x    2 root     system          256 Aug 20 10:31 lost+found

-rw-r–r–    1 root     system   2236979200 Dec 10 09:16 AIXLPAR2-mksysb

drwxr-xr-x    2 root     system          256 Dec 10 09:23 image

– Confirm the ISO image has been created.

root@AIXLPAR2 /usr/sap/put # cd image

root@AIXLPAR2 /usr/sap/put/image # ls -ltr

total 4483256

-rw-r–r–    1 root     system   2295425024 Dec 10 09:24 cd_image_712892

 – Copy the image to the VIOS virtual media library directory.

 # df -m .

Filesystem    MB blocks      Free %Used    Iused %Iused Mounted on

/dev/VMLibrary_LV   7168.00   2768.93   62%        6     1% /var/vio/VMLibrary

# scp 10.X.X.X:/usr/sap/put/image/cd_image_712892 .

root@10.X.X.X’s password:

cd_image_712892                               100% 2189MB  40.5MB/s   00:54

 

# ls -ltr

total 13432312

drwxr-xr-x    2 root     system          256 Dec 03 11:08 lost+found

-rw-r–r–    1 root     staff    3857645568 Dec 04 08:53 AIX61_DVD_1.iso

-rw-r–r–    1 root     staff     724271104 Dec 04 10:09 AIX61_DVD_2.iso

-rw-r–r–    1 root     staff    2295425024 Dec 10 09:33 cd_image_712892

– Rename the image to a more meaningful name.

# mv cd_image_712892 AIXLPAR2_mksysb.iso

# ls -ltr

total 13432312

drwxr-xr-x    2 root     system          256 Dec 03 11:08 lost+found

-rw-r–r–    1 root     staff    3857645568 Dec 04 08:53 AIX61_DVD_1.iso

-rw-r–r–    1 root     staff     724271104 Dec 04 10:09 AIX61_DVD_2.iso

-rw-r–r–    1 root     staff    2295425024 Dec 10 09:33 AIXLPAR2_mksysb.iso

– Map a virtual optical device to the client LPAR.

$ lsmap –vadapter vhost1

SVSA            Physloc                                      Client Partition ID

————— ——————————————– ——————

vhost1          U7998.61X.10071DA-V1-C13                     0x00000000

VTD                   vtscsi3

Status                Available

LUN                   0x8100000000000000

Backing device        lp2vd1

Physloc

$ mkvdev -fbo -vadapter vhost1

vtopt0 Available

 

$ lsmap –vadapter vhost1

SVSA            Physloc                                      Client Partition ID

————— ——————————————– ——————

vhost1          U7998.61X.10071DA-V1-C13                     0x00000000

 

VTD                   vtopt0

Status                Available

LUN                   0x8200000000000000

Backing device

Physloc

 

VTD                   vtscsi3

Status                Available

LUN                   0x8100000000000000

Backing device        lp2vd1

Physloc

 

$ lsrep

Size(mb) Free(mb) Parent Pool         Parent Size      Parent Free

7139      579 rootvg                   139776            57344

 

Name                                    File Size Optical         Access

AIX61_DVD_1.iso                              3679 None            rw

AIX61_DVD_2.iso                               691 None            rw

AIXLPAR2_mksysb.iso                           2190 None            rw

 

$ loadopt -f -vtd vtopt0 -disk AIXLPAR2_mksysb.iso

 

$ lsmap -vadapter vhost1

SVSA            Physloc                                      Client Partition ID

————— ——————————————– ——————

vhost1          U7998.61X.10071DA-V1-C13                     0x00000000

 

VTD                   vtopt0

Status                Available

LUN                   0x8200000000000000

Backing device        /var/vio/VMLibrary/AIXLPAR2_mksysb.iso

Physloc

 

VTD                   vtscsi3

Status                Available

LUN                   0x8100000000000000

Backing device        lp2vd1

Physloc

– Boot the LPAR from the virtual “SCSI CD” and install the image as “normal”.

How to get the Network Card speed on AIX

There are several ways to get this info.

# netstat -v | grep Speed
Media Speed Selected: Auto negotiation
Media Speed Running: 1000 Mbps Full Duplex
Media Speed Selected: Auto negotiation
Media Speed Running: 1000 Mbps Full Duplex

# entstat -d en0

#for en in `netstat -i | grep en | awk ‘{print $1}’ | sort -u | cut -c3`
>do
> adapter=`echo ent${en}`
> entstat -d ${adapter} | grep “Media Speed”
>done

To Change the Network Card speed on AIX –

#chdev -l en0 -a state=detach –> Detach the interface

#chdev -l ent0 -a media_speed=1000_Full_Duplex –> Make appropriate changes

#chdev -l en0 -a state=up –> Change the step to UP

[NOTE: Don’t do ifconfig enX up – this will put an IP address of 0.0.0.0]

#mkdev -l inet0 –> to activate all routes

Hope this will be helpful.

EMC and MPIO in AIX

You can run into an issue with EMC storage on AIX systems using MPIO (No Powerpath) for your boot disks:

After installing the ODM_DEFINITONS of EMC Symmetrix on your client system, the system won’t boot any more and will hang with LED 554 (unable to find boot disk).

The boot hang (LED 554) is not caused by the EMC ODM package itself, but by the boot process not detecting a path to the boot disk if the first MPIO path does not corresponding to the fscsiX driver instance where all hdisks are configured. Let me explain that more in detail:

Let’s say we have an AIX system with four HBAs configured in the following order:

# lscfg -v | grep fcs
fcs2 (wwn 71ca) -> no devices configured behind this fscsi2 driver instance (path only configured in CuPath ODM table)
fcs3 (wwn 71cb) -> no devices configured behind this fscsi3 driver instance (path only configured in CuPath ODM table)
fcs0 (wwn 71e4) -> no devices configured behind this fscsi0 driver instance (path only configured in CuPath ODM table)
fcs1 (wwn 71e5) -> ALL devices configured behind this fscsi1 driver instance

Looking at the MPIO path configuration, here is what we have for the rootvg disk:

# lspath -l hdisk2 -H -F”name parent path_id connection status”
name   parent path_id connection                      status
hdisk2 fscsi0 0       5006048452a83987,33000000000000 Enabled
hdisk2 fscsi1 1       5006048c52a83998,33000000000000 Enabled
hdisk2 fscsi2 2       5006048452a83986,33000000000000 Enabled
hdisk2 fscsi3 3       5006048c52a83999,33000000000000 Enabled

The fscsi1 driver instance is the second path (pathid 1), then remove the 3 paths keeping only the path corresponding to fscsi1 :

# rmpath -l hdisk2 -p fscsi0 -d
# rmpath -l hdisk2 -p fscsi2 -d
# rmpath -l hdisk2 -p fscsi3 -d
# lspath -l hdisk2 -H -F”name parent path_id connection status”

Afterwards, do a savebase to update the boot lv hd5. Set up the bootlist to hdisk2 and reboot the host.

It will come up successfully, no more hang LED 554.

When checking the status of the rootvg disk, a new hdisk10 has been configured with the correct ODM definitions as shown below:

# lspv
hdisk10 0003027f7f7ca7e2 rootvg active
# lsdev -Cc disk
hdisk2 Defined   00-09-01 MPIO Other FC SCSI Disk Drive
hdisk10 Available 00-08-01 EMC Symmetrix FCP MPIO Raid6

To summarize, it is recommended to setup ONLY ONE path when installing an AIX to a SAN disk, then install the EMC ODM package then reboot the host and only after that is complete, add the other paths. Dy doing that we ensure that the fscsiX driver instance used for the boot process has the hdisk configured behind.

Configuring MPIO

Use the Following steps to set up the scenario:

  1. Create two Virtual I/O server partition and them VIO_Server1 and VIO_Server2. Creating virtual I/O server partition Select one Fiber Channel adapter in addition to the physical adapter.
  2. Install the both VIO Servers using CD or NIM server.
  3. Change the fc_err_recov to fast fail and dyntrk to yes attributes on the Fibre Channel adapters.

lsdev –type adapter command to find the number of channel adapter.

$ chdev -dev fscsi0 -attr fc_err_recov=fast_fail dyntrk=yes –perm

fscsi0 changed

$ lsdev -dev fscsi0 -attr

attribute value description

user_settable

attach switch How this adapter is CONNECTED False

dyntrk yes Dynamic Tracking of FC Devices True

fc_err_recov fast_fail FC Fabric Event Error RECOVERY Policy True

scsi_id 0x660c00 Adapter SCSI ID False

sw_fc_class 3 FC Class for Fabric True

Important: If you have two or more Fibre Channel adapters per Virtual I/O

Server you have to change the attributes for each of them.

  1. Reboot the VIO Servers for the changes to the Fibre Channel devices to take effect.
  2. Create the Client partition Shows the required virtual SCSI adapters based on the configuration shown in following Chart
VIO Server VIO Server Slot Client Partition Client Slot
VIO_Server1 30 DB_Server 21
VIO_Server1 40 Apps_Server 21
VIO_Server2 30 DB_Server 22
VIO_Server2 40 Apps_Server 22
  1. Also add two virtual Ethernet adapters to each client to provide the highly available network access. One adapter if you plan on using SEA failover for network redundancy.
  2. On VIO_Server1 and VIO_Server2 use the fget_config command to get the LUN to hdisk mappings.

# fget_config -vA

—dar0—

User array name = ‘FAST200’

dac0 ACTIVE dac1 ACTIVE

Disk DAC LUN Logical Drive

utm 1

hdisk0 dac1 0 1

hdisk1 dac0 2 2

hdisk2 dac0 3 4

hdisk3 dac1 4 3

hdisk4 dac1 5 5

hdisk5 dac0 6 6

You can also use the lsdev -dev hdiskn -vpd command, where n is the hdisk number, to retrieve this information

  1. The disk are to be accessed though both VIO Servers. The reserve_policy for each disk must be set to no_reserve on VIO_Server1 and VIO_Server2.

$ chdev -dev hdisk2 -attr reserve_policy=no_reserve

hdisk2 changed

$ chdev -dev hdisk3 -attr reserve_policy=no_reserve

hdisk3 changed

9. Check using the lsdev command, to make sure reserve_policy attribute is

now set to no_reserve

$ lsdev -dev hdisk2 -attr

attribute value description

user_settable

PR_key_value none Persistant Reserve Key Value True

cache_method fast_write Write Caching method False

ieee_volname 600A0B8000110D0E0000000E47436859 IEEE Unique volume name False

lun_id 0x0003000000000000 Logical Unit Number False

max_transfer 0x100000 Maximum TRANSFER Size True

prefetch_mult 1 Multiple of blocks to prefetch on read False

pvid none Physical volume identifier False

q_type simple Queuing Type False

queue_depth 10 Queue Depth True

raid_level 5 RAID Level False

reassign_to 120 Reassign Timeout value True

reserve_policy no_reserve Reserve Policy True

rw_timeout 30 Read/Write Timeout value True

scsi_id 0x660a00 SCSI ID False

size 20480 Size in Mbytes False

write_cache yes Write Caching enabled False

10.Double check both Virtual I/O Servers that the vhost adapters have the correct slot numbers by running the lsmap -all command.

11.Map the hdisks to the vhost adapters using the mkvdev command

$ mkvdev -vdev hdisk2 -vadapter vhost0 -dev app_server

app_server Available

$ mkvdev -vdev hdisk3 -vadapter vhost1 -dev db_server

db_server Available

12. Install the AIX OS in client partitions.

Configuring MPIO in the client partitions

  1. Check the MPIO configuration by running the commands shown in

# lspv

# lsdev -Cc disk

hdisk0 Available Virtual SCSI Disk Drive

  1. Run the lspath command to verify that the disk is attached using two different paths. shows hat hdisk0 is attached using the VSCSI0 and VSCSI1 adapter that point to different Virtual I/O servers. Both Virtual I/O Servers are up and running. Both paths are enabled.

# lspath

Enabled hdisk0 vscsi0

Enabled hdisk0 vscsi1

  1. Enable the health check mode for the disk so that the status of the disks is automatically updated

# chdev -l hdisk0 -a hcheck_interval=20 -P

hdisk0 changed

Aix : Grow / expand your rootvg on the fly (from 6.1 TL 4)

Increase rootvg dynamically


If your rootvg “disk” is actually virtual, such as a SAN LUN or a logical volume on the VIO server, then it usually can be expanded on the SAN (or using extendlv on the VIOS) and then recognised on the AIX LPAR using the -g flag of the chvg command:

chvg -g rootvg


Note: this is supported for rootvg and concurrent vgs from AIX 6.1 TL 4. See IBM technote IZ80021 http://bit.ly/cmHjmy

Resizing the rootvg disk

I tried to increase rootvg on an LPAR running AIX 5.3 TL 11 and hit the following error:

aix53_lpar # chvg -g rootvg

0516-1380 chvg: Re-sizing of the disks is not supported for the rootvg.

0516-732 chvg: Unable to change volume group rootvg.

Looks like the volume group needed to be varied off and varied on again. For rootvg, that means a reboot.

No reboot on AIX 6.1

In AIX 6.1 (from TL 4 – use oslevel -s to check your AIX level), you can increase rootvg on the fly.

aix61_lpar:/# chvg -g rootvg

0516-1164 chvg: Volume group rootvg changed.  With given characteristics rootvg can include up to 16 physical volumes with 2032 physical partitions each.

Example :

bash-3.2# lsvg rootvg
VOLUME GROUP:       rootvg                   VG IDENTIFIER:  00f8c83f00004c00000001436bebe1dd
VG STATE:           active                   PP SIZE:        256 megabyte(s)
VG PERMISSION:      read/write               TOTAL PPs:      119 (30464 megabytes)
MAX LVs:            256                      FREE PPs:       16 (4096 megabytes)
LVs:                12                       USED PPs:       103 (26368 megabytes)
OPEN LVs:           11                       QUORUM:         2 (Enabled)
TOTAL PVs:          1                        VG DESCRIPTORS: 2
STALE PVs:          0                        STALE PPs:      0
ACTIVE PVs:         1                        AUTO ON:        yes
MAX PPs per VG:     32512
MAX PPs per PV:     1016                     MAX PVs:        32
LTG size (Dynamic): 512 kilobyte(s)          AUTO SYNC:      no
HOT SPARE:          no                       BB POLICY:      relocatable
PV RESTRICTION:     none                     INFINITE RETRY: no
bash-3.2# chvg -g rootvg
bash-3.2# lsvg rootvg
VOLUME GROUP:       rootvg                   VG IDENTIFIER:  00f8c83f00004c00000001436bebe1dd
VG STATE:           active                   PP SIZE:        256 megabyte(s)
VG PERMISSION:      read/write               TOTAL PPs:      199 (50944 megabytes)
MAX LVs:            256                      FREE PPs:       96 (24576 megabytes)
LVs:                12                       USED PPs:       103 (26368 megabytes)
OPEN LVs:           11                       QUORUM:         2 (Enabled)
TOTAL PVs:          1                        VG DESCRIPTORS: 2
STALE PVs:          0                        STALE PPs:      0
ACTIVE PVs:         1                        AUTO ON:        yes
MAX PPs per VG:     32512
MAX PPs per PV:     1016                     MAX PVs:        32
LTG size (Dynamic): 512 kilobyte(s)          AUTO SYNC:      no
HOT SPARE:          no                       BB POLICY:      non-relocatable
PV RESTRICTION:     none                     INFINITE RETRY: no
bash-3.2# oslevel -s
7100-02-02-1316
bash-3.2#