I used this tutorial to install hamachi as a system service:
http://ubuntuforums.org/showthread.php?t=135036sudo modprobe tun
sudo gedit /etc/modules
ls /dev/net/tun
sudo mkdir /dev/net sudo mknod /dev/net/tun c 10 200
#Extract the archive tar -zxvf hamachi-0.9.9.9-x.tar.gz cd hamachi-0.9.9.9-x/ #install Hamachi sudo make install sudo tuncfg #Hamachi is installed
#Create the 'hamachi' group sudo groupadd hamachi #Add your user to the group sudo gpasswd -a user hamachi #Add root to the group sudo gpasswd -a root hamachi #Set socket permissions sudo chmod 760 /var/run/tuncfg.sock #Finally, changing the group of the file sudo chgrp hamachi /var/run/tuncfg.sock
sudo hamachi-init -c /etc/hamachi
Initializing Hamachi configuration (/etc/hamachi). Please wait .. generating 2048-bit RSA keypair .. ok making /etc/hamachi directory .. ok saving /etc/hamachi/client.pub .. ok saving /etc/hamachi/client.pri .. ok saving /etc/hamachi/state .. ok Authentication information has been created. Hamachi can now be started with 'hamachi start' command and then brought online with 'hamachi login'.
sudo hamachi -c /etc/hamachi start
sudo hamachi -c /etc/hamachi set-nick "YourNickHere"
#Login to Hamachi sudo hamachi -c /etc/hamachi login #To join an existing network sudo hamachi -c /etc/hamachi join network password #Or to create a new network sudo hamachi -c /etc/hamachi create network password #Lastly, to go online to the network you joined sudo hamachi -c /etc/hamachi go-online network
#!/bin/sh
hamachi_start() {
echo "Starting hamachi..."
/sbin/tuncfg
/usr/bin/hamachi -c /etc/hamachi start
/bin/chmod 760 /var/run/tuncfg.sock
/bin/chgrp hamachi /var/run/tuncfg.sock
}
hamachi_stop() {
echo "Stopping hamachi..."
killall tuncfg
/usr/bin/hamachi -c /etc/hamachi stop
}
hamachi_restart() {
hamachi_stop
sleep 1
hamachi_start
}
case "$1" in
'start')
hamachi_start
;;
'stop')
hamachi_stop
;;
'restart')
hamachi_restart
;;
*)
hamachi_start
esac
sudo chmod +x /etc/init.d/hamachi sudo update-rc.d hamachi defaults
hamachi-init
Initializing Hamachi configuration (/home/user/.hamachi). Please wait .. generating 2048-bit RSA keypair .. ok making (/home/user/.hamachi directory .. ok saving (/home/user/.hamachi/client.pub .. ok saving (/home/user/.hamachi/client.pri .. ok saving (/home/user/.hamachi/state .. ok Authentication information has been created. Hamachi can now be started with 'hamachi start' command and then brought online with 'hamachi login'.
hamachi start
hamachi set-nick "YourNickHere"
#Login to Hamachi hamachi login #To join an existing network hamachi join network password #Or to create a new network hamachi create network password #Lastly, to go online to the network you joined hamachi go-online network
sudo dpkg -i [downloaded file]
hamachi-gui
At first I could not ping the other members, and this fixed it:
http://ubuntuforums.org/archive/index.php/t-208692.html To check if the problem is caused by invalid routing entry do this: 1) open the terminal 2) ifconfig you should see something like this ham0 Link encap:Ethernet HWaddr 00:FF:CA:D0:F5:AA inet addr:5.23.68.35 Bcast:5.255.255.255 Mask:255.0.0.0 UP BROADCAST RUNNING MULTICAST MTU:1200 Metric:1 RX packets:100 errors:0 dropped:0 overruns:0 frame:0 TX packets:244 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:500 RX bytes:26780 (26.1 KB) TX bytes:21076 (20.5 KB) The IP address of the ham0 interface is the IP of the gateway for all hamachi network bound connections. 3) check the routing table with route -n root@cronos:~# route -n Kernel IP routing table Destination Gateway Genmask Flags Metric Ref Use Iface 64.238.220.160 0.0.0.0 255.255.255.240 U 0 0 0 eth0 169.254.0.0 0.0.0.0 255.255.0.0 U 1000 0 0 eth0 5.0.0.0 5.23.68.35 255.0.0.0 UG 0 0 0 ham0 0.0.0.0 64.238.220.161 0.0.0.0 UG 100 0 0 eth0 The 3rd line defines hamachi connections. Destination Gateway Genmask Flags Metric Ref Use Iface 5.0.0.0 5.23.68.35 255.0.0.0 UG 0 0 0 ham0 If in the Gateway column you don't see the IP of the ham0 interface, as it was the case with me, delete that line and create the correct routing entry for hamachi. delete invalid route: route del -net 5.0.0.0 gw 0.0.0.0 netmask 255.0.0.0 dev ham0 add new route: route add -net 5.0.0.0 gw 5.23.68.35 netmask 255.0.0.0 dev ham0