LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 07-01-2019, 02:40 PM   #1
danmartinj
Member
 
Registered: Oct 2009
Posts: 89

Rep: Reputation: 1
Setting Up Multiple Disk File System For Media Server Using LVM Question


Hello,

I have been working on a personal project for months now trying to figure out best way to do it, waiting for parts to arrive, and trying to do it all on a limited budget. This link outlines by basic goal: https://www.linuxquestions.org/quest...on-4175652938/.

Anyhow, I am trying to prepare my media server with a single large partition where my data will be as it makes sense to me. I intend to put images, movies, etc. here. I intend for plex to be able to access media from this location as well and I am just curious if this makes sense to more experienced Linux professionals. The details as of now is I have 2 5xTB disks. This link outlines the howto I used to provision the disks https://www.tecmint.com/add-new-disk...-lvm-to-linux/
Basically, I put a single ext4 partition on each disk, created a Physical Volume for each partition, created a single volume group, and then finally created a single Logical Volume of about 9TB in size formatted again using ext4. Does anyone here know of any reason that will not work? Hopefully, I explained everything clearly.

Thanks,
Joe
 
Old 07-01-2019, 04:49 PM   #2
Deviathan
Member
 
Registered: Dec 2005
Posts: 52

Rep: Reputation: 18
If you're looking to set up a single partition on each disk to use as a lvm physical volume, look to parted for creating partitions like that above 2TB, also you'll want to set lvm to "on" within parted on each partition, should be able to find how to do that with a quick google.

The rest sounds ok for what you want, my only concern would be to make sure you find a good backup solution, a real simple one would be to add a third disk and use rsync.
 
Old 07-01-2019, 06:19 PM   #3
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 18,143

Rep: Reputation: 2935Reputation: 2935Reputation: 2935Reputation: 2935Reputation: 2935Reputation: 2935Reputation: 2935Reputation: 2935Reputation: 2935Reputation: 2935Reputation: 2935
Looks ok for a basic setup - do you really need all 9T ?
A simple backup solution would be to RAID1 the two disks - LVM now supports this natively and will separate the data itself. You'll get redundancy (not true backup) but you'll lose half the capacity. What's more important to you.
Redhat have a good LVM guide for free download.
 
Old 07-01-2019, 09:31 PM   #4
danmartinj
Member
 
Registered: Oct 2009
Posts: 89

Original Poster
Rep: Reputation: 1
Hey, I fully believe 9TB is ideal. My plan is to put all my media here in addition to VMs, work stuff, etc. so I think 9TB is ideal for now.

So if I run df -h I can see the partition (which is exciting) so my next step is to setup Plex and do some testing.

/dev/mapper/mediavg-media_data 9.0T 81M 8.5T 1% /media/data

I did have a question about backups. As of now it looks like using LVM for a shared drive will work and once I start loading up data I do not want to loose anything. I originally wanted to use an external machine for backups and basically duplicate the physical environment with identical hard drives but I invested all my money I had to spare into building my current Desktop Server (media server) which is basically a maxed out HP Z240. I had some spare machines laying around but they are very old and did not seem reliable so my current plan is to:

Add identical 2x 5TB drives to the HP Z240 (I did some testing with older SATA drives I had laying around and it looked like my HPZ240 could handle it) So that would mean by server will have:

1 1TB drive with Windows/Linux Dual Boot
2x 5TB drives as primary volume to hold my media so plex can access it
2x 5TB drives as an exact duplicate

I definitely did not originally plan to have everything on a single PC.... but like I said all my money is in it now and it so far seems to be a rockstar so that is my plan.

So my question is what method of backup should I choose since everything is going to be on the same machine? Originally, someone recommended rsync but it seems like that is best for remote networked machines. Currently, my instincts are telling me to use dd but maybe there is something better?

Thanks,

Joe
 
Old 07-01-2019, 11:17 PM   #5
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 18,143

Rep: Reputation: 2935Reputation: 2935Reputation: 2935Reputation: 2935Reputation: 2935Reputation: 2935Reputation: 2935Reputation: 2935Reputation: 2935Reputation: 2935Reputation: 2935
Ignore your instincts - "dd" is the absolute worst option. Forget it.
It has its uses, but this ain't one of them. Rsync is an excellent option - one used under the covers by a lot of backup tools. It offers compression and only transmits what has changed since the last invocation. You do not need an exact copy of the disk/filesystem, you need a copy of the data - which may be way less than 9T until you get everything loaded up.

And a backup on the same physical machine is exposed to similar risks - simple example; what happens if the machine gets stolen ?.
My opinions only, feel free to ignore any or all.

Last edited by syg00; 07-02-2019 at 02:45 AM. Reason: syntax
 
1 members found this post helpful.
Old 07-02-2019, 06:06 AM   #6
lleb
Senior Member
 
Registered: Dec 2005
Location: Florida
Distribution: CentOS/Fedora
Posts: 2,745

Rep: Reputation: 523Reputation: 523Reputation: 523Reputation: 523Reputation: 523Reputation: 523
Going out on a limb for this one as I have been running PlexMediaServer for decades. Past experiences are as follows:

1. CentOS Host with JBOD (just a bunch of drives) Worked well, but when I lost a drive 100% of that drives data was gone. Not ideal, but worked as long as I did not care about losing data. Drives of all kinds will fail. That is a fact of life.

2. CentOS Host with sRaid5 (software OS created RAID). Worked great until my sRAID died. lost 100% of that data. Was not a happy camper.

3. CentOS Host with physical RAID6. Much much better, but ran into a similar situation as #2 when the RAID died so went my data.

4. FreeNAS RAID6. Been running well through 3 physical servers over 10 years. Little bit of a learning curve to get it up and running as it is based on FreeBSD, not Linux, but close enough to not be a horrid transition. Currently in the process of upgrading my 3TB drives on the RAID6 to 10TB drives.

To answer the question about storage space, yes 9T is very small for a media server. I have 11T total to use with my RAID6 and I'm currently pushing the 80% capacity mark all the time and have to transfer files between my media server and workstation to keep the load under the limit for performance.

One the cheap, I would recommend sticking with what you know to start with. I would avoid LVM spanning for reasons mentioned above, if you lose 1 drive, you lose 100% of the data on the LVM.

Start out with a JBOD setup. That way when you drop a drive, and it will happen, you only lose the data on that single drive. As you can afford add another HDD, be that internal or external, to a different system to use as backup. Rsync is the way to go for the backup as all you need to backup is the media data, not the entire OS setup.

Plex does have some config files that you can backup in addition to the media files you want to backup. Not really needed, but can reduce rebuild times.

https://freenas.org/

https://www.christitus.com/2018/10/2...lugin-freenas/

https://www.ixsystems.com/community/...-2-jail.19412/

https://www.ceos3c.com/freenas/how-t...-freenas-11-1/

Fast google search came up with those guides. I have not dug deep into them, but there is plenty of data out there on setup and configuration for FreeNAS + Plex.

Good luck and have fun with your PlexMediaServer.
 
1 members found this post helpful.
Old 07-02-2019, 09:16 PM   #7
danmartinj
Member
 
Registered: Oct 2009
Posts: 89

Original Poster
Rep: Reputation: 1
Thanks for the input. I feel LVM will be a pain in the butt if I do loose a drive (honestly speaking and knocking on wood as I type I do not ever remember loosing a drive yet) I think I will keep LVM as it seems like it is easy to manage and basically makes sense to me. I plan on doing an exact mirror as far as disks go....but I am not exactly sure how I will do it yet with Rsync but it seems like everyone talks about Rsync so I will plan on trying to figure out how to use it. Thanks for the info everyone as I really appreciate it.
 
Old 07-05-2019, 02:02 PM   #8
X-LFS-2010
Member
 
Registered: Apr 2016
Posts: 423

Rep: Reputation: Disabled
Quote:
Originally Posted by danmartinj View Post
Hello,

I have been working on a personal project for months now trying to figure out best way to do it
Thanks,
Joe
there's your first mistake. trying to be a top level manager when your very un-learned, when you "don't have to". answer is: do not.

think of this: how does your cable tv have multiple media delivered by service agreement to all homes ON A TIME SCHEDULE? how do these corporations organize their media so they can find it? they have hardware and software that do it. allot of them, very advanced.

just log on to youtube and watch videos or place some new ones there. do not try to invent a home solution you don't need.
 
Old 07-05-2019, 02:04 PM   #9
X-LFS-2010
Member
 
Registered: Apr 2016
Posts: 423

Rep: Reputation: Disabled
you may still need a cheap/old pc around so if you are in a pinch you can put a TB drive into it to mount under a directory for repair
 
Old 07-05-2019, 02:10 PM   #10
X-LFS-2010
Member
 
Registered: Apr 2016
Posts: 423

Rep: Reputation: Disabled
you should spend all that money on a linux multimedia system - it'll probably BURN you bad. you may do a linux update and get a failure and have no access to your media for a month - or a year - waiting for a driver update that fixes a bug added to a driver that "used to work" that frankly may never happen

if you are within 30 days my advice is to RETURN IT ALL and get an iMac which has excellent media making/arranging software, or win10 which has (pro software you can purchase)

i don't know where you got the idea that you can build a custom media machine with linux

but you do so if YOUR FUNDED (ie, you have partners and plan to sell the result and have funding)

you don't spend months on linux "fixing it" unless, well, your back in 1995 and there was simply no choice (as an IT student) if you wished to do computing other than (win95 - which was so bad you couldn't finish 1 night's homework without re-installing it, or unix - which was $20,000 a copy in 1990's dollars). there was a time people did huge projects - yes. but for a different reason: no choice. today there are real choices for you.

you will not save money or time making a media machine using linux
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Why does /media/cdrecorder pop up with "cd /media/ + tab" when I have /media/usb too? SharpyWarpy Fedora 6 11-22-2012 01:05 AM
Adding an LVM hard disk to a system already running/using LVM firewiz87 Linux - Hardware 5 08-15-2010 12:59 AM
Mounting LVM Disk to non-LVM disk gak_92 Linux - Hardware 1 08-07-2009 03:34 AM
LVM and multiple iSCSI disks performance of LVM xxx_anuj_xxx Linux - Server 4 05-01-2008 12:26 PM
Media, media, and oh yeah......media. Morbid SUSE / openSUSE 2 03-11-2007 08:50 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 12:59 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration