Let me run through the specific case. What I am trying to do here is record on fast SSD storage and later move the files to slower HDD storage.
I have one storage directory (/var/tmp/mythtv) in the default storage group.
I record some shows. Now I have files in /var/tmp/mythtv. Two days later I decide I want to move the actual files to /archive and symlink the file to this location. So I do this
mv /var/tmp/mythtv/file1.ts /archive
ln -s /archive/file1.ts /var/tmp/mythtv/file1.ts
now the file is /var/tmp/mythtv/file1.ts is a symlink but points to the real file /archive/file1.ts
Within minutes myth deletes the symlink and the recording from its DB.
What is going on here? Is it even possible to make this work (record on fast storage, and store later on slower, larger storage)?
myth deletes recording files that I symlink
Moderator: Forum Moderators
-
- Senior
- Posts: 265
- Joined: Sun Jun 15, 2014 1:08 am
Re: myth deletes recording files that I symlink
How does the symlink do anything?
Your archive folder would need read only access.
Use storage groups & always write into a folder in the mountpoint target.
"archive" is a type of storage group.
Make the slow long term storage folder be included in storage group of type archive.
I believe there is a setting to indicate/allow following symlinks.. but that will just make the files disappear.
Your archive folder would need read only access.
Use storage groups & always write into a folder in the mountpoint target.
"archive" is a type of storage group.
Make the slow long term storage folder be included in storage group of type archive.
I believe there is a setting to indicate/allow following symlinks.. but that will just make the files disappear.
Re: myth deletes recording files that I symlink
Probably the same reason as for the other question. /var/tmp/mythtv may be short of space and it thinks by deleting the files it will get space in there. Clearly it is best not to symlink files in this way.
Re: myth deletes recording files that I symlink
You beat me to it. Yes, this is the same reason. I will still be managing my files in this way but effectively disabling myth's auto deletion process by configuring it to only trigger when there is near zero space available. I will manage/monitor the diskspace outside of myth.
-
- Senior
- Posts: 265
- Joined: Sun Jun 15, 2014 1:08 am
Re: myth deletes recording files that I symlink
I have a shingled 8TB drive in an archive storage group.
I record to a 2TB HDD. After 6 months of aging , files are just moved to HDD folder that is in the archive storage group.
AFAIUI The archive storage group allows manual deleting but no auto-deletion.
I record to a 2TB HDD. After 6 months of aging , files are just moved to HDD folder that is in the archive storage group.
AFAIUI The archive storage group allows manual deleting but no auto-deletion.