The online racing simulator
Choose local ip
(8 posts, started )
Choose local ip
Is it possible to choose the ip lfs uses to connect to remote servers? I have multiple ip assigned to my ethernet and lfs uses the wrong one.
edit: read that wrong.

I dont think it is possible. Never thought about it :S.
If it's "choosing the wrong one" then your network is broken. LFS doesn't choose how to contact the outside world, this is governed by your routing table.
My network is not broken, i simply do source ip policy routing so the packet are routed correctly if the source ip is right. I hope developers will add this (easy to implement) option in the next patch
Nope, it won't happen, there is a very good reason why LFS only uses the 192.168.0.xxx range for LAN usage

edit : I think I may have mis-read the question...........
Quote from yapsoft :My network is not broken, i simply do source ip policy routing so the packet are routed correctly if the source ip is right. I hope developers will add this (easy to implement) option in the next patch

Source based IP routing is all well and good, but I must be having a stupid moment as I don't see why this is a problem with LFS still.

I can see why you'd want this in the instance of running a server (and this behaviour already exists), but I still don't understand why you'd want this in a client. Any client, for any application that I can currently think of, that I know of simply requests to make a connection and the underlying OS makes the decision of where the connection should Go. In most cases this is usually the default route (of which you can only have one).

Moreover I don't see why LFS would make a mistake whereas every other application would work properly - unless LFS has some strange behaviour that I've never noticed.

Perhaps it's because I've never implemented source based ip routing tables, in which case I apologise as my understanding of it is flawed. However, by understanding is that you can use it to simply push certain IPs out on different routes..
My PC has 2 ip addresses (XXX and YYY) from different provider (A and B). I can't route packets with XXX source address on the link to B and viceversa i can't route packets YYY on the link to A (egress filtering). So i do policy routing to route packets with source address XXX on the link A and packets with source address YYY on the link B. Now if i can't choose which IP lfs binds to it will choose the first one configured on the NIC. If XXX is the first address lfs will bind to it and all my packets are routed on the link A but i want to use the link to B because is low latency. You can say: "swap the address order!" but i don't want to use the low latency link as default link for surfing web ecc.
Quote from yapsoft :but i don't want to use the low latency link as default link for surfing web ecc.

On the chance that the LFS don't provide this feature for you, would it not be possible to create a script that changes the route whilst you're playing LFS, and then swaps it back after you've finished playing.

Assuming the routing is happening on your PC (and it's windows), something like the following springs to mind (untested, sorry if I've typoed, it's been a long day)
route change 0.0.0.0 mask 0.0.0.0 yourfastgatewayip & path\to\LFS.exe & route change 0.0.0.0 mask 0.0.0.0 yourslowgatewayip

which would delete your default gateway, readd it using the faster line, run LFS until it finished which would then delete the default gateway and then readd it using the slower line...

Hacky, but it might keep you going until you can beg to the development team?

Choose local ip
(8 posts, started )
FGED GREDG RDFGDR GSFDG