Results 1 to 5 of 5
hey!
im runnig centos 5.1 on vmware and configured eth0 to use dhcp.
at this situation, after i added a route line to my router details i can access the ...
- 04-19-2010 #1Just Joined!
- Join Date
- Apr 2010
- Posts
- 1
have problems with static ip and dns name
hey!
im runnig centos 5.1 on vmware and configured eth0 to use dhcp.
at this situation, after i added a route line to my router details i can access the internet from the server.
BUT, when i changed to configurations and edited the ip to static one, no matter the gateway stay the same one - suddenly the internet was blocked!
anyone can help me figure it out?
i have another problem with the connection to the server:
i can access the server with my win 7 by the ip address but not by the hostname...
any help will appreciate
- 04-19-2010 #2
TalmoR,
hi, let me understand...
eth0 is using DHCP. You connected the network, get an IP address from the router and you can access the Internet, right.
Now you change to static IP on the machine and no luck anymore.
Two hints:
a) you have not set a DNS server and so attempts to the Internet using names (like google ..) do not get resolved. --> add the DNS server name, so maybe the router or whatever the router has assigned before. check while on DHCP with "system-config-network" and go to DNS tab.
b) you have not set the default router, either within the "system-config-network" tool or via "ip route" command. Configure the default router for example like
for exampleCode:ip route add default via [router-ip]
Code:ip route add default via 192.168.1.254
- 04-20-2010 #3
Both problems may be a dns issue. When you changed to
a static address, you must also specify the name server
by editing the etc/resolv.conf file.
On second thought, this is a client issue. The easiest wayi can access the server with my win 7 by the ip address but not by the hostname...
to fix it is to edit the hosts file on the Windows computer.
It is usually in C:\windows\system32\drivers\etc
There you find (by default) hosts.sam
Edit it and remove the .sam extension.Last edited by rcgreen; 04-20-2010 at 10:25 AM.
- 04-20-2010 #4
Google public DNS servers are: 8.8.8.8 and 8.8.4.4
Gateway is your router IP (ex 192.168.1.1 or 192.168.2.1 depending on brand)
- 04-25-2010 #5Just Joined!
- Join Date
- Apr 2010
- Posts
- 1
make sure the the static ip you have assigned and the gateway belong to the same class .
check the subnet mask
see if you can ping the router successfully
second one :
this is a DNS server problem
if it dns client: check /etc/resolv.conf
make sure the the dns server that you have set up is working fine
and you have resolved the win & system correctly
if problem still persists feel free to reply


Reply With Quote