System setup
From Cheatsheet
this installs stuff on Debian Squeeze
apt-get install java-common javascript-common libmysql-java sun-java6-bin sun-java6-jdk sun-java6-jre sun-java6-plugin
then add this to home/whateveruser/.bashrc
export JAVA_HOME=/usr/lib/jvm/java-6-sun-1.6.0.20 export PATH=$PATH:$JAVA_HOME/bin CLASSPATH=".:/usr/share/java/mysql-connector-java-5.1.10.jar:/usr/share /java/mysql-connector-java.jar" export CLASSPATH
now, re-login as you, so it will re-read .bashrc. you may have to change your classpath first . to /whatever/path/to/your/class files
now disable ipv6, or it will hoze you on Squeeze
echo net.ipv6.conf.all.disable_ipv6=1 > /etc/sysctl.d/disableipv6.conf
you'll have to reboot for that to take effect. If you don't want to disable ipv6, run your java apps with this:
java -Djava.net.preferIPv4Stack=true
