Server - die komplette debug.cfg
Falls der Start von OpenVPN nicht funktionieren sollte, vergleichen Sie Ihre debug.cfg nochmals mit der komplett dargestellten Startdatei. Eine Hilfe zur Fehlersuche finden Sie am Ende des Beitrags auf der Seite "Erster Test":
# # # # # # # # # Start des telnet-daemons
/usr/sbin/telnetd -l /sbin/ar7login
while !(ping -c 1 www.tecchannel.de); do
sleep 7
done
# # # # # # # # # Installation FTP-Server
cd /var/tmp
wget http://www.tecchannel.de/download/432803/bftpd.conf
wget http://www.tecchannel.de/download/432803/bftpd
chmod +x bftpd
chmod 777 bftpd.conf
# Hier den Usernamen und den Passwort-Hash für den FTP-Server eintragen
echo "xxxxxxxxxxxxx:0:0:root:/:null" >> /var/tmp/passwd
/var/tmp/bftpd -d -c /var/tmp/bftpd.conf
# set hostname to fritz.box
hostname fritz.box
# load VPN-Server (OpenVPN)
# change dir
cd /var/tmp
# write 'secret.key' to file
cat > /var/tmp/secret.key << 'ENDSECRETKEY'
#
# 2048 bit OpenVPN static key
#
-----BEGIN OpenVPN Static key V1-----
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
-----END OpenVPN Static key V1-----
ENDSECRETKEY
# write 'server.ovpn' to file
cat > /var/tmp/server.ovpn << 'END-SERVER-OVPN'
#
dev tun0
dev-node /dev/misc/net/tun
ifconfig 192.168.200.2 192.168.200.1
tun-mtu 1500
float
mssfix
#Pfad zum Key File
secret /var/tmp/secret.key
#Protokoll auf TCP und Port 1194
proto tcp-server
port 1194
#Protokollierung auf 4
verb 4
#daemon
#Routen setzen, bei route Subnetz des Clients
# bei push Subnetz des eigenen Servers eintragen route 192.168.1.0 255.255.255.0
push "route 192.168.100.0 255.255.255.0"
#Verbindung erhalten
ping 15
push "ping 15"
ping-restart 120
push "ping-restart 120"
END-SERVER-OVPN
# load files
wget http://www.tecchannel.de/download/435560/openvpn
# make them executable
chmod +x /var/tmp/openvpn
chmod 0600 /var/tmp/server.ovpn
chmod 0600 /var/tmp/secret.key
# start OpenVPN
./openvpn --config ./server.ovpn &