It was time to tuck all my computers beneath my desk. They’d been laying about for way too long.
I wanted to share my experience with setting up Internet Connection Sharing with Ubuntu. It was very well documented, but I did have to search in a few places to find the final result. All was well with the Ubuntu side, but the windows side needed a little filling in.
I’m connecting to my wireless router via a wireless card…I’m then sharing that connection with a secondary ethernet card, which plugs into my other machine.
Router –> Ubuntu Wireless Card –> Eth0 –> Windows Box.
Right-Click on your “Network Connections” icon at the top right of your screen and select “Edit Connections.” The first connection that pops up is your wired connection, Auto eth0. Click that, then click edit. Select IPv4 Settings, and set the “Method” to “Share to other computers.”
Now, make sure that both of the computers are connected via their NIC’s, and restart the network(service networking restart, /etc/init.d/networking restart, or the like). Now pop over to the windows machine, open up a command prompt and type “ipconfig”
Ethernet adapter Local Area Connection:
Now the Windows box has been assigned an ip, subnet, and gateway(you can change these values manually on your linux box).
At this point, you should be able to access the ‘net…via only IP addresses! Why would that be? Correct, DNS. Let’s dig up the nameservers used on the Linux box;
First, cat /etc/resolv.conf
# Generated by NetworkManager
domain home
search home
nameserver 192.168.1.1
nameserver 71.252.0.12
Take those nameservers, and move over to your windows box. Next open up the “Network Connections,” Right-Click on your LAN connection and select “Properties.”
Scroll down to “Internet Protocol(TCP/IP), and click “Properties.”
Next, you’re going to fill in the nameservers from the /etc/resolv.conf file we did previously.
Select “use the following DNS server addresses,” click “Ok,” and bang! You should be able to ping any url from the command line. If that’s the case, then you can open up your favorite web browser from either machine, and surf the web using one(wlan0) connection.
If this doesn’t work, it’d probably be a good idea to disable and enable the windows connection.
Wallah.




