PDA

View Full Version : Wine port forwarding trouble



dusenbutt
April 16th, 2011, 20:40
Hello all. I got FGII to run in wine, found the app data folder and got my campaign loaded up. It runs great.

I can't get the connection test to succeed. I have port 1802 forwarded through my router and I can go to http://www.yougetsignal.com/tools/open-ports/ and test it. It's open. For one thing, the internal ip shown in FG is different from the internal ip on my Mac. my Mac is 192.168.1.x the FG ip is 63.251.whatever.numbers. I don't know how to get wine to forward port 1802. Any suggestions?

Ictinike
April 17th, 2011, 04:35
Does the device your running FG2 on have a static IP address?

You mention your internal LAN IP of 192.168.xx.xx. This is the IP your router serves you and alike for every other device using the router.

This is nothing new and it's not hard but when your dealing with Port Forwarding the best method is to give your device a static IP and then the port-forward is a bit easier or maybe not has complicated. This is because if you serve out DHCP or Dynamic Host Protocol you may get 192.168.1.100 today and tomorrow 101 or even yet in 3 days 123.

If you set your router to starting servicing addresses at say 192.168.1.110 lets say instead of 192.168.1.100 then you have 10 IP adresses, .100,.101,.102, etc up to .109, that you can assign devices on your lan.

I have my 2 network cards on my LAN as .100 and .101 and my Tivo .105, etc. This makes it easier to port forward and when you say port forward port 1802 you can give it the IP you've given yourself on the device. This makes things that utilize ports such as FG2, BitTorrent, etc an easier path through the routing. Of course, you'll have to configure you devices and set them up with each a static IP but that's fairly simple. Just consult the web on the idea of setting Windows, Mac, whatever for static IP's and your set.

Hope this helps instead of hinders! :)

Cheers,
~Ictinike

dusenbutt
April 17th, 2011, 05:10
Ictinike

Thanks for the reply. The weird thing is that I'm not running two devices. The laptop I'm running FG on has port 1802 open. But for some reason Wine (the emulator thingy) I have to use to run FG assigns the 63.251.xx.xx IP to FG. I have no idea why nor any idea of how to change it.

I've tried running FG in Parallels but for some reason the chat window is completely non-functional but at least in Parallels I know how to forward the port through the emulator.

damned
April 17th, 2011, 11:12
if you go to www.showmyip.com what is your ip address? is that teh address that fg is displaying?

Zeus
April 17th, 2011, 11:39
dusenbutt - FGII should show the 63.251.xx.xx address as your external IP (that is the internet facing or NAT IP), are you saying that FGII shows the 63.251.xx.xx address as your internal IP?

You shouldn't need to configure Wine for your networking as long as the hostname (internal) of your system can be resolved. You can check this by typing in hostname in a shell window and matching it to an entry in your /etc/hosts file.

Also, what version of Wine are you running?

dusenbutt
April 17th, 2011, 13:46
damned, the internal IP and the external IP that FG is showing are different. I couldn't get that showmyip site to work.
FG Internal: 63.251.xx.xx
FG External: 64.188.xx.xx

Dr. Zeuss, I typed hostname into terminal (is that what you meant?). Where do I find the etc/host file? I'm running Wine 1.1.44. I tried to update it yesterday and it kept failing. I installed FG using winebottler. It was very easy.

Thanks for your ongiong help guys! I really appreciate it.

Zeus
April 17th, 2011, 13:51
dusenbutt - Yes a command line shell is opened through terminal.

To view the hosts file for your linux box, type the following in a terminal window: cat /etc/hosts

dusenbutt
April 17th, 2011, 13:53
OK I was able to update this morning. So now I'm running Wine 1.2.2.

dusenbutt
April 17th, 2011, 13:55
Sorry, I'm not running linux. I'm running Mac OS 10.6.7.

Zeus
April 17th, 2011, 13:59
That's OK, OS X is a UNIX implementation under the covers.

Open a terminal and type in cat /etc/hosts to view the system hosts file

dusenbutt
April 17th, 2011, 14:03
That's OK, OS X is a UNIX implementation under the covers.

Open a terminal and type in cat /etc/hosts to view the system hosts file
Ok did that and got this:


-bash: cat/etc/hosts: No such file or directory

dusenbutt
April 17th, 2011, 14:38
OK here's what I did.

1. Opened terminal and entered "sudo cp /etc/hosts /etc/hosts.backup"
2. Entered the password
3. Typed "sudo pico /etc/hosts"

And got this:

##
# Host Database
#
# localhost is used to configure the loopback interface
# when the system is booting. Do not change this entry.
##
127.0.0.1 localhost
255.255.255.255 broadcasthost
::1 localhost
fe80::1%lo0 localhost

dusenbutt
April 17th, 2011, 14:41
That's OK, OS X is a UNIX implementation under the covers.

Open a terminal and type in cat /etc/hosts to view the system hosts file
OK sorry I'm a dufus. I didn't see the space between cat and /etc. Now it's working...

##
# Host Database
#
# localhost is used to configure the loopback interface
# when the system is booting. Do not change this entry.
##
127.0.0.1 localhost
255.255.255.255 broadcasthost
::1 localhost
fe80::1%lo0 localhost

Zeus
April 17th, 2011, 14:46
dusenbutt - Try adding an entry to /etc/hosts for the hostname of the system you are using e.g.

192.168.xx.xx <your hostname>

You can do this by using any standard text editor.

And try again.

dusenbutt
April 17th, 2011, 15:01
dusenbutt - Try adding an entry to /etc/hosts for the hostname of the system you are using e.g.

192.168.xx.xx <your hostname>

You can do this by using any standard text editor.

And try again.
OK So now it reads:


##
# Host Database
#
# localhost is used to configure the loopback interface
# when the system is booting. Do not change this entry.
##
127.0.0.1 localhost
255.255.255.255 broadcasthost
ashley-dusenberys-macbook-2.local 192.168.1.9
::1 localhost
fe80::1%lo0 localhost

Going to restart and see.

Zeus
April 17th, 2011, 15:04
You need to have the IP first, then the hostname. You have them reversed.

Also drop the .local of the hostname.

To test you have it entered correctly try entering the following command in a terminal window:

ping ashley-dusenberys-macbook-2

You should get a ping response and a response time of 0ms

BTW. I am on the FGII chat chennel, if you prefer to chat. FGII Chatroom Link (http://fg2.rpg-vault.net/)

dusenbutt
April 17th, 2011, 15:10
You need to have the IP first, then the hostname. You have them reversed.

Also drop the .local of the hostname.

To test you have it entered correctly try entering the following command in a terminal window:

ping ashley-dusenberys-macbook-2

You should get a ping response and a response time of 0ms
It's not working.

Host file is now:


##
# Host Database
#
# localhost is used to configure the loopback interface
# when the system is booting. Do not change this entry.
##
127.0.0.1 localhost
255.255.255.255 broadcasthost
192.168.1.9 ashley-dusenberys-macbook-2
::1 localhost
fe80::1%lo0 localhost


Do I need to restart?

Zeus
April 17th, 2011, 15:13
You shouldn't have to. have you tried the ping command, do you get a response?

damned
April 17th, 2011, 15:14
host file does not require restart.
you can have your .local name in there also you would just use teh line like this:
192.168.1.9 ashley-dusenberys-macbook-2 ashley-dusenberys-macbook-2.local
if you are on dhcp i would suggest however that you try adding them after localhost as your 192 address could change?
127.0.0.1 localhost ashley-dusenberys-macbook-2 ashley-dusenberys-macbook-2.local

dusenbutt
April 17th, 2011, 15:33
Guys thanks so much for your help. I've got to run for a few hours. I'll be back this afternoon. Thanks again!! I really appreciate your help.

dusenbutt
April 17th, 2011, 15:55
host file does not require restart.
you can have your .local name in there also you would just use teh line like this:
192.168.1.9 ashley-dusenberys-macbook-2 ashley-dusenberys-macbook-2.local
if you are on dhcp i would suggest however that you try adding them after localhost as your 192 address could change?
127.0.0.1 localhost ashley-dusenberys-macbook-2 ashley-dusenberys-macbook-2.local
Is that in addition to adding the line that Dr. Z had me add? I am on DHCP.

damned
April 17th, 2011, 16:09
that would be an either/or thing not a both...
if you are on dhcp and your ip changes you would have to update your host file so i would tend to use the latter option if i was doing this...

dusenbutt
April 17th, 2011, 19:31
Progress!

Host file now reads:
##
# Host Database
#
# localhost is used to configure the loopback interface
# when the system is booting. Do not change this entry.
##
127.0.0.1 localhost ashley-dusenberys-macbook-2 ashley-dusenberys-macbook-2.local
255.255.255.255 broadcasthost
::1 localhost
fe80::1%lo0 localhost

the ping <hostname> is working too.

Unfortunately FG still isn't working.

nazzy
May 8th, 2011, 16:45
On my local setup I have VirtualBox. I use it for some testing setups and it uses a subnet that is only available on my local machine. FG2 is binding to the virtual network adapter which is only available to the local machine.

I'm not ready to have anyone connect to my game so it's not an immediate concern. I will change it to be NATed or change my VM adapter to make it work when the time comes. I mention this because I notice that the internal IP FG2 is useing is not available on my network.

Is there a way to change the internal IP in FG2? This would allow dusenbutt to use "ifconfig" to check his IP configuration and change FG2 to match. Then port forward the proper IP from the router.

Moon Wizard
May 13th, 2011, 20:38
For the internal IP address,
FG uses the GetComputerName (Windows API) and gethostbyname (WinSock API) functions to determine the internal IP address.

For the external IP address,
FG sends a request to the FG web servers, and FG responds with the IP address used for the request.

Neither of these can be set manually.

Regards,
JPG