Solved

Redhat 7.2 & Windows 98 workstations & cable modem on same LAN setup?

Posted on 2002-06-30
10
252 Views
Last Modified: 2013-12-15
I am trying to set up a linux machine on my Windows 98 LAN with a Cox Cable modem. Cox makes me disable DNS. How do I set up the Linux machine?
0
Comment
Question by:jimmywfl
10 Comments
 
LVL 17

Expert Comment

by:psimation
Comment Utility
I'm not sure what you mean.
Do you want to have the Linux box connect to the internet via the cable modem connected to your win98 box?

Pointers:
file sharing over lan between Linux & Windows = samba
Normal TCP/IP traffic between Linux and Windows gets configured on the Linux box via netconf.

For modem sharing, you normally only need to make sure the Linux box has the same subnet as the windows network, and then to give the windows pc's IP as the gateway to the Linux box ( also in netconf).
PS, do you have DHCP?
0
 

Author Comment

by:jimmywfl
Comment Utility
I am a novice at linux and rote administrator for Windows. When I set up the Windows LAN, I assigned 10.0.0.1 and 10.0.0.2 with 255.255.255.0 submasks to the two windows machines. I disabled wins and DNS. It took netbeui and ipx/spx, making netbeui the default protocol for the LAN to work. The computer with the Toshiba cable modem on Cox obtains its IP address automatically and has dns and wins disabled.
On the linux machine, I screwed up (I found out later by going online with the redhat manual) and deleted localhost. I then set up three hosts, one for each of the windows machines (10.0.0.1 and 10.0.0.2) and "localhost" for the linux machine with 10.0.0.3. In the TCP/IP section I set up an IP of 10.0.0.3 with 255.255.255.0 submask. I left the DNS section totally blank. I used the hardware address for the adapter rather than aliasing. When I boot, the DHCP program complains that there is no subnet mask for eth0 (10.0.0.3). When I try to access the network, I get "could not connect to localhost".
0
 
LVL 20

Expert Comment

by:Gns
Comment Utility
localhost should be bound to the loopback (dummy) interface.
It should be assigned an address of 127.0.0.1 with network mask 255.0.0.0 (that is 127.0.0.1/8). The loopback interface is "named" lo.

You shouldn't need NetBEUI (and definitely not IPX/SPX) between the windows hosts. Netbios, tcp/ip and a "microsoft klient whatever" should be all that you need to make them interoperable (setting them to the same workgroup, giving them a Netbios name etc).

Please provide the verbatim contents of the files /etc/sysconfig/network, /etc/sysconfig/network-scripts/ifcfg-lo and /etc/sysconfig/network-scripts/ifcfg-eth0, and we will be able to more accurately tell you how to modify your configuration.

When these files have been corrected, it will simply be  a case of "restarting the network" on the linux host (ifdown eth0; ifdown lo; ifup lo; ifup eth0).

-- Glenn
0
 

Author Comment

by:jimmywfl
Comment Utility
contents of
/etc/sysconfig/network
Networking=Yes
Hostname=
GatewayDev=eth0
Gateway=
/etc/sysconfig/network-scripts/ifcfg-lo
Device=lo
IPADDR=127.0.0.1
NETMASK=255.0.0.0
NETWORK=127.0.0.0
BRAODCAST=127.255.255.255
ONBOOT=YES
NAME=loopback
/etc/sysconfig/network-scripts/ifcfg-eth0
Device=eth0
IPADDR=10.0.0.3
NETMASK=255.255.255.255
NETWORK=10.0.0.0
BRAODCAST=10.0.0.255
ONBOOT=YES
BOOTPROTO=Static
UserCtrl=Yes
PeerDNS=No
Gateway=localhost.localdomain
IPXPRIMARY_802_2=no
IPXACTIVE_802_2=no
IPXPRIMARY_802_3=no
IPXACTIVE_802_3=no
IPXPRIMARY_ETHERII=no
IPXACTIVE_ETHERII=no
IPXPRIMARY_SNAP=no
IPXACTIVE_SNAP=no
0
Get up to 2TB FREE CLOUD per backup license!

An exclusive Black Friday offer just for Expert Exchange audience! Buy any of our top-rated backup solutions & get up to 2TB free cloud per system! Perform local & cloud backup in the same step, and restore instantly—anytime, anywhere. Grab this deal now before it disappears!

 
LVL 20

Expert Comment

by:Gns
Comment Utility
Ah. Not that much wrong, but still...

In /etc/sysconfig/network, you should set a hostname (best if it is a fully qualified domain name: linux.fake.domain or similar), and you should point Gateway to the IP address of the gateway machine (I'd guess 10.0.0.1 ?!), so that the linuxbox knows where to forward packets destined for the internet.

/etc/sysconfig/network-scripts/ifcfg-lo looks OK.
Ah, you might have some foolishness in /etc/hosts. It should contain only one line where localhost is mentioned:
127.0.0.1  localhost
You'll probably want to add a line for your hostname too, as well as an entry for each of the windows hosts (probably best to make that for their Netbios names):
10.0.0.1  win1 win1.fake.domain
10.0.0.2  win2 win2.fake.domain
10.0.0.3  linux linux.fake.domain

/etc/sysconfig/network-scripts/ifcfg-eth0 only contains one fault, as far as I can see:
NETMASK=255.255.255.255 is a "hostmask", and should be

NETMASK=255.255.255.0
so that the calculation of "network part" and "host part" adds up.
Oh, and lose the "Gateway=...". It's wrong, and will be set at the "global level" in /etc/sysconfig/network.

Once you have done these changes, and restarted the network (or done the "windoze thing" and rebooted;-), you should be able to ping the hosts on your network, and ping internet hosts via theirto  IP address (but not name).

To make names work, the gateway host will have to act as an intermediary, and be the DNS server/forwarder for your LAN (via some ICS fiddling? This is because you get DNS info via DHCP from the ADSL link setup(?)), or you will have to know the IP address of some public DNS server that will honour requests for you, and add that one to your /etc/resolv.conf.

HtH
-- Glenn
0
 

Author Comment

by:jimmywfl
Comment Utility
Well, I still get "could not connect to localhost" when I click on network. I am using a cable modem that is not going through a router so the internet is unaccessable by the other windoze machines. I have tried variations of everything on names for localhost like localhost.fake.domain, localhost.localdomain, localhost alone.
On boot I still get a message from the dchp asking for a subnet mask for eth0
I am using 7.2 so there is a network config program. In it, the network adapter's configuration has no info in it such as IRQ, MEM, IO, etc., all blank

Here are the files as they stand now:
hosts:
10.0.0.3 linux linux.fake.domain
10.0.0.2 sys600 sys600.fake.domain
10.0.0.1 3840ct 3840ct.fake.domain
127.0.0.1 localhost

eth0:
Device=eth0:0
BOOTPROTO=Static
ONBOOT=YES
IPXPRIMARY_802_2=no
IPXACTIVE_802_2=no
IPXPRIMARY_802_3=no
IPXACTIVE_802_3=no
IPXPRIMARY_ETHERII=no
IPXACTIVE_ETHERII=no
IPXPRIMARY_SNAP=no
IPXACTIVE_SNAP=no
NETWORK=0.0.0.0
BRoaDCAST=255.255.255.255
UserCtrl=Yes
PeerDNS=No
IPADDR=10.0.0.3
NETMASK=255.255.255.0
Gateway=

lo:
Device=lo
IPADDR=127.0.0.1
NETMASK=255.0.0.0
NETWORK=127.0.0.0
BRAODCAST=127.255.255.255
ONBOOT=YES
NAME=loopback

network
Networking=Yes
Hostname=linux.fake.domain
GatewayDev=eth0
Gateway=10.0.0.1
0
 
LVL 20

Accepted Solution

by:
Gns earned 50 total points
Comment Utility
Oh dear. The /etc/sysconfig/network-scripts/ifcfg-eth0 file is very wrong now. The rest look fairly OK though.

Don't use netconf or any other tool, just use an editor to change the file. You (and I;-) know what is supposed to be in the files, so we don't need any tool to "help" us, now do we?

Lets see if I can do some cut'n'paste'n'edits....

Here you go:

Device=eth0
BOOTPROTO=Static
ONBOOT=YES
NETWORK=10.0.0.0
BROADCAST=10.0.0.255
UserCtrl=Yes
PeerDNS=No
IPADDR=10.0.0.3
NETMASK=255.255.255.0


This is all you should need to have in ifcfg-eth0, remove any other ifcfg-eth* files (the * is a wildcard). What you had was a wrong broadcast and network "address", and you had configured an alias for eth0 (eth0:0), so most probably you have a config-file for eth0 that use DHCP, but that is ...conjecture on my part.

Enjoy
-- Glenn
0
 
LVL 49

Expert Comment

by:DanRollins
Comment Utility
Upon review of the comments here, I am recommending this disposition:

        points to Gns

Please post a comment if you disagree.

DanRollins -- EE database cleanup volunteer
0
 

Expert Comment

by:SpideyMod
Comment Utility
per recommendation.

SpideyMod
Community Support Moderator @Experts Exchange
0

Featured Post

Windows Server 2016: All you need to know

Learn about Hyper-V features that increase functionality and usability of Microsoft Windows Server 2016. Also, throughout this eBook, you’ll find some basic PowerShell examples that will help you leverage the scripts in your environments!

Join & Write a Comment

Over the last ten+ years I have seen Linux configuration tools come and go. In the early days there was the tried-and-true, all-powerful linuxconf that many thought would remain the one and only Linux configuration tool until the end of times. Well,…
Introduction We as admins face situation where we need to redirect websites to another. This may be required as a part of an upgrade keeping the old URL but website should be served from new URL. This document would brief you on different ways ca…
Learn how to find files with the shell using the find and locate commands. Use locate to find a needle in a haystack.: With locate, check if the file still exists.: Use find to get the actual location of the file.:
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

6 Experts available now in Live!

Get 1:1 Help Now