Disk Setup

According to US-CERT, I’m supposed to make a record of how the disks are set up in my server and keep it in a safe place.  What safer place than the Internet where the whole world can keep track of my disk layout for me.

green [imbrius@dustpuppy ~]$ sudo /sbin/lvm lvs
  LV       VG         Attr   LSize   Origin Snap%  Move Log Copy%  Convert
  LogVol00 VolGroup00 -wi-ao   2.00G
  LogVol01 VolGroup00 -wi-ao   8.00G
  LogVol02 VolGroup00 -wi-ao   8.00G
  LogVol03 VolGroup00 -wi-ao   4.00G
  LogVol04 VolGroup00 -wi-ao   2.00G
  LogVol05 VolGroup00 -wi-ao  95.00G
  LogVol06 VolGroup00 -wi-ao   2.00G
  LogVol07 VolGroup00 -wi-ao 512.00M
  LogVol08 VolGroup00 -wi-ao   2.00G
  LogVol09 VolGroup00 -wi-ao   8.00G
  LogVol10 VolGroup00 -wi-ao   1.00G
  LogVol11 VolGroup00 -wi-ao   2.00G
  LogVol12 VolGroup00 -wi-ao 310.38G

green [imbrius@dustpuppy ~]$ sudo /sbin/lvm lvdisplay
  --- Logical volume ---
  LV Name                /dev/VolGroup00/LogVol00
  VG Name                VolGroup00
  LV UUID                09sVWu-BIk2-5YcU-HMoy-WJym-X73m-iAeKkr
  LV Write Access        read/write
  LV Status              available
  # open                 1
  LV Size                2.00 GB
  Current LE             32
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     3072
  Block device           253:0                                 

  --- Logical volume ---
  LV Name                /dev/VolGroup00/LogVol11
  VG Name                VolGroup00
  LV UUID                e2HdS3-Oj27-G6H8-I4gU-aDqw-YWry-UqABoP
  LV Write Access        read/write
  LV Status              available
  # open                 1
  LV Size                2.00 GB
  Current LE             32
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     3072
  Block device           253:1                                 

  --- Logical volume ---
  LV Name                /dev/VolGroup00/LogVol12
  VG Name                VolGroup00
  LV UUID                HKX7aq-Z5l9-tW9M-irzu-Wxei-xJ7p-GybvdT
  LV Write Access        read/write
  LV Status              available
  # open                 1
  LV Size                310.38 GB
  Current LE             4966
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     3072
  Block device           253:2                                 

  --- Logical volume ---
  LV Name                /dev/VolGroup00/LogVol01
  VG Name                VolGroup00
  LV UUID                KoUJJw-T8SH-TZac-ZXfx-2nzK-t4ZO-nuE7Sx
  LV Write Access        read/write
  LV Status              available
  # open                 1
  LV Size                8.00 GB
  Current LE             128
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     3072
  Block device           253:3                                 

  --- Logical volume ---
  LV Name                /dev/VolGroup00/LogVol02
  VG Name                VolGroup00
  LV UUID                qGuEBY-YpTl-F3KG-YAtB-kyTH-VEg3-Y51EuF
  LV Write Access        read/write
  LV Status              available
  # open                 1
  LV Size                8.00 GB
  Current LE             128
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     3072
  Block device           253:4                                 

  --- Logical volume ---
  LV Name                /dev/VolGroup00/LogVol10
  VG Name                VolGroup00
  LV UUID                haZLZl-ySNg-11Ne-GYRo-u3IJ-feG1-2nWjB5
  LV Write Access        read/write
  LV Status              available
  # open                 1
  LV Size                1.00 GB
  Current LE             16
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     3072
  Block device           253:5                                 

  --- Logical volume ---
  LV Name                /dev/VolGroup00/LogVol03
  VG Name                VolGroup00
  LV UUID                0o6Abc-5BO9-Ac0l-GO0A-quwH-yr0Y-ZIa0wP
  LV Write Access        read/write
  LV Status              available
  # open                 1
  LV Size                4.00 GB
  Current LE             64
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     3072
  Block device           253:6                                 

  --- Logical volume ---
  LV Name                /dev/VolGroup00/LogVol09
  VG Name                VolGroup00
  LV UUID                dCiUuj-XBv1-sO3h-hY4e-cXVf-0hpv-fKPCOP
  LV Write Access        read/write
  LV Status              available
  # open                 1
  LV Size                8.00 GB
  Current LE             128
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     3072
  Block device           253:7                                 

  --- Logical volume ---
  LV Name                /dev/VolGroup00/LogVol05
  VG Name                VolGroup00
  LV UUID                BjDe64-klS8-AAHp-6I5Y-IMy3-6f54-2oN9e6
  LV Write Access        read/write
  LV Status              available
  # open                 1
  LV Size                95.00 GB
  Current LE             1520
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     3072
  Block device           253:8                                 

  --- Logical volume ---
  LV Name                /dev/VolGroup00/LogVol06
  VG Name                VolGroup00
  LV UUID                m3JJO2-T8GD-i3nK-ruD2-jRLa-8dmZ-ylUDh0
  LV Write Access        read/write
  LV Status              available
  # open                 1
  LV Size                2.00 GB
  Current LE             32
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     3072
  Block device           253:9

  --- Logical volume ---
  LV Name                /dev/VolGroup00/LogVol08
  VG Name                VolGroup00
  LV UUID                cv1OTp-s2ZJ-Gq2h-S7Mg-4uvn-pEiF-3DQwod
  LV Write Access        read/write
  LV Status              available
  # open                 1
  LV Size                2.00 GB
  Current LE             32
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     3072
  Block device           253:10

  --- Logical volume ---
  LV Name                /dev/VolGroup00/LogVol04
  VG Name                VolGroup00
  LV UUID                RBgEBn-PlfU-XX8u-RvR0-DtBd-dluH-c2dhX3
  LV Write Access        read/write
  LV Status              available
  # open                 1
  LV Size                2.00 GB
  Current LE             32
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     3072
  Block device           253:11

  --- Logical volume ---
  LV Name                /dev/VolGroup00/LogVol07
  VG Name                VolGroup00
  LV UUID                TESQW8-MVLI-2UWF-NmbG-nBIg-hXwi-1YOl3n
  LV Write Access        read/write
  LV Status              available
  # open                 1
  LV Size                512.00 MB
  Current LE             8
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     3072
  Block device           253:12

green [imbrius@dustpuppy ~]$ cat /etc/fstab
/dev/VolGroup00/LogVol00  /  ext3  grpquota,suid,dev,defaults,noatime,exec  0  1
/dev/VolGroup00/LogVol11  /tmp  ext2  grpquota,suid,defaults,noatime,exec,nodev  0  2
/dev/VolGroup00/LogVol12  /export/home  ext3  suid,defaults,noatime,usrquota,exec,nodev  0  2
/dev/VolGroup00/LogVol01  /opt  ext3  grpquota,suid,defaults,noatime,exec,nodev  0  2
/dev/VolGroup00/LogVol02 /usr                    ext3    defaults,nodev,noatime        1 2
/dev/VolGroup00/LogVol10 /usr/local              ext3    defaults,nodev,noatime        1 2
/dev/VolGroup00/LogVol03  /var  ext3  grpquota,suid,defaults,noatime,exec,nodev  0  2
/dev/VolGroup00/LogVol09 /var/lib/mysql          ext3    defaults,nodev,sync,noatime        1 2
/dev/VolGroup00/LogVol05  /var/ftp  ext3  grpquota,suid,defaults,noatime,usrquota,noexec,nodev  0  2
/dev/VolGroup00/LogVol06  /var/cache  ext3  grpquota,suid,defaults,noatime,noexec,nodev  0  2
/dev/VolGroup00/LogVol08  /var/spool  ext3  grpquota,suid,defaults,noatime,usrquota,noexec,nodev  0  2
/dev/VolGroup00/LogVol04  /var/log  ext3  grpquota,suid,defaults,noatime,noexec,nodev  0  2
/dev/VolGroup00/LogVol07 /var/www                ext3    defaults,nodev,noatime        1 2
LABEL=/boot1            /boot                   ext2    defaults        1 2
tmpfs                   /dev/shm                tmpfs   defaults        0 0
devpts                  /dev/pts                devpts  gid=5,mode=620  0 0
sysfs                   /sys                    sysfs   defaults        0 0
proc                    /proc                   proc    defaults        0 0
LABEL=SWAP-sdb1         swap                    swap    pri=0        0 0
LABEL=SWAP-sda1         swap                    swap    pri=0        0 0
LABEL=SWAP-hdc1         swap                    swap    pri=0        0 0
LABEL=SWAP-hda2         swap                    swap    pri=0        0 0
/dev/sdc1  /media/usb  ext2  user,nosuid,noatime,noexec,nodev,noauto  0  0

And here are the screenies that go along with it:

The LVM Layout

The LVM Layout

md0 extents mapping - showing how the LVM2 logical volumes are laid out on the RAID logical volume

md0 extents mapping - showing how the LVM2 logical volumes are laid out on the RAID logical volume

LVM layout on top of volume group

LVM layout on top of volume group

Red shows physical layout and blue shows logical layout.  In fact, the “physical layout” isn’t really the physical disk layout as /dev/md0 is a Linux mdraid device:

green [imbrius@dustpuppy ~]$ cat /proc/mdstat
Personalities : [raid6] [raid5] [raid4]
md0 : active raid5 sdb2[3] sda2[2] hdc2[1] hda3[0]
      466503168 blocks level 5, 256k chunk, algorithm 2 [4/4] [UUUU]

unused devices: <none>
Advertisements

, , , , , , , , , , ,

  1. Leave a comment

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: