• 24Jul

    http://www.pfsense.org

    http://www.untangle.com/Product-Overview

  • 24Jul

    Install PoPToP Point to Point Tunneling Server:

    sudo apt-get install pptpd

    Edit /etc/pptpd.conf file:

    sudo joe /etc/pptpd.conf

    Uncomment the following lines (replace IP range if you like)

    localip 192.168.0.1
    remoteip 192.168.1.1-255

    Save and exit.

    Edit /etc/ppp/pptpd-options file

    sudo joe /etc/ppp/pptpd-options

    Continue reading »

  • 24Jul

    For updates of this post please visithttp://mexpolk.wordpress.com.

    Hello again, this time we’re going to setup a DynDNS client so your computer/server can be reached from anywhere.

    Step 1

    First, you need to create an account with DynDNS to do so follow this howto:https://www.dyndns.com/services/dns/dyndns/howto.html.

    Step 2

    First we’ll install ssh and ssh-socket so we can send our DynDNS user and password encrypted instead clear text:

    $ sudo apt-get install ssh libio-socket-ssl-perl

    Continue reading »

  • 21Jul

    ความเป็นมาและประโยชน์น้ำหมักชีวภาพหรือEM

    น้ำหมักชีวภาพหรือน้ำสกัดชีวภาพ
    ปัจจุบันได้มีการเรียกชื่อน้ำหมักชีวภาพที่แตกต่างกันออกไป เช่น น้ำสกัดชีวภาพ ปุ๋ยน้ำจุลินทรีย์ เป็นต้น และผู้คิดค้นวิธีการทำน้ำหมักชีวภาพขึ้นมาขณะนี้ไม่ต่ำกว่า 100 สูตร โดยเกษตรกรเองได้ทดลองทำ และเรียนรู้นำไปใช้กับพืชผลของตนเอง ก็ได้พบความมหัศจรรย์ของเจ้าน้ำหมักชีวภาพตัวนี้ ว่าสามารถดลบันดาลให้พืชผลของตนเองเจริญเติบโตงอกงามขึ้นอย่างรวดเร็ว ในระยเวลามิช้ามินาน ศัตรูพืชที่เคยเข้ามารบกวนพืชผลต่าง ๆ หลังจากปลูกไม่ว่าจะเป็นโรคแมลงค่อย ๆ ลดน้อยถอยลงไปเป็นลำดับ หลังจากที่ได้ใช้น้ำหมักชีวภาพนี้แล้ว จึงแสดงให้เห็นว่าน้ำหมักชีวภาพมีความสำคัญ และความจำเป็นต่อการทำเกษตรอินทรีย์อย่างแท้จริง

    ประโยชน์ของน้ำหมักชีวภาพ
    - เร่งการเจริญเติบโตของพืช เร่งการออกดอกของพืช
    - เพิ่มคุณภาพของผลผลิตให้ดีขึ้น เป็นสารไล่แมลงศัตรูพืช
    - เป็นสารเสริมสุขภาพในคนและสัตว์ บำบัดกลิ่นเหม็นในปศุสัตว์
    - ฉีดพ่นก่อนไถกลบตอซังทำให้ตอซังนิ่ม บำบัดน้ำเสียในการประมง
    - เป็นสารเร่งและเป็นธาตุอาหารเสริมในปุ๋ยหมัก

    Continue reading »

  • 15Jul

    Pre-Installation Setup

     

    None of the following pre-installation steps are strictly necessary.

     

    User Permissions

     

    NFS user permissions are based on user ID (UID). UIDs of any users on the client must match those on the server in order for the users to have access. The typical ways of doing this are:

    • Manual password file synchronization
    • Use of LDAP

    • Use of NIS

    It’s also important to note that you have to be careful on systems where the main user has root access – that user can change UID’s on the system to allow themselves access to anyone’s files. This page assumes that the administrative team is the only group with root access and that they are all trusted. Anything else represents a more advanced configuration, and will not be addressed here.

      Continue reading »

  • 15Jul

    NFS was developed at a time when we weren’t able to share our drives like we are able to today – in the Windows environment. It offers the ability to share the hard disk space of a big server with many smaller clients. Again, this is a client/server environment. While this seems like a standard service to offer, it was not always like this. In the past, clients and servers were unable to share their disk space.

     

    Thin clients have no hard drives and thus need a “virtual” hard-disk. The NFS mount their hard disk from the server and, while the user thinks they are saving their documents to their local (thin client) disk, they are in fact saving them to the server. In a thin client environment, the root, usr and home partitions are all offered to the client from the server via NFS

     

    .

  • 12Jul

    Imagine you have a machine with all of its disk full and another with unused gigabytes, and you don’t want to move the data from one to the other. Why not using the second’s disk on the first, you can do it with iSCSI but you can do it with ATA over Ethernet (AoE) too. It’s the second method I’ll explain in this article. All of this was made with two computers running Debian Etch.

    Prepare The Kernel
    First check if your running kernel has AoE, the config option name is CONFIG_ATA_OVER_ETH, have a look at fig1, my kernel has AoE as a module:

    host:/# grep ATA_OVER /boot/config-`uname -r`

    CONFIG_ATA_OVER_ETH=m
    host:/#

    If not, configure your kernel and activate AoE in core or in module like you prefer:

    Device Drivers –>
    |- Block Devices —>
    |- ATA over Ethernet support

    Ok now you have a kernel with AoE, just load the aoe module:

    host:/# modprobe aoe

    You can check your syslog to be sure AoE is available:

    host:/#tail /var/log/syslog

    Oct 10 11:54:07 host kernel: aoe: aoe_init: AoE v22 initialised.
    host:/#

    Now we’ll call the client ‘client’ and the server ’server’, funny isn’t it?
    In SAN vocabulary we call the client ‘initiator’ and the server ‘target’, I prefer to continue using simplest terms. Continue reading »

  • 12Jul
    • ทดสอบใช้กับ ubuntu 8.04
    • ต้นฉบับจาก http://smartmontools.sourceforge.net/
    • ใช้สำหรับอ่านค่าคุณสมบัติต่างๆของ hard disk
    • ต้องตั้งค่า BIOS ของ PC ให้รองรับคุณสัมบัติ S.M.A.R.T hard disk ด้วย

     

    1. ติดตั้งด้วยคำสั่ง  sudo apt-get install smartmontools
    2. ในขั้นต้นให้ตรวจสอบว่าใน PC มี hard disk กี่ลูก ด้วยคำสั่ง sudo fdisk -lตัวอย่างนี้เป็นแบบง่ายๆ มี hard disk ลูกเดียว
      Disk /dev/hda: 20.4 GB, 20404101120 bytes
      255 heads, 63 sectors/track, 2480 cylinders
      Units = cylinders of 16065 * 512 = 8225280 bytes
      Device Boot      Start         End      Blocks   Id  System
      /dev/hda1   *           1          13      104391   83  Linux
      /dev/hda2              14        2480    19816177+  8e  Linux LVM

      ตัวอย่างต่อไปมี hard disk 2 ลูก ต่อกันแบบ software raid
      Disk /dev/hda: 80.0 GB, 80026361856 bytes
      255 heads, 63 sectors/track, 9729 cylinders
      Units = cylinders of 16065 * 512 = 8225280 bytes
      Device Boot      Start         End      Blocks   Id  System
      /dev/hda1   *           1          13      104391   fd  Linux raid autodetect
      /dev/hda2              14        9447    75778605   fd  Linux raid autodetect
      /dev/hda3            9448        9708     2096482+  fd  Linux raid autodetect
      Disk /dev/hdc: 80.0 GB, 80026361856 bytes
      255 heads, 63 sectors/track, 9729 cylinders
      Units = cylinders of 16065 * 512 = 8225280 bytes
      Device Boot      Start         End      Blocks   Id  System
      /dev/hdc1   *           1          13      104391   fd  Linux raid autodetect
      /dev/hdc2              14        9447    75778605   fd  Linux raid autodetect
      /dev/hdc3            9448        9708     2096482+  fd  Linux raid autodetect

    3. ตรวจสอบชนิด hard disk /dev/hda ด้วยตัวอย่างคำสั่ง  sudo smartctl -i /dev/hda
      หากเป็น hard disk แบบ SATA อาจต้องเพิ่ม option ว่า -d ata ด้วย ตัวอย่างคำสั่ง sudo smartctl -i /dev/sda -d ata ได้ผลดังตัวอย่าง=== START OF INFORMATION SECTION ===
      Device Model:     ST320413A
      Serial Number:    7ED2J419
      Firmware Version: 3.39
      User Capacity:    20,404,101,120 bytes
      Device is:        In smartctl database [for details use: -P show]
      ATA Version is:   4
      ATA Standard is:  Exact ATA specification draft version not indicated
      Local Time is:    Mon Oct 16 12:55:11 2006 ICT
      SMART support is: Available – device has SMART capability.
      SMART support is: Enabled
    4. ตรวจสอบสุขภาพ hard disk /dev/hda  ด้วยตัวอย่างคำสั่ง sudo smartctl -Hc /dev/hda
      หากเป็น hard disk แบบ SATA อาจต้องเพิ่ม option ว่า -d ata ด้วย  ตัวอย่างคำสั่ง sudo smartctl -Hc /dev/sda -d ata  ได้ผลดังตัวอย่าง*** บรรทัดที่มีคำว่า PASSED แสดงว่าปรกติดี ถ้าเสียจะเป็น FAILED
      === START OF READ SMART DATA SECTION ===
      SMART overall-health self-assessment test result: PASSED

      General SMART Values:
      Offline data collection status:  (0×82) Offline data collection activity
                                              was completed without error.
                                              Auto Offline Data Collection: Enabled.
      Self-test execution status:      (   0) The previous self-test routine completed                                        without error or no self-test has ever
                                              been run.
      Total time to complete Offline
      data collection:                 ( 422) seconds.
      Offline data collection
      capabilities:                    (0×1b) SMART execute Offline immediate.
                                              Auto Offline data collection on/off support.
                                              Suspend Offline collection upon new
                                              command.
                                              Offline surface scan supported.
                                              Self-test supported.
                                              No Conveyance Self-test supported.
                                              No Selective Self-test supported.
      SMART capabilities:            (0×0003) Saves SMART data before entering
                                              power-saving mode.
                                              Supports SMART auto save timer.
      Error logging capability:        (0×01) Error logging supported.
                                              No General Purpose Logging support.
      Short self-test routine
      recommended polling time:        (   1) minutes.
      Extended self-test routine
      recommended polling time:        (  23) minutes.

    5. ทดสอบแบบเร็ว hard disk /dev/hda  ด้วยตัวอย่างคำสั่ง sudo smartctl -t short /dev/hda
      หากเป็น hard disk แบบ SATA อาจต้องเพิ่ม option ว่า -d ata ด้วย  ตัวอย่างคำสั่ง sudo smartctl -t short /dev/sda -d ata  ได้ผลดังตัวอย่าง=== START OF OFFLINE IMMEDIATE AND SELF-TEST SECTION ===
      Sending command: “Execute SMART Short self-test routine immediately in off-line mode”.
      Drive command “Execute SMART Short self-test routine immediately in off-line mode” successful.
      Testing has begun.
      Please wait 1 minutes for test to complete.
      Test will complete after Mon Oct 16 15:01:20 2006

      Use smartctl -X to abort test.

      ให้รอสัก 1 นาที จะได้ผลลัพธ์ออกมา
      ตรวจสอบดูด้วยคำสั่งว่า  sudo smartctl -l selftest /dev/hda
      หากเป็น hard disk แบบ SATA ต้องเพิ่ม option ว่า -d ata ด้วย
      ตัวอย่างคำสั่ง smartctl -l selftest /dev/sda -d ata
      ได้ผลตัวอย่าง

      === START OF READ SMART DATA SECTION ===
      SMART Self-test log structure revision number 1
      Num  Test_Description    Status                  Remaining  LifeTime(hours)  LBA_of_first_error
      # 1  Short offline       Completed without error       00%     19789         -
      # 2  Short offline       Completed without error       00%     19788         -

      หมายความว่าเคยทดสอบมา 2 ครั้งแล้ว และสภาพดีไม่มีปัญหา

    6. ดูรายงาน error ของ hard disk /dev/hda  ด้วยตัวอย่างคำสั่ง  sudo smartctl -l error /dev/hda
      หากเป็น hard disk แบบ SATA อาจต้องเพิ่ม option ว่า -d ata ด้วย ตัวอย่างคำสั่ง sudo smartctl -l error /dev/sda -d ataตัวอย่างผลที่ได้แสดงว่าเป็นปรกติดี
      === START OF READ SMART DATA SECTION ===
      SMART Error Log Version: 1
      No Errors Logged

      ตัวอย่างผลที่ได้  ว่าเคยมี error เกิดขึ้น แต่ก็ยังคงใช้งานได้
      === START OF READ SMART DATA SECTION ===
      SMART Error Log Version: 1
      ATA Error Count: 5
              CR = Command Register [HEX]
              FR = Features Register [HEX]
              SC = Sector Count Register [HEX]
              SN = Sector Number Register [HEX]
              CL = Cylinder Low Register [HEX]
              CH = Cylinder High Register [HEX]
              DH = Device/Head Register [HEX]
              DC = Device Command Register [HEX]
              ER = Error register [HEX]
              ST = Status register [HEX]
      Powered_Up_Time is measured from power on, and printed as
      DDd+hh:mm:SS.sss where DD=days, hh=hours, mm=minutes,
      SS=sec, and sss=millisec. It “wraps” after 49.710 days.

      Error 5 occurred at disk power-on lifetime: 13636 hours (568 days + 4 hours)
        When the command that caused the error occurred, the device was active or idle.
        After command completion occurred, registers were:
      ………. มีต่อมากมาย

    7. หากต้องการให้มีการตรวจสภาพโดยอัตโนมัติ แล้วส่งอีเมล์แจ้งผู้ดูแลระบบด้วย
      ให้แก้ไขแฟ้ม /etc/smard.conf ให้มีข้อความตัวอย่างว่า
      /dev/sda -H -m  myemail@domain.com
      หากเจอปัญหาสุขภาพไม่ค่อยดี  ก็จะส่งอีเมล์มาให้แก่ myemail@domain.com
    8. หากต้องการให้ระบบตรวจสอบอัตโนมัติทุกครั้งที่บูทเครื่อง  ให้แก้ไขแฟ้ม  /etc/default/smartmontools 
      ปรับตั้งค่าตัวแปรประมาณตัวอย่างดังนี้
      start_smartd=yes
      enable_smart=”/dev/sda”สั่งให้ระบบเริ่มทำงานด้วยคำสั่ง sudo /etc/init.d/smartmontools start
    9. ตัวอย่างคำสั่งในการอ่านเฉพาะค่าอุณหภูมิของ hard disk คือ
      sudo smartctl -A /dev/sda|grep “Temperature_Celsius”
  • 11Jul

    DNS free สำหรับผู้ที่ต้องการใช้ DNS ที่เป็นกลางและมีความเร็วสูง

    208.67.222.222
    208.67.220.220

     ที่มา: www.opendns.com

     

  • 04Jul

    ส่วนหนึ่งของ พรบ.ด้านคอมพิวเตอร์ ปี 2550 คือต้องปรับเวลาของเครื่องคอมพิวเตอร์ให้ตรงกับเวลามาตรฐาน เพราะจะมีผลต่อ log file ต่างๆ ที่อยู่ในเครื่อง เพื่อการตรวจสอบย้อนหลัง

    ในบทความนี้จะแนะนำวิธีการคอนฟิก NTP ในลินุกซ์ เพื่อให้มีเวลาตรงกับมาตรฐาน โดยจะมีตัวอย่างการคอนฟิกของ Fedora 9

     

    NTP คืออะไร
    NTP ย่อมาจาก Network Time Protocol ถือว่าเป็น protocol หนึ่ง (UDP Port 123) ที่ใช้ในการปรับเวลาของเครื่องต่างๆ ที่อยู่บนเครือข่ายให้มีเวลาตรงกันตลอดเวลา โดยเครื่อง client จะรัน ntpd เพื่อใช้เทียบเวลา server อยู่เรื่อยๆ ตลอดเวลา ซึ่งถ้าเวลาไม่ตรง โปรแกรม ntpd จะค่อยๆ ปรับเวลาของเครื่อง client ให้ใกล้เคียงเรื่อยๆ จนตรงกับ server ในที่สุด

    ในการใช้งาน จะมีวิธีการอ้างอิงเวลาเป็นลำดับขั้นที่เรียกว่า stratum โดยบนเครื่องคอมพิวเตอร์ค่าเริ่มต้นจะตั้งแต่ 1 ซึ่งถือเป็นเวลามาตรฐานกลาง เครื่องที่ทำหน้าที่เป็น stratum 1 นั้น จะมีกระบวนการเทียบเวลาจากอุปกรณ์ชนิดอื่นๆ ที่ไม่ใช่คอมพิวเตอร์  เช่น GPS เป็นต้น (อุปกรณ์จำพวกนี้ ถือว่าเป็น stratum 0, หาอ่านเพิ่มเติมได้จากในส่วนของ ข้อมูลอ้างอิง)

    ตอนคอนฟิก ถ้าเราไม่มีอุปกรณ์ที่เป็น stratum 0 แล้ว เราก็ต้องต่ออินเตอร์เน็ต เพื่ออ้างอิง (sync) เวลามาจากเครื่องที่เป็น stratum 1 และเมื่อเวลาตรงกันแล้ว เครื่องของเราก็จะถือว่าเป็น stratum 2 แล้วถ้าเครื่องที่มาอ้างอิงเวลาจากเครื่องนี้อีกที ก็จัดเป็น stratum 3, 4 เรื่อยๆ

    ประโยชน์ในการจัดเป็น stratum คือจะลดโหลดที่เกิดขึ้น คือแทนที่ทุกเครื่องจะไปอ้างอิง (sync) เวลามาจาก stratum 1 ก็กระจายโหลดไป ทั้งลดโหลดบน stratum 1 เอง แล้วก็ประหยัด bandwidth อินเตอร์เน็ตด้วย

    คำแนะนำ : ในทางปฎิบัติ แนะนำให้คอนฟิก NTP บนเครื่องเดียวหรือสองเครื่อง ที่ต่ออินเตอร์เน็ตได้ ให้ไปเทียบเวลาจาก  stratum 1 ส่วนเครื่องอื่นๆ ในสำนักงานของเรา ก็คอนฟิกเพื่อมาเทียบเวลาจากเครื่องนี้แทน หรืออาจจะมี ลำดับ 3, 4 ต่อไปอีกก็ได้ แล้วแต่จำนวนเครื่องที่มีอยู่ เช่น มีเครื่องที่ทำหน้าที่ stratum 2 ที่ต่ออินเตอร์เน็ตอยู่ 2 เครื่อง แล้วมี stratum 3 อีกจำนวนหนึ่งของแต่ละฝ่าย ส่วนเครื่อง client ที่อยู่ในฝ่ายก็คอนฟิกให้เทียบเวลาจาก stratum 3 อีกที ก็จะเป็น statum 4

    เริ่มคอนฟิก NTP
    โดยดีฟอลต์แล้ว NTP จะติดตั้งมาพร้อมกับ Fedora และจะมีคอนฟิกไฟล์หลักคือ /etc/ntp.conf ในคอนฟิกจะอ้างอิงเวลากับ stratum 1 ซึ่งเป็น time server จำนวน 3 ตัว ซึ่งเป็นของทาง redhat.com แต่ถ้าดูแล้วยังไม่มีการติดตั้ง ก็ติดตั้ง rpm ที่ชื่อ ntp-4.2.4p4-6.fc9

    ตัวอย่างคอนฟิก NTP ที่ติดตั้งมากับ Fedora 9

    [root@server ~]# cat /etc/ntp.conf
    ...
    # Use public servers from the pool.ntp.org project.
    # Please consider joining the pool (http://www.pool.ntp.org/join.html).
    server 0.fedora.pool.ntp.org dynamic
    server 1.fedora.pool.ntp.org dynamic
    server 2.fedora.pool.ntp.org dynamic
    ...

    หลังจากตรวจสอบการติดตั้งและคอนฟิก ขั้นต่อไปคือการรัน service โดยจะมี ntpdate และ ntpd ที่ต้องรัน ntpdate จะเป็นโปรแกรมที่รันครั้งเดียวปรับเวลาของเครื่องให้ใกล้เคียงกับ server มากที่สุด ส่วนการปรับโดยละเอียดจะเป็นหน้าที่ของ ntpd ซึ่งจะรันเป็น daemon อยู่ตลอดเวลา ค่อยๆ ปรับเวลาให้ตรงกับ server ซึ่งบางครั้งต้องใช้เวลานานพอสมควร

    ในตัวอย่าง จะแสดงการรันคำสั่ง พร้อมทั้งข้อความที่ขึ้นในไฟล์ /var/log/messages ด้วย เพื่อแสดงสถานะการปรับเวลา

    ตัวอย่างการรัน service NTP

    [root@server ~]# /etc/init.d/ntpdate start
    Aug 31 22:02:55 server ntpdate[20097]: step time server 66.187.233.4 offset -47.741249 sec
    [root@server ~]# /etc/init.d/ntpd start
    Aug 31 22:05:43 server ntpd[20149]: ntpd 4.2.4p4@1.1520-o Mon Apr  7 17:39:41 UTC 2008 (1)
    Aug 31 22:05:43 server ntpd[20150]: precision = 22.000 usec
    Aug 31 22:05:43 server ntpd[20150]: Listening on interface #0 wildcard, 0.0.0.0#123 Disabled
    Aug 31 22:05:43 server ntpd[20150]: Listening on interface #1 wildcard, ::#123 Disabled
    Aug 31 22:05:43 server ntpd[20150]: Listening on interface #2 lo, ::1#123 Enabled
    Aug 31 22:05:43 server ntpd[20150]: Listening on interface #3 eth0, fe80::20c:29ff:feef:f18c#123 Enabled
    Aug 31 22:05:43 server ntpd[20150]: Listening on interface #4 lo, 127.0.0.1#123 Enabled
    Aug 31 22:05:43 server ntpd[20150]: Listening on interface #5 eth0, 192.168.1.1#123 Enabled
    Aug 31 22:05:43 server ntpd[20150]: kernel time sync status 0040
    Aug 31 22:09:59 server ntpd[20150]: synchronized to 66.187.233.4, stratum 1
    Aug 31 22:09:59 server ntpd[20150]: time reset -0.299785 s
    Aug 31 22:14:30 server ntpd[20150]: synchronized to 66.187.224.4, stratum 1

    การใช้คำสั่ง ntptrace เพื่อแสดงสถานะ stratum
    เราสามารถใช้คำสั่ง ntptrace เพื่อตรวจสอบว่า ตอนนี้เครื่องของเรา เป็น stratum เท่าไร ซึ่ง stratum 16 หมายถึง เครื่องของเรายังไม่สามารถปรับเวลาให้ตรงกับ stratum 1 ได้ ต้องใช้เวลา

    [root@server etc]# ntptrace
    server.spalinux.com: stratum 16, offset 0.000000, synch distance 0.001800

    เมื่อเวลาผ่านไปซักพัก เมื่อเครื่องของเราสามารถปรับเวลาให้ตรงได้แล้ว จะมีข้อความดังตัวอย่าง ขึ้นในไฟล์ /var/log/messages

    Aug 31 22:22:01 server ntpd[20150]: synchronized to 66.187.233.4, stratum 1
    Aug 31 22:25:59 server ntpd[20150]: time reset -0.271322 s
    Aug 31 22:25:59 server ntpd[20150]: kernel time sync status change 0001
    Aug 31 22:35:18 server ntpd[20150]: synchronized to 66.187.233.4, stratum 1

    ซึ่งถ้าเราใช้คำสั่ง ntptrace ตรวจสอบดู จะเห็นว่าเครื่องของเรากลายเป็น stratum 2 แล้ว ซึ่งถือว่าเครื่องเรามีเวลาเป็นมาตรฐานแล้ว

    [root@server etc]# ntptrace
    server.spalinux.com: stratum 2, offset 0.014226, synch distance 0.225802
    clock1.redhat.com: stratum 1, offset -0.000001, synch distance 0.000330, refid 'CDMA'

    การเปิด server ตอนบู๊ตเครื่อง
    สุดท้ายอย่าลืมเปิด service ทั้งสองอัน สำหรับตอนบู๊ตเครื่องด้วย ซึ่งสามารถทำได้ตามตัวอย่าง

    ตัวอย่างการเปิด server NTP สำหรับตอนบู๊ตเครื่อง

    [root@server etc]# chkconfig ntpd on
    [root@server etc]# chkconfig ntpdate on
    [root@server etc]# ls -l /etc/rc3.d/*ntp*
    lrwxrwxrwx 1 root root 17 2008-08-31 22:07 /etc/rc3.d/S57ntpdate -> ../init.d/ntpdate
    lrwxrwxrwx 1 root root 14 2008-08-31 22:07 /etc/rc3.d/S58ntpd -> ../init.d/ntpd

    การคอนฟิก NTP สำหรับเครื่อง Client
    ส่วนการคอนฟิกในเครื่องอื่นๆ นั้น ถ้าเป็นลินุกซ์ก็แก้ไฟล์ /etc/ntp.conf ให้ชี้มาเครื่องที่เราคอนฟิกเป็น stratum 2 นี้ หรือถ้าเป็น Windows XP สามารถ double-click ที่เวลาแล้วเลือกไปที่ Internet Time คลิกเพื่อเลือก [x] Automatically synchronize with an Internet time server แล้วใส่ server ให้เป็น ip address ของเครื่อง stratum 2 สุดท้ายก็กด Update Now ถ้าถูกต้องจะมีข้อความขึ้นเป็น  The time has been successfully synchronized with 192.168.1.1 on 31/08/08 at 10:46 PM.

    ที่มา: http://spalinux.com/2008/08/configure_ntp_on_linux

« Previous Entries