Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
There is no GUI installed ( for some reason , the GUI is unable to install )
I want to change DNS configuration , as I know it is not work to directly update the file /etc/resolv.conf , therefore , I would like to ask is there any method to update DNS without GUI ?
There is no GUI installed ( for some reason , the GUI is unable to install )
I want to change DNS configuration , as I know it is not work to directly update the file /etc/resolv.conf , therefore , I would like to ask is there any method to update DNS without GUI ?
Edit /etc/sysconfig/network-scripts/ifcfg-ethX (where X is the number of your ethernet card) and add/change
Code:
DNS1=x.x.x.x
DNS2=y.y.y.y
Mind that your NIC could be named other than ethX, in which case you need to edit the proper /etc/sysconfig/network-scripts/ifcfg-<something> file
Just would like to know how can I confirm the DNS is properly applied after updated the configuration ( withoth GUI ) , if the settings is updated in /etc/resolv.conf , is that mean the DNS is properly applied ?
Just would like to know how can I confirm the DNS is properly applied after updated the configuration ( withoth GUI ) , if the settings is updated in /etc/resolv.conf , is that mean the DNS is properly applied ?
Yes, if you see the nameserver(s) you used in ifcfg-ethX in /etc/resolv.conf, it means that the changes are done. Or else you need to restart the network as tocii said.
I have a redhat 7 web server .
There is no GUI installed ( for some reason , the GUI is unable to install )
Most probably, because you haven't PAID FOR RHEL, and as such, don't have access to the repositories. You've been asking about RHEL for years now, and have received the same advice over and over: either pay for RHEL, or use CentOS.
Quote:
I want to change DNS configuration , as I know it is not work to directly update the file /etc/resolv.conf , therefore , I would like to ask is there any method to update DNS without GUI ?
Did you open that file? Because in the ones I have, I have this at the top:
Code:
# Before you change this file manually, consider to define the
# static DNS configuration using the following variables in the
# /etc/sysconfig/network/config file:
...that tells you what to edit. Also, "DNS configuration" is a bit vague. Are you RUNNING DNS on this system, or do you mean you just want to change the nameservers the system points to?
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.