Deprecated
This page is deprecated and may contain information that is no longer up to date.
File system off¶
How to reproduce the problem¶
Archive a file to tape:
[itctabuild02] ~ > echo -n '1234567890' > ten_byte_file.txt
[itctabuild02] ~ > run_eosuser1_shell
[itctabuild02] ~ (krb5=eosuser1)> xrdcp ten_byte_file.txt root://localhost//eos/dev/userfiles/testdir_1
[10B/10B][100%][==================================================][10B/s]
[itctabuild02] ~ (krb5=eosuser1)> exit
exit
[itctabuild02] ~ >
Observe that the file is only on tape (d0::t1
):
[itctabuild02] ~ > run_eosuser1_shell
[itctabuild02] ~ (krb5=eosuser1)> eos root://localhost ls -y /eos/dev/userfiles/testdir_1/ten_byte_file.txt
d0::t1 -rw-r--r-- 1 eosuser1 eosuser1 10 Apr 21 10:56 ten_byte_file.txt
[itctabuild02] ~ (krb5=eosuser1)> exit
exit
[itctabuild02] ~ >
Request that the file be retrieved from tape:
[itctabuild02] ~ > run_eospoweruser1_shell
[itctabuild02] ~ (krb5=eospoweruser1)> xrdfs localhost prepare -s /eos/dev/userfiles/testdir_1/ten_byte_file.txt
eos:044620011458020202280000000001000042:e03bfa81.5e9eb2b9:11
[itctabuild02] ~ (krb5=eospoweruser1)> exit
exit
[itctabuild02] ~ >
Observe that the file is both on disk and on tape (d1::t1
):
[itctabuild02] ~ > run_eosuser1_shell
[itctabuild02] ~ (krb5=eosuser1)> eos root://localhost ls -y /eos/dev/userfiles/testdir_1/ten_byte_file.txt
d1::t1 -rw-r--r-- 2 eosuser1 eosuser1 10 Apr 21 10:56 ten_byte_file.txt
[itctabuild02] ~ (krb5=eosuser1)> exit
exit
[itctabuild02] ~ >
Determine the file system identifier of the disk replica and switch the corresponding file system off:
[itctabuild02] ~ > sudo eos root://localhost fileinfo /eos/dev/userfiles/testdir_1/ten_byte_file.txt
File: '/eos/dev/userfiles/testdir_1/ten_byte_file.txt' Flags: 0644
Size: 10
Modify: Tue Apr 21 10:56:45 2020 Timestamp: 1587459405.150208000
Change: Tue Apr 21 10:57:45 2020 Timestamp: 1587459465.148593212
Birth : Tue Apr 21 10:56:45 2020 Timestamp: 1587459405.112753275
CUid: 19227 CGid: 1487 Fxid: 00000010 Fid: 16 Pid: 15 Pxid: 0000000f
XStype: adler XS: 0b 2c 02 0e ETAGs: "4294967296:0b2c020e"
Layout: replica Stripes: 1 Blocksize: 4k LayoutId: 00100012
#Rep: 2
┌───┬──────┬────────────────────────┬────────────────┬────────────────────────────────────────────┬──────────┬──────────────┬────────────┬────────┬────────────────────────┐
│no.│ fs-id│ host│ schedgroup│ path│ boot│ configstatus│ drain│ active│ geotag│
└───┴──────┴────────────────────────┴────────────────┴────────────────────────────────────────────┴──────────┴──────────────┴────────────┴────────┴────────────────────────┘
0 65535 localhost tape.0 /does_not_exist off nodrain offline
1 2 itctabuild02.cern.ch spinner.0 /run/media/smurray/250GB/fst_spinner_storage booted rw nodrain online flat
*******
[itctabuild02] ~ >
[itctabuild02] ~ > sudo eos fs config 2 configstatus=off
[itctabuild02] ~ >
Try to copy out the disk replica as an end user and print the exit code of the failing command:
[itctabuild02] ~ > run_eosuser1_shell
[itctabuild02] ~ (krb5=eosuser1)> xrdcp root://localhost//eos/dev/userfiles/testdir_1/ten_byte_file.txt /tmp/tmp_ten_byte_file.txt
[0B/0B][100%][==================================================][0B/s]
Run: [ERROR] Server responded with an error: [3014] Unable to open file /eos/dev/userfiles/testdir_1/ten_byte_file.txt; Network is unreachable (source)
[itctabuild02] ~ (krb5=eosuser1)> echo $?
54
[itctabuild02] ~ (krb5=eosuser1)> exit
exit
[itctabuild02] ~ >
How an end user can recover the data¶
An end user cannot recover the data themselves because they do have the necessary privileges to change the state of the EOS file system where the disk replica is located.
What a tape operator can do to recover the data¶
Switch the EOS file system back on:
Copy the recovered file out:
[itctabuild02] ~ > run_eosuser1_shell
[itctabuild02] ~ (krb5=eosuser1)> xrdcp root://localhost//eos/dev/userfiles/testdir_1/ten_byte_file.txt /tmp/tmp_ten_byte_file.txt
[10B/10B][100%][==================================================][10B/s]
[itctabuild02] ~ (krb5=eosuser1)> cat /tmp/tmp_ten_byte_file.txt; echo
1234567890
[itctabuild02] ~ (krb5=eosuser1)> exit
exit
[itctabuild02] ~ >