0

I have a home server running Centos 6.4. There are 2 400GB physical disks, and I believe I have 1 logical volume over one of the disks. I want to mount the 2nd disk under /backup and use it for backups only (my thinking was to keep backup data on a separate physical device).

  1. Are my assumptions about my set up correct?
  2. Should I add the 2nd disk to the LVM, and if so how do I ensure that only backup data goes to the 2nd disk?
  3. Should I the disk some other way

I've included some paired down output that I hope will be useful:

[root@server ~]# fdisk -l

Disk /dev/sda: 400.1 GB, 400088457216 bytes
...

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *           1          64      512000   83  Linux
Partition 1 does not end on cylinder boundary.
/dev/sda2              64       48642   390198272   8e  Linux LVM

Disk /dev/sdb: 400.1 GB, 400088457216 bytes
...

   Device Boot      Start         End      Blocks   Id  System
/dev/sdb1               1       48642   390710272   83  Linux

Disk /dev/mapper/vg_server-lv_root: 53.7 GB, 53687091200 bytes
... 

Disk /dev/mapper/vg_server-lv_swap: 8405 MB, 8405385216 bytes
...

Disk /dev/mapper/vg_server-lv_home: 337.5 GB, 337469505536 bytes
...

[root@server ~]# df -H
Filesystem             Size   Used  Avail Use% Mounted on
/dev/mapper/vg_server-lv_root
                        53G   3.5G    47G   7% /
tmpfs                  4.2G      0   4.2G   0% /dev/shm
/dev/sda1              508M    68M   415M  14% /boot
/dev/mapper/vg_server-lv_home
                       333G    41G   275G  13% /home

[root@server ~]# pvs --all
  PV                     VG        Fmt  Attr PSize   PFree
  /dev/ram0                             ---       0     0
  /dev/ram1                             ---       0     0
  /dev/ram10                            ---       0     0
  /dev/ram11                            ---       0     0
  /dev/ram12                            ---       0     0
  /dev/ram13                            ---       0     0
  /dev/ram14                            ---       0     0
  /dev/ram15                            ---       0     0
  /dev/ram2                             ---       0     0
  /dev/ram3                             ---       0     0
  /dev/ram4                             ---       0     0
  /dev/ram5                             ---       0     0
  /dev/ram6                             ---       0     0
  /dev/ram7                             ---       0     0
  /dev/ram8                             ---       0     0
  /dev/ram9                             ---       0     0
  /dev/root                             ---       0     0
  /dev/sda1                             ---       0     0
  /dev/sda2              vg_server lvm2 a--  372.12g    0
  /dev/sdb1                             ---       0     0
  /dev/vg_server/lv_home                ---       0     0
  /dev/vg_server/lv_swap                ---       0     0

Edit

Further output as requested

[root@server ~]# cat '/proc/partitions'
major minor  #blocks  name

   8        0  390711384 sda
   8        1     512000 sda1
   8        2  390198272 sda2
   8       16  390711384 sdb
   8       17  390710272 sdb1
 253        0   52428800 dm-0
 253        1    8208384 dm-1
 253        2  329560064 dm-2
2
  • what does cat '/proc/partitions' say?
    – golimar
    Jun 17, 2013 at 9:09
  • @golimar I've added the requested output as an edit
    – Romski
    Jun 17, 2013 at 11:41

1 Answer 1

0

You appear to have 3 logical volumes: root, /home, and swap. There's no reason to add the backup drive to LVM. If you do, then you can specify which disk a volume should be allocated on when you create it, though in your case, your first disk is already 100% allocated, so the new disk is the only place a new volume could go.

1
  • thanks for the reply. To confirm my understanding: I have 1 drive with 3 logical volumes. The 2nd drive is not in use, and whilst it could be added to the volume, this is not necessary. If I do add it to the volume, the new mount point will go to the 2nd disk by default as the 1st disk is fully allocated. Since there is no reason to add it to the lvm, can I just mount it directly? Is this desirable, and is it ok to mix lvm/non-lvm. Is it possible to have a second lvm? What are the trade-offs - Thanks once more for the help.
    – Romski
    Jun 17, 2013 at 23:24

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .