Opened 18 years ago
Closed 17 years ago
#1744 closed task (fixed)
support multiple recording directories
Reported by: | Owned by: | cpinkham | |
---|---|---|---|
Priority: | minor | Milestone: | 0.21 |
Component: | mythtv | Version: | head |
Severity: | medium | Keywords: | |
Cc: | ltd@… | Ticket locked: | no |
Description
What this patch does is allows you to specify multiple recording directories (separated by commas). mythbackend will then 'choose' one of those recording directories based on which one has the most free disk space.
Rationale behind this patch (rather than using DM/LVM/MD et al) is that creating one large partition means that if you lose a HDD you lose _all_ content, not just part of your media store.
No databases changes are involved with this patch (i.e. myth isn't storing the actual directory chosen anywhere). Backends will search each recording directory to find the recording. This also means that you are free to move your media around _between_ your recording directories & it will still find the media.
Auto Expiration will now loop across multiple directories, checking each individually to ensure they meet the minimum space threshold.
A minor change I made was in the default filenames chosen for recording (libs/libmythtv/programinfo.cpp:1294). That part isn't necessary but I found it useful when testing to 'see' what the programmes being recorded actually were... feel free to drop that hunk if you don't like the revised filenames.
Attachments (5)
Change History (14)
Changed 18 years ago by
Attachment: | multiple_recording_dirs.txt added |
---|
comment:1 Changed 18 years ago by
This works really well and removes the need for unreliable LVM configurations that span multiple disks without any mirroring.
comment:2 Changed 18 years ago by
Owner: | changed from Isaac Richards to danielk |
---|
I'll look at this after I take care of some of my segfault tickets.
comment:3 Changed 18 years ago by
Just a passing thought or two while reading this ticket.
Great! idea. Moreoever, the various places/directories where videos are stored *could* be stored in the settings table, so that no command line parameters are needed to tell the backend where to search.
Thirdly, it would on top of that, be possible to designate certain directories for certain types of video, so that the 'parental control' parameters are more easily controlled... Put all the kid's stuff on /dev/hdx or whatever....
Looking forward to this, so as to avoid using LVM etc. or the horrors of moving everything from a small drive to a larger one. Sooner rather than later please!
Geoff
comment:4 Changed 18 years ago by
Type: | enhancement → task |
---|
It looks like a lot of the issues have been thought out in this patch.
But I would also like to add some checks to figure out which filesystem is best to record to when recording starts. i.e. checking that next files to auto-expire are there, and perhaps load-balancing a bit between the available file systems and prefrerring local filesystems over remote ones (esp if a slave backend has local access to the remote filesystem.) So I'm changing this to a task to remind me to address those issues.
comment:5 Changed 18 years ago by
Milestone: | 0.20 → 0.21 |
---|
Changed 18 years ago by
Attachment: | multiple_recording_dirs.diff added |
---|
applies cleanly to [10750] svn trunk
comment:6 Changed 18 years ago by
I can confirm that the patch from Janne applies cleanly to 11059 too and works nicely.
Changed 18 years ago by
Attachment: | diff16.txt added |
---|
updated patch (as of [11121], have been running this successfully for 5 months with no issues
comment:7 Changed 18 years ago by
Auto expire of live tv doesn't work correctly with these patches. Live tv is being stored in all the directories but auto expire is only looking in the first directory for the live tv files.
Changed 18 years ago by
Attachment: | mythtv-0.20-r11396-multiple-dirs.diff added |
---|
Updated the patch to apply to svn head
comment:8 Changed 18 years ago by
Owner: | changed from danielk to cpinkham |
---|
Taking ownership of this after talking with Daniel. I'm not sure what if any parts of this will make it into SVN because of other ongoing parallel work so I'm going to leave the ticket open for now. I am currently working on the previously discussed concept of Storage Groups which will implement the functionality contained in this patch and more.
comment:9 Changed 17 years ago by
Resolution: | → fixed |
---|---|
Status: | new → closed |
Closing this ticket since the Storage Groups patch has been committed.
patch