ntp·þÎñÆ÷µÄ½¨Á¢ÓëÉèÖÃ
[font=ËÎÌå][size=2]×î½ü¹«Ë¾×öÒ»Ì×Ó¦ÓÃϵͳ£¬ÐèÒªÄÚÍøÖ÷»úʱ¼äͬ²½£¬ËùÒÔ¾ÍÉÏÍøÕÒ¹ØÓÚntp·½ÃæµÄ×ÊÁÏ£¬ÆäʵҲ²»ÄÑ£¬Ö»ÊÇÔÚÅäÖùý³ÌÖо³£»á³öµÄÒ»µãС´íÎó£¬Í¨¹ý²»¶Ï³¢ÊÔ£¬ÎÒ×ܽáÁËÒ»¸ö¼òµ¥¿ÉÐеIJ½Öè¡£[/size][/font][color=#000000][size=2][font=ËÎÌå][size=10.5pt]1¡¢[font=ËÎÌå] [/font][/size][/font][font=ËÎÌå][size=10.5pt]linux[/size][/font][font=ËÎÌå][size=10.5pt]×÷Ϊ·þÎñÆ÷£¬ÆäËû»úÆ÷À´Óë֮ͬ²½¡£[/size][/font][/size][/color]
[color=#000000][size=2][font=ËÎÌå][size=10.5pt]a¡¢[font=ËÎÌå] [/font][/size][/font][font=ËÎÌå][size=10.5pt]Ê×Ïȼì²élinuxϵͳÖÐÊÇ·ñÓа²×°ntpÈí¼þ°ü[/size][/font][/size][/color]
[size=2][color=#000000][font=ËÎÌå][size=10.5pt] #rpm -q ntp[/size][/font][/color][/size]
[font=ËÎÌå][size=10.5pt][font=ËÎÌå][size=2][/size][/font][/size][/font]
[font=ËÎÌå][size=10.5pt][color=#000000][size=2]Èç¹ûûÓа²×°¿ÉÒÔÈ¥ÏÂÔØÈí¼þ°ü½øÐа²×°¡£ÀýÈçÏÂÔØntp-4.1.2-4.EL3.1.i386.rpm È»ºó°²×°¡¢ÅäÖãº[/size][/color][/size][/font]
[font=ËÎÌå][size=10.5pt][color=#000000][size=2]# rpm -ivh ntp-4.1.2-4.EL3.1.i386.rpm[/size][/color][/size][/font]
[font=ËÎÌå][size=10.5pt][size=2][color=#000000]# vi /etc/ntp.conf
[/color][/size][/size][/font][font=ËÎÌå][size=10.5pt][size=2][color=#000000]×¢ÊÍÒ»ÐÐ[/color][/size]
[size=2][color=#000000]restrict default ignore
[/color][/size][size=2][color=#000000]¼ÓÈëÒ»ÐÐ[/color][/size]
[color=#000000][size=2]restrict 192.168.10.0 mask 255.255.255.0 nomodify notrap[/size][/color][/size][/font]
[font=ËÎÌå][size=10.5pt][color=#000000][size=2]ÉÏÃæÎª¸Ã¾ÖÓòÍøµÄÍøÂçºÍÑÚÂë¡£[/size][/color][/size][/font]
[font=ËÎÌå][size=10.5pt][color=#000000][size=2]# service ntpd start[/size][/color][/size][/font]
[font=ËÎÌå][size=10.5pt][color=#000000][size=2]Æô¶¯ntp·þÎñ¡£[/size][/color][/size][/font]
[color=#000000][size=2][font=ËÎÌå][size=10.5pt]# netstat -an |grep 123
[/size][/font][font=ËÎÌå][size=10.5pt]È·±£¸Ã¶Ë¿ÚÒÔudp·½Ê½¿ª·Å[/size][/font][/size][/color]
[color=#000000][size=2][font=ËÎÌå][size=10.5pt]b¡¢[font=ËÎÌå] [/font][/size][/font][font=ËÎÌå][size=10.5pt]ʹ¾ÖÓòÍøÄÚËùÓÐÖ÷»ú´¦ÓÚͬһ¸ö¹¤×÷×éÖУ¬ÒòΪntpֻͬ²½Í¬Ò»¸ö¹¤×÷×éÖеÄÖ÷»ú¡£[/size][/font][/size][/color]
[font=ËÎÌå][size=10.5pt][color=#000000][size=2]#vi /etc/samba/snb.conf[/size][/color][/size][/font]
[font=ËÎÌå][size=10.5pt][color=#000000][size=2]¸Äworkgroup = workgroup[/size][/color][/size][/font]
[font=ËÎÌå][size=10.5pt][color=#000000][size=2]ÕâÀïÖ÷»ú¶¼ÔÚworkgroup¹¤×÷×éÖС£[/size][/color][/size][/font]
[color=#000000][size=2][font=ËÎÌå][size=10.5pt]c¡¢[font=ËÎÌå] [/font][/size][/font][font=ËÎÌå][size=10.5pt]ÔÚwindowsÖУ¬´ò¿ªÊ±¼ä¹ÜÀí[/size][/font][/size][/color]
[font=ËÎÌå][size=10.5pt][color=#000000][size=2]°Ñ·þÎñÆ÷µØÖ·Ö¸¶¨Îª¿ª·Åntp·þÎñµÄÖ÷»úµØÖ·¡£[/size][/color][/size][/font]
[font=ËÎÌå][size=10.5pt][color=#000000][size=2]Èç¹ûÕâÑù²»³É¹¦ÔòÔÚÃüÁîÐÐÖ´ÐÐ[/size][/color][/size][/font]
[font=ËÎÌå][size=10.5pt][size=2][color=#000000]>net time [/color][/size][size=2][color=#0000ff]\\servername(ip)[/color][/size][color=#000000][size=2] /set[/size][/color][/size][/font]
[font=ËÎÌå][size=10.5pt][color=#000000][size=2]È»ºó¿ÉÒÔ°ÑÕâÌõÃüÁî×÷ΪÅú´¦ÀíÎļþÌí¼Óµ½¼Æ»®ÈÎÎñÖС£[/size][/color][/size][/font]
[font=ËÎÌå][size=10.5pt][color=#000000][size=2]Èç¹ûÓô˷½Ê½Ôò½«¡°×Ô¶¯ÓëInternetʱ¼ä·þÎñÆ÷ͬ²½¡±µÄ¹´È¥µô¡£[/size][/color][/size][/font]
[font=ËÎÌå][size=10.5pt][color=#000000][size=2]¿ÉÒÔÐÞ¸Äͬ²½Ê±¼ä¼ä¸ô£¬ÐÞ¸Ä×¢²á±í£¬Õ¹¿ª[/size][/color][/size][/font]
[color=black][font=ËÎÌå][size=10.5pt][size=2]HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\W32Time\TimeProviders\NtpClient[/size][/size][/font][/color]
[color=black][font=ËÎÌå][size=10.5pt][size=2]Ë«»÷SpecialPollInterval ¼üÖµ£¬½«¶Ô»°¿òÖеġ°»ùÊýÀ¸¡±Ñ¡Ôñµ½¡°Ê®½øÖÆ¡±ÉÏ£¬[/size][/size][/font][/color]
[font=ËÎÌå][size=10.5pt][color=#000000][size=2]½«Öµ¸ÄΪÏëÒªµÄÖµ£¬µ¥Î»ÎªÃ룬86400=60£¨Ã룩*60£¨·Ö£©*24£¨Ê±£©£¬ÎªÒ»Ììͬ²½Ò»´Î¡£¸ÃĬÈÏÖµÒ»°ãΪ604800£¬¼´Ò»ÖÜͬ²½Ò»´Î¡£[/size][/color][/size][/font]
[color=#000000][size=2][font=ËÎÌå][size=10.5pt]d¡¢[font=ËÎÌå] [/font][/size][/font][font=ËÎÌå][size=10.5pt]linux[/size][/font][font=ËÎÌå][size=10.5pt]¿Í»§¶Ë[/size][/font][/size][/color]
[font=ËÎÌå][size=10.5pt][size=2][color=#000000]# ntpdate 192.168.10.1 ¨Cset
[/color][/size][/size][/font][font=ËÎÌå][size=10.5pt][size=2][color=#000000]Ó¦¸ÃÏÔʾͬ²½³É¹¦£¬ÓÐʱ²»±¨´í¼´Îª³É¹¦¡£[/color][/size]
[size=2][color=#000000]# crond -e
[/color][/size][size=2][color=#000000]¼ÓÈë[/color][/size]
[size=2][color=#000000]0-59/10 * * * * /usr/sbin/ntpdate 192.168.10.1 ¨Cset
[/color][/size][color=#000000][size=2]±íʾÿ¸ô10·ÖÖÓͬ²½Ò»´Îʱ¼ä£¬Ê±¼ä¼ä¸ô¿ÉËæÒâµ÷Õû¡£[/size][/color][/size][/font]
[font=ËÎÌå][size=10.5pt][size=2][color=#000000][/color][/size][/size][/font]
[font=ËÎÌå][size=10.5pt][size=2][color=#000000][/color][/size][/size][/font]
[color=#000000][size=2][font=ËÎÌå][size=10.5pt]2¡¢[font=ËÎÌå] [/font][/size][/font][font=ËÎÌå][size=10.5pt]windows[/size][/font][font=ËÎÌå][size=10.5pt]×÷Ϊʱ¼ä·þÎñÆ÷¡£[/size][/font][/size][/color]
[color=#000000][size=2][font=ËÎÌå][size=10.5pt]a¡¢[font=ËÎÌå] [/font][/size][/font][font=ËÎÌå][size=10.5pt]ÐÞ¸Ä×¢²á±í£¬Ê¹¸ÃÖ÷»úΪntp·þÎñÆ÷, ´ò¿ª[/size][/font][/size][/color]
[font=ËÎÌå][size=10.5pt][color=#000000][size=2]HKEY_LOCAL_MACHINE/SYSTEM/CurrentControlSet/Services/W32Time/Parameters[/size][/color][/size][/font]
[font=ËÎÌå][size=10.5pt][color=#000000][size=2]±à¼LocalNTPֵΪ1.[/size][/color][/size][/font]
[font=ËÎÌå][size=10.5pt][size=2][color=#000000][/color][/size][/size][/font]
[color=#000000][size=2][font=ËÎÌå][size=10.5pt]b¡¢[font=ËÎÌå] [/font][/size][/font][font=ËÎÌå][size=10.5pt]Æô¶¯ntp·þÎñ£¬¿ÉÒÔÔÚÃüÁîÐнçÔËÐÐ [/size][/font][/size][/color]
[font=ËÎÌå][size=10.5pt][color=#000000][size=2]>net stop w32time[/size][/color][/size][/font]
[font=ËÎÌå][size=10.5pt][color=#000000][size=2]>net start w32time[/size][/color][/size][/font]
[color=#000000][size=2][font=ËÎÌå][size=10.5pt]»òÕßÔÚ¿ØÖÆÃæ°å[/size][/font][font=ËÎÌå][font=Wingdings][size=10.5pt][font=Wingdings]¨¤[/font][/size][/font][font=ËÎÌå][size=10.5pt]¹ÜÀí¹¤¾ß[/size][/font][font=Wingdings][size=10.5pt][font=Wingdings]¨¤[/font][/size][/font][font=ËÎÌå][size=10.5pt]·þÎñÀïÃæÆô¶¯Windows time·þÎñ£¬È»ºó°Ñ¸Ã·þÎñÉèΪ×Ô¶¯Æô¶¯¡£ÒԺ󿪻ú¾ÍÔËÐд˷þÎñ¡£[/size][/font][/font][/size][/color]
[font=ËÎÌå][size=10.5pt][size=2][color=#000000][/color][/size][/size][/font]
[font=ËÎÌå][size=10.5pt][color=#000000][size=2]¿Í»§¶ËÉèÖÃͬÉÏ¡£[/size][/color][/size][/font]
[font=ËÎÌå][size=10.5pt][color=#000000][size=2]¸½£ºntp.confÄÚÈÝ£¬×÷Ϊ·þÎñÆ÷£¨×¢ÊͲ¿·Öδ¸ø³ö£©[/size][/color][/size][/font]
[font=ËÎÌå][size=10.5pt][size=2][color=#000000][/color][/size][/size][/font]
[font=ËÎÌå][size=10.5pt][color=#000000][size=2]restrict
127.0.0.1[/size][/color][/size][/font]
[font=ËÎÌå][size=10.5pt][color=#000000][size=2]restrict
192.168.1.0 mask 255.255.255.0 nomodify notrap[/size][/color][/size][/font]
[font=ËÎÌå][size=10.5pt][color=#000000][size=2]server
127.127.1.0[/size][/color][/size][/font]
[font=ËÎÌå][size=10.5pt][color=#000000][size=2]fudge
127.127.1.0 stratum 5[/size][/color][/size][/font]
[font=ËÎÌå][size=10.5pt][color=#000000][size=2]driftfile
/var/lib/ntp/drift[/size][/color][/size][/font]
[font=ËÎÌå][size=10.5pt][color=#000000][size=2]broadcastdelay
0.008[/size][/color][/size][/font]
[font=ËÎÌå][size=10.5pt][color=#000000][size=2]keys
/etc/ntp/keys[/size][/color][/size][/font]
[font=ËÎÌå][size=2][/size][/font]
[[i] ±¾Ìû×îºóÓÉ gfluisfigo ÓÚ 2007-10-19 11:28 ±à¼ [/i]]
Ò³:
[1]