Make sure you have swapping activated.
These are the scripts I use. The 1st 3 go in the top-level directory of your USB drive.
Note that you should delay the startup of transmission for a few minutes after bootup, because the router is really busy at that time and transmission will often fail and/or cause other problems if you don't wait.
You should run it with "nice", which is in coreutils package.
root@wl500-host:/tmp/mnt/TOSH_120# cat 00-start-swap.autorun
# This is 00-start-swap.autorun
# The 1st parameter is the path to here.
# The label of the swap partition.
# If no parameter, complain and quit.
[[ xx == x$1x ]] && (logger No pathname parameter [$0] ; exit)
# Edit fstab to put the swap partition label there.
sed -i "/^LABEL=$SWAPNAME /d" /etc/fstab
echo "LABEL=$SWAPNAME swap swap" >>/etc/fstab
# Then turn it on
root@wl500-host:/tmp/mnt/TOSH_120# cat 05-setup_opt.autorun
# This is 05-setup_opt.autorun
# If there is an "opt" directory on this disk, then mount it as "/opt".
if [[ xx = x$1x ]] ; then logger No pathname parameter [$0] ; exit ; fi
# Mount the opt directory on this disk to /OPT
# But only if it hasn't been done yet.
if [[ -d $1/opt ]] ; then
if [[ $1/opt -ef /opt ]] ; then
logger "/OPT is already mounted"
logger "Remounting $1/opt to /opt"
mount -o bind $1/opt /opt
root@wl500-host:/tmp/mnt/TOSH_120# cat 99-start-torrent.autorun
if [ -d $1/opt/config ] ; then
( sleep 5m ; /opt/config/torrent-start) &
root@wl500-host:/tmp/mnt/TOSH_120# cat /opt/config/torrent-start
# Start transmission bit-torrent client.
# If it's already running, make it stop.
# Be robust, because killall doesn't always get
# the sub-processes to terminate.
logger Entering script
if $(killall -q transmission-daemon)
logger killing old daemon
while [ "$(pidof transmission-daemon)" ] ; do
logger killing it again
killall -q transmission-daemon
logger starting ne daemon
nice transmission-daemon -g $TRANSMISSION_HOME
# Schedule it to exit and restart once a day, at 1:11 AM
# because it sometimes runs into a resource problem and locks up.
# When that happens it needs to be restarted.
cru d trans_restart
cru a trans_restart "11 1 * * * " $0