Results 1 to 2 of 2

Thread: Manual DNS server info update

  1. #1

    Manual DNS server info update

    Hello,

    In https://www.suse.com/documentation/s...t_manconf.html,
    the /etc/resolv.conf should not be edited by hand. Instead, it is generated by the netconfig script. To define static DNS configuration without using YaST, edit the appropriate variables manually in the /etc/sysconfig/network/config file.

    So I edited like
    NETCONFIG_DNS_STATIC_SERVERS="4.2.2.2"

    systemctl restart wicked
    cat /etc/resolv.conf

    However I don't see the change in /etc/resolv.conf

    Then I ran /sbin/netconfig update
    And the output says : Attention: you have modified /etc/resolv/conf. Leaving it untouched. You can find my version in /etc/resolv.conf.netconfig (which contains the DNS server I added in /etc/sysconfig/network/config file).

    I think I edited /etc/resolv.conf manually before the /etc/sysconfig/network/config test.

    So at this point, if I would need to update DNS server info again, should I continue to edit /etc/resolv.conf manually or /etc/sysconfig/network/config?

    Thanks,
    Jerry

  2. Re: Manual DNS server info update

    Hi Jerry,

    Quote Originally Posted by jerry98 View Post
    Hello,

    In https://www.suse.com/documentation/s...t_manconf.html,
    the /etc/resolv.conf should not be edited by hand. Instead, it is generated by the netconfig script. To define static DNS configuration without using YaST, edit the appropriate variables manually in the /etc/sysconfig/network/config file.

    So I edited like
    NETCONFIG_DNS_STATIC_SERVERS="4.2.2.2"

    systemctl restart wicked
    cat /etc/resolv.conf

    However I don't see the change in /etc/resolv.conf

    Then I ran /sbin/netconfig update
    And the output says : Attention: you have modified /etc/resolv/conf. Leaving it untouched. You can find my version in /etc/resolv.conf.netconfig (which contains the DNS server I added in /etc/sysconfig/network/config file).

    I think I edited /etc/resolv.conf manually before the /etc/sysconfig/network/config test.

    So at this point, if I would need to update DNS server info again, should I continue to edit /etc/resolv.conf manually or /etc/sysconfig/network/config?
    you can run "/sbin/netconfig -f update" to force replacing the files with the generated version. I'd recommend to do so and stay with modifying /etc/sysconfig/network/config.

    Regards,
    J
    From the times when today's "old school" was "new school"

    If you find this post helpful and are logged into the web interface, show your appreciation and click on the star below...

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •