editing fstab, setting up a network share with multiple drives
Linux - ServerThis forum is for the discussion of Linux Software used in a server related context.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
editing fstab, setting up a network share with multiple drives
I have what will soon become a file server here running Mandriva 2009.1 and I need to set it up for use.
There are 6 physical drives, sda-sdf. According to my fstab (pasted below), the OS is installed on sdb.. and for some reason I have a swap partition on sda and sdb. I had a horrible time getting a working installation, and that's probably leftover from a previous attempt.
Question 1: Can I simply edit my fstab to remove the swap on sda, effectively confining all system resources to sdb?
The end result I want is all storage space over all drives accessible from a single mount point which can be accessed over the network.
Question 2: Once I sort out the weird fstab, what's the best way to go about setting this up? I imagine I need to format & partition the other drives (all but sdb).. but as far as organizing the free space, what's the best way? Is it possible to have multiple physical drives accessible from a single mount point? Or will the users have to use each drive separately? I was thinking I could create a directory on sdb (in /home?) to use as a root for the network share, and then automount the other 5 physical drives there. Does that make sense?
1 - yes, delete the entries and then the partitions, there's really nothing that can go wrong, as long as you ensure the swap is definitely not in use when you nuke the partitions
2 - lvm. combine an arbitrary number of partitions across multiple devices into a single filesystem. You can have a degree of redundancy in place too using the --mirror option during lvcreate, without needing exact matching geometries and such like you would for a raid0 or raid5 implementation. Simple example here: http://linuxdevcenter.com/pub/a/linu...-with-lvm.html
Last edited by acid_kewpie; 08-12-2009 at 04:09 PM.
Thanks for your quick reply.. and for the suggestion for lvm, I will check it out.
Quote:
delete the entries and then the partitions, there's really nothing that can go wrong, as long as you ensure the swap is definitely not in use when you nuke the partitions
Awesome.. how do I go about ensuring the swap partition in question is not in use? Will swapoff do the trick?
it should be fine, but ideally no swap shoud be in use in the first place. I've had some systems crash doing a swapoff of a swap partition whne it was already being used. safest is certainly to delete the fstab entry and then reboot.
I realized I forgot to mention that this file server will only be accessed from Mac computers (via NFS). Is that possible with LVM? It seems easier to do what I suggested above - create a root directory for the share in one drive, then mount the other 5 there. But maybe LVM will be easier in the long run?
[ETA: After thinking about it, I imagine it depends on the file system used, and that the client won't know the share it's connecting to is managed by LVM. Would ext3 be the best choice?]
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.