kurz zu meinem Server:
Undzwar habe ich einen server den ich auf VMware 7.1.4 Hoste
Host ist Centos Guest ist Freebsd 7.2.
Der server ist ein Strato Server.
Problem:
Ich habe ein Online Game drauf. Das spiel Connectet über den Port 11002 und 13000
das sind die wichtigsten. Beim anmelden ins spiel funktioniert alles wunderbar.
Nun habe aber das problem das der Server die Interne IP von der VMWare an das spiel übergibt ! (habe ich in TCPIPVIEW) gesehen da steht 172.16.29.128 SYN_STATE
obwohl da die Externe IP vom servere stehen müsste !
warum gibt er mir die interne VMWARE HOST IP raus ? Statt die externe ?
hat das was eventuell mit source routing oder sowas zu tun ?
Bitte um Hilfe !
Meine IP Tables einstellungen auf dem HOST sehen Folgeneder maßen aus:
Code: Alles auswählen
#!/bin/bash
IPTABLES="/sbin/iptables"
SYSCTLW="/sbin/sysctl -q -w"
$SYSCTLW net.ipv4.conf.all.rp_filter=1
$SYSCTLW net.ipv4.conf.all.log_martians=1
$SYSCTLW net.ipv4.conf.all.send_redirects=0
$SYSCTLW net.ipv4.conf.all.accept_source_route=0
$SYSCTLW net.ipv4.conf.all.accept_redirects=0
$SYSCTLW net.ipv4.tcp_syncookies=1
$SYSCTLW net.ipv4.icmp_echo_ignore_broadcasts=1
$SYSCTLW net.ipv4.ip_forward=1
PORTS="2222 3306 11002 12001 13000 13001 13002 13003 13004 13061 13099 14000 14001 14002 14003 14004 14061 14099 15001 16000 16001 16002 16003 16004 16061 16099"
EXTIF="eth0"
INTIF="vmnet1"
$IPTABLES -F
$IPTABLES -t nat -F
$IPTABLES -t mangle -F
$IPTABLES -X
$IPTABLES -t nat -X
$IPTABLES -t mangle -X
$IPTABLES -t nat -A PREROUTING -i eth0 -p tcp -d 81.169.xxx.xxx--dport 2121 -j DNAT --to-destination 172.16.29.128:21
for PORT in $PORTS; do
iptables -t nat -A PREROUTING -i eth0 -p tcp -d 81.169.xxx.xxx--dport $PORT -j DNAT --to-destination 172.16.29.128
done
for PORT in $PORTS; do
iptables -t nat -A PREROUTING -i eth0 -p udp -d 81.169.xxx.xxx--dport $PORT -j DNAT --to-destination 172.16.29.128
done
$IPTABLES -A FORWARD -i $INTIF -o $EXTIF -m state --state NEW,ESTABLISHED -j ACCEPT
$IPTABLES -A FORWARD -i $EXTIF -o $INTIF -m state --state ESTABLISHED,RELATED -j ACCEPT
$IPTABLES -t nat -A POSTROUTING -o $EXTIF -j MASQUERADEMeine Systctl auf dem HOST;
Code: Alles auswählen
# Kernel sysctl configuration file for Red Hat Linux
#
# For binary values, 0 is disabled, 1 is enabled. See sysctl(8) and
# sysctl.conf(5) for more details.
# Controls IP packet forwarding
net.ipv4.ip_forward = 1
# Controls source route verification
net.ipv4.conf.default.rp_filter = 0
# Do not accept source routing
net.ipv4.conf.default.accept_source_route = 1
# Controls the System Request debugging functionality of the kernel
kernel.sysrq = 0
# Controls whether core dumps will append the PID to the core filename
# Useful for debugging multi-threaded applications
kernel.core_uses_pid = 1
# Controls the use of TCP syncookies
net.ipv4.tcp_syncookies = 1
# Controls the maximum size of a message, in bytes
kernel.msgmnb = 65536
# Controls the default maxmimum size of a mesage queue
kernel.msgmax = 65536
# Controls the maximum shared segment size, in bytes
kernel.shmmax = 68719476736
# Controls the maximum number of shared memory segments, in pages
kernel.shmall = 4294967296
# Automatically generated by the VMware Installer - DO NOT REMOVE
# kernel.sched_compat_yield = 1
# Automatically generated by the VMware Installer - DO NOT REMOVE
net.ipv4.conf.all.send_redirects = 1
net.ipv4.conf.all.accept_source_route = 1
net.ipv4.conf.all.accept_redirects = 1[/code]
