Skip to content
This repository was archived by the owner on Oct 4, 2022. It is now read-only.

Commit ecb0e10

Browse files
committed
added lmfdb-disks.txt explaining lmfdb's disk config, btrfs etc
1 parent 5b9ffe4 commit ecb0e10

File tree

2 files changed

+97
-0
lines changed

2 files changed

+97
-0
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
*~

lmfdb-disks.txt

Lines changed: 96 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,96 @@
1+
lmfdb.warwick.ac.uk disk setup
2+
3+
Physically there are 12 Physical Disks (PD), each of 4T capacity.
4+
They are in 3 rows of 4 numbered as follows:
5+
6+
0 1 2 3
7+
4 5 6 7
8+
8 9 10 11
9+
10+
Hardware RAID configuration: there are 11 Drive Groups (DG) and 11
11+
Virtual Drives (VD) whose numbering is not quite natural:
12+
13+
DG0 includes PD0+PD1 in VD1, under RAID-1.
14+
DG1 includes PD2 in VD0 (!) under RAID-0
15+
DG2 includes PD3 in VD2 under RAID-0
16+
DG{n} includes PD{n+1} in VD{n} under RAID-0 for n=2,3,...,10.
17+
18+
DG0 = VD1 is the boot drive and contains all the Operating System.
19+
because of the RAID1 it appears to the O/S as a single 4T (actually
20+
3.6T) drive. This holds both the root partition (3.6T) containing the
21+
operating system and home directories, and also the /boot partitiion
22+
(229M).
23+
24+
Use "lsblk" to see the situation.
25+
26+
Warning: /boot fills up regularly. The unattended system package
27+
upgrades result in new kernel versions being put in there, which take
28+
up around 25M each. These need to be cleared out regularly -- see
29+
the file server-notes.txt for hints about this.
30+
31+
DG1-DG10 (the other 10 disks, VD0, VD2,...,VD10) use no hardware RAID,
32+
i.e. they are set as RAID-0. There is a single partition /data on
33+
device /dev/sdg, which is configured under BTRFS. This allows each of
34+
the 10 physical disks to be brough online / offline individually. At
35+
present (since March 2015) 6 of these are in use, as revealed by:
36+
37+
jec@lmfdb:~/system$ sudo btrfs fi show
38+
Label: lmfdb uuid: 495a3b08-5ae4-45e5-a994-d2aa0ca1c480
39+
Total devices 6 FS bytes used 9.42TiB
40+
devid 1 size 3.64TiB used 3.25TiB path /dev/sda
41+
devid 2 size 3.64TiB used 3.25TiB path /dev/sdc
42+
devid 3 size 3.64TiB used 3.25TiB path /dev/sdd
43+
devid 4 size 3.64TiB used 3.25TiB path /dev/sde
44+
devid 5 size 3.64TiB used 3.25TiB path /dev/sdf
45+
devid 6 size 3.64TiB used 3.25TiB path /dev/sdg
46+
47+
The O/S sees only one partition, on device /dev/sdg: see /etc/fstab
48+
where the relevant entry is
49+
50+
UUID=495a3b08-5ae4-45e5-a994-d2aa0ca1c480 /data btrfs defaults,noatime,compress,user_subvol_rm_allowed 0 1
51+
52+
The O/S thinks (using "df -h /data") it has size 22T of which 19T are
53+
currently used, but this is not accurate since btrfs manages its own
54+
RAID on that. In fact 9.42T are used (see above output) but (in
55+
effect) duplicated by btrfs.
56+
57+
Note that the physical disk block devices used by this partition are
58+
/dev/sd{x} for x=a,c,d,e,f,g (NOT b!). I think these letters
59+
correspond to the VDs, so /dev/sda=VD0, /dev/sdc=VD2, ...,
60+
/dev/sdg=VD6 and the reason for /dev/sdb being missing is that it is
61+
the other DG, i.e. DG0 (=VD1).
62+
63+
To add a new device, use "sudo btrfs device add", for example
64+
65+
"sudo btrfs device add /dev/sdh /data" to add VD7
66+
"sudo btrfs device add /dev/sdh /data" to add VD8
67+
"sudo btrfs device add /dev/sdh /data" to add VD9
68+
"sudo btrfs device add /dev/sdh /data" to add VD10
69+
70+
followed by "sudo btrfs balance /data". This takes a very long time; you
71+
can use "sudo btrfs fi show to see how it is going.
72+
73+
Another useful command is "sudo btrfs fi df /data":
74+
75+
Data, RAID1: total=9.72TiB, used=9.40TiB
76+
System, RAID1: total=8.00MiB, used=1.43MiB
77+
System, single: total=4.00MiB, used=0.00
78+
Metadata, RAID1: total=18.00GiB, used=16.69GiB
79+
Metadata, single: total=8.00MiB, used=0.00
80+
81+
[After writing the above I did "sudo btrfs device add /dev/sdh /data"
82+
on Thu Jan 7 16:35:24 GMT 2016, after which "sudo btrfs fi show"
83+
shows
84+
85+
86+
Label: lmfdb uuid: 495a3b08-5ae4-45e5-a994-d2aa0ca1c480
87+
Total devices 7 FS bytes used 9.42TiB
88+
devid 1 size 3.64TiB used 3.25TiB path /dev/sda
89+
devid 2 size 3.64TiB used 3.25TiB path /dev/sdc
90+
devid 3 size 3.64TiB used 3.25TiB path /dev/sdd
91+
devid 4 size 3.64TiB used 3.25TiB path /dev/sde
92+
devid 5 size 3.64TiB used 3.25TiB path /dev/sdf
93+
devid 6 size 3.64TiB used 3.25TiB path /dev/sdg
94+
devid 7 size 3.64TiB used 0.00 path /dev/sdh
95+
96+
and have just started the balancing with "sudo btrfs balance /data".]

0 commit comments

Comments
 (0)