Installing bittorrent for linux is pretty easy, and it enables you to download torrents from the command line. This works for Debian Etch.
I’ll also give instructions for using screen to keep downloads going when you logout of the machine.
1, Install the dependancies and other useful packages:
# sudo apt-get install python-wxgtk2.6 python-twisted python-crypto python-psyco python-zopeinterface screen
2, Get the bittorrent .deb file
# wget http://download.bittorrent.com/dl/bittorrent_5.0.8_python2.4.deb
# dpkg -i bittorrent_5.0.8_python2.4.deb
3, Download torrents!
You’ve now got a command line, and curses interface for bittorrent installed. To download a file, run:
# bittorrent-curses http://path/to/file.torrent
(you can also use local paths for torrent files).
To use the command line interface:
# bittorrent-console http://path/to/file.torrent
If you want to leave a file downloading while you’re logged out, use screen. Simply type screen before your preferred command above, ie:
# screen bittorrent-curses http://path/to/file.torrent
To detach from the screen, press “Ctrl+A”, then “D”, and you will be returned to the shell. To re-attach to the screen, run “screen -r”
Bittorrent downloads will be stored in “~/Bittorrent Downloads” when they are complete. While they are being downloaded, they will be in “~/.bittorrent/incomplete/”
Packages for different distributions can be found here, along with source code.
Lets face it, the default debian bash prompt is pretty dull whereas distributions like Gentoo have nice colours.
This is very easy to get in all distributions, and it’s one of the first things I do on new installs.
The file you need to edit is ~/.bashrc, and if you want it to apply to all new users, /etc/skel/.bashrc.
Simply add the following lines to the bottom of the file:
//////
eval `dircolors -b`
alias ls=’ls –color=auto’
if [ "`id -u`" -eq 0 ]; then
PS1=’\[\033[01;31m\]\h \[\033[01;34m\]\w \$ \[\033[00m\]‘
else
PS1=’\[\033[01;32m\]\u@\h \[\033[01;34m\]\w \$ \[\033[00m\]‘
fi
//////
This will give you a light green prompt for standard users, and red for root. To use different colours, change the numbers in the [01;32m] sections. You will need to logout and login again to see the changes.
There are plenty of guides for doing this, but here’s my way, which I’ve done on loads of different hardware.
Personally, I prefer to use the stock debian kernel because it supports most hardware and makes upgrading through apt easier. Occasionally though, I like to test the newest kernel releases, and here’s how I do it.
1, Install necessary tools:
# apt-get install kernel-package ncurses-dev bzip2 module-init-tools initrd-tools procps fakeroot
2, Download the latest kernel source:
# cd /usr/src
# wget http://kernel.org/pub/linux/kernel/v2.6/linux-2.6.22.1.tar.bz2
# tar -xjvf linux-2.6.22.1.tar.bz2
# cd linux-2.6.22.1
3, Unzip any extra patches and apply them:
# bzip2 -dc patch-xxx.bz2 | patch -p1
5, Configure the kernel.
a, Using the current config as a base:
# cp /boot/config-x.x.x /usr/src/linux-2.6.22.1/.config
# make oldconfig
[ answer all the questions]
b, Using the menu interface (you can do the cp line above to use the old config as a base but make changes):
# make menuconfig
If you have multiple processors/cores, you can speed up the compile by utilising them all (this is similar to the -j flag when compiling the non debian way). To find out the number of cores you have, run:
# grep -c ‘^processor’ /proc/cpuinfo
Then to make sure all cores are used:
# export CONCURRENCY_LEVEL=4
replace 4 with the number of processors.
6, Compile and install:
# make-kpkg clean
# time fakeroot make-kpkg –initrd –revision=1 –append-to-version=.kris kernel-image
This will usually take between 5 minutes and over an hour, depending on how many modules there are to compile, and how fast your hardware is.
Once this has finished, you will be left with a .deb file which you can install using dpkg:
# dpkg -i linux-image*.deb
Because of the –initrd flag earlier, the initrd image will be created when you install the kernel. This command will also update grub, so all you need to do to use your new kernel is reboot.