Permissions
Added by Koen De Buck over 7 years ago
Hi,
Annyone who like to help me? I succeed to build tvhe and install it on my ubuntu mate xenial running on a amlogic S905 device. Tv is working, tvhe is streaming channels to my remote-LibreElec boxes, but I have some permission problems
2017-04-06 18:44:53.648 settings: Unable to create "/home/hts/.hts/tvheadend/input/dvb/networks/8ce9b1827f57fb1df7d9bb6042208cd4/config.tmp" - Permission denied
and this
2017-04-06 18:45:01.246 dvr: "een HD" on "een HD" recorder starting
2017-04-06 18:45:01.263 subscription: 0005: "DVR: een HD" subscribing on channel "een HD", weight: 300, adapter: "SAT>IP DVB-S Tuner #1 (192.168.1.6)", network: "DVB-S 235E", mux: "12188H", provider: "M7 Group", service: "een HD", profile="pass"
2017-04-06 18:45:01.325 pass: /media/toshiba/recordings/een HD.ts: Unable to create file, open failed -- Permission denied
2017-04-06 18:45:01.325 dvr: Recording error: "/media/toshiba/recordings/een HD.ts": Unable to open file
2017-04-06 18:45:01.325 subscription: 0005: "DVR: een HD" unsubscribing from "een HD"
2017-04-06 18:45:01.329 dvr: "een HD" on "een HD": End of program: File not created
thanks.
Replies (8)
RE: Permissions - Added by Mark Clarkstone over 7 years ago
Make sure the configuration directories have the correct user permissions. Default is 755. so (using the default hts user)..
sudo -s chown hts:hts /home/hts/.hts/tvheadend -R chmod 755 /home/hts/.hts/tvheadend /media/toshiba/recordings/ -R chmod 700 /home/hts/.hts/tvheadend/superuser
Should fix it. If the last one fails, you more than likely don't have a superuser file.
RE: Permissions - Added by Koen De Buck over 7 years ago
Hi Mark,
Many thanks for Your reaction, I'm suffering here of a headache in trying to solve this.
Your commands did solve the first problem but recording is still not possible.
My extern HDD is mounted on an other device (Libreelec) because My extra port is not acceable due to a smargo card reader and I mounted in fstab this samba share:
//192.168.1.29/toshiba /media/toshiba cifs rw,guest 0 0
2017-04-07 07:29:07.584 dvr: entry aa1f330a832f57adc0cf57f11a040b91 "Canvas HD" on "Canvas HD" starting at 2017-04-07 07:28:33, scheduled for recording by "2/8"
2017-04-07 07:29:07.585 dvr: "Canvas HD" on "Canvas HD" recorder starting
2017-04-07 07:29:07.593 subscription: 000C: "DVR: Canvas HD" subscribing on channel "Canvas HD", weight: 300, adapter: "SAT>IP DVB-S Tuner #1 (192.168.1.6)", network: "DVB-S 235E", mux: "12188H", provider: "M7 Group", service: "Canvas HD", profile="pass"
2017-04-07 07:29:07.643 dvr: Unable to change directory permissions to "775" for "/var/media/toshiba/recordings/Canvas HD" (keeping "777")
2017-04-07 07:29:07.672 pass: /var/media/toshiba/recordings/Canvas HD/Canvas HD-Canvas HD2017-04-0707-29.ts: Unable to create file, open failed -- Permission denied
2017-04-07 07:29:07.672 dvr: Recording error: "/var/media/toshiba/recordings/Canvas HD/Canvas HD-Canvas HD2017-04-0707-29.ts": Unable to open file
2017-04-07 07:29:07.672 subscription: 000C: "DVR: Canvas HD" unsubscribing from "Canvas HD"
2017-04-07 07:29:07.686 dvr: "Canvas HD" on "Canvas HD": End of program: File not created
regards, Koen.
RE: Permissions - Added by Koen De Buck over 7 years ago
Ok I'm sorry, yesterday I had mounted it to /var/media/toshiba/recordings/, now I want to do things as You have explaind and mounted it back to /media/toshiba/recordings/ but in the configuration recording I had forgotten to change the path after I changed tvheadend gives me back the same error;
2017-04-07 07:49:00.766 dvr: Unable to change directory permissions to "775" for "/media/toshiba/recordings/een HD" (keeping "777")
RE: Permissions - Added by Koen De Buck over 7 years ago
Hello,
ps -efH
hts 17282 1 2 Apr06 ? 00:11:10 /usr/bin/tvheadend -f -u hts -
shouldent it be;
hts 571 1 1 Jan09 ? 12:18:58 /usr/bin/tvheadend -f -u hts -g video
hts is running but without the video group, is this my problem? If so how can I change this?
RE: Permissions - Added by Mark Clarkstone over 7 years ago
Koen De Buck wrote:
Hello,
ps -efH
hts 17282 1 2 Apr06 ? 00:11:10 /usr/bin/tvheadend -f -u hts -
shouldent it be;
hts 571 1 1 Jan09 ? 12:18:58 /usr/bin/tvheadend -f -u hts -g video
hts is running but without the video group, is this my problem? If so how can I change this?
It looks like the command has just been cut off in the output, nothing to worry about, anyway.
As the hts user
To enter.. sudo -u hts /bin/bash; try touching/creating a file in your recording directory. touch /media/toshiba/recordings/test_file mkdir /media/toshiba/recordings/test_dir To exit.. exit;
If the touch or mkdir fail, check to see if you've passed the correct permissions when mounting. This should give you a few hints
RE: Permissions - Added by Koen De Buck over 7 years ago
Goodmorning Mark,
Once again thank You for spending Your time in my problem.
Here is my output;
root@amlogic-s905x:~# sudo -u hts /bin/bash;
bash: /root/.bashrc: Permission denied
hts@amlogic-s905x:~$ touch /media/toshiba/recordings/test_file
touch: cannot touch '/media/toshiba/recordings/test_file': Permission denied
hts@amlogic-s905x:~$ mkdir /media/toshiba/recordings/test_dir
hts@amlogic-s905x:~$
RE: Permissions - Added by Mark Clarkstone over 7 years ago
Koen De Buck wrote:
Goodmorning Mark,
Once again thank You for spending Your time in my problem.
Here is my output;
root@amlogic-s905x:~# sudo -u hts /bin/bash;
bash: /root/.bashrc: Permission denied
hts@amlogic-s905x:~$ touch /media/toshiba/recordings/test_file
touch: cannot touch '/media/toshiba/recordings/test_file': Permission denied
hts@amlogic-s905x:~$ mkdir /media/toshiba/recordings/test_dir
hts@amlogic-s905x:~$
Looks like an issue with samba, this may help
RE: Permissions - Added by Koen De Buck over 7 years ago
Hi Mark,
Thanks for all the help!
My usb HDD was mounted on an other device (LibreELEC).
Via USB hub I mounted it directly on my device and it is recording!
My problem is solved!
I think it is time to make a donation now.
thanks again,
Koen.