Register a domain and help support LQ
Go Back > Forums > Linux Forums > Linux - Networking
User Name
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.


  Search this Thread
Old 12-15-2006, 12:20 PM   #1
Registered: Jul 2004
Posts: 43

Rep: Reputation: 15
Newbie: Now to configure DNS and gateway

I am running Fedora core 5 on my linux box. Usually it detected my network settings, or I would just run dhclient.
However, something went wrong with my router and it's no longer being picked up automatically as DNS and gateway. On my windows machines, I would usually go into TCP/IP settings and configure:
IP: (IP address of my linux box)
Gateway: (IP of my D-link router)
Default DNS server:

On my linux box:
I just run
ifconfig eth0
to set the IP, not sure how to set up DNS and Gateway

How do I do this in linux, is there a quick command do set these things: specify the gateway and the Default DNS so the internet works?

Thank you very much for your help in advance!!

Best Regards
Old 12-15-2006, 12:54 PM   #2
Senior Member
Registered: Nov 2006
Distribution: Debian Squeeze SMP AMD64
Posts: 3,255

Rep: Reputation: 125Reputation: 125
Login to your router and make sure the DHCP service is still running. Sounds like you may have accidentally shut it down.
Old 12-15-2006, 01:10 PM   #3
LQ Newbie
Registered: Jan 2006
Location: Twin Cities, Minnesota, USA
Distribution: Gentoo
Posts: 5

Rep: Reputation: 0
Manual DNS/Gateway configuration.

Your DHCP server is probably just disabled, but I have written up terse instructions for you to follow anyway. It's a good thing to know!

if you use route to manage your routing tables like I do, seting a default gateway is easy...
route add default gw

dns is really easy. Edit the file /etc/resolv.conf and add the line

the routing table will need to be configured each time your computer starts. Fedora should provide a utility for setting the default gateway. /etc/resolv.conf is just a regular file, and will persist until changed by you or by automatic configuration via dhcp.

Good luck.


configure, dns, gateway

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Suse DNS vs free DNS server for Newbie maxsanders Linux - Newbie 1 01-31-2006 04:57 PM
How to configure DNS for a local LAN (at least I think I want DNS) FlyingPenguin128 Linux - Networking 8 12-11-2005 04:15 PM
How to see DNS ,GATEWAY etc.. tkmuthuvel Linux - Networking 1 09-12-2005 02:53 PM
DNS and gateway ThorRune Linux - Hardware 3 08-26-2005 02:19 PM
Gateway and DNS jayakrishnan Linux - Networking 5 07-05-2003 02:01 AM

All times are GMT -5. The time now is 07:16 AM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration