4060
Comment:
|
← Revision 23 as of 2010-03-22 09:59:28 ⇥
11251
|
Deletions are marked like this. | Additions are marked like this. |
Line 4: | Line 4: |
== statistic == Get rpc statistics of a server You can also use the ID of osd list, e.g.: #osd stat 2 That gives the same output. {{{ # osd statistic zyklop20-al funny kvno (256) in ticket, proceeding Since 2009-11-15 04:00:04 (458674 seconds == 5 days, 7:24:34 hours) Total number of bytes received 96448669084672 87 tb Total number of bytes sent 95887024458752 87 tb rpc 220 Dummy 17884 rpc 131 read 4 rpc 170 list 3 rpc 314 updatecounters 93420271 rpc 211 CopyOnWrite 1972564 rpc 110 create 1 rpc 121 write 140 rpc 187 examine 25 rpc 185 examine0 1 rpc 150 incdec 1 rpc 311 Variable 2 rpc 312 statistic 2 }}} == listosds == List osds {{{ # osd listosds id name size state usage rpri wpri own loc flag lun sizerange 1 local_disk 0 gb up 0.0 % 100 64 --- --- --- 0 (0kb-1mb) 2 zyklop20-al 10694 gb up 2.5 % 64 64 --- --- --- 37 (1mb-2tb) 4 arch 46 gb up 0.3 % 64 64 --- --- arch 0 (0kb-10gb) }}} '''Important: '''You can use the ID instead of the Name. == osd == show single osddb entry You can also show only the entry of a given OSD: e.g. #osd osd 2 {{{ # osd osd Osd 'local_disk' with id=1: type = 0 minSize = 0 KB maxSize = 1024 KB totalSize = 0 MB pmUsed = 0 per mille used totalFiles = 0 M Files pmFilesUsed = 0 per mille used ip = 0.0.0.0 server = 0 lun = 0 alprior = 64 rdprior = 100 flags = 0 unavail = 0 owner = 0 = '' location = 0 = '' timeStamp = 0 = never highWaterMark = 0 per mille used minWipeSize = 0 MB chosen = 0 (should be zero) Osd 'zyklop20-al' with id=2: type = 0 minSize = 1024 KB maxSize = 2147483648 KB totalSize = 10951323 MB pmUsed = 17 per mille used totalFiles = 10 M Files pmFilesUsed = 0 per mille used ip = 141.34.22.43 server = 0 lun = 37 alprior = 64 rdprior = 64 flags = 0 unavail = 0 owner = 0 = '' location = 0 = '' timeStamp = 1257495000 = 2009-11-06 09:10:00 highWaterMark = 800 per mille used minWipeSize = 0 MB chosen = 0 (should be zero) }}} == volumes == list volumes {{{ # osd volumes 2 7 volumes found: 536900068 536900304 536900326 536900071 536901161 536901164 536901170 }}} The 2 means, that you want the information of the server with the id 2 (you can see the id"s with listosd) The numbers are the ID's of the volumes. == servers == show server osddb entry # osd servers == addserver == create server entry in osddb # osd addserver -id <ip address> -name <osd name> == deleteserver == delete a server entry # osd deleteserver -id <server name or ip-address> == policies == show policy osddb entry # osd policies {{{ # osd policies 2 txtpol ~'*.txt' => location=local, continue; }}} There is an policie with the id number ''2'' and a name ''txtpol''. |
|
Line 6: | Line 140: |
add a policy == addserver == create server entry in osddb |
add a policy You should first check, how many policies where given. (You can do that with osd policies) # osd addpolicy -id <policy number> -name <short name for policy> -policy <string representation as given by policies -cryptic> You can choose the id by yourself, but watch out if the id already exists! The Name is only a string representation. === Syntax === Predication => Option1, Option2, ... Predications can be: ||<tablewidth="938px" tableheight="139px">minimum size ||>2M ||>521k ||... || ||maximum size ||<10M ||<100k ||... || ||wildcard expression ||~*gz* ||*.[Zz][Ii][Pp] ||*.root ... || ||regex ||~/tmp_[a-z]{4,8}\.bin/ ||~/orig\./, /\.zip$/i ||... || ||user id ||uid=245 ||uid=290 ||... || ||group id ||gid=-150 ||... || || Predications supports brackets and logical AND, OR and NOT. e.g.: (>2M && <10M ) || *.root Option means, what the rule should do. Possible Options are: ||<tablewidth="560px" tableheight="178px">'''Options''' ||'''Syntax''' ||'''synonyms''' ||'''Comment''' || ||location ||location= ||l= loc= ''nothing'' ||l= can be omitted, see below || ||stripes ||stripes= ||s= str= || || ||stripesize ||stripe_size= ||ss= ssize= || || ||copies ||copies= ||c= || || ||stop ||stop || || || ||continue ||continue ||c''ont nothing'' || || Location can be: * osd (the file will be stored as an OSD File) * local (the file will be stored as a typical AFS File without OSD) * dynamic (the Fileserver choose where the file is stored) == deletepolicy == delete a policy # osd deletepolicy -id <policy id (number)> Use # osd policies for get the ID of a policy. == createobject == create object in existing volume subtree # osd createobject -osd <osd or name or IP-address of server> -fid <file-id: volume.vnode.uniquifier[.tag]> == createosd == create osd entry in osddb # osd createosd -id <osd id> -name <osd name> == deleteosd == delete osd entry in odddb # osd deleteosd -id <osd id> == examine == examine single object Usage: osd examine -osd <osd or server name or IP-address> -fid <file-id> {{{ # osd exa 2 536901170.12.36621.0, 536901170.12.36621.0 fid 536901170.12.36621 tag 0 not-striped lng 7000000000 lc 1 2010-03-09 14:13:37 }}} ||<tablewidth="721px" tableheight="24px"21% style="text-align: center;">oid ||<22% style="text-align: center;">fid ||<6% style="text-align: center;">tag ||<12% style="text-align: center;">notes ||<14% style="text-align: center;">size ||<5% style="text-align: center;"> ||<width="140px" style="text-align: center;">date || |
Line 12: | Line 221: |
search by help text Usage: osd apropos -topic <help string> {{{ # osd apropos create addserver: create server entry in osddb createobject: create object in existing volume subtree createosd: create osd entry in osddb }}} == createobject == create object in existing volume subtree == createosd == create osd entry in osddb |
search by help text Usage: osd apropos -topic <help string> {{{ # osd apropos create addserver: create server entry in osddb createobject: create object in existing volume subtree createosd: create osd entry in osddb }}} == objects == list objetcs of a volume # osd objects -osd <osd or name or IP-address of server> -volume <volume-id> {{{ # osd objects -osd 2 -volume 536901170 536901170.22.36613.0 fid 536901170.22.36613 tag 0 not-striped lng 7000000000 lc 1 536901170.24.36629.0 fid 536901170.24.36629 tag 0 not-striped lng 7000000000 lc 1 }}} {{{ 536901170.6.7.0 fid 536901170.6.7 tag 0 not-striped lng 8589934592 lc 1 }}} ||<tablewidth="518px" tableheight="40px"22% style="text-align: center;">Object-ID ||<25% style="text-align: center;">File id ||<8% style="text-align: center;">Tag ||<16% style="text-align: center;">notes ||<20% style="text-align: center;">Size ||<20% style="text-align: center;"> || == threads == show active threads in osd server # osd threads == wipecandidates == gets a list of oldest/largest objects from OSD based on access time # osd wipecandidates -osd <osd or name or IP-address of server> {{{ # osd wipecandidates -osd 2 1 Jun 11 2009 12000000000 536900068.174.2493.0 536900068.174.2493 2 Aug 27 2009 14680064 536900068.634.13785.0 536900068.634.13785 3 Nov 5 2009 1000000000 536900068.632.57037.0 536900068.632.57037 }}} ||<tablewidth="527px" tableheight="56px"7% style="text-align: left;">ID ||<17% style="text-align: center;">Date ||<18% style="text-align: center;">Size ||<width="45px" style="text-align: center;">fid ||<width="30px" style="text-align: center;">oid || ID - only a counter Date - Access last time Size - Size of the File fid/oid - == fetchqueue == show fetch requests # osd fetchqueue == getvariable == get rxosd variable # osd getvariable -server <name or IP-address> -variable <name> == setvariable == set rxosd variable # osd setvariable -server <name or IP-address> -variable <name> -value <value> |
Line 30: | Line 288: |
decrement link count of an objekt == deleteosd == delete osd entry in odddb == deletepolicy == delete a policy == deleteserver == delete a server entry == examine == examine single object Usage: osd examine -osd <osd or server name or IP-address> -fid <file-id: volume.vnode.uniquifier[.tag]> == fetchqueue == show fetch requests == getvariable == get rxosd variable |
decrement link count of an objekt # osd decrlinkcount -osd <osd or name or IP-address of server> -fid <file-id> == incrlinkcount == increment link count of an objekt # osd incrlinkcount -osd <osd or name or IP-address of server> -fid <file-id> == setosd == set fields in osddb # osd setosd -id <osd id> == md5sum == get md5 sum # osd md5sum -osd <osd or name or IP-address of server> -fid <file-id> == psread == pseudo striped read data from an object # osd psread -osd <osd or name or IP-address of server> -fid <file-id> {{{ # osd psread -osd 2 -fid 536901170.12.36621 -length 50000000 1 reading of 13107200 bytes took 0.838 sec. (15279 Kbytes/sec) 2 reading of 13107200 bytes took 0.763 sec. (16767 Kbytes/sec) 3 reading of 13107200 bytes took 0.863 sec. (14840 Kbytes/sec) reading of 50000000 bytes took 3.051 sec. Total data rate = 16004 Kbytes/sec. for read. }}} == pswrite == write data into an object # osd pswrite -osd <osd or name or IP-address of server> -fid <file-id> Looks like #osd psread == read == read data from an object # osd read -osd <osd or name or IP-address of server> -fid <file-id> Looks like #osd psread == write == write data into an object # osd write -osd <osd or name or IP-address of server> -fid <file-id> Looks like #osd psread |
Line 57: | Line 342: |
get help on commands == incrlinkcount == increment link count of an objekt == listosds == list osds == md5sum == get md5 sum == objects == list objetcs of a volume == osd == show single osddb entry {{{ osd osd Osd 'local_disk' with id=1: type = 0 minSize = 0 KB maxSize = 1024 KB totalSize = 0 MB pmUsed = 0 per mille used totalFiles = 0 M Files pmFilesUsed = 0 per mille used ip = 0.0.0.0 server = 0 lun = 0 alprior = 64 rdprior = 100 flags = 0 unavail = 0 owner = 0 = '' location = 0 = '' timeStamp = 0 = never highWaterMark = 0 per mille used minWipeSize = 0 MB chosen = 0 (should be zero) Osd 'zyklop20-al' with id=2: type = 0 minSize = 1024 KB maxSize = 2147483648 KB totalSize = 10951323 MB pmUsed = 17 per mille used totalFiles = 10 M Files pmFilesUsed = 0 per mille used ip = 141.34.22.43 server = 0 lun = 37 alprior = 64 rdprior = 64 flags = 0 unavail = 0 owner = 0 = '' location = 0 = '' timeStamp = 1257495000 = 2009-11-06 09:10:00 highWaterMark = 800 per mille used minWipeSize = 0 MB chosen = 0 (should be zero) }}} == policies == show policy osddb entry == psread == pseudo striped read data from an object == pswrite == write data into an object == read == read data from an object == servers == show server osddb entry == setosd == set fields in osddb == setvariable == set rxosd variable == statistic == get rpc statistic {{{ # osd statistic zyklop20-al funny kvno (256) in ticket, proceeding Since 2009-11-15 04:00:04 (458674 seconds == 5 days, 7:24:34 hours) Total number of bytes received 96448669084672 87 tb Total number of bytes sent 95887024458752 87 tb rpc 220 Dummy 17884 rpc 131 read 4 rpc 170 list 3 rpc 314 updatecounters 93420271 rpc 211 CopyOnWrite 1972564 rpc 110 create 1 rpc 121 write 140 rpc 187 examine 25 rpc 185 examine0 1 rpc 150 incdec 1 rpc 311 Variable 2 rpc 312 statistic 2 }}} == threads == show active threads in osd server == volumes == list volumes == wipecandidates == get candidates for wipeing == write == write data into an object |
get help on commands # osd help [topic/command] {{{ # osd help osd: Commands are: addpolicy add a policy addserver create server entry in osddb apropos search by help text createobject create object in existing volume subtree createosd create osd entry in osddb decrlinkcount decrement link count of an objekt deleteosd delete osd entry in odddb deletepolicy delete a policy deleteserver delete a server entry examine examine single object fetchqueue show fetch requests getvariable get rxosd variable help get help on commands incrlinkcount increment link count of an objekt listosds list osds md5sum get md5 sum objects list objetcs of a volume osd show single osddb entry policies show policy osddb entry psread pseudo striped read data from an object pswrite write data into an object read read data from an object servers show server osddb entry setosd set fields in osddb setvariable set rxosd variable statistic get rpc statistic threads show active threads in osd server volumes list volumes wipecandidates get candidates for wipeing write write data into an object }}} |
Contents
osd commands
statistic
Get rpc statistics of a server
You can also use the ID of osd list, e.g.: #osd stat 2
That gives the same output.
# osd statistic zyklop20-al funny kvno (256) in ticket, proceeding Since 2009-11-15 04:00:04 (458674 seconds == 5 days, 7:24:34 hours) Total number of bytes received 96448669084672 87 tb Total number of bytes sent 95887024458752 87 tb rpc 220 Dummy 17884 rpc 131 read 4 rpc 170 list 3 rpc 314 updatecounters 93420271 rpc 211 CopyOnWrite 1972564 rpc 110 create 1 rpc 121 write 140 rpc 187 examine 25 rpc 185 examine0 1 rpc 150 incdec 1 rpc 311 Variable 2 rpc 312 statistic 2
listosds
List osds
# osd listosds id name size state usage rpri wpri own loc flag lun sizerange 1 local_disk 0 gb up 0.0 % 100 64 --- --- --- 0 (0kb-1mb) 2 zyklop20-al 10694 gb up 2.5 % 64 64 --- --- --- 37 (1mb-2tb) 4 arch 46 gb up 0.3 % 64 64 --- --- arch 0 (0kb-10gb)
Important: You can use the ID instead of the Name.
osd
show single osddb entry
You can also show only the entry of a given OSD:
e.g. #osd osd 2
# osd osd Osd 'local_disk' with id=1: type = 0 minSize = 0 KB maxSize = 1024 KB totalSize = 0 MB pmUsed = 0 per mille used totalFiles = 0 M Files pmFilesUsed = 0 per mille used ip = 0.0.0.0 server = 0 lun = 0 alprior = 64 rdprior = 100 flags = 0 unavail = 0 owner = 0 = '' location = 0 = '' timeStamp = 0 = never highWaterMark = 0 per mille used minWipeSize = 0 MB chosen = 0 (should be zero) Osd 'zyklop20-al' with id=2: type = 0 minSize = 1024 KB maxSize = 2147483648 KB totalSize = 10951323 MB pmUsed = 17 per mille used totalFiles = 10 M Files pmFilesUsed = 0 per mille used ip = 141.34.22.43 server = 0 lun = 37 alprior = 64 rdprior = 64 flags = 0 unavail = 0 owner = 0 = '' location = 0 = '' timeStamp = 1257495000 = 2009-11-06 09:10:00 highWaterMark = 800 per mille used minWipeSize = 0 MB chosen = 0 (should be zero)
volumes
list volumes
# osd volumes 2 7 volumes found: 536900068 536900304 536900326 536900071 536901161 536901164 536901170
The 2 means, that you want the information of the server with the id 2 (you can see the id"s with listosd)
The numbers are the ID's of the volumes.
servers
show server osddb entry
# osd servers
addserver
create server entry in osddb
# osd addserver -id <ip address> -name <osd name>
deleteserver
delete a server entry
# osd deleteserver -id <server name or ip-address>
policies
show policy osddb entry
# osd policies
# osd policies 2 txtpol ~'*.txt' => location=local, continue;
There is an policie with the id number 2 and a name txtpol.
addpolicy
add a policy
You should first check, how many policies where given. (You can do that with osd policies)
# osd addpolicy -id <policy number> -name <short name for policy> -policy <string representation as given by policies -cryptic>
You can choose the id by yourself, but watch out if the id already exists!
The Name is only a string representation.
Syntax
Predication => Option1, Option2, ...
Predications can be:
minimum size |
>2M |
>521k |
... |
maximum size |
<10M |
<100k |
... |
wildcard expression |
~*gz* |
*.[Zz][Ii][Pp] |
*.root ... |
regex |
~/tmp_[a-z]{4,8}\.bin/ |
~/orig\./, /\.zip$/i |
... |
user id |
uid=245 |
uid=290 |
... |
group id |
gid=-150 |
... |
|
Predications supports brackets and logical AND, OR and NOT.
e.g.: (>2M && <10M ) || *.root
Option means, what the rule should do.
Possible Options are:
Options |
Syntax |
synonyms |
Comment |
location |
location= |
l= loc= nothing |
l= can be omitted, see below |
stripes |
stripes= |
s= str= |
|
stripesize |
stripe_size= |
ss= ssize= |
|
copies |
copies= |
c= |
|
stop |
stop |
|
|
continue |
continue |
cont nothing |
|
Location can be:
- osd (the file will be stored as an OSD File)
- local (the file will be stored as a typical AFS File without OSD)
- dynamic (the Fileserver choose where the file is stored)
deletepolicy
delete a policy
# osd deletepolicy -id <policy id (number)>
Use # osd policies for get the ID of a policy.
createobject
create object in existing volume subtree
# osd createobject -osd <osd or name or IP-address of server> -fid <file-id: volume.vnode.uniquifier[.tag]>
createosd
create osd entry in osddb
# osd createosd -id <osd id> -name <osd name>
deleteosd
delete osd entry in odddb
# osd deleteosd -id <osd id>
examine
examine single object Usage: osd examine -osd <osd or server name or IP-address> -fid <file-id>
# osd exa 2 536901170.12.36621.0, 536901170.12.36621.0 fid 536901170.12.36621 tag 0 not-striped lng 7000000000 lc 1 2010-03-09 14:13:37
oid |
fid |
tag |
notes |
size |
|
date |
apropos
search by help text Usage: osd apropos -topic <help string>
# osd apropos create addserver: create server entry in osddb createobject: create object in existing volume subtree createosd: create osd entry in osddb
objects
list objetcs of a volume
# osd objects -osd <osd or name or IP-address of server> -volume <volume-id>
# osd objects -osd 2 -volume 536901170 536901170.22.36613.0 fid 536901170.22.36613 tag 0 not-striped lng 7000000000 lc 1 536901170.24.36629.0 fid 536901170.24.36629 tag 0 not-striped lng 7000000000 lc 1
536901170.6.7.0 fid 536901170.6.7 tag 0 not-striped lng 8589934592 lc 1
Object-ID |
File id |
Tag |
notes |
Size |
|
threads
show active threads in osd server
# osd threads
wipecandidates
gets a list of oldest/largest objects from OSD based on access time
# osd wipecandidates -osd <osd or name or IP-address of server>
# osd wipecandidates -osd 2 1 Jun 11 2009 12000000000 536900068.174.2493.0 536900068.174.2493 2 Aug 27 2009 14680064 536900068.634.13785.0 536900068.634.13785 3 Nov 5 2009 1000000000 536900068.632.57037.0 536900068.632.57037
ID |
Date |
Size |
fid |
oid |
ID - only a counter
Date - Access last time
Size - Size of the File
fid/oid -
fetchqueue
show fetch requests
# osd fetchqueue
getvariable
get rxosd variable
# osd getvariable -server <name or IP-address> -variable <name>
setvariable
set rxosd variable
# osd setvariable -server <name or IP-address> -variable <name> -value <value>
decrlinkcount
decrement link count of an objekt
# osd decrlinkcount -osd <osd or name or IP-address of server> -fid <file-id>
incrlinkcount
increment link count of an objekt
# osd incrlinkcount -osd <osd or name or IP-address of server> -fid <file-id>
setosd
set fields in osddb
# osd setosd -id <osd id>
md5sum
get md5 sum
# osd md5sum -osd <osd or name or IP-address of server> -fid <file-id>
psread
pseudo striped read data from an object
# osd psread -osd <osd or name or IP-address of server> -fid <file-id>
# osd psread -osd 2 -fid 536901170.12.36621 -length 50000000 1 reading of 13107200 bytes took 0.838 sec. (15279 Kbytes/sec) 2 reading of 13107200 bytes took 0.763 sec. (16767 Kbytes/sec) 3 reading of 13107200 bytes took 0.863 sec. (14840 Kbytes/sec) reading of 50000000 bytes took 3.051 sec. Total data rate = 16004 Kbytes/sec. for read.
pswrite
write data into an object
# osd pswrite -osd <osd or name or IP-address of server> -fid <file-id>
Looks like #osd psread
read
read data from an object
# osd read -osd <osd or name or IP-address of server> -fid <file-id>
Looks like #osd psread
write
write data into an object
# osd write -osd <osd or name or IP-address of server> -fid <file-id>
Looks like #osd psread
help
get help on commands
# osd help [topic/command]
# osd help osd: Commands are: addpolicy add a policy addserver create server entry in osddb apropos search by help text createobject create object in existing volume subtree createosd create osd entry in osddb decrlinkcount decrement link count of an objekt deleteosd delete osd entry in odddb deletepolicy delete a policy deleteserver delete a server entry examine examine single object fetchqueue show fetch requests getvariable get rxosd variable help get help on commands incrlinkcount increment link count of an objekt listosds list osds md5sum get md5 sum objects list objetcs of a volume osd show single osddb entry policies show policy osddb entry psread pseudo striped read data from an object pswrite write data into an object read read data from an object servers show server osddb entry setosd set fields in osddb setvariable set rxosd variable statistic get rpc statistic threads show active threads in osd server volumes list volumes wipecandidates get candidates for wipeing write write data into an object