Ich kämpfe schon ziemlich lange damit und wäre wirklich nice wenn mir jmd dabei helfen könnte.
Ich habe den DHCP einrichten könenn mit hilfe von dier Anleitung: https://codeghar.wordpress.com/2012/05/02/ubuntu-12-04-ipv4-nat-gateway-and-dhcp-server/
Netzwerk
www –> router –> host –> vmserver(dhcp/dns) –> dhcp
Router:192.168.0.1, Host:dhcp, VMserver-2x Network cards -bridged
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 | $ cat /etc/network/interfaces auto lo iface lo inet loopback # WAN auto eth0 iface eth0 inet dhcp # LAN auto eth1 iface eth1 inet static address 172.22.22.1 netmask 255.255.255.0 network 172.22.22.0 broadcast 172.22.2.255 |
Folgende einträge wurden gemacht /etc/rc.local:
1 2 3 | /sbin/iptables -P FORWARD ACCEPT /sbin/iptables –table nat -A POSTROUTING -o eth0 -j MASQUERADE |
Aber ich komme noch immer nicht raus ins www. 192.168.0.2(host) or 192.168.0.1(router).
Ping von 192.168.0.2(Host) zu 192.168.0.18 eth0 ubuntu router funktioniert. 192.168.0.2 > 172.22.22.21 = nein
172.22.22.21 (Clientdhcp) 172.22.22.21 > 192.168.0.18 eht0 = ja
172.22.22.21 > 192.168.0.2 = nein
1 2 3 4 5 6 7 8 | apo@apo-VirtualBox:~$ sudo route [sudo] password for apo: Kernel IP routing table Destination Gateway Genmask Flags Metric Ref Use Iface default 192.168.0.1 0.0.0.0 UG 0 0 0 eth0 link-local * 255.255.0.0 U 1000 0 0 eth1 172.22.22.0 * 255.255.255.0 U 0 0 0 eth1 192.168.0.0 * 255.255.255.0 U 0 0 0 eth0 |