The Notebook Review forums were hosted by TechTarget, who shut down them down on January 31, 2022. This static read-only archive was pulled by NBR forum users between January 20 and January 31, 2022, in an effort to make sure that the valuable technical information that had been posted on the forums is preserved. For current discussions, many NBR forum users moved over to NotebookTalk.net after the shutdown.
Problems? See this thread at archive.org.

    DNS-321 Torrent Permission Errors

    Discussion in 'Linux Compatibility and Software' started by SoundOf1HandClapping, Aug 10, 2010.

  1. SoundOf1HandClapping

    SoundOf1HandClapping Was once a Forge

    Reputations:
    2,360
    Messages:
    5,594
    Likes Received:
    16
    Trophy Points:
    206
    First, I hope this is the right area. The DNS-321 is a NAS, but since the problem I'm encountering seems to be Linux-based, not the NAS itself, I'm posting it here.

    Anyway. The DNS-321 is hackable to do some lightweight Linux stuff, using Fonz Fun Plug ( Directions here). I then install Transmission 2.03 ( directions here) and start torrenting. I give folder permission to user "nobody" in group "501", and for the most part is works. I can fully manipulate torrent files whether they are a single file or if they were a group of files in the torrent.

    However, when I restart my laptop I run into my problem. If the torrent was a single file, I still have full control over it. However, if it's a new folder created I get "You need permission to perform this action; you require permission from Unix User/Nobody to make changes to this file. In short, if it's "Torrents/Blargh.mkv" I have full read/write/rename control over Blargh.mkv. However, if it's something like "Torrents/FolderOfBlahhhh/Blahhhh01.mkv", I cannot cut, remove, or rename Blahhhh01.mkv. I can, however, rename "FolderOfBlahhhh", but not delete it.



    Here's a complete list of the steps I took to do FFP and Transmission. Brackets are little sidenotes and not part of the actual input

    I log into Telnet via Putty.
    Code:
    pwconv 
    
    passwd
    
    [I insert my password]
    
    usermod -s /ffp/bin/sh root
    
    login     [I login using user root and my personal password]
    
    store-passwd.sh
    
    chmod a+x /ffp/start/sshd.sh
    
    sh /ffp/start/sshd.sh start
    
    chmod -x /ffp/start/telnetd.sh
    
    I then close the Telnet Putty and start up a SSH Putty. I install Tranmission 2.03 and the required files as per instructions. My configuration is as follows

    Code:
    su nobody -c "transmission-daemon -f -g /mnt/HD_a2/.transmission-daemon -t -u [I insert username here] -v [I insert password here] -a 127.0.0.1,192.168.*.*"     [I use a username/password that's part of the usergroups in the NAS]
    I restart SSH after this step]

    Code:
    chown -R nobody:501 /mnt/HD_a2/.transmission-daemon
    
    chown -R nobody:501 /mnt/HD_a2/Torrents
    I check permissions

    Code:
    ls /mnt/HD_a2/.transmission-daemon -l
    drwxr-xr-x    2 nobody   501          4096 Jul 30 08:53 blocklists
    -rw-------    1 nobody   501           544 Aug  7 19:20 dht.dat
    drwxr-xr-x    2 nobody   501          4096 Aug 10 19:51 resume
    -rw-------    1 nobody   501          1895 Aug 10 10:15 settings.json
    -rw-------    1 nobody   501           158 Aug 10 19:51 stats.json
    drwxr-xr-x    2 nobody   501          4096 Aug 10 13:06 torrents
    -rw-r--r--    1 nobody   501          1614 Aug 10 10:14 transmission-daemon.log
    root@GregBox1:~# ls /mnt/HD_a2/Torrents -l
    drwxr-xr-x    2 nobody   501          4096 Aug 10 16:02 Heroic Age [Blu-Ray 720p]
    drwxr-xr-x    2 nobody   501          4096 Aug 10 10:19 The.Forbidden.Kingdom
    At this point everything is well and good. I can manipulate anything in Windows Explorer. I can even go into the transmission-daemon config folder and view/edit settings.js0n. However, once I restart my computer and login into Win7 using my Windows username/password, I get denied.


    So... I know it's almost TL;DR, but anyone have a clue? The workaround I'm using is to reset to default and reinstall FFP, but I'm getting annoyed with that.
     
  2. ALLurGroceries

    ALLurGroceries  Vegan Vermin Super Moderator

    Reputations:
    15,730
    Messages:
    7,146
    Likes Received:
    2,343
    Trophy Points:
    331
    Sounds like the share is being mounted with the wrong directory mask (permissions mask) and the user mounting it is not the same as the (nobody) owner. You can set the dirmask to 0777 and it will give everyone read/write access to it.

    For example in my fstab I have a samba share that has the option (this is to mount a remote share):
    Code:
    dir_mode=0777
    On another machine, I share a public folder and here's the excerpt from smb.conf (this is to share to other computers):
    Code:
    [public]
       comment = public
       read only = no
       locking = no
       path = /home/groceries/public
       guest ok = yes
       browseable = yes
       writeable = yes
       create mask = 777
       directory mask = 777
       public = yes
    
     
  3. SoundOf1HandClapping

    SoundOf1HandClapping Was once a Forge

    Reputations:
    2,360
    Messages:
    5,594
    Likes Received:
    16
    Trophy Points:
    206
    Hope I'm not asking too much, but what commands do I use to do that? This is the first time I've ever used Linux. Is it chmod?

    Or maybe I'll reload FFP--to get access to settings.js0n back again--and modify the text file itself.
     
  4. ALLurGroceries

    ALLurGroceries  Vegan Vermin Super Moderator

    Reputations:
    15,730
    Messages:
    7,146
    Likes Received:
    2,343
    Trophy Points:
    331
    I'm not sure if it is your problem, it just sounds like you have the wrong dirmask and/or the account you're using to log in has no permissions for that folder. You can edit /etc/samba/smb.conf (if one exists), or tweak that json config file but I'm not sure where it would go in that. You might try posting on the forum that you linked to, since there are probably more people who know your setup there...
     
  5. SoundOf1HandClapping

    SoundOf1HandClapping Was once a Forge

    Reputations:
    2,360
    Messages:
    5,594
    Likes Received:
    16
    Trophy Points:
    206
    I already posted there, but the expert guy isn't there at the moment, and the help I've been getting from the other people hasn't turned out so well. Well, I'll keep plunking around.
     
  6. ALLurGroceries

    ALLurGroceries  Vegan Vermin Super Moderator

    Reputations:
    15,730
    Messages:
    7,146
    Likes Received:
    2,343
    Trophy Points:
    331
    Try a chmod -R 777 /mnt/HD_a2/Torrents and that should work for stuff you've already downloaded. But if you download new stuff and it doesn't let you in it's probably the directory mask.
     
  7. SoundOf1HandClapping

    SoundOf1HandClapping Was once a Forge

    Reputations:
    2,360
    Messages:
    5,594
    Likes Received:
    16
    Trophy Points:
    206
    Seems to be working again, after reinstalling everything. I set umask to 0. I'll what comes of it. Thanks for the help.