23.07.2014 Views

Lustre 1.6 Operations Manual

Lustre 1.6 Operations Manual

Lustre 1.6 Operations Manual

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

9. Format the new device. The easiest way to get the optimal ext3 parameters is to<br />

use lconf --reformat {config}.xml ONLY ON THE NODE being restored.<br />

If there are multiple services on the node, then this reformats all of the devices on<br />

that node and should NOT be used. Instead, use the step below:<br />

■ For MDS filesystems, use: mke2fs -j -J size=400 -I {inode_size} -i 4096 {dev}<br />

where {inode_size} is at least 512, and possibly larger if you have a default,<br />

stripe count > 10 (inode_size = power_of_2_>=_than(384 + stripe_count * 24)).<br />

■ For OST filesystems, use: mke2fs -j -J size=400 -I 256 -i 16384 {dev}<br />

10. Enable ext3 filesystem directory indexing. Type:<br />

tune2fs -O dir_index {dev}<br />

11. Mount the filesystem. Type:<br />

■ For 2.4 kernels use: mount -t ext3 {dev} /mnt/mds<br />

■ For 2.6 kernels use: mount -t ldiskfs {dev} /mnt/mds<br />

12. Change to the new filesystem mount point. Type:<br />

cd /mnt/mds<br />

13. Restore the filesystem backup. Type:<br />

tar xzvpf {backup file}<br />

14. Restore the filesystem EAs. Type:<br />

setfattr --restore=ea.bak<br />

15. Remove the (now invalid) recovery logs. Type:<br />

rm OBJECTS/* CATALOGS<br />

Again, the restore of the EAs (described in Step 6) is not currently required for OST<br />

devices, but this may change in the future.<br />

If the filesystem was used between the time the backup was made and when it was<br />

restored, then the "lfsck" tool (part of <strong>Lustre</strong> e2fsprogs) can be run to ensure the<br />

filesystem is coherent. If all of the device filesystems were backed up at the same<br />

time after the whole <strong>Lustre</strong> filesystem was stopped this is not necessary. The<br />

filesystem should be immediately usable even if lfsck is not run, though there will be<br />

IO errors reading from files that are present on the MDS but not the OSTs, and files<br />

that were created after the MDS backup will not be accessible/visible.<br />

Appendix D <strong>Lustre</strong> Knowledge Base D-15

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!