User:Adr

(In progress)...

Customizing the daemonizer
The Gentoo ebuild installs a good basic init script. However, it can be enhanced in various ways if needed. The following examples are completely optional.

Arrow keys not working
Probably you can enable them in your terminal application. For instance XTerm has the "set-appcursor" option, and "Enable Application Cursor Keys" in the toolbar.

Or on the server side, you can change the TERM variable. Your terminal application might work well with TERM="linux" instead of "xterm".

Changing the TERM variable:

Using dtach as daemonizer
A smaller alternative to the app-misc/screen package is. This is all what's needed for using dtach instead of screen.

Save this patch on your computer: {{File|rtorrentd-init.patch|| --- /usr/portage/net-p2p/rtorrent/files/rtorrentd.init	2011-11-07 16:46:30.000000000 +0100 +++ /etc/init.d/rtorrentd	2013-12-21 10:55:01.251541772 +0100 @@ -15,13 +15,12 @@ 	env TERM="xterm" \ start-stop-daemon \ --start \ -			--make-pidfile \ --pidfile /var/run/rtorrentd.pid \ -			--background \ --user $USER \ --env HOME="${PWHOME:-/home/$USER}" \ -			--name rtorrent \ -			--exec /usr/bin/screen -- -D -m -S rtorrentd /usr/bin/rtorrent +			--exec /usr/bin/dtach -- -n /tmp/rtorrentd.dtach /usr/bin/rtorrent + +	pgrep --newest --uid $USER --exact rtorrent >/var/run/rtorrentd.pid eend $? } }}

Change the the USER variable to your user account, or (better) a separate account.

If needed, you can give access to group members of the configured user. Add this at the end of the start section of the init script:

Starting rTorrent in the background, and run at system boot:

Login as user, or execute as group member to attach the rtorrentd session:

Localization
Extra environment variable, if you set LANG in your users file. This doesn't affect translations, but only character set and sorting.

Renice the process
If checksum calculations eat a lot of CPU, try adding this at the end of the start section of the init script:

Controlling rTorrent exit
By default, the application is closed by the TERM signal. A more graceful exit would be to issue the INT signal, which is equivalent to the Ctrl-q key press in the rTorrent interface. This way, seeding quota get a last chance to be reported to the tracker. A second Ctrl-q key press is TERM exit, without waiting for the trackers to respond. After that, a KILL signal is justified.

Changing exit signals, and seconds waiting time: