If you've installed the image kindly created by raas directly or indirectly using my tutorial you may have noticed that the Transmission version is quite old by now and the latest one has to be installed differently.
This tutorial helps you in that. In fact it's sufficient to run only a script that does everything for you:
So what does it do?Code:#!/bin/sh #written by ecaddict, distributed (conveyed) under GPL version 3 or any later version BASE="/mnt/protected/Downloaders/Transmission" CONFD="/opt/etc/transmission" CONFF="${CONFD}/settings.json" INITF="/opt/etc/init.d/S60transmission" EBDIR="`echo ${BASE} | /bin/sed 's#/#\\\\/#g'`" killall transmission-daemon ipkg update ipkg install openssl libcurl libevent zlib transmission ln -s /opt/share/transmission /mnt/transmission mkdir -p ${CONFD} mkdir -p ${BASE} mkdir -p ${BASE}/done mkdir -p ${BASE}/work mkdir -p ${BASE}/source #check https://trac.transmissionbt.com/wiki/EditConfigFiles for config options cat > ${CONFF} << __EOF__ { "alt-speed-enabled": false, "alt-speed-time-begin": 1080, "alt-speed-time-day": 127, "alt-speed-time-enabled": true, "alt-speed-time-end": 1320, "alt-speed-up": 100, "alt-speed-down": 600, "blocklist-enabled": 1, "cache-size-mb": 8, "download-dir": "${EBDIR}\/done", "incomplete-dir": "${EBDIR}\/work", "incomplete-dir-enabled": true, "watch-dir": "${EBDIR}\/source", "watch-dir-enabled": true, "encryption": 1, "max-peers-global": 100, "peer-port": 65534, "pex-enabled": 1, "port-forwarding-enabled": 1, "rpc-authentication-required": false, "rpc-password": "", "rpc-bind-address": "192.168.1.1", "rpc-port": 9091, "rpc-url": "/transmission/", "rpc-username": "", "rpc-whitelist": "127.0.0.1,192.168.1.*", "rpc-whitelist-enabled": false, "speed-limit-down": 1200, "speed-limit-down-enabled": true, "speed-limit-up": 200, "speed-limit-up-enabled": true, "ratio-limit" : 5, "ratio-limit-enabled": true } __EOF__ cat > ${INITF} << __EOF__ #!/bin/sh #written by ecaddict, distributed (conveyed) under GPL version 3 or any later version CONFD=${CONFD} CONFF=\${CONFD}/settings.json OPTIONS="-g \${CONFD} -e /opt/var/log/transmission" NAME=transmission EXEC=/opt/bin/\${NAME}-daemon checkcnfg() { if ! [ -x "\${EXEC}" ]; then echo \${NAME} "\${EXEC} not found." exit 1 fi if ! [ -r "\${CONFF}" ] ; then echo "\${NAME} cannot find readable config \${CONFF}" exit 2 fi } d_start() { checkcnfg export TRANSMISSION_WEB_HOME='/opt/share/transmission/web/' \${EXEC} \${OPTIONS} } d_stop() { killall transmission-daemon } case "\$1" in start) echo "Starting \$NAME" d_start echo "." ;; stop) echo "Stopping \$NAME" d_stop echo "." ;; restart|force-reload) echo "Restarting \$NAME" d_stop sleep 2 d_start echo "." ;; *) echo "Usage: \$0 {start|stop|restart|force-reload}" >&2 exit 3 ;; esac exit 0 __EOF__ chmod u+x ${INITF} cd /opt/etc/lighttpd/ && [ ! -f lighttpd.conf.old ] && cp lighttpd.conf lighttpd.conf.old sed -i 's/^#\(.*"mod_rewrite",\).*/\1/' lighttpd.conf if [ -z "`sed -n 's/\/transmission\/rpc/&/p' lighttpd.conf`" ]; then cat >> lighttpd.conf << __EOF__ url.rewrite-once += ( "^/transmission[/]?\$" => "/transmission/web" ) \$HTTP["url"] =~ "^/transmission/rpc" { proxy.server = ( "" => ( ( "host" => "192.168.1.1", "port" => 9091 ) ) ) } __EOF__ fi /opt/etc/init.d/S80lighttpd restart /opt/etc/init.d/S60transmission start ps afx | grep transmission-daemon
Creates the Transmission config file:
/opt/etc/transmission/settings.json
Creates the starter script:
/opt/etc/init.d/S60transmission
It also creates couple of directories in /mnt/protected/Downloaders/Transmission/ (should they not exist already).
It also has to modify the lighttpd.conf file as it probably does not have the mod_rewrite module enabled and for almost sure it's missing the proxy function for transmission port (9091), which is required if you'd like to access it remotely via lighttpd (like I prefer via https instead of opening 9091 port on the firewall) .
Don't worry, the old version is saved during the first run as /opt/etc/lighttpd/lighttpd.conf.old should anything go wrong.
The script also restarts lighttpd and starts transmission.
If everything goes fine you can access it from LAN via:
http://192.168.1.1:9091
or
https://192.168.1.1/transmission/
or whatever port and transport you use with your web server.
From internet you can access it either via VPN (if you've installed it) the same way or using your public (WAN) IP address and https.
The configuration file contains reasonable parameters (like lowering the bandwidth used during the evening where usually traffic peaks so being nice with others) and watch directory etc.
If you feel, however you can adjust it based on the following link:
https://trac.transmissionbt.com/wiki/EditConfigFiles
or using the GUIs.
If you change the settings.json file directly don't forget to stop Tranmission before saving it as when Transmission exits it overwrites the config file.
While the built in web interface of Transmission is nice it's certainly lacking compared to Transmission remote GUI (not to talk about ruTorrent what I prefer with rtorrent) so you may prefer installing the Transmission remote GUI on your PC/laptop:
http://code.google.com/p/transmisson-remote-gui/
All you need to do is set 192.168.1.1 and 9091 as port in the connection options.
One thing I particularly don't like about transmission that it stores the torrents in the subdirectory of the configuration directory, which is /opt/etc/transmission/torrents
In my view the best would be somewhere in /mnt/protected/Downloaders/Transmission/torrents so you may remove the torrents directory from /opt/etc/transmission/ and add a link instead to /mnt/...
The install script is also uploaded here: install.tar.gz
So if you're really lazy you can install it single line (copy to PuTTY) or whatever terminal client you use:
After successful install don't forget to remove the old transmissiond with ipkg remove transmissiond as it uses quite much memory and precious CPU time. Comment out also from /opt/etc/crontab the transmission_watchdog via inserting # to the beginning of the line.Code:cd /tmp && wget -O install.tar.gz "http://wl500g.info/attachment.php?attachmentid=8276&d=1316097791" && tar xvzf install.tar.gz && ./install.sh




Reply With Quote
