Select Your Language

Infrastructure and Management

Cloud Computing

Storage

Runtimes

Integration and Automation

  • Comments
  • Cannot set ndots with nmcli.

    Posted on

    Hi All,
    I am using RHEL 8.6. (But even on RHEL 9 I have the same problem)
    I need to use ndots option for nslookup.
    On my servers, I use nmcli settings with NetworkManager keyfiles; I do not use old ifcfg scripts (/etc/sysconfig/network-scripts/).
    Thus I have added ndots option with command :
    nmcli connection modify ens192 ipv4.dns-options "ndots:5"
    It adds well ndots:5 option to active connection, and I can see it with nmcli -p connection show ens192.
    Then I reload and restart network services, even reboot the server, I still cannot resolve host host1.mylab.abc.zone1.com
    But when I do nslookup command like => nslookup -ndots:5 host1.mylab.abc.zone1.com it resolves the host.
    How to correctly enable ndots in nslookup ?
    I cannot manually add this option to /etc/resolv.conf, because my /etc/resolv.conf is automatically Generated from NetworkManager, and I need to keep it as such. I've even tried dns-options paragraph in NetworkManager conf files - no luck.
    Actually, what I really need is, to find where and how to put ndots option in NetworkManager conf files.
    Can you help me?

    by

    points

    Responses

    Red Hat LinkedIn YouTube Facebook X, formerly Twitter

    Quick Links

    Help

    Site Info

    Related Sites

    © 2026 Red Hat