General discussion

Locked

Sharing an Internet Connection

By cazzopar ·
I'm trying to set-up an internet connection whereby a Windows 95 workstation accesses the internet via a Linux server connected thru Ethernet.
The Linux server's connection to the internet seems to be fine. Whereas my Win 95 workstation is able to resolve domain names to IP addresses via the network (thru Ping-ing), my ping packets are not received back.

IP Gateway settings on the Win 95 are set to be the Linux server's IP address. I haven't set up any firewall on the Linux machine yet.

Any suggestions?

This conversation is currently closed to new comments.

11 total posts (Page 1 of 2)   01 | 02   Next
| Thread display: Collapse - | Expand +

All Comments

Collapse -

Sharing an Internet Connection

by Vasjatka In reply to Sharing an Internet Conne ...

It seems that server doesn't have route to the workstations. To correct this you should add lines like:

route add -host 111.222.33.44 -interface ed13

details about addresse can be found in manual pages (man route).
If you ISP didn't allocatedIP-addresses for your workstations you should also use some type of Network Address Translation (IP-masquerading). It can be done by "natd" daemon (search on "Network Address translation" on TYahoo, for example).

Collapse -

Sharing an Internet Connection

by cazzopar In reply to Sharing an Internet Conne ...

The question was auto-closed by TechRepublic

Collapse -

Sharing an Internet Connection

by coursey In reply to Sharing an Internet Conne ...

I currently use a Linux box (server) to connect two networks to the internet thru an ethernet interface. I use an ipchains firewall to route the packets to my private network. This is described in detail in the DSL HOWTO for Linux.

In short youneed a minimum of two NIC's, one for the internet connection and one for the local network. Set up one NIC to connect with the internet. Set up the second NIC with it's own internal network address and set the gatewat to the first NIC's (internet)address.

This can be accomplished thru ipchains with a script like this (Please note this offers minimal protection. If you need more read the Firewall HOWTO)

#!/sh

#This flushed the interfaces.

/sbin/ipchains -F input
/sbin/ipchains -F output
/sbin/ipchains -F forward

#Set up masquerading

echo "setting up firewall"

# The network address below is a local Class #C address

/sbin/ipchains -P forward DENY
/sbin/ipchains -A forward -s 192.168.x.1/24 -j MASQ
# Add any additional local network

Collapse -

Sharing an Internet Connection

by cazzopar In reply to Sharing an Internet Conne ...

The question was auto-closed by TechRepublic

Collapse -

Sharing an Internet Connection

by coursey In reply to Sharing an Internet Conne ...

My previous answer was truncated:

# End of script

Give the script name and make it an executable file with chmod a+x filename

Next set up the windows box with an IP address on the local network (192.168.x.2) and the gateway the same as the Linux local NIC (192.168.x.1). Note the subnet mask for a class c network is 255.255.255.0.

run the script on the Linux server and restart the windows box. You should have internet thru windows.

Collapse -

Sharing an Internet Connection

by cazzopar In reply to Sharing an Internet Conne ...

The question was auto-closed by TechRepublic

Collapse -

Sharing an Internet Connection

by joshnarins In reply to Sharing an Internet Conne ...

ipchains are a great firewalling system with complex
rules and lots of configurability, but that isn't what your
toruble is for the Win95 box.
If you can get a unique IP for the windows box, it needs
to be added to the routing table of your Linux box, using
the route command mentioned above.
If you cannot, you will need to use the standard fake class
C addres, 192.168.1.XXX..
I can only assume that you have a NIC to NIC connection
between the Linux and Win boxes. You'll probably want
to use ifconfig to set up the linux boxes [toWin] connection to help it understand the private class C 192

Collapse -

Sharing an Internet Connection

by cazzopar In reply to Sharing an Internet Conne ...

The question was auto-closed by TechRepublic

Collapse -

Sharing an Internet Connection

by bakerk In reply to Sharing an Internet Conne ...

First make the following things true of your system:
1) two NICs in the Linux box 2.0 kernel or better, eth0 connected to the internet, eth1 using a non-routable address (192.168.*.*)
2) ipchains installed
3) download pmfirewall from pointman.organd run the resulting shell script in pmfirewall directory (type: sh install.sh) be sure to say yes to "masquerade" question.
4) windows box should use eth1 on the linux box as it's gateway
Now you have an effective firewall and multiple box access to the net using IP Masquerade without the hassles of developing your own firewall chains.

Collapse -

Sharing an Internet Connection

by cazzopar In reply to Sharing an Internet Conne ...

The question was auto-closed by TechRepublic

Back to Linux Forum
11 total posts (Page 1 of 2)   01 | 02   Next

Operating Systems Forums