LiveTV Won't Play
Moderator: Forum Moderators
LiveTV Won't Play
Problem: When I click Watch TV in the front end, it just flashes and returns to the menu.
It's obvious from the log below that it doesn't have permissions to write the recording file to the directory, but I have the permissions opened up as wide as I can. Any suggestions on how to get this to work? I must be missing something simple ;-(
Configuration:
Old NUC computer
Fresh install of Ubuntu 20.04.3
Installed MythTV from the repos
USB Connected Hard Drive mounted at /media/jeff/5tb/
HD Homerun Connect Duo tuner
Mythbackend configured to use /media/jeff/5tb/mythrepo/recordedtv/ as live TV storage group
jeff@NUC:/media/jeff/5tb/mythrepo$ ls -l
total 40
drwxrwxrwx 2 mythtv mythtv 4096 Oct 14 11:21 coverart
drwxrwxrwx 2 mythtv mythtv 4096 Oct 14 11:21 db_backups
drwxrwxrwx 2 mythtv mythtv 20480 Oct 14 11:21 recordedtv
drwxrwxrwx 2 mythtv mythtv 4096 Oct 14 11:21 screenshots
drwxrwxrwx 2 mythtv mythtv 4096 Sep 22 12:22 streaming
drwxrwxrwx 2 mythtv mythtv 4096 Sep 22 12:22 trailers
Relevant Log entry:
Oct 15 09:54:26 NUC mythbackend: mythbackend[6317]: E TVRecEvent threadedfilewriter.cpp:106 (Open) TFW(/media/jeff/5tb/mythrepo/recordedtv/10401_20211015145426.ts:-1): Opening file '/media/jeff/5tb/mythrepo/recordedtv/10401_20211015145426.ts'.#012#011#011#011eno: Permission denied (13)
It's obvious from the log below that it doesn't have permissions to write the recording file to the directory, but I have the permissions opened up as wide as I can. Any suggestions on how to get this to work? I must be missing something simple ;-(
Configuration:
Old NUC computer
Fresh install of Ubuntu 20.04.3
Installed MythTV from the repos
USB Connected Hard Drive mounted at /media/jeff/5tb/
HD Homerun Connect Duo tuner
Mythbackend configured to use /media/jeff/5tb/mythrepo/recordedtv/ as live TV storage group
jeff@NUC:/media/jeff/5tb/mythrepo$ ls -l
total 40
drwxrwxrwx 2 mythtv mythtv 4096 Oct 14 11:21 coverart
drwxrwxrwx 2 mythtv mythtv 4096 Oct 14 11:21 db_backups
drwxrwxrwx 2 mythtv mythtv 20480 Oct 14 11:21 recordedtv
drwxrwxrwx 2 mythtv mythtv 4096 Oct 14 11:21 screenshots
drwxrwxrwx 2 mythtv mythtv 4096 Sep 22 12:22 streaming
drwxrwxrwx 2 mythtv mythtv 4096 Sep 22 12:22 trailers
Relevant Log entry:
Oct 15 09:54:26 NUC mythbackend: mythbackend[6317]: E TVRecEvent threadedfilewriter.cpp:106 (Open) TFW(/media/jeff/5tb/mythrepo/recordedtv/10401_20211015145426.ts:-1): Opening file '/media/jeff/5tb/mythrepo/recordedtv/10401_20211015145426.ts'.#012#011#011#011eno: Permission denied (13)
Re: LiveTV Won't Play
Just a guess - even though the mythtv user can read and write to the recordedtv directory what about the directories leading up to it? Sometimes the permissions of the directories in the path can affect what the user is allowed to do in the chosen directory.
Re: LiveTV Won't Play
I tried changing the group to mythtv and giving "others" rights all the way from the root, and still no joy.
But thanks for the suggestion!
But thanks for the suggestion!
Re: LiveTV Won't Play
The strange thing is when I use the Backend config tool to set up the storage directory for LiveTV, it writes a test file to make sure it has permissions (I've seen the error message when it doesn't have them), since I don't get the error message, I'm confident it has write permissions to the directory.
I keep poking around, but still can't find the bit to flip to make it work.
I keep poking around, but still can't find the bit to flip to make it work.
Re: LiveTV Won't Play
The first post contains output that appears to have been created when logged in as user jeff.
Have you tried logging in as user mythtv and then testing if you can write a file, e.g. with
Have you tried logging in as user mythtv and then testing if you can write a file, e.g. with
Code: Select all
touch /media/jeff/5tb/mythrepo/recordedtv/z.z
Re: LiveTV Won't Play
I'd like to give this suggestion a try, but I can't figure out how to log in as the mythtv user. How can I find out the password?
I did try another test and changed the setup of the storage directory to point to /var/lib/mythtv/livetv and watching live tv worked fine. So I went back and tried to make my usb connected HD directories match /var/lib/mythtv exactly. But once I changed the storage directory back to /media/jeff/5tb/mythrepo/livetv I had the same issue not being able to watch live tv:
jeff@NUC:/var/lib/mythtv$ ls -l
total 40
drwxrwsr-x 2 mythtv mythtv 4096 Mar 23 2020 banners
drwxrwsr-x 2 mythtv mythtv 4096 Mar 23 2020 coverart
drwxrwsr-x 2 mythtv mythtv 4096 Mar 23 2020 db_backups
drwxrwsr-x 2 mythtv mythtv 4096 Mar 23 2020 fanart
drwxrwsr-x 2 mythtv mythtv 4096 Oct 18 11:52 livetv
drwxrwsr-x 2 mythtv mythtv 4096 Mar 23 2020 recordings
drwxrwsr-x 2 mythtv mythtv 4096 Mar 23 2020 screenshots
drwxrwsr-x 2 mythtv mythtv 4096 Mar 23 2020 streaming
drwxrwsr-x 2 mythtv mythtv 4096 Mar 23 2020 trailers
drwxrwsr-x 2 mythtv mythtv 4096 Mar 23 2020 videos
jeff@NUC:/media/jeff/5tb/mythrepo$ ls -l
total 40
drwxrwsr-x 2 mythtv mythtv 4096 Oct 18 11:55 banners
drwxrwsr-x 2 mythtv mythtv 4096 Oct 18 11:03 coverart
drwxrwsr-x 2 mythtv mythtv 4096 Oct 18 11:03 db_backups
drwxrwsr-x 2 mythtv mythtv 4096 Oct 18 12:44 fanart
drwxrwsr-x 2 mythtv mythtv 4096 Oct 18 12:15 livetv
drwxrwsr-x 2 mythtv mythtv 4096 Oct 18 11:56 recordings
drwxrwsr-x 2 mythtv mythtv 4096 Oct 18 11:03 screenshots
drwxrwsr-x 2 mythtv mythtv 4096 Sep 22 12:22 streaming
drwxrwsr-x 2 mythtv mythtv 4096 Sep 22 12:22 trailers
drwxrwsr-x 2 mythtv mythtv 4096 Oct 18 12:12 videos
I also tried adding the mythtv user to all the same groups that my user "jeff" is in thinking I have some special permissions to use the USB drive, but no joy.
I did try another test and changed the setup of the storage directory to point to /var/lib/mythtv/livetv and watching live tv worked fine. So I went back and tried to make my usb connected HD directories match /var/lib/mythtv exactly. But once I changed the storage directory back to /media/jeff/5tb/mythrepo/livetv I had the same issue not being able to watch live tv:
jeff@NUC:/var/lib/mythtv$ ls -l
total 40
drwxrwsr-x 2 mythtv mythtv 4096 Mar 23 2020 banners
drwxrwsr-x 2 mythtv mythtv 4096 Mar 23 2020 coverart
drwxrwsr-x 2 mythtv mythtv 4096 Mar 23 2020 db_backups
drwxrwsr-x 2 mythtv mythtv 4096 Mar 23 2020 fanart
drwxrwsr-x 2 mythtv mythtv 4096 Oct 18 11:52 livetv
drwxrwsr-x 2 mythtv mythtv 4096 Mar 23 2020 recordings
drwxrwsr-x 2 mythtv mythtv 4096 Mar 23 2020 screenshots
drwxrwsr-x 2 mythtv mythtv 4096 Mar 23 2020 streaming
drwxrwsr-x 2 mythtv mythtv 4096 Mar 23 2020 trailers
drwxrwsr-x 2 mythtv mythtv 4096 Mar 23 2020 videos
jeff@NUC:/media/jeff/5tb/mythrepo$ ls -l
total 40
drwxrwsr-x 2 mythtv mythtv 4096 Oct 18 11:55 banners
drwxrwsr-x 2 mythtv mythtv 4096 Oct 18 11:03 coverart
drwxrwsr-x 2 mythtv mythtv 4096 Oct 18 11:03 db_backups
drwxrwsr-x 2 mythtv mythtv 4096 Oct 18 12:44 fanart
drwxrwsr-x 2 mythtv mythtv 4096 Oct 18 12:15 livetv
drwxrwsr-x 2 mythtv mythtv 4096 Oct 18 11:56 recordings
drwxrwsr-x 2 mythtv mythtv 4096 Oct 18 11:03 screenshots
drwxrwsr-x 2 mythtv mythtv 4096 Sep 22 12:22 streaming
drwxrwsr-x 2 mythtv mythtv 4096 Sep 22 12:22 trailers
drwxrwsr-x 2 mythtv mythtv 4096 Oct 18 12:12 videos
I also tried adding the mythtv user to all the same groups that my user "jeff" is in thinking I have some special permissions to use the USB drive, but no joy.
Re: LiveTV Won't Play
I think Paul and Klaas are spot on. Note that /media/<username> may be special.
Try: ls -ld /media/jeff. I suspect you'll see a + sign after the permissions and that
means that an Access Control List is in play. It is in my Ubuntu host.
Try getfacl /media/jeff and you'd typically see that the directory is owned by root:root
but actually, it's jeff:jeff with no permissions for groups/others.
/media is there for mounting removable stuff. I'd put an entry in /etc/fstab and mount
the external drive under /var/lib/mythtv/storage (for example). Then, on the removable,
have the recordings directory.
Try: ls -ld /media/jeff. I suspect you'll see a + sign after the permissions and that
means that an Access Control List is in play. It is in my Ubuntu host.
Try getfacl /media/jeff and you'd typically see that the directory is owned by root:root
but actually, it's jeff:jeff with no permissions for groups/others.
/media is there for mounting removable stuff. I'd put an entry in /etc/fstab and mount
the external drive under /var/lib/mythtv/storage (for example). Then, on the removable,
have the recordings directory.
Re: LiveTV Won't Play
Genius!
jeff@NUC:/var/lib/mythtv$ ls -ld /media/jeff
drwxrwxrwx+ 3 root mythtv 4096 Oct 14 10:39 /media/jeff
jeff@NUC:/var/lib/mythtv$ getfacl /media/jeff
getfacl: Removing leading '/' from absolute path names
# file: media/jeff
# owner: root
# group: mythtv
user::rwx
user:jeff:r-x
group::---
mask::rwx
other::rwx
I put this line in my fstab file (hope it's ok):
# /dev/sdb1: LABEL="5tb"
UUID=b604ce59-bfbd-4770-97fa-bbf4ba4a24c3 /var/lib/ ext4 defaults 0 2
Did:
sudo mount -a
Reconfigured storage directories to use the new location and voilà!
But I have to say, that is some esoteric linux sh!& there. The last few years I've been lulled into expecting to just plug stuff in and have it work. Oh well, live and learn I guess
Thank you all so much for all your help!!!!
jeff@NUC:/var/lib/mythtv$ ls -ld /media/jeff
drwxrwxrwx+ 3 root mythtv 4096 Oct 14 10:39 /media/jeff
jeff@NUC:/var/lib/mythtv$ getfacl /media/jeff
getfacl: Removing leading '/' from absolute path names
# file: media/jeff
# owner: root
# group: mythtv
user::rwx
user:jeff:r-x
group::---
mask::rwx
other::rwx
I put this line in my fstab file (hope it's ok):
# /dev/sdb1: LABEL="5tb"
UUID=b604ce59-bfbd-4770-97fa-bbf4ba4a24c3 /var/lib/ ext4 defaults 0 2
Did:
sudo mount -a
Reconfigured storage directories to use the new location and voilà!
But I have to say, that is some esoteric linux sh!& there. The last few years I've been lulled into expecting to just plug stuff in and have it work. Oh well, live and learn I guess
Thank you all so much for all your help!!!!
Re: LiveTV Won't Play
Careful be! Mounting on top of /var/lib covers up everything else under /var/lib.
Nothing wrong with that if the 5tb drive has everything else on it.
Nothing wrong with that if the 5tb drive has everything else on it.
Re: LiveTV Won't Play
You were sooo right! Mounting it at /var/lib was a bad idea. I changed it to /var/lib/mythtv and we're back to normal
Re: LiveTV Won't Play
That's OK too if the external drive has a copy of everything under /var/lib/mythtv.
In the above, there were directories from banners. ... videos.
Safer to make a new directory: /var/lib/mythtv/storage and mount on that.
Then be sure the recordings directory lives on the external drive. You never
want to have a mount point on the root filesystem that <could> be written to
if the mount fails (and recordings fill up the root partition).
In the above, there were directories from banners. ... videos.
Safer to make a new directory: /var/lib/mythtv/storage and mount on that.
Then be sure the recordings directory lives on the external drive. You never
want to have a mount point on the root filesystem that <could> be written to
if the mount fails (and recordings fill up the root partition).
Re: LiveTV Won't Play
More really sage advice!