Attaching to a network using an additional computer
What's a simplified dish to connect my COMPUTER to my WLAN via my laptop computer?
I have one cordless network, one desktop computer that (for sensible factors) has no link to the WLAN, and also one laptop computer with cordless and also an ethernet port.
I would love to run a wire from my desktop computer to my laptop computer, connect my laptop computer to my WLAN and also onward the network to my desktop computer.
Exists a remedy?
You can additionally connect the laptop computer to the WLAN, the desktop computer to Laptop and also just link the links on the laptop computer so you do not require to run anything on the laptop computer (DHCP/NAT). The Desktop will certainly get its config from the WLAN dhcp.
Simple and also system agnostic:
- Ensure that both networks to be linked have various subnet addresses.
- Enable typical Linux IP forwarding in /etc/sysctl.conf.
For various subnets, thinking you are making use of the alloted exclusive class C room, 192.168.1. * and also 192.168.2. * are various subnets.
Asuming that :
- PC1 has a functioning net link which we intend to show to PC2.
- PC1 is attached to PC2 with a cross - over wire or a button
- 192.168.0.1 is the IP address we assign to PC1
- 192.168.0.2 is the IP address we assign to PC2
- 10.0.0.2 is the IP address for the nameserver made use of by PC1 (
cat /etc/resolve.confon PC1)
ON PC1 :
eth0 is the network user interface that attaches to PC2
# configure eth0 ifconfig eth0 192.168.0.1 netmask 255.255.255.0 ifconfig eth0 up # enable forwarding echo 1 > /proc/sys/net/ipv4/ip_forward # forward with iptables iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE /etc/rc.d/iptables save /etc/rc.d/iptables start
ON PC2 :
eth0 is the user interface that attaches to PC1
# enable eth0 ifconfig eth0 192.168.0.2 netmask 255.255.255.0 ifconfig eth0 up # route through other pc route add default gw 192.168.0.1 # specify nameserver echo "nameserver 10.0.0.2" >> /etc/resolve.conf
See Internet Share for reference.
Ok, I do not assume I actually have the solution below yet below it goes :
- Connect your laptop computer to the WLAN,
- Connect your Desktop to your Laptop (see to it to set up the IP's effectively, or have a DHCP web server on your laptop computer),
- Use firestarter (need to be readily available on your plan supervisor) to create a bridge in between both links.
That's regarding I can manage looking into the subject ; hope this details acts as an excellent beginning factor.