Die Foren-SW läuft ohne erkennbare Probleme. Sollte doch etwas nicht funktionieren, bitte gerne hier jederzeit melden und wir kümmern uns zeitnah darum. Danke!

Vmware Workstation Iptables SYN_STATE Problem Falsche HILFE!

Hilfe bei Problemen mit der Installation und Benutzung der VMware Workstation und VMware Workstation Pro.

Moderatoren: Dayworker, irix

Member
Beiträge: 4
Registriert: 27.09.2010, 11:38

Vmware Workstation Iptables SYN_STATE Problem Falsche HILFE!

Beitragvon ismaily86 » 08.05.2011, 14:06

Hallo Liebe VMWare gemeinde,

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 MASQUERADE






Meine 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]

Benutzeravatar
UNSTERBLICH(R.I.P.)
Beiträge: 14759
Registriert: 09.08.2003, 05:41
Wohnort: sauerland
Kontaktdaten:

Beitragvon continuum » 08.05.2011, 19:22

stell mal auf bridged statt NAT um

Member
Beiträge: 4
Registriert: 27.09.2010, 11:38

Sorry es ist auf Host und kann nicht auf Bridge umgestellt..

Beitragvon ismaily86 » 09.05.2011, 02:58

Hallo da es ein Root Server mit Switchport ist kann ich leider nicht
auf bridge mode umstellen da sonst der server sofort gesperrt wird
wegen mac spoofing.

nat ist sowieso zu langsam deswegen benutze ich bereits HOST-ONLY

umgeschaltet auf nat habe ich auch passiert trozdem nichts...

mfg

King of the Hill
Beiträge: 13658
Registriert: 01.10.2008, 12:54
Wohnort: laut USV-Log am Ende der Welt...

Beitragvon Dayworker » 09.05.2011, 17:46

NAT oder Host-only macht eigentlich keine Unterschied, beide sind wesentlich schneller als Bridge.
Kannst du dir vielleicht nicht noch eine 2.MAC-addy holen und dann auf Bridge gehen?


Zurück zu „VMware Workstation und VMware Workstation Pro“

Wer ist online?

Mitglieder in diesem Forum: 0 Mitglieder und 21 Gäste