Transmission


Recommended Posts

Buenas,

Cual es la mejor configuración de transmisión funcione correctamente e el synology? Algún manual para su instalación?

 

Nexus 6 with Tapatalk

Link to post
Share on other sites

Yo lo tengo configurado a la vez que Download Station.

Uso transmision para trackers privados --que requieren mantener los archivos compartidos durante más tiempo-- y DS para trackers públicos.

 

Estas son mis notas sobre la configuración:

 

AÑADIR PACKAGE SOURCE A PACKAGE CENTER

http://packages.synocommunity.com/

 

Instalar desde el Package Center

 

 

CAMBIAR CONFIGURACION

 

* Stop the Transmission service

* SSH to your NAS as root

* cd /volume1/@appstore/transmission/var

* vi settings.json

* modify the download-dir line to change the download destination. Alternatively, you can break the downloads into complete and incomplete by setting incomplete-dir to where you want incomplete torrents to go, and incomplete-dir-enabled to true.

* setting the watch-dir directory will let you upload to a particular directory (typically 'incoming') and transmission will scan that dir for new .torrent files, and add them when they appear.

* save the settings.json file

* make sure the directories you specify exist, and are read/write capable by user transmission

* Run the Transmission service

 

 

EJEMPLOS DE COMANDOS

 

NAS> /usr/local/transmission/bin/transmission-remote --auth miusuario:????--list

ID Done Have ETA Up Down Ratio Status Name

1 100% 77.48 GB Unknown 0.0 0.0 0.2 Idle la que se avecina

2 100% 9.95 GB Unknown 0.0 0.0 0.2 Idle La Venus de las Pieles 2013 BDRip 1080p DTS-FaViO.mkv

3 100% 14.05 GB Unknown 0.0 0.0 0.1 Idle Al.Encuentro.De.Mr.Banks.1080p.DTS.DTS-HD.Dual.Bluray.2013.[TRCKHD].mkv

4 100% 24.68 GB Unknown 0.0 0.0 0.2 Idle Rebeldes.(La.obra.completa).BDremux.1080p.DTS.DTS-HD.Dual.Bluray.1983.[TRCKHD].mkv

5 100% 1.59 GB 6 days 0.0 0.0 0.6 Idle Ocho Apellidos Vascos [DVD Rip][AC3 2.0 Español Castellano][2014]

6 100% 34.78 GB Unknown 0.0 0.0 0.6 Idle Hasta.que.llegó.su.hora.BDremux.1080p.AC3.DTS-HD.Dual.Bluray.1968.[TRCKHD].mkv

7 100% 5.04 GB Unknown 0.0 0.0 0.0 Idle Juego de Tronos XXX.2014.BR-720p.AC3.ING.GrupoD69M.xBytes.mkv

8 100% 19.79 GB Unknown 0.0 0.0 0.3 Idle Speed.BDREMUX.1080p.DTS.DTS-HD.Dual.Bluray.1994.mkv

9 100% 2.15 GB Unknown 0.0 0.0 0.0 Idle Juego.De.Tronos.S04E08.1080p.AC3.Dual.HDTV.2014.mkv

Sum: 189.5 GB 0.0 0.0

 

 

NAS> /usr/local/transmission/bin/transmission-remote --auth miusuario:????--torrent 1 --info

NAME

Id: 1

Name: la que se avecina

Hash: 3327f1c1429b33ced1a31b65022bfcf19c147dcc

Magnet: magnet:?xt=urn:btih:3327f1c1429b33ced1a31b65022bfcf19c147dcc&dn=la%20que%20se%20avecina&tr=http%3A%2F%2Fwww.xbytes.li%2Fannounce.php%3Fpasskey%3Dc665adb591628db73b4eb9563605cd60

 

TRANSFER

State: Idle

Location: /volume1/descargas/030_DESCARGADO_SEEDING

Percent Done: 100%

ETA: 0 seconds (0 seconds)

Download Speed: 0 kB/s

Upload Speed: 0 kB/s

Have: 77.48 GB (77.48 GB verified)

Availability: 100%

Total size: 77.48 GB (77.48 GB wanted)

Downloaded: 77.49 GB

Uploaded: 21.06 GB

Ratio: 0.2

Corrupt DL: None

Peers: connected to 0, uploading to 0, downloading from 0

 

HISTORY

Date added: Sat May 31 20:12:01 2014

Date finished: Mon Jun 2 02:30:47 2014

Date started: Wed Jun 4 19:32:56 2014

Latest activity: Wed Jun 4 00:03:54 2014

Downloading Time: 17 hours (63732 seconds)

Seeding Time: 2 days (175808 seconds)

 

ORIGINS

Date created: Wed May 28 13:03:11 2014

Public torrent: Yes

Creator: uTorrent/2040

Piece Count: 18474

Piece Size: 4.00 MiB

 

LIMITS & BANDWIDTH

Download Limit: Unlimited

Upload Limit: Unlimited

Ratio Limit: Default

Honors Session Limits: Yes

Peer limit: 60

Bandwidth Priority: Normal

 

 

 

SCRIPT AUTOMATIZACION

 

Preparar script y ejecutarlo mediante cron, para dejar de compartir descargas que han cumplido los requisitos del tracker privado.

 

#!/bin/sh

 

## Script for tranmission on synology

## Problems:

## * The custom package of tranmission on synology machines does not run scripts after completion [1]

## * Couchpotato Server does not appear to activate the postprocessing once a torrent has finished downloading

##

## Solution:

## * In the synology taskplanner I set up a task to run every 2 hours to run this script

##

## Script:

## 1) check which torrents are finished downloading

## 2) remove completed torrents from transmission

## 3) run Couchpotato renamer if completed torrents are found

## 4) If there are no torrents in torrent list, clean up download directory

## !!This option is disabled by default, because it uncareful usage may delete all data!!

##

## Prerequisites:

## * Synology machine (currently tested on Synology DS411j, DSM 4.2-3211)

## * Transmission & Couchpotato Server (SPK's obtained from SynoCommunity repository)

## * Enable Couchpotato Renamer, but set so that it never runs [3]

##

## Warning: Regarding 4)

## * My transmission downloads to a temporary directory. Movies that have finished downloading are

## moved to $DOWNLOADDIR. Thus if all movies have been processed this folder contains no more movies and can be safely deleted

## * the Couchpotato renamer will need some time to process. Therefor do not set up the taskplanner to run to often. Every 1 or 2 hours is sufficient

##

## Referencias:

## https://forum.transmissionbt.com/viewto ... =2&t=13970

## https://forum.transmissionbt.com/viewto ... =2&t=11468

## https://couchpota.to/forum/viewtopic.ph ... 9db1#p7330

## https://forum.transmissionbt.com/viewto ... 792#p64792

## https://forum.transmissionbt.com/viewto ... =1&t=13427

##

## date: 9 may 2013

 

# Inputs

USER="miusuario"

PASSWORD="????"

TRANSMISSION="/usr/local/transmission/bin/transmission-remote --auth $USER:$PASSWORD"

 

DESCARGADO_SEEDING="/volume1/descargas/030_DESCARGADO_SEEDING"

DESCARGADO_OFFLINE="/volume1/descargas/040_DESCARGADO_OFFLINE"

 

COMPLETADOS_BORRAR_TORRENT=1

COMPLETADOS_MOVER_A_OFFLINE=1

COMPLETADOS_TIEMPO_SIEMBRA=`expr 86400 \* 2` # Máximo 2 dias en segundos

 

# COUCHPOTATOURL=localhost

# COUCHPOTATOPORT=5050

# COUCHPOTATOAPI=couchpotatoapi

 

# Initialize

LISTA_COMPLETADOS=""

 

echo ""

echo "++++++ PROCESAR TORRENTS DESCARGADOS Y SEMBRADOS +++++"

echo "`date`"

echo "++++++++++++++++++++++++++++++++++++++++++++++++++++++"

 

# Lista de Torrents

TORRENTLIST=`$TRANSMISSION --list | sed -e '1d;$d;s/^ *//' | cut -s -d" " -f 1 | sed "s/[^0-9]//"`

for TORRENTID in $TORRENTLIST ; do

 

DL_COMPLETED=`$TRANSMISSION --torrent $TORRENTID --info | grep "Percent Done: 100%"`

STATE_FINISHED=`$TRANSMISSION --torrent $TORRENTID --info | grep "State: Stopped\|Finished\|Idle"`

 

# ------- Comprobamos tiempo de siembra

ALCANZADO_TIEMPO_SIEMBRA=0

TORRENTNAME="`$TRANSMISSION --torrent $TORRENTID --info | grep "Name:" | sed -e 's/ *Name: *//'`"

# Es una carpeta, recorrer ficheros

if [ -d "$DESCARGADO_SEEDING/$TORRENTNAME" ]; then

LASTMODIFIED=0

find "$DESCARGADO_SEEDING/$TORRENTNAME" | while read FILE ; do

AGE=`stat "$FILE" -c%Y`

if [ $AGE -gt $LASTMODIFIED ]; then

LASTMODIFIED=$AGE

fi

done

# Es un fichero unico

else

LASTMODIFIED=`stat "$DESCARGADO_SEEDING/$TORRENTNAME" -c%Y`

fi

 

TIME=`date +%s`

DIFF=`expr $TIME - $LASTMODIFIED`

 

# Se ha alcanzado el tiempo maximo de siembra COMPLETADOS_TIEMPO_SIEMBRA

if [ $DIFF -gt $COMPLETADOS_TIEMPO_SIEMBRA ]; then

ALCANZADO_TIEMPO_SIEMBRA=1

fi

 

 

if [ "$DL_COMPLETED" != "" ] && [ "$STATE_FINISHED" != "" ] && [ "$ALCANZADO_TIEMPO_SIEMBRA" -eq 1 ]; then

echo "Torrent #$TORRENTID: completado."

LISTA_COMPLETADOS="$LISTA_COMPLETADOS $TORRENTID"

else

echo "Torrent #$TORRENTID: no completado. Lo ignoramos"

fi

done

 

 

if [ "$LISTA_COMPLETADOS" != "" ]; then

echo "Torrents finalizados y sembrados: "$LISTA_COMPLETADOS

fi

 

 

for TORRENTID in $LISTA_COMPLETADOS ; do

 

TORRENTNAME="`$TRANSMISSION --torrent $TORRENTID --info | grep "Name:" | sed -e 's/ *Name: *//'`"

echo "Tratando torrent $TORRENTID : $TORRENTNAME"

 

if [ $COMPLETADOS_BORRAR_TORRENT -eq 1 ] ; then

$TRANSMISSION --torrent $TORRENTID --remove

if [ $? -eq 0 ] ; then

echo "... torrent borrado en transmission"

else

echo "ERROR AL BORRAR TORRENT"

fi

else

echo "... no borramos torrent (desactivado)"

fi

 

if [ $COMPLETADOS_MOVER_A_OFFLINE -eq 1 ] ; then

if [ -f "$DESCARGADO_SEEDING/$TORRENTNAME" -o -d "$DESCARGADO_SEEDING/$TORRENTNAME"] ; then

mv "$DESCARGADO_SEEDING/$TORRENTNAME" "$DESCARGADO_OFFLINE"

if [ $? -eq 0 ] ; then

echo "... fichero movido a $DESCARGADO_OFFLINE"

else

echo "ERROR AL MOVER FICHERO"

fi

else

echo "... ERROR NO SE HA ENCONTRADO EL FICHERO."

fi

else

echo "... no movemos fichero (desactivado)"

fi

 

done

 

# # Activate Couchpotato renamer

# if [ $RUNCOUCHPOTATOPOSTPROCESS == "TRUE" ]; then

# echo Run Couchpotato renamer

# # start couchpotato postprocessing script

# curl http://$COUCHPOTATOURL:$COUCHPOTATOPORT ... amer.scan/

# printf "\n"

# fi

 

echo "++++++++++++++++++++++++++ FINISHED ++++++++++++++++++++++++++"

Link to post
Share on other sites

Gracias. Solucionado.

El problema era al instalar, los directorios donde se ponia las descargas incompletas y demás estaban en un directorio que no permitía modifcación por el usuario en si. Los he cambiado y todo ok.

Edito ese fichero con la app Config File Editor 1.4 que va muy bien !

 

Gracias!!!!!!!!!

Link to post
Share on other sites
  • 5 months later...
Yo lo tengo configurado a la vez que Download Station.

Uso transmision para trackers privados --que requieren mantener los archivos compartidos durante más tiempo-- y DS para trackers públicos.

 

Estas son mis notas sobre la configuración:

 

AÑADIR PACKAGE SOURCE A PACKAGE CENTER

http://packages.synocommunity.com/

 

Instalar desde el Package Center

 

 

CAMBIAR CONFIGURACION

 

* Stop the Transmission service

* SSH to your NAS as root

* cd /volume1/@appstore/transmission/var

* vi settings.json

* modify the download-dir line to change the download destination. Alternatively, you can break the downloads into complete and incomplete by setting incomplete-dir to where you want incomplete torrents to go, and incomplete-dir-enabled to true.

* setting the watch-dir directory will let you upload to a particular directory (typically 'incoming') and transmission will scan that dir for new .torrent files, and add them when they appear.

* save the settings.json file

* make sure the directories you specify exist, and are read/write capable by user transmission

* Run the Transmission service

 

 

EJEMPLOS DE COMANDOS

 

NAS> /usr/local/transmission/bin/transmission-remote --auth miusuario:????--list

ID Done Have ETA Up Down Ratio Status Name

1 100% 77.48 GB Unknown 0.0 0.0 0.2 Idle la que se avecina

2 100% 9.95 GB Unknown 0.0 0.0 0.2 Idle La Venus de las Pieles 2013 BDRip 1080p DTS-FaViO.mkv

3 100% 14.05 GB Unknown 0.0 0.0 0.1 Idle Al.Encuentro.De.Mr.Banks.1080p.DTS.DTS-HD.Dual.Bluray.2013.[TRCKHD].mkv

4 100% 24.68 GB Unknown 0.0 0.0 0.2 Idle Rebeldes.(La.obra.completa).BDremux.1080p.DTS.DTS-HD.Dual.Bluray.1983.[TRCKHD].mkv

5 100% 1.59 GB 6 days 0.0 0.0 0.6 Idle Ocho Apellidos Vascos [DVD Rip][AC3 2.0 Español Castellano][2014]

6 100% 34.78 GB Unknown 0.0 0.0 0.6 Idle Hasta.que.llegó.su.hora.BDremux.1080p.AC3.DTS-HD.Dual.Bluray.1968.[TRCKHD].mkv

7 100% 5.04 GB Unknown 0.0 0.0 0.0 Idle Juego de Tronos XXX.2014.BR-720p.AC3.ING.GrupoD69M.xBytes.mkv

8 100% 19.79 GB Unknown 0.0 0.0 0.3 Idle Speed.BDREMUX.1080p.DTS.DTS-HD.Dual.Bluray.1994.mkv

9 100% 2.15 GB Unknown 0.0 0.0 0.0 Idle Juego.De.Tronos.S04E08.1080p.AC3.Dual.HDTV.2014.mkv

Sum: 189.5 GB 0.0 0.0

 

 

NAS> /usr/local/transmission/bin/transmission-remote --auth miusuario:????--torrent 1 --info

NAME

Id: 1

Name: la que se avecina

Hash: 3327f1c1429b33ced1a31b65022bfcf19c147dcc

Magnet: magnet:?xt=urn:btih:3327f1c1429b33ced1a31b65022bfcf19c147dcc&dn=la%20que%20se%20avecina&tr=http%3A%2F%2Fwww.xbytes.li%2Fannounce.php%3Fpasskey%3Dc665adb591628db73b4eb9563605cd60

 

TRANSFER

State: Idle

Location: /volume1/descargas/030_DESCARGADO_SEEDING

Percent Done: 100%

ETA: 0 seconds (0 seconds)

Download Speed: 0 kB/s

Upload Speed: 0 kB/s

Have: 77.48 GB (77.48 GB verified)

Availability: 100%

Total size: 77.48 GB (77.48 GB wanted)

Downloaded: 77.49 GB

Uploaded: 21.06 GB

Ratio: 0.2

Corrupt DL: None

Peers: connected to 0, uploading to 0, downloading from 0

 

HISTORY

Date added: Sat May 31 20:12:01 2014

Date finished: Mon Jun 2 02:30:47 2014

Date started: Wed Jun 4 19:32:56 2014

Latest activity: Wed Jun 4 00:03:54 2014

Downloading Time: 17 hours (63732 seconds)

Seeding Time: 2 days (175808 seconds)

 

ORIGINS

Date created: Wed May 28 13:03:11 2014

Public torrent: Yes

Creator: uTorrent/2040

Piece Count: 18474

Piece Size: 4.00 MiB

 

LIMITS & BANDWIDTH

Download Limit: Unlimited

Upload Limit: Unlimited

Ratio Limit: Default

Honors Session Limits: Yes

Peer limit: 60

Bandwidth Priority: Normal

 

 

 

SCRIPT AUTOMATIZACION

 

Preparar script y ejecutarlo mediante cron, para dejar de compartir descargas que han cumplido los requisitos del tracker privado.

 

#!/bin/sh

 

## Script for tranmission on synology

## Problems:

## * The custom package of tranmission on synology machines does not run scripts after completion [1]

## * Couchpotato Server does not appear to activate the postprocessing once a torrent has finished downloading

##

## Solution:

## * In the synology taskplanner I set up a task to run every 2 hours to run this script

##

## Script:

## 1) check which torrents are finished downloading

## 2) remove completed torrents from transmission

## 3) run Couchpotato renamer if completed torrents are found

## 4) If there are no torrents in torrent list, clean up download directory

## !!This option is disabled by default, because it uncareful usage may delete all data!!

##

## Prerequisites:

## * Synology machine (currently tested on Synology DS411j, DSM 4.2-3211)

## * Transmission & Couchpotato Server (SPK's obtained from SynoCommunity repository)

## * Enable Couchpotato Renamer, but set so that it never runs [3]

##

## Warning: Regarding 4)

## * My transmission downloads to a temporary directory. Movies that have finished downloading are

## moved to $DOWNLOADDIR. Thus if all movies have been processed this folder contains no more movies and can be safely deleted

## * the Couchpotato renamer will need some time to process. Therefor do not set up the taskplanner to run to often. Every 1 or 2 hours is sufficient

##

## Referencias:

## https://forum.transmissionbt.com/viewto ... =2&t=13970

## https://forum.transmissionbt.com/viewto ... =2&t=11468

## https://couchpota.to/forum/viewtopic.ph ... 9db1#p7330

## https://forum.transmissionbt.com/viewto ... 792#p64792

## https://forum.transmissionbt.com/viewto ... =1&t=13427

##

## date: 9 may 2013

 

# Inputs

USER="miusuario"

PASSWORD="????"

TRANSMISSION="/usr/local/transmission/bin/transmission-remote --auth $USER:$PASSWORD"

 

DESCARGADO_SEEDING="/volume1/descargas/030_DESCARGADO_SEEDING"

DESCARGADO_OFFLINE="/volume1/descargas/040_DESCARGADO_OFFLINE"

 

COMPLETADOS_BORRAR_TORRENT=1

COMPLETADOS_MOVER_A_OFFLINE=1

COMPLETADOS_TIEMPO_SIEMBRA=`expr 86400 \* 2` # Máximo 2 dias en segundos

 

# COUCHPOTATOURL=localhost

# COUCHPOTATOPORT=5050

# COUCHPOTATOAPI=couchpotatoapi

 

# Initialize

LISTA_COMPLETADOS=""

 

echo ""

echo "++++++ PROCESAR TORRENTS DESCARGADOS Y SEMBRADOS +++++"

echo "`date`"

echo "++++++++++++++++++++++++++++++++++++++++++++++++++++++"

 

# Lista de Torrents

TORRENTLIST=`$TRANSMISSION --list | sed -e '1d;$d;s/^ *//' | cut -s -d" " -f 1 | sed "s/[^0-9]//"`

for TORRENTID in $TORRENTLIST ; do

 

DL_COMPLETED=`$TRANSMISSION --torrent $TORRENTID --info | grep "Percent Done: 100%"`

STATE_FINISHED=`$TRANSMISSION --torrent $TORRENTID --info | grep "State: Stopped\|Finished\|Idle"`

 

# ------- Comprobamos tiempo de siembra

ALCANZADO_TIEMPO_SIEMBRA=0

TORRENTNAME="`$TRANSMISSION --torrent $TORRENTID --info | grep "Name:" | sed -e 's/ *Name: *//'`"

# Es una carpeta, recorrer ficheros

if [ -d "$DESCARGADO_SEEDING/$TORRENTNAME" ]; then

LASTMODIFIED=0

find "$DESCARGADO_SEEDING/$TORRENTNAME" | while read FILE ; do

AGE=`stat "$FILE" -c%Y`

if [ $AGE -gt $LASTMODIFIED ]; then

LASTMODIFIED=$AGE

fi

done

# Es un fichero unico

else

LASTMODIFIED=`stat "$DESCARGADO_SEEDING/$TORRENTNAME" -c%Y`

fi

 

TIME=`date +%s`

DIFF=`expr $TIME - $LASTMODIFIED`

 

# Se ha alcanzado el tiempo maximo de siembra COMPLETADOS_TIEMPO_SIEMBRA

if [ $DIFF -gt $COMPLETADOS_TIEMPO_SIEMBRA ]; then

ALCANZADO_TIEMPO_SIEMBRA=1

fi

 

 

if [ "$DL_COMPLETED" != "" ] && [ "$STATE_FINISHED" != "" ] && [ "$ALCANZADO_TIEMPO_SIEMBRA" -eq 1 ]; then

echo "Torrent #$TORRENTID: completado."

LISTA_COMPLETADOS="$LISTA_COMPLETADOS $TORRENTID"

else

echo "Torrent #$TORRENTID: no completado. Lo ignoramos"

fi

done

 

 

if [ "$LISTA_COMPLETADOS" != "" ]; then

echo "Torrents finalizados y sembrados: "$LISTA_COMPLETADOS

fi

 

 

for TORRENTID in $LISTA_COMPLETADOS ; do

 

TORRENTNAME="`$TRANSMISSION --torrent $TORRENTID --info | grep "Name:" | sed -e 's/ *Name: *//'`"

echo "Tratando torrent $TORRENTID : $TORRENTNAME"

 

if [ $COMPLETADOS_BORRAR_TORRENT -eq 1 ] ; then

$TRANSMISSION --torrent $TORRENTID --remove

if [ $? -eq 0 ] ; then

echo "... torrent borrado en transmission"

else

echo "ERROR AL BORRAR TORRENT"

fi

else

echo "... no borramos torrent (desactivado)"

fi

 

if [ $COMPLETADOS_MOVER_A_OFFLINE -eq 1 ] ; then

if [ -f "$DESCARGADO_SEEDING/$TORRENTNAME" -o -d "$DESCARGADO_SEEDING/$TORRENTNAME"] ; then

mv "$DESCARGADO_SEEDING/$TORRENTNAME" "$DESCARGADO_OFFLINE"

if [ $? -eq 0 ] ; then

echo "... fichero movido a $DESCARGADO_OFFLINE"

else

echo "ERROR AL MOVER FICHERO"

fi

else

echo "... ERROR NO SE HA ENCONTRADO EL FICHERO."

fi

else

echo "... no movemos fichero (desactivado)"

fi

 

done

 

# # Activate Couchpotato renamer

# if [ $RUNCOUCHPOTATOPOSTPROCESS == "TRUE" ]; then

# echo Run Couchpotato renamer

# # start couchpotato postprocessing script

# curl http://$COUCHPOTATOURL:$COUCHPOTATOPORT ... amer.scan/

# printf "\n"

# fi

 

echo "++++++++++++++++++++++++++ FINISHED ++++++++++++++++++++++++++"

 

Hola, y por qué no mola Download Station para los trackers privados?

 

Es que estoy en DSM desde ayer, y estoy tratando de empaparme!

 

Muchas gracias.

Link to post
Share on other sites
  • 2 months later...
Yo lo tengo configurado a la vez que Download Station.

Uso transmision para trackers privados --que requieren mantener los archivos compartidos durante más tiempo-- y DS para trackers públicos.

 

Estas son mis notas sobre la configuración:

 

AÑADIR PACKAGE SOURCE A PACKAGE CENTER

http://packages.synocommunity.com/

 

Instalar desde el Package Center

 

 

CAMBIAR CONFIGURACION

 

* Stop the Transmission service

* SSH to your NAS as root

* cd /volume1/@appstore/transmission/var

* vi settings.json

* modify the download-dir line to change the download destination. Alternatively, you can break the downloads into complete and incomplete by setting incomplete-dir to where you want incomplete torrents to go, and incomplete-dir-enabled to true.

* setting the watch-dir directory will let you upload to a particular directory (typically 'incoming') and transmission will scan that dir for new .torrent files, and add them when they appear.

* save the settings.json file

* make sure the directories you specify exist, and are read/write capable by user transmission

* Run the Transmission service

 

 

EJEMPLOS DE COMANDOS

 

NAS> /usr/local/transmission/bin/transmission-remote --auth miusuario:????--list

ID Done Have ETA Up Down Ratio Status Name

1 100% 77.48 GB Unknown 0.0 0.0 0.2 Idle la que se avecina

2 100% 9.95 GB Unknown 0.0 0.0 0.2 Idle La Venus de las Pieles 2013 BDRip 1080p DTS-FaViO.mkv

3 100% 14.05 GB Unknown 0.0 0.0 0.1 Idle Al.Encuentro.De.Mr.Banks.1080p.DTS.DTS-HD.Dual.Bluray.2013.[TRCKHD].mkv

4 100% 24.68 GB Unknown 0.0 0.0 0.2 Idle Rebeldes.(La.obra.completa).BDremux.1080p.DTS.DTS-HD.Dual.Bluray.1983.[TRCKHD].mkv

5 100% 1.59 GB 6 days 0.0 0.0 0.6 Idle Ocho Apellidos Vascos [DVD Rip][AC3 2.0 Español Castellano][2014]

6 100% 34.78 GB Unknown 0.0 0.0 0.6 Idle Hasta.que.llegó.su.hora.BDremux.1080p.AC3.DTS-HD.Dual.Bluray.1968.[TRCKHD].mkv

7 100% 5.04 GB Unknown 0.0 0.0 0.0 Idle Juego de Tronos XXX.2014.BR-720p.AC3.ING.GrupoD69M.xBytes.mkv

8 100% 19.79 GB Unknown 0.0 0.0 0.3 Idle Speed.BDREMUX.1080p.DTS.DTS-HD.Dual.Bluray.1994.mkv

9 100% 2.15 GB Unknown 0.0 0.0 0.0 Idle Juego.De.Tronos.S04E08.1080p.AC3.Dual.HDTV.2014.mkv

Sum: 189.5 GB 0.0 0.0

 

 

NAS> /usr/local/transmission/bin/transmission-remote --auth miusuario:????--torrent 1 --info

NAME

Id: 1

Name: la que se avecina

Hash: 3327f1c1429b33ced1a31b65022bfcf19c147dcc

Magnet: magnet:?xt=urn:btih:3327f1c1429b33ced1a31b65022bfcf19c147dcc&dn=la%20que%20se%20avecina&tr=http%3A%2F%2Fwww.xbytes.li%2Fannounce.php%3Fpasskey%3Dc665adb591628db73b4eb9563605cd60

 

TRANSFER

State: Idle

Location: /volume1/descargas/030_DESCARGADO_SEEDING

Percent Done: 100%

ETA: 0 seconds (0 seconds)

Download Speed: 0 kB/s

Upload Speed: 0 kB/s

Have: 77.48 GB (77.48 GB verified)

Availability: 100%

Total size: 77.48 GB (77.48 GB wanted)

Downloaded: 77.49 GB

Uploaded: 21.06 GB

Ratio: 0.2

Corrupt DL: None

Peers: connected to 0, uploading to 0, downloading from 0

 

HISTORY

Date added: Sat May 31 20:12:01 2014

Date finished: Mon Jun 2 02:30:47 2014

Date started: Wed Jun 4 19:32:56 2014

Latest activity: Wed Jun 4 00:03:54 2014

Downloading Time: 17 hours (63732 seconds)

Seeding Time: 2 days (175808 seconds)

 

ORIGINS

Date created: Wed May 28 13:03:11 2014

Public torrent: Yes

Creator: uTorrent/2040

Piece Count: 18474

Piece Size: 4.00 MiB

 

LIMITS & BANDWIDTH

Download Limit: Unlimited

Upload Limit: Unlimited

Ratio Limit: Default

Honors Session Limits: Yes

Peer limit: 60

Bandwidth Priority: Normal

 

 

 

SCRIPT AUTOMATIZACION

 

Preparar script y ejecutarlo mediante cron, para dejar de compartir descargas que han cumplido los requisitos del tracker privado.

 

#!/bin/sh

 

## Script for tranmission on synology

## Problems:

## * The custom package of tranmission on synology machines does not run scripts after completion [1]

## * Couchpotato Server does not appear to activate the postprocessing once a torrent has finished downloading

##

## Solution:

## * In the synology taskplanner I set up a task to run every 2 hours to run this script

##

## Script:

## 1) check which torrents are finished downloading

## 2) remove completed torrents from transmission

## 3) run Couchpotato renamer if completed torrents are found

## 4) If there are no torrents in torrent list, clean up download directory

## !!This option is disabled by default, because it uncareful usage may delete all data!!

##

## Prerequisites:

## * Synology machine (currently tested on Synology DS411j, DSM 4.2-3211)

## * Transmission & Couchpotato Server (SPK's obtained from SynoCommunity repository)

## * Enable Couchpotato Renamer, but set so that it never runs [3]

##

## Warning: Regarding 4)

## * My transmission downloads to a temporary directory. Movies that have finished downloading are

## moved to $DOWNLOADDIR. Thus if all movies have been processed this folder contains no more movies and can be safely deleted

## * the Couchpotato renamer will need some time to process. Therefor do not set up the taskplanner to run to often. Every 1 or 2 hours is sufficient

##

## Referencias:

## https://forum.transmissionbt.com/viewto ... =2&t=13970

## https://forum.transmissionbt.com/viewto ... =2&t=11468

## https://couchpota.to/forum/viewtopic.ph ... 9db1#p7330

## https://forum.transmissionbt.com/viewto ... 792#p64792

## https://forum.transmissionbt.com/viewto ... =1&t=13427

##

## date: 9 may 2013

 

# Inputs

USER="miusuario"

PASSWORD="????"

TRANSMISSION="/usr/local/transmission/bin/transmission-remote --auth $USER:$PASSWORD"

 

DESCARGADO_SEEDING="/volume1/descargas/030_DESCARGADO_SEEDING"

DESCARGADO_OFFLINE="/volume1/descargas/040_DESCARGADO_OFFLINE"

 

COMPLETADOS_BORRAR_TORRENT=1

COMPLETADOS_MOVER_A_OFFLINE=1

COMPLETADOS_TIEMPO_SIEMBRA=`expr 86400 \* 2` # Máximo 2 dias en segundos

 

# COUCHPOTATOURL=localhost

# COUCHPOTATOPORT=5050

# COUCHPOTATOAPI=couchpotatoapi

 

# Initialize

LISTA_COMPLETADOS=""

 

echo ""

echo "++++++ PROCESAR TORRENTS DESCARGADOS Y SEMBRADOS +++++"

echo "`date`"

echo "++++++++++++++++++++++++++++++++++++++++++++++++++++++"

 

# Lista de Torrents

TORRENTLIST=`$TRANSMISSION --list | sed -e '1d;$d;s/^ *//' | cut -s -d" " -f 1 | sed "s/[^0-9]//"`

for TORRENTID in $TORRENTLIST ; do

 

DL_COMPLETED=`$TRANSMISSION --torrent $TORRENTID --info | grep "Percent Done: 100%"`

STATE_FINISHED=`$TRANSMISSION --torrent $TORRENTID --info | grep "State: Stopped\|Finished\|Idle"`

 

# ------- Comprobamos tiempo de siembra

ALCANZADO_TIEMPO_SIEMBRA=0

TORRENTNAME="`$TRANSMISSION --torrent $TORRENTID --info | grep "Name:" | sed -e 's/ *Name: *//'`"

# Es una carpeta, recorrer ficheros

if [ -d "$DESCARGADO_SEEDING/$TORRENTNAME" ]; then

LASTMODIFIED=0

find "$DESCARGADO_SEEDING/$TORRENTNAME" | while read FILE ; do

AGE=`stat "$FILE" -c%Y`

if [ $AGE -gt $LASTMODIFIED ]; then

LASTMODIFIED=$AGE

fi

done

# Es un fichero unico

else

LASTMODIFIED=`stat "$DESCARGADO_SEEDING/$TORRENTNAME" -c%Y`

fi

 

TIME=`date +%s`

DIFF=`expr $TIME - $LASTMODIFIED`

 

# Se ha alcanzado el tiempo maximo de siembra COMPLETADOS_TIEMPO_SIEMBRA

if [ $DIFF -gt $COMPLETADOS_TIEMPO_SIEMBRA ]; then

ALCANZADO_TIEMPO_SIEMBRA=1

fi

 

 

if [ "$DL_COMPLETED" != "" ] && [ "$STATE_FINISHED" != "" ] && [ "$ALCANZADO_TIEMPO_SIEMBRA" -eq 1 ]; then

echo "Torrent #$TORRENTID: completado."

LISTA_COMPLETADOS="$LISTA_COMPLETADOS $TORRENTID"

else

echo "Torrent #$TORRENTID: no completado. Lo ignoramos"

fi

done

 

 

if [ "$LISTA_COMPLETADOS" != "" ]; then

echo "Torrents finalizados y sembrados: "$LISTA_COMPLETADOS

fi

 

 

for TORRENTID in $LISTA_COMPLETADOS ; do

 

TORRENTNAME="`$TRANSMISSION --torrent $TORRENTID --info | grep "Name:" | sed -e 's/ *Name: *//'`"

echo "Tratando torrent $TORRENTID : $TORRENTNAME"

 

if [ $COMPLETADOS_BORRAR_TORRENT -eq 1 ] ; then

$TRANSMISSION --torrent $TORRENTID --remove

if [ $? -eq 0 ] ; then

echo "... torrent borrado en transmission"

else

echo "ERROR AL BORRAR TORRENT"

fi

else

echo "... no borramos torrent (desactivado)"

fi

 

if [ $COMPLETADOS_MOVER_A_OFFLINE -eq 1 ] ; then

if [ -f "$DESCARGADO_SEEDING/$TORRENTNAME" -o -d "$DESCARGADO_SEEDING/$TORRENTNAME"] ; then

mv "$DESCARGADO_SEEDING/$TORRENTNAME" "$DESCARGADO_OFFLINE"

if [ $? -eq 0 ] ; then

echo "... fichero movido a $DESCARGADO_OFFLINE"

else

echo "ERROR AL MOVER FICHERO"

fi

else

echo "... ERROR NO SE HA ENCONTRADO EL FICHERO."

fi

else

echo "... no movemos fichero (desactivado)"

fi

 

done

 

# # Activate Couchpotato renamer

# if [ $RUNCOUCHPOTATOPOSTPROCESS == "TRUE" ]; then

# echo Run Couchpotato renamer

# # start couchpotato postprocessing script

# curl http://$COUCHPOTATOURL:$COUCHPOTATOPORT ... amer.scan/

# printf "\n"

# fi

 

echo "++++++++++++++++++++++++++ FINISHED ++++++++++++++++++++++++++"

 

Hola, y por qué no mola Download Station para los trackers privados?

 

Es que estoy en DSM desde ayer, y estoy tratando de empaparme!

 

Muchas gracias.

Depende de los requisitos de tu trackers. El transmisión es más personalizable posiblemente que el ds. Además, transmission instalas la versión que quieras y/o la versión que el trackers te diga.

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.