bryson_ac wrote:i switched the transmission package to zebulon's, found here:
http://synoblog.superzebulon.org/category/transmission/ - it can be run under a specific user, which i actually consider "safer" than running it under "root". it's up-to-date with 2.11 and comes with all the utilities, including transmission-remote.
thanks for the link! I'll take a look at this.
however i'd love if anyone with more expertise in this area could explain to us if running transmission as root is a real danger or problematic in any way.
bryson_ac wrote:having said that: you're "remove" script works just fine, thanks! am trying now to include a "unrar" and "email notification upon completion" part ... we'll see how that goes.
I might be able to help here. The script I used to remove the torrents originally included such functionality. All I needed was the part that removes the torrents ("transmission-remote -n name:password -t$TR_TORRENT_ID --remove &") as I don't d/l rar-files. Heres the complete script (which I did not test):
- Code: Select all
#! /bin/sh
cd $TR_TORRENT_DIR
if [ -d "$TR_TORRENT_NAME" ]
then
if ls "$TR_TORRENT_NAME"/*.rar > /dev/null 2>&1
then
find "$TR_TORRENT_NAME" -iname "*.rar" | while read file
do
unrar x -inul "$file"
done
transmission-remote -n name:password -t$TR_TORRENT_ID --remove &
echo "Unrarred" $TR_TORRENT_NAME >> /var/log/posttorrent.log
fi
fi
I don't think the unrar package is installed by default but it certainly can be found with ipkg.
Finally I found the reason why I kept getting this error about the missing permissions to the Transmission-Session-Id file.
This file is being created by torrentwatch-x. The way the permissions are set on this file is determined by the tor_client.php script.
Line 50 of this file reads:
- Code: Select all
if($platform == 'NMT') chmod($sessionIdFile, 0666);
However there is no chmod command in this script for the case that the platform is NOT set to be "NMT" (what kind of platform torrentwatch-x thinks its dealing with is set in the config.php file and the platform.php file).
So all I did was to change line 50 in the tor_client.php file to this:
- Code: Select all
if($platform != 'NMT') chmod($sessionIdFile, 0666);
This way the permissions are set the right way and the webserver user has access to the file. (might be different for other versions of torrentwatch-x. I have 0.6.5 beta2)
bry, how are you going to deal with DSM updates? Did you install the lastest update (DSM 3.0-1354)? Am not sure if I should as it changes the php-version and theres no going back to the older version if things end up broken...
cheers,
dash