Can't Add Nameserver on New Installation

I installed a new Suse machine using the Live CD.

At the time I did not have network access, so I skipped that part of the setup.

Today, I tried to configure the network with IP, nameserver and gateway.

The problem was the nameserver wouldn’t take.

What would happen is that Yast would stop and start the network, then try to download updates from opensuse.org. The problem is, it could not resolve the domain names to IP address. Even if I skipped over the download errors, when it completed, it still did not retain the IP of the nameserver.

What I had to do was wait for it to hit an error on the download/install and then manually edit /etc/resolv.conf and add

nameserver nnn.nnn.nnn.nnn

Then it was able to download and complete the network installation.

I’ve had this once or twice when switching from a dhcp setup to static one using networkmanager as setup method (on openSUSE 11.0). Don’t know if there is a relation, but it did stick out to me.
Solution for me was to delete the current nic settings (using YaST), save it, and again reconfigure it all.

Similar problem, new install of 11.0 via the DVD but I did have network availability. The installer chose to set things up as DHCP, after the full install and updates I went in through Yast/Network Devices/Network Settings and set up a static IP using ifup and set my own gateway and DNS. Everything worked except vncviewer to my other machines (openSuse 11.0 is the client here). By using NetworkManager in the Network Settings/ Global Options tab I could get vncviewer to connect to other VNC servers but I lost and nameserver entry in /etc/resolv.conf and thus lost all outside world connectivity.

If I manually add nameserver nnn.nnn.nnn.nnn to the resolv.conf file everything works – until I reboot then I must reedit the resolv.conf file to add back the nameserver.

Anybody know which file(s) I edit (don’t need to do it through a GUI) to get this nameserver value to stick?

Yes, confirming, after reboot the nameserver settings disappear and I no longer can do lookups. Very bad since I am building this as a postfix mail server!!

In the Network Settings, I also ask:

Global Options Tab:

  1. What is the difference between NetworkManager and ifup.

  2. What does “Change Default Route via DHCP” checkbox do?

Overview Tab:

  1. I tried deleting the netcard entry, but it doesn’t contain the nameservers so it doesn’t help the problem with resolv.conf getting overwritten on boot.

Hostname Tab:

  1. There is a greyed out checkbox that says “Change /etc/resolv.conf manually”. Why would this be greyed out? Do I need to login as root? Or check some other selection?

As it is, this is a major show stopper!
:confused:

I added this issue to Bugzilla:

https://bugzilla.novell.com/show_bug.cgi?id=413683

(PS…it says I can “edit” my posts on this forum…how?)

Actually, looks like my bug is a dupe. Here’s the original bug report acknowledging the problem here:

https://bugzilla.novell.com/show_bug.cgi?id=388266

However, I don’t see any fixes or workarounds described.

:confused:

If this is a server i would recommend configuring everything statically and using ifup.

ifup is the ‘old way’ to manage the network connections whereas Networkmanager is the new way.
Networkmanager is mainly useful when having to deal with different environments. It lets you configure directly and automatically without having to go into YaST.

For a server I would not recommend Networkmanager and set it to ifup. Note that you will lose the little network icon in the panel tray as this is an element of Networkmanager.

  1. What does “Change Default Route via DHCP” checkbox do?

It overwrites the current default route that is set(check the setting using ’ route ’ in a terminal console) with the one given by any dhcp server located in the network you are connected to.
You normally want this when having set a nic to DHCP.

Overview Tab:

  1. I tried deleting the netcard entry, but it doesn’t contain the nameservers so it doesn’t help the problem with resolv.conf getting overwritten on boot.

True, the purpose of deleting the netcard entry is so you can give it a new static ip configuration that should ‘stick’

Hostname Tab:

  1. There is a greyed out checkbox that says “Change /etc/resolv.conf manually”. Why would this be greyed out? Do I need to login as root? Or check some other selection?

You should be able to override this setting and be able to set this manually. See what happens when using ifup and having deleted and re-entered the static ip details for you nic.

As it is, this is a major show stopper!
:confused:

Agreed, fortunately most are not having issues with this. But it is a pain.

To recap, see what happens when you use ifup, entering all configurations (ip address/subnet, dns & gateway) manually.

As root (using 'su - ') also check to see what ’ ifconfig ’ and ’ route ’ return.

-Wj

Please note that in my situation ifup would work with static IP’s configured manually if I didn’t require vncviewer to also work in my deveolpment environment. Whatever NetworkManager is doing behind the scenes it does allow vncviewer to work on my LAN but it hoses /etc/resolv.conf until I manually edit it to give it nameserver … Now everything works until I reboot.

What are you using to vnc (tightvnc or other?).
Also your development environment, is it in another subnet? And can you ping a server in it when using the ifup method?

Well, I type vncviewer nnn.nnn.nnn.nnn in a console window, but I think the answer to your question is that it is actually using Xtightvnc. I am using tightvnc at the server end.

Yes, with the ifup method I can ping (UDP) and I can run my own TCP/IP capable apps against my network (no subnet), when I try vncviewer it comes back with

Connected to RFB server, using protocol version 3.7

followed by some messages about having no desktops to connect to. This of course sent me off chasing things that never solved a thing. On a whim I changed over to NetworkManager and vncviewer now reports protocol version 3.3 and works perfectly - however I’m back to hand modifying the resolv.conf file as previously discussed.

So I’m happy that NetworkManager has done whatever magic it does, I can hand modify resolv.conf by myself.

Have you also tried using ‘vncviewer nnn.nnn.nnn.nnn:1 or vncviewer nnn.nnn.nnn:5901’ ?

I would be expecting a fix for this in a not too long timeframe as there are more issues like this reported.

But we will see…

Thanks Magic32, yes I tried that - one of those dead ends I alluded to.

Thanks a lot, I followed your advice and it seems somewhat stable now. I changed from Network Manager to ifup in Yast. Then exited yast and use ifconfig to set up my eth0 card and (again) edited resolv.conf.

I followed the steps here:

itmission.org - How To Configure Linux Network

This time, however, the settings stuck after reboot!