ntpdate given Can not find host ntp1.aliyun.com update the system time: Servname not supported for ai_socktype (-8)

ntpdate given Can not find host ntp1.aliyun.com update the system time: Servname not supported for ai_socktype (-8)

Error reported:

[root@web01 ~]# ntpdate ntp1.aliyun.com

Error resolving ntp1.aliyun.com: Servname not supported for ai_socktype (-8)

11 Feb 20:58:03 ntpdate[3318]: Can't find host ntp1.aliyun.com: Servname not supported for ai_socktype (-8)

11 Feb 20:58:03 ntpdate[3318]: no servers can be used, exiting

The reason: / etc / services file is modified or non-existent domain lead to parsing errors

[@ web01 the root etc] -l Servic LS # * 

-rw-R & lt -. 10240 r-- the root. 1 the root Services On Feb. 11 02:27 

-rw-R & lt - r--. 1 the root the root 641.02 thousand On Feb. 11 02:22 after long services.bak Comparative found format source files has been modified 

[@ web01 the root etc] # Music Videos Services / tmp 

[@ web01 the root etc] -l Servic LS # * 

-rw-R & lt - r--. 1 641 020 the root the root On Feb. 11 services.bak 02:22 

[@ web01 the root etc] # Music Videos services.bak Services 

[@ web01 the root etc] -l Servic LS # * 

-rw-R & lt - r--. 1 the root the root 641.02 thousand On Feb. 11 02:22 Services 

[ @ web01 etc root] # ntpdate ntp1.aliyun.com 

12 Feb 17:00:54 ntpdate [3363]: the STEP Time Server 182.92.12.11 offset 71111.641937 sec

 

 

Guess you like

Origin www.cnblogs.com/HByang/p/11876384.html