Azureus

How to install and configure Azureus

Installation

Can install from the repository, though this is not an up to date copy

sudo apt-get install -y vuze

Best get it from sourceforge

wget http://sourceforge.net/projects/azureus/files/vuze/Vuze_4502/Vuze_4502_linux-x86_64.tar.bz2/download
bzcat Vuze_4502_linux-x86_64.tar.bz2 | tar xvf -

Plugins

List of plugins

  • Azureus HTML WebUI
  • Auto Stopper
  • SafePeer
  • Speed Scheduler

Enable IP Filters/SafePeer

Tools ~ Options ~ IP Filters
Set IP Filter to autoload as :
http://www.bluetack.co.uk/config/level1.gz
Taken from Azureus instructions

Configure Headless operation

It’s recommended to start the Azureus GUI once and configure the settings and web interface. Once done, you can look at starting it headless.
Test that it runs:
Taken from Vuze Wiki

cd /home/rob/vuze
ln -s /usr/share/java/commons-cli.jar commons-cli.jar
ln -s /usr/share/java/log4j-1.2.jar log4j.jar
java -jar Azureus2.jar --ui=console

This should start up and you can control Azureus from the in-built menu\\
Next is to create the daemon script in the Azureus directory:\\

cd /home/rob/vuze
touch azureusd
chmod +x azureusd
vi azureusd
#!/bin/bash
#
# Azureus Daemon
#
nohup java -jar Azureus2.jar --ui=console >/dev/null 2>&1

Now we need to create the startup script

sudo touch /etc/init.d/azureus
sudo chown root:root /etc/init.d/azureus
sudo chmod 755 /etc/init.d/azureus
ln -s /etc/init.d/azureus /etc/rc5.d/S99azureus
ln -s /etc/init.d/azureus /etc/rc5.d/K01azureus
sudo vi /etc/init.d/azureus
#!/bin/bash
#Credits
#Minor Changes by Louis - http://laj.ca/
#Based on rc script for Azureus by Phill - http://phillstechstuff.blogspot.com
#Based on script from Azureus wiki - http://www.azureuswiki.com/index.php/HeadlessSwingUIAtBoot
#The user that will run Azureus
AZ_USER=rob
#your path to the azureus directory, where Azureus2.jar is located
DIR=/home/rob/vuze
#executable files in the following paths that are perhaps needed by the script
PATH=/bin:/usr/bin:/sbin:/usr/sbin
#Description
DESC="Azureus daemon"
PROC="java -jar Azureus2.jar --ui=console"
CMD="./azureusd"
start_az() {
if [[ ` ps -ef | grep "$PROC"|grep -v grep` ]]; then
echo "Azureus is already running!"
else
echo "Starting $DESC"
su $AZ_USER -c "cd $DIR; $CMD"
fi
}
stop_az() {
if [[ `ps -ef | grep "$PROC"|grep -v grep` ]]; then
echo -n "Stopping $DESC"
su $AZ_USER -c "kill `ps -ef | grep "$PROC" | grep -v grep | awk '{print $2}'`"
echo " ... done."
else
echo "Coulnd't find a running $DESC"
fi
}
case "$1" in
start)
start_az
;;
stop)
stop_az
;;
restart)
stop_az
sleep 10
start_az
;;
status)
if [[ ` ps -ef | grep "$PROC"|grep -v grep` ]]; then
echo "Azureus is RUNNING"
else
echo "Azureus is DOWN"
fi
;;
*)
echo "Usage: $0 {start|stop|status|restart}"
exit 1
;;
esac
exit 0