transmission-remote

I'm currently working on a script that runs after a torrent is done.
My problem is transmission-remote doesn't output anything.
If I try transmission-remote -n user:pass -l when SSHing to my NAS I only get some message with: " SUCCESS!"
I googled my ass off and I only found some RPC-related thing, but I'm quite stuck at what to do.
When I add the --debug to it, I can see the output, but I can't pipe it to a file.
Differrent problem:
When I use transmissions script-after-done option, it gives me the torrent id, but when I put for example transmission-remote -n user:pass -t ID --remove
it doesn't remove the torrent at all with no errors in my log.
When I do it manually, with SSH, it DOES work...
My testscript (currently hit-and-run script ;) I will be adding some sleep() to it):
Also the logfile is saved as posttorrent.log?? not as posttorrent.log.
The weird thing is everything works except for the transmission-remote....
When I just do : transmission-remote >> $LOG_FILE, it DOES output the help information in my log...
Any ideas someone? Is transmission-daemon runned as root?
My problem is transmission-remote doesn't output anything.
If I try transmission-remote -n user:pass -l when SSHing to my NAS I only get some message with: " SUCCESS!"
I googled my ass off and I only found some RPC-related thing, but I'm quite stuck at what to do.
When I add the --debug to it, I can see the output, but I can't pipe it to a file.
Differrent problem:
When I use transmissions script-after-done option, it gives me the torrent id, but when I put for example transmission-remote -n user:pass -t ID --remove
it doesn't remove the torrent at all with no errors in my log.
When I do it manually, with SSH, it DOES work...
My testscript (currently hit-and-run script ;) I will be adding some sleep() to it):
- Code: Select all
# !/bin/sh
# posttorrent script
# Log file, file where we tell what events have been processed.
LOG_FILE="/share/1000/tr-downloads/log/posttorrent.log"
NOW=$(date +%Y-%m-%d\ %H:%M:%S)
echo $NOW "Finished $TR_TORRENT_NAME" >> $LOG_FILE
transmission-remote -n admin:***** -t $TR_TORRENT_ID --remove >> $LOG_FILE
echo $NOW "Torrent $TR_TORRENT_NAME met id: $TR_TORRENT_ID verwijderd..." >> $LOG_FILE
# chmodding for samba
chmod -R 777 /share/1000/tr-downloads
Also the logfile is saved as posttorrent.log?? not as posttorrent.log.
The weird thing is everything works except for the transmission-remote....
When I just do : transmission-remote >> $LOG_FILE, it DOES output the help information in my log...
Any ideas someone? Is transmission-daemon runned as root?