49. DNS

Hostname and DNS data

49.1. Summary of Module Globals

List of Global Functions

  • Export - Dump the DNS settings to a map, for autoinstallation use.

  • Import - Get all the DNS configuration from a map. When called by dns_auto (preparing autoinstallation data) the map may be empty.

  • IsHostLocal - Check if hostname or IP address is local computer Used to determine if LDAP server is local (and it should be checked if required schemes are included Calls Read () function before querying any data

  • Read - Reads current DNS and hostname settings Includes Host,NetworkConfig::Read

  • ReadHostDomain - Use this host and domain name, if they are defined

  • ReadNameserver - Use the parameter, coming usually from install.inf, if it is defined. Used when there is nothing better.

  • Summary - Create DNS text summary

  • Write - Write new DNS and hostname settings Includes Host,NetworkConfig::Write

List of Global Variables

49.2. Global Functions

49.2.1. Export

Dump the DNS settings to a map, for autoinstallation use.

Return value

  • map - autoinstallation settings

49.2.2. Import

Get all the DNS configuration from a map. When called by dns_auto (preparing autoinstallation data) the map may be empty.

Function parameters

  • map settings

Return value

  • boolean - true if success

49.2.3. IsHostLocal

Check if hostname or IP address is local computer Used to determine if LDAP server is local (and it should be checked if required schemes are included Calls Read () function before querying any data

Function parameters

  • string check_host

Return value

  • boolean - true if hostname is local host

49.2.4. Read

Reads current DNS and hostname settings Includes Host,NetworkConfig::Read

Return value

  • boolean - true if success

49.2.5. ReadHostDomain

Use this host and domain name, if they are defined

Function parameters

  • string hn

  • string dn

Return value

  • boolean - true if the hostname has been assigned

49.2.6. ReadNameserver

Use the parameter, coming usually from install.inf, if it is defined. Used when there is nothing better.

Function parameters

  • string ns

Return value

  • boolean - true if success

49.2.7. Summary

Create DNS text summary

Return value

  • string - summary text

49.2.8. Write

Write new DNS and hostname settings Includes Host,NetworkConfig::Write

Return value

  • boolean - true if success

49.3. Global Variables

49.3.1. domain

Domain Name (not including the host part)

49.3.2. hostname

Short Hostname

49.3.3. modified

Data was modified?

49.3.4. proposal_valid

Should the hostname be proposed? #152218

49.3.5. resolv_conf_process

Name of program that has claimed resolv.conf

49.4. Module Requirements

49.4.1. Module Imports

  • Detection
  • Host
  • Hostname
  • IP
  • NetworkConfig
  • NetworkDevices
  • Service
  • Summary

49.4.2. Module Includes

  • network/runtime.ycp