LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Networking (https://www.linuxquestions.org/questions/linux-networking-3/)
-   -   ifcfg-eth0 configuration problem (https://www.linuxquestions.org/questions/linux-networking-3/ifcfg-eth0-configuration-problem-79442/)

shyam 08-06-2003 04:18 AM

ifcfg-eth0 configuration problem
 
In my Linux server(Wipro EzyNet Server) there are two network cards.

1. eth0 for LAN

2. eth1 for DSL modem

The configuration files are as below

ifcfg-eth0
------------
ONBOOT=yes
NETWORK=192.168.1.0
NETMASK=255.255.255.0
IPADDR=192.168.1.6


ifcfg-eth1
------------
ONBOOT=yes
NETWORK=192.168.1.0
NETMASK=255.255.255.240
IPADDR=10.23.0.9

When the server starts it shows the IP address 192.168.1.6 on the LCD screen.

To configure the server(to enable DSL modem) i changed the ifcfg-eth0 as below


ifcfg-eth0
------------
ONBOOT=yes
NETWORK=192.168.1.0
NETMASK=255.255.255.0
IPADDR=192.168.1.6
GATEWAY=10.23.0.9

When the server restarts it shows the IP address as 10.23.0.9 instead of 192.168.1.6 and i am unable to ping the server. How i can connect the server , so that i can edit the ifcfg-eth0 file, to restore default configuration.

Pl help to short out the problem.

Rgds,

Shyam

ppuru 08-06-2003 05:22 AM

shouldn't GATEWAY appear in /etc/sysconfig/network

cIx 08-06-2003 06:25 AM

Why did you setup NETWORK for eth1 to be 192.168.1.0 ?

I'm not sure that I correctly understood you, but I guess you should do the following settings:

ifcfg-eth0
------------
ONBOOT=yes
NETWORK=192.168.1.0
NETMASK=255.255.255.240 #why?
IPADDR=192.168.1.6

ifcfg-eth1
------------
ONBOOT=yes
NETWORK=10.0.0.0
NETMASK=255.0.0.0
IPADDR=10.23.0.9

I don't understand what are you trying to do, but if you try to enable internet access for you LAN, you should use NAT.


All times are GMT -5. The time now is 03:04 PM.