Transmission. Started with a "permission denied", now it won't even run

21,492

The last command in that set:

sudo chown your_user -R /etc/transmission-daemon/settings.json 

sets your user as the owner of the settings file, and that file has read-permissions only for the owner by default. Transmission won't even be able to read it. Try:

sudo service transmission-daemon stop 
chmod g+rw /etc/transmission-daemon/settings.json 
sudo service transmission-daemon start

Since the commands don't change the group ownership of that file, giving it group read/write permission should be enough to get Transmission to start.

There are other problems as well, so I suggest these modifications as well:

chmod g+rw /var/lib/transmission-daemon/info/
chmod u+s /your_path/progress /your_path/completed

This will:

  1. Give the daemon the necessary write permissions on /var/lib/transmission-daemon/info/, where it stores the current status.
  2. Ensure that files created in the download and temporary folders are owned by you, by making the folders setuid.
Share:
21,492

Related videos on Youtube

Erik
Author by

Erik

Updated on September 18, 2022

Comments

  • Erik
    Erik over 1 year

    So I just ventured into the land of Ubuntu. It was a pleasant stroll until I came onto the chasm of users and permissions.

    I installed transmission-daemon. Everything looked nice and easy, but once a download gets going, it gives a shiny red "Permission denied" to my download path. So I started reading up on permissions. Learned how to use "gksudo nautilus" amongst other things. But things didn't clear up at all. The download folder had no owner as far as I could see when I worked through the files dialog. With "gksudo nautilus", it just crashed the window. I couldn't even see who owned it. Through the terminal it seemed all set like it should. Both owner and group set to debian-transmission.

    Then I stumbled on this topic: Transmission daemon: permission denied even if debian-transmission has root group and I thought: "Hey, those are clear instructions I can follow! Let's do this!". Now I'm stuck with a transmission that won't even start. It gives me a nice "transmission-daemon start/running, process 29525". But that's it. It stops right away and it's gone. No error or anything that my untrained eyes can work with.

    Can somebody help me with this? Some commands that can help me get further? Or should I just remove the whole thing and start over? Thanks in advance.

    //Edit

    I have followed muru's instructions and the daemon is back up and running but I am getting this error now:

    Error: Unable to save resume file: Permission denied
    

    My download folders look like this:

    drwsrwxrwx 2 debian-transmission debian-transmission 4096 sep  8 22:35 completed
    drwsrwxrwx 2 debian-transmission debian-transmission 4096 sep  8 22:35 incomplete
    drwxrwxr-x 2 erik                erik                4096 sep  8 22:35 torrents
    

    And the info folder is this:

    drwsrwxr-x 5 erik                debian-transmission 4096 sep 10 13:43 info
    

    Running transmission-daemon --log-debug --foreground gives me Couldn't read "/home/erik/.config/transmission-daemon/stats.json": No such file or di rectory (utils.c:201)

    Even though it can't read the stats.json and I think it is somehow ignoring my settings file (whitelist for ip's isnt working). It does succesfully download to /home/erik/Downloads. Then I stop the service. And restart it with the command that I thought was correct sudo service transmission-daemon start and it starts making a mess again. So I don't know, is the fact that it's a service making a difference?

    • muru
      muru over 9 years
      Can you run transmission-daemon --log-debug --foreground as well (after stopping the service)?
    • Erik
      Erik over 9 years
      I did this and added some stuff to the post.
  • Erik
    Erik over 9 years
    It is not running I'm afraid. It is not showing when I use ps aux. It gives me an error when I try to stop or pause the service. And the web interface doesn't work (it did before).
  • muru
    muru over 9 years
    @Erik what happens when you run transmission-daemon manually? What error does it show when you stop it?
  • muru
    muru over 9 years
    Oh, crap. The last command in that set: sudo chown your_user -R /etc/transmission-daemon/settings.json sets your user as the owner of the settings file, and that file has read-permissions only for the owner by default. Transmission won't even be able to read it. Try: sudo service transmission-daemon stop; sudo chmod g+rw /etc/transmission-daemon/settings.json; sudo service transmission-daemon start
  • Erik
    Erik over 9 years
    That did the trick. It runs again now. I got this new error now: Error: Unable to save resume file: Permission denied so I still have work to do. But at least it is running again.
  • muru
    muru over 9 years
    @Erik it's the same bug: /var/lib/transmission-daemon/info/ does not have group write permissions and we have set the owner to your user. Another chmod g+w needed.
  • Erik
    Erik over 9 years
    I followed all your instructions (thanks for being so thorough) but it does not seem to help. These are my download folders drwsrwxrwx 2 debian-transmission debian-transmission 4096 sep 8 22:35 completed drwsrwxrwx 2 debian-transmission debian-transmission 4096 sep 8 22:35 incomplete drwxrwxr-x 2 erik erik 4096 sep 8 22:35 torrents And this is the other folder Access: (4775/drwsrwxr-x) Uid: ( 1000/ erik) Gid: ( 128/debian-transmission) Is there anything else I can check to help solve this?
  • muru
    muru over 9 years
    @Erik you can remove the accept since the problem hasn't been solved. What are the current permissions of /var/lib/transmission-daemon/info/, and your download folders? Does transmission give any other error? You can edit your question to add the information.
  • koogee
    koogee almost 8 years
    you need to edit /etc/init.d/transmission-daemon as well and run the daemon as your username
  • Prasanth Louis
    Prasanth Louis over 7 years
    If you're having permission access Eg. To the resume file, all you need to do is change the ownership to g+rw for whatever user the tranmission-daemon is running as. This includes the directories it's being downloaded to. For the resume file its here /var/lib/transmission-daemon/.config/transmission-daemon/res‌​ume