0

I don't know if my question makes any sense. I have never tried this sort of thing before. What I would like to do is create one logical volume spanning multiple physical partitions like /dev/sdb1, /dev/sdb2, etc on a Linux machine and mount this logical volume on a single mount point on another machine running Ubuntu. Is that possible? If yes, how do I do it?

3 Answers 3

0

You've asked at least two questions here:

  1. How do I concatentate multiple partitions into a single volume?
  2. How do I make a filesystem accessible to a remote machine?

The simplest way of combining multiple partitions is to simply repartition your drive. If /dev/sdb1 and /dev/sdb2 are adjacent on the disk, you can simply remove sdb2 and extend sdb1. If your question was more general ("How do I combine multiple devices into a single logical device?"), you have several options, including the Linux software RAID subsystem (md) and the Logical Volume Manager (LVM).

Using LVM, you combine multiple physical devices into a volume group, and then you allocate logical volumes from the volume group. This is a way of abstracting your storage so that the size of your filesystems is no longer related to the size of any particular block device or disk partition. LVM is probably the most flexible solution for this sort of thing. More documentation can be found here, and there are lots of tutorials out there.

The software RAID subsystem will let you create various flavors of RAID volume out of existing physical devices. For what you're describing you would probably create a simple concatenated volume. Some documentation is here.

Once you've created your device and created a local filesystem, you can use NFS or CIFS or some other network protocol to make it available to other systems. NFS is probably easiest for Linux systems. Start here.

0

Just keywords:

  1. Use LVM to create a logical volume spanning multiple physical drives (but this isn't necessary)
  2. Install NFS/Samba on that machine to access to that volume over the network
0

Answering your plane question: it would be

  1. combine multiple phisical devices into a volume group.

pvcreate /dev/sdb1 /dev/sdb2

  1. create a Volume Group

vgcreate NameofVG /dev/sdb1 /dev/sdb2

Now you can see the vg created by using vgdisplay

  1. create a Logical Volume

lvcreate -n NAME -L 20G NameofVG

  1. making filesystem to it. (xfs for example)

mkfs.xfs /dev/NameofVG/NAME

Now you're ready to mount the recently created logical volumne by modifying /etc/fstab (to make it persistent) or just by using mount command.

You must log in to answer this question.

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