Click to See Complete Forum and Search --> : Problem in configuring TCP IP


DipeshKhakhkhar
11-23-2004, 01:15 PM
Hi,

I am new to linux OS and trying to set up IP (internet settings) for my test server.

I have IP with me and i did the following:

1) Start -> System Settings -> Network

2) Here I got network setting dialog box and I activated the eth0 connection by giving static IP and connected the network cable. I don't know what to give in the subnet mask and default gateway address.

Then i saved this configuration but in vain.

I do have one running server and i am looking into it also. When i did ifconfig command on my production server, i got its address and other information from eth0 and lo. And when i viewed the step 1 above for production it has Automatically obtain IP address settings with dhcp enabled.

I tried to do the same with the test machine but i m not getting it working.

I googled for this and found about files etc/sysconfig/network and etc/sysconfig/network-scripts/ifcfg-eth0. But not able to do much as these files are almost same in my production and test.

My production is running fine and i m working on test. But not able to do this. Can someone please tell me where i'm getting wrong. Any help would be highly appreciated.

Thanks!
Regards,

ph34r
11-23-2004, 01:40 PM
How are you connecting to the network? Do you have a dhcp server somewhere?

DipeshKhakhkhar
11-23-2004, 01:48 PM
Hi,

Thanks for replying.

Well I am connecting using LAN. The production machine is also connected using LAN.

I hope I answered your question, if not pls. bear with me as I am neophyte in linux world.

Thanks!
Regards,

ph34r
11-23-2004, 02:03 PM
OK, well what happens if you plug a Windows box into the network? Does it get an address automatically? If so, you just need to enable dhcp. Otherwise, you need to assign a static address...

DipeshKhakhkhar
11-23-2004, 02:15 PM
Hi,

Thanks for replying immediately.

Well I am not infering it wrong when you say, Windows Box you mean Windows Server. I don't have windows server but i do have window OS in one machine and when i plugged network cable i get connected to it simply.

I do have static IP for me for the test server and trying to configure it and connect it to the internet.

Well i was reading about DHCP and found out that in my production there is a file
etc/resolv.conf and it contains two different name servers.

And when i checked it in test server the same file does not contain anything.

And in the production, in that file the first line was
; generated by /sbin/dhclient-script.

So do i have to run something or some GUI is available to do this.

Because when i see using start-->system settings --> network in production the DHCP option is enabled and it is not using that static IP option but the machine does have static IP. I want to do something like that only.

So what should i do to get that.

Once again thanks for your help.

Regards,

bradfordgd
11-23-2004, 03:24 PM
It sounds like for now you should enable dhcp on eth0 and see if you can get that working before you move on to your static IP. After you set eth0 to use dhcp, have you brought eth0 down and up again or just rebooted your box?

DipeshKhakhkhar
11-23-2004, 11:51 PM
Hi,

Thanks for replying.

Well i restarted the system once but it didn't helped.

As I am new to linux can you please tell me what do you mean by making eth0 up and down. Do you mean i need to run some bin file or other file.

Thanks once again !!
Regards,

soulestream
11-24-2004, 12:27 AM
1) Start -> System Settings -> Network


then just click on eth0 and select "edit"

this will allow you to manually set ip or use dhcp.


soule

DipeshKhakhkhar
11-24-2004, 02:02 PM
Hi,

I did this but in vain.

I do have one machine which is running fine with the same kind of setting as i am doing here on my test machine.

Any help would be highly appreciated.

Thanks!
Regards,

KenP
11-24-2004, 11:46 PM
It seems you need to go back to "square one" and do some swatting up on tcp/ip setup

Each machine Needs the following to work on an IP network
IP address-----eg 192.168.1.11
Netmask--------eg 255.255.255.0 (for a class "C" )

Optional components are
Gateway address ---- (only used if needing to talk to machines on another network). It is usually the IP address of the router / gateway out of your own network (Modem, router, etc)

DNS Resolvers ---- ( entries in /etc/resolv.conf or MS DNS entries) NOt needed unless you need to do DNS name lookups for machines on the network, or a remote network. Usually set to IP addresses of your ISP. TCP/IP connections can allways be made with IP addresses

If you are setting up a test network then you only need to set the IP address and Netmask.

All of these TCP/IP settings can be automatically set on NIC startup, by having a DHCP server on the network. This machine will give out appropriate settings for all of the relevant tcp/ip settings, but there must be one somewhere on the network. Any server OS can be configured as a DHCP server, (linux, Windows etc), but it will have to be set up by someone.

Using the Linux distros own tools, you can set up the network card with the settings you need, or you can modify /etc/sysconfig/network_scripts as appropriate.

DipeshKhakhkhar
11-30-2004, 02:29 PM
Hi,

Thanks for replying.

I checked these things but still not able to configure internet on linux.

Everybody says its quite easy to configure internet on linux and thru GUI it seems to but its not working that way for me.

Can somebody please tell me where i am goofing and how to solve it.

Thanks in the anticipation that I will get some help.

Regards,

DMR
11-30-2004, 03:23 PM
1. When the system is booting, watch the startup messages as they scroll by. In the entries pertaining to eth0, do you see any indication of failures?

For example, a machine which should be using DHCP but is having trouble in that area might display a line similar to:

"Determining IP information for eth0: FAILED"


A machine configured for static addressing which is experiencing something like a resource conflict or driver problem related to the NIC will display:

"Bringing up interface eth0: FAILED"


You can scrolll through the contents of your startup log with the following command:

dmesg |less

Let us know if you find any log entries which might help us pinpoint the problem.

2. If you truly are using static addressing, have a read through the suggestions here:

http://www.stevewolfonline.com/Downloads/DMR/Doc/Linux/Network/NICConfig.txt