Good morning , in settings CouchPotato , General tab (indicating "Show Advanced Settings " ) under the option "Folder CHMOD " where you can indicate that permissions to create folders ( also is "File CHMOD " that applies is shown to file permissions ) . You tried to change this setting ?, I think default is 0755 .
Yes! Thank you very much. I think this should be work.
thanks for the great scripts hopefully you will keep it updated, is there something like sickrage for music?
Youre welcome yes, it is. The program name is Headphones. You can find guides with google, but startup script must be created with systemctl otherwise wonât start at reboot.
I created an account just to thank you for this guide. I got my media centre up and running with ease. This is now the go to guide to my friends too!
Youâre welcome and thank you for nice words. Iâm glad that it was useful and easy
can you do a guide for Headphones as well? then we get a complete HTCP
My personal notes
Headphones
Install Headphones Raspberry Pi for Usenet Torrent Music â˘
sudo git clone https://github.com/rembo10/headphones.git /opt/headphones
sudo chown -R osmc:osmc /opt/headphones
test
python /opt/headphones/Headphones.py
CTRL+Z
edit config.py
'HTTP_HOST': (str, 'General', 'localhost'),
to
'HTTP_HOST': (str, 'General', '0.0.0.0'),
ip:8181
sudo nano /etc/default/headphones
HP_USER=osmc
HP_HOME=/opt/headphones
HP_PORT=8181
save
sudo cp /opt/headphones/init-scripts/init.ubuntu /etc/init.d/headphones
sudo chmod +x /etc/init.d/headphones
sudo update-rc.d headphones defaults
sudo service headphones start
yes i seen that guide before but iâm having some trouble
20-Jan-2016 19:49:27 - INFO :: MainThread : Checking to see if the database has all tablesâŚ
20-Jan-2016 19:49:27 - INFO :: MainThread : Retrieving latest version information from GitHub
20-Jan-2016 19:49:33 - ERROR :: MainThread : Unable to connect to remote host. Check if the remote host is up and running.
20-Jan-2016 19:49:33 - WARNING :: MainThread : Could not get the latest version from GitHub. Are you running a local development version?
20-Jan-2016 19:49:33 - INFO :: MainThread : Starting Headphones web server on http://localhost:8181/
20-Jan-2016 19:49:33 - INFO :: MainThread : Scheduled background task: Search for Wanted
20-Jan-2016 19:49:33 - INFO :: MainThread : Scheduled background task: Download Scan
20-Jan-2016 19:49:33 - INFO :: MainThread : Scheduled background task: Library Scan
20-Jan-2016 19:49:33 - INFO :: MainThread : Scheduled background task: MusicBrainz Update
20-Jan-2016 19:49:33 - INFO :: MainThread : Scheduled background task: Check GitHub for updates
20-Jan-2016 19:49:33 - INFO :: MainThread : Scheduled background task: Torrent removal check
and it gets stuck there, when i check with my ip:8181 theres nothing, connexion times out
Did you do:
edit config.py
osmc@homershtcp:~$ edit config.py
Error: no âeditâ mailcap rules found for type âtext/x-pythonâ
Sorry my bad (quick notes to self)
edit = of course edit that file, not a command
Here is my config.py located
sudo nano /opt/headphones/headphones/config.py
hehe yea i figured afterwards, yet when i do start service , going to the browser doesnt give me anythingâŚshould i python /opt/headphones/Headphones.py after that?
I just used a isntall without headphones, doing these steps it works
Copy from git & set owner
sudo git clone GitHub - rembo10/headphones: Automatic music downloader for SABnzbd /opt/headphones
sudo chown -R osmc:osmc /opt/headphones
test:
python /opt/headphones/Headphones.py
stop with:
CTRL+Z
sudo nano /opt/headphones/headphones/config.py
change
âHTTP_HOSTâ: (str, âGeneralâ, âlocalhostâ),
to
âHTTP_HOSTâ: (str, âGeneralâ, â0.0.0.0â),
save:
CTRL+X
Y
ENTER
Create file & put some lines:
sudo nano /etc/default/headphones
HP_USER=osmc
HP_HOME=/opt/headphones
HP_PORT=8181
save:
CTRL+X
Y
ENTER
sudo cp /opt/headphones/init-scripts/init.ubuntu /etc/init.d/headphones
sudo chmod +x /etc/init.d/headphones
sudo update-rc.d headphones defaults
sudo service headphones start
Open a browser:
http:\\osmc:8181
dunno i may need to start from scratch, how can i purge this whole headphones setup?
hej, you should try to download new version of osmc easyscripts
I have some questions and small things I noticed:
- In the sickrage howto you mixed sysvinit and systemd:
â sudo systemctl stop sickrage
- Concerning ownership and permissions:
Now this is still a difficult issue for me but I guess I understood the basics.
Setting everything up myself on my current system, I created a new group called dlgrp and added all important users to it. You take osmc, ok. I think kodi also should be member of group osmc because there may be files created that arenât readable for others (i.ex. kodi user). Btw.: is kodi service called mediacenter on osmc? Can someone confirm that? So are there also the user mediacenter and group?
I also changed the programâs .serivce file:
âŚ
Group=osmc
âŚ
This way, if a program creates a folder or a file itâs always created with osmc as group.
Moving on to the file and folder permissions: I think itâs already stated somewhere in the comments of this thread that you can change the permissions of the files and folders created by sickrage, couchpotato in their settings somewhere (I donât recall exact location, I think in sickrage itâs in the general settings tab) I would suggest to set them so created files and folders are read and writeable to all members of group osmc. I think right number is 775âŚ
- Installing unrar:
Can you explain, why you took a unrar package for bananapi? At least the weburl suggests so:
Doesnât just sudo apt-get install unrar
do the trick? - The reason I ask is because it would be nice to keep your howto and scripts as universal as possible. Brings me to the next small thing: At the end of installation script echo echo âwebgui raspberry_ip:8081â maybe write your_ip:8081.
Ok, these are just suggestions -of course. Based on my personal experience being a linux noob. So if especially the suggestions about permissions and ownership are questionable or simply wrong I ask anyone reading this and being more experienced than me to correct me.
@nenad maybe you could change your howto and scripts accordingly.
PS: If you would add installation and configuration of nzbget and nzbtomedia this would be the ultimate script of all time
Did you read the topic of this tutorial? Thank you for noticing. I changed name of Topic, beacuse now should everybody know itâs for Raspberry Pi. I writed for raspberry pi and not for other devices, beacuse Iâm not sure if will works there. This answers your two questons I used this unrar, beacuse I alredy tested it and I never had problems. I should say, that Iâm not expert at linux. So I am like you, a noob about nzbtomedia and nzbget. I donât use them, so I wonât write scripts for those programs. And for sudo service sickrage stop, I use it, beacuse it works too. Why should now strictly use only sudo systemctl stop sickrage? About groups, I wouldnât recommend to play with permissions and groups. To find about how to check your groups you could use google and find that if you type groups, you see all groups that alredy exists. It should only take you a 15sec to find that command. So why you didnât use google for this? One thing about groups, do you know that one user can be added to more than one groups? So why should you create dlgrp? You can just add it to second or third group. That is for example one user in three groups and not only in one. Or you can create dlgroup and add all of users to this group. About creating and adding permissions to group, please use google
PS: if someone write scripts for nzbget and nzbtomedia, I would happily add them to this collections of my scripts
Sorry, I didnât state that Iâm currently waiting for the vero2. My i.mx6 device isnât supported by osmc so I canât run it on this device and see myself.
True, itâs stated in the first line of the post that its for raspberry pi, but not in the title of the tread - my bad.
Ok, maybe you didnât encounter these permission/ownership problems because you donât use nzbget and nzbtomedia. Nzbget is a download manager and nzbtomedia a script for postprocessing with sickrage,couchpotato, etc.
For example: nzbget dlâs a file with nzbget:nzbget. Nzbtomedia sends request to sickrage for postprocessing. Now sickrage canât post process it because group of dl file is nzbget. And giving write permissions to all others isnât a good ideaâŚas i already learned =)
Maybe you can try do add nzbget to other group and for the sickrage the same. I will give you example for couchpotato:
sudo usermod -a -G osmc couchpotato
In my scenario osmc group has privileges like root. So if I donât give couchpotato in that group, there will be problems with permissions for write and read. And with that command I give user couchpotato the same permission that has user osmc.
So for your case maybe you should find which groups you have and which one is like for my case is osmc. You can check with command: groups
Or look at some instrucitons here:
Maybe you can try thisâŚ
In your scenario, maybe you should choose to run as nzbget and not as sickrage. Maybe that will fix permissions becasue sickrage and nzbget runs with same user and same group.
I my case I choosed couchpotato in startup file:
sudo nano /etc/systemd/system/couchpotato.service
And this looks like:
[Unit]
Description=CouchPotato application instance
After=network.target
[Service]
ExecStart=/opt/CouchPotatoServer/CouchPotato.py --daemon
GuessMainPID=no
Type=forking
User=couchpotato
Group=couchpotato
[Install]
WantedBy=multi-user.target