i can't seem to find anything recent related to agents auto-registering with the server using the dns name instead of the ip address for the agent interface.
In add_discovered_host() eventid:17426
query [txnlev:1] [select proxy_hostid,host,listen_ip,listen_dns,listen_port from autoreg_host where autoreg_hostid=14]
query [txnlev:1] [select null from hosts where host='host.xxx.com' and status=3]
query [txnlev:1] [select hostid,proxy_hostid from hosts where host='host.xxx.com' and flags<>2 and status in (0,1) order by hostid limit 1]
In DBget_nextid() tablename:'hosts'
query [txnlev:1] [select nextid from ids where nodeid=0 and table_name='hosts' and field_name='hostid']
query [txnlev:1] [update ids set nextid=nextid+1 where nodeid=0 and table_name='hosts' and field_name='hostid']
query [txnlev:1] [select nextid from ids where nodeid=0 and table_name='hosts' and field_name='hostid']
End of DBget_nextid():10123 table:'hosts' recid:'hostid'
query [txnlev:1] [insert into hosts (hostid,proxy_hostid,host,name) values (10123,null,'host.xxx.com','host.xxx.com')]
In DBadd_interface()
query [txnlev:1] [select interfaceid,useip,ip,dns,port,main from interface where hostid=10123 and type=1]
In DBget_nextid() tablename:'interface'
query [txnlev:1] [select nextid from ids where nodeid=0 and table_name='interface' and field_name='interfaceid']
query [txnlev:1] [update ids set nextid=nextid+1 where nodeid=0 and table_name='interface' and field_name='interfaceid']
query [txnlev:1] [select nextid from ids where nodeid=0 and table_name='interface' and field_name='interfaceid']
End of DBget_nextid():20 table:'interface' recid:'interfaceid'
query [txnlev:1] [insert into interface (interfaceid,hostid,main,type,useip,ip,dns,port) values (20,10123,1,1,1,'192.168.246.148','',10050)]
it seems as though the dns name is known by zabbix_server, but for some reason it doesn't use it.
i'm using the following from the amazon linux repo, it's the latest version.
zabbix_agentd --version
Zabbix Agent (daemon) v2.2.1 (revision 40808) (09 December 2013)
zabbix_server --version
Zabbix server v2.2.1 (revision 40808) (09 December 2013)
has this been fixed/changed in a newer version?
EDIT - just found this - https://www.zabbix.com/documentation...g_of_dns_names
5.5.4 Automatic filling of DNS names
For network discovery and active agent autoregistration, host DNS entry is now populated by doing a reverse lookup from Zabbix server or Zabbix proxy, if discovery is performed by a proxy.
EDIT 2 - providing a working reverse dns entry for the ip address does indeed populate the dns name into the agent interface. however, the connect to option is still set to IP instead of DNS. does anyone know how to force that to use DNS?
In add_discovered_host() eventid:17426
query [txnlev:1] [select proxy_hostid,host,listen_ip,listen_dns,listen_port from autoreg_host where autoreg_hostid=14]
query [txnlev:1] [select null from hosts where host='host.xxx.com' and status=3]
query [txnlev:1] [select hostid,proxy_hostid from hosts where host='host.xxx.com' and flags<>2 and status in (0,1) order by hostid limit 1]
In DBget_nextid() tablename:'hosts'
query [txnlev:1] [select nextid from ids where nodeid=0 and table_name='hosts' and field_name='hostid']
query [txnlev:1] [update ids set nextid=nextid+1 where nodeid=0 and table_name='hosts' and field_name='hostid']
query [txnlev:1] [select nextid from ids where nodeid=0 and table_name='hosts' and field_name='hostid']
End of DBget_nextid():10123 table:'hosts' recid:'hostid'
query [txnlev:1] [insert into hosts (hostid,proxy_hostid,host,name) values (10123,null,'host.xxx.com','host.xxx.com')]
In DBadd_interface()
query [txnlev:1] [select interfaceid,useip,ip,dns,port,main from interface where hostid=10123 and type=1]
In DBget_nextid() tablename:'interface'
query [txnlev:1] [select nextid from ids where nodeid=0 and table_name='interface' and field_name='interfaceid']
query [txnlev:1] [update ids set nextid=nextid+1 where nodeid=0 and table_name='interface' and field_name='interfaceid']
query [txnlev:1] [select nextid from ids where nodeid=0 and table_name='interface' and field_name='interfaceid']
End of DBget_nextid():20 table:'interface' recid:'interfaceid'
query [txnlev:1] [insert into interface (interfaceid,hostid,main,type,useip,ip,dns,port) values (20,10123,1,1,1,'192.168.246.148','',10050)]
it seems as though the dns name is known by zabbix_server, but for some reason it doesn't use it.
i'm using the following from the amazon linux repo, it's the latest version.
zabbix_agentd --version
Zabbix Agent (daemon) v2.2.1 (revision 40808) (09 December 2013)
zabbix_server --version
Zabbix server v2.2.1 (revision 40808) (09 December 2013)
has this been fixed/changed in a newer version?
EDIT - just found this - https://www.zabbix.com/documentation...g_of_dns_names
5.5.4 Automatic filling of DNS names
For network discovery and active agent autoregistration, host DNS entry is now populated by doing a reverse lookup from Zabbix server or Zabbix proxy, if discovery is performed by a proxy.
EDIT 2 - providing a working reverse dns entry for the ip address does indeed populate the dns name into the agent interface. however, the connect to option is still set to IP instead of DNS. does anyone know how to force that to use DNS?
Comment