======AIX - Souborove systemy, LVM, disky, ...======
[[#soubory|Pristupy k souborum]]\\
[[#FS|FS]]\\
[[#LV|LV]]\\
[[#VG|VG]]\\
[[#PV|PV]]\\
[[#disky|informace o fyzickych discich]]\\
[[#tape|Magneticke pasky]]\\
[[#CD|CD/DVD]]\\
[[#PS|Paging space]]\\
[[#dos|dos]]\\
[[#backup|zalohovani]]\\
[[#boot|boot]]\\
[[#sysdump|system dump]]\\
[[#GLVM|GLVM]]\\
[[#storage|Storage, datova uloziste]]\\
[[#problemy|Resene problemy s FS,LVM, ...]]\\
lsdev -Cc disk ... seznam disku
lsdev -p hdisk0 ... ktery adapter ovlada disk hdisk0
lsdev -C -c disk -S a -F 'name class subclass location parent' ... ukaze disky i s rodicema\\
lsparent -Pl scsi0 ... ktere disky ovlada radic scsi0
lscfg | grep disk ... nazvy disku
lscfg -vl hdisk0 ... podrobne informace o disku hdisk0
lsattr -El hdisk0 ... nastaveni driveru disku hdsik0
lspath ... ktery radic ovlada ktery disk
/lq\\
====Fibre Chanel, [[http://kutngedg.homelinux.org/blog/?cat=5&paged=2|SDD]] (Storagesystem Device Driver),
datapath query device ... seznam zarizeni fro FC
datapath query essmap|grep hdisk1667 ... informace o disku v fiber chanel
lquerypr ... Ukazuje a meni rezervacni status (SCSI Locks).\\
lquerypr -Vh /dev/hdisk ... ukaze reserved status\\
lquerypr -rh /dev/hdisk ... vyprazdni reserved status \\
SDDPCM
pcmsrv - Deamon, der die Pfade überwacht.\\
pcmpath ... info a meneni SDDPCM zarizeni
pcmpath query device ... seznam SDDPCM zarizeni
pcmquerypr - Zeigt und setzt persistente Reservierungen (SCSI Locks).\\
sddpcmke - Kernel-Extension. Stellt System-Calls zum Management der Pfade zu Platten auf Storage Boxen zur Verfügung.\\
sdduserke - API zu dieser Kernel Extension.\\
pcmgenprkey - Generiert Keys zur Reservirung von Platten und zeigt bestehende Keys.\\
relbootsrv - Hebt SCSI-2 Reservierungen auf.\\
sddpcmgetdata - Sammelt Debug-Information und Traces (File sddpcmdata_hostname_time.tar).\\
pdmtest - Umfangreiches Tool zum Testen und Debuggen. \\
ESS\\
[[http://unix.derkeiler.com/Mailing-Lists/AIX-L/2005-10/0037.html|lsess]]\\
\\
[[http://www.alanward.info/Glossary/S/SSA.html|ssa]]
diag -> Task Selection -> SSA Service Aids -> Set Service Mode ... seriove cisla disku\\
lsdev -C -t hdisk -c disk -s ssar -H ... ukaze ssa disky
ssaadap -l hdisk59 ... ukaze, na kterem adapteru je zapojen disk 59\\
ssaconn -l pdisk59 -a ssa2 ... ukaze, jak je zapojen SSA disk v SSA poli\\
ssadisk -a ssa0 -L ... seznam disku na ssa\\
ssaxlate -l hdisk5 ... info o ssa disku hdisk5
[[http://www.alanward.info/Glossary/S/SSA_Commands/ssaload.htm|ssaload]] ... nahraji mikrokod na ssa disk\\
ssa_fw_status -a ssa0 ... ukaze stav baretie pro ssa0\\
SCSI X-PCI RAIDs\\
sisraidmgr -L -j1 -l sisioa0 ... vypis raid zarizeni pod radicem sisioa0\\
sisraidmgr -h ... help k praci s RAID polema\\
ssaraid ... SSA raid
SVC\\
$SVCCLI svcinfo lsvdisk | grep 600507680190025518000000000009E4 ... zjisti, zda je naasignovany disk z nasledujicim SCSIid\\
$SVCCLI svcinfo lsvdiskhostmap vdisk1465 ... infomace o disku 1465\\
===Storage===
[[http://www.aixhealthcheck.com/blog?id=48|/tmp/emc/emcgrab/emcgrab.sh]] ... ukaze vsechny informace tykajici se EMC storage - FC, LUNu atd.\\
exportvg - export volume group
extendvg - volume group
extendvg4vp -f datavg vpath32 ... rozsiri VG o virtualni cestu
importvg - import volume group
mirrorvg - mirror volume group
mkvg - make volume group
lsvg - show volume groups
lsvg -p VGrupa ... kuaze PV, ktere pouziva VGrupa\\
lsvgfs rootvg ... ukaze filesystemy VG rootvg\\
lvmstat -v rootvg ... ukaze statistiky o VG rootvg
reducevg ... reduce volume group
reorgvg ... reorganizuje VG pro lepsi vykon
restvg -q -f /tmp/zaloha hdisk1 ... Obnovi VG ze souboru /tmp/zaloha na hdisk1
splitvg ... snapshoty\\
syncvg ... (Synchronize Volume Groups) synchronizuje vg, pv, nebo lv
syncvg -l ... zynchronizuje LV ktere jsou ve stavu "stale" - nesynchronizovane\\
synclvodm ... synchronizuje LVM a ODM informace
unmirrorvg - unmirror volume group
varyonvg - aktivuje deaktivovanou volume groupu, nebo ji reaktivuje (synchronizuje)
varyoffvg - deactivate volume group
readvgda / lquerypv / lqueryvg ... Verify VG integrity
port: 6192/tcp, muze byt vary on jen na jednom pocitaci
glvm.rpv.client - Remote Physical Volume Client
glvm.rpv.server - Remote Physical Volume Server
glvm.rpv.util - Geographic LVM Utilities
glvm.rpv.msg.en_US - RPV Messages - U.S. English
/usr/sbin/rpvsitename -a 'SITE_NAME' ... nastavi jmeno GLVM serveru
/usr/sbin/mkdev -c rpvserver -s rpvserver -t rpvstype -a rpvs_pvid='HDISK_PVID' -a client_addr='RPV_CLIENT_IP' -a auto_online='y' ... nastavi server
/usr/sbin/mkdev -c disk -s remote_disk -t rpvclient -a pvid='PVID' -a server_addr='RPV_SERVER_IP' -a local_addr='RPV_CLIENT_IP' -a io_timeout='180' ... nastavi klienta
lsdev -Cc rpvserver ... zarizeni GLVM serveru
lsattr -El rpvserver0 ... atributy
lsdev -Cc disk -t rpvclient ... GLVM disky
mount -t glvm ... namountuje glvm disky
[[https://www.ibm.com/support/knowledgecenter/en/ssw_aix_72/com.ibm.aix.cmds3/mkcifsmnt.htm|
mkcifsmnt]] -f /mnt -d share1 -h server1 -c user1 ... vytvori CIFS FS /mnt z disku share1 z windows pocitace server1 pod uzivatelem user1\\
mkps -s 1 -a rootvg ... (make paging space) Vytvori paging space na rootvg veliky 1 PP
chps -s 3 paging00 ... (change paging space) zmeni velikost PS paging00 o 3 LP
chps -d 1 paging00 ... zmensi PS paging00 o 1 LP
rmps paging00 ... smaze PS paging00
swapoff /dev/paging00 ... vypne PS /dev/paging00
swapon
vmo -p -o lru_file_repage=0 ... meni parametry paging space
vmstat 1 ... kazdou sekundu informace a statistiky virtualni pameti
sysdumpdev -P -p /dev/SysDumpP
sysdumpdev -l ... ukaze aktivni sysdump disky
sysdumpdev -e ... ukaze potrebne misto na system dump
/usr/lib/ras/dumpcheck ... test, jestli je sysdompfs dost veliky
kdb soubor ... analyza sysdumpu
... Vypise vsachna zarizeni pro praci s magnetickou paskou
lscfg -vl rmt* ... Vypise informcae o vsech mechanikach (serial number, ...)
lsattr -El rmt0 ... Vypise informace o prvni pasce a mechanice
tapeutil -f /dev/smc0 devids ... Collects the WWN as recorded in the special device file for the given device (e.g. 'rmt5').
tctl -f smc0 status ... informace o mechanice/pasce
tctl ... controls the tape recorder
mt ... jako mctl\\
tapechk 2 ... precte 2 blok z pasky
tcopy /dev/rmt0.1 /dev/rmt1.1 ... prekopiruje rmt0 na rmt0\\
1724-100 = DS4100 = FAStT 100
1722-600 = DS4300 = FAStT 600
1742-900 = DS4500 = FAStT 900
1814 = DS4700/DS4200
1815 = DS4800
FC 2105 ==> ESS (mit FC ==> Fiber Channel connected, sonst SCSI)
FC 2107 ==> DS8000
FC 1750 ==> DS6000
FC 2145 ==> SAN Volume Controller Device
FC 2062 ==> SAN Volume Controller for Cisco MDS 9000
pcmpath (devices.sddpcm.53.rte)
datapath (devices.sdd.53.rte) - existuji zarizeni vpathX, ktere zastupuji cesty+disky na Storage
/usr/sbin/pathtest
nebo
HACMP smitty:
---------------------
smitty hacmp
System Management (C-SPOC)
HACMP Logical Volume Management
Shared Volume Groups
Set Characteristics of a Shared Volume Group
Add a Volume to a Shared Volume Group
---------------------
---------------------
smitty hacmp
System Management (C-SPOC)
HACMP Logical Volume Management
Synchronize a Shared Volume Group Definition
---------------------
==Rozsireni LV v clusteru==
smitty hacmp -> System management -> HACMP Logical Volume Manager -> Shared Logical Volumes -> Change a shared LV
smitty hacmp -> System management -> HACMP Logical Volume Manager -> Shared Logical Volumes -> Set Characteristics of Shared LV -> Increase the Size of a Shared LV
nebo
lslv aaa
chlv -x 14000 aaa
chlv -u 8 aaa
extendlv aaa 1000 hdisk95 hdisk96
varyonvg -ub aaa
ssh node2 "importvg -L aaa hdisk43" (nebo extendvg aaa hdisk95)
varyon
==Rozsireni FS v clusteru==
lsfs -q /abc
smitty hacmp -> System management -> HACMP Volume Manager -> Shared File Systems -> Enhanced JFS -> Change / Show ...
==Obnoveni smazaneho souboru==
istat 1243 /dev/lv_cog # Block Pointer d0450
echo "ibase=16;D0459 | bc # 853072
lsfs -q /Cognos # block size: 4096
echo "853072 * 4096" | bc # 3494182912
dd if=/dev/lv_cog of=/tmp/lost_file skip=3494182912 bs=1 count=41450