User`s manual
ThinkCore IA241/240 Linux User’s Manual Managing Embedded Linux
3-8
KxxRUNFILE stands for
K: start the run file while linux shuts down or halts.
xx: a number between 00-99. Smaller numbers have a higher priority.
RUNFILE: the file name.
To remove the daemon, remove the run file from the
/etc/rc.d/rc3.d
directory by using the
following command:
#rm –f /etc/rc.d/rc3.d/S60tcps2
Adjusting the System Time
Setting the Time Manually
The IA241/240 has two time settings. One is the system time, and the other is the RTC (Real Time
Clock) time kept by the IA241/240’s hardware. Use the
#date
command to query the current
system time or set a new system time. Use
#hwclock
to query the current RTC time or set a new
RTC time.
Use the following command to query the system time:
#date
Use the following command to query the RTC time:
#hwclock
Use the following command to set the system time:
#date MMDDhhmmYYYY
MM = Month
DD = Date
hhmm = hour and minute
YYYY = Year
Use the following command to set the RTC time:
#hwclock –w
Write current system time to RTC
The following figure illustrates how to update thesystem time and set the RTC time.
192.168.3.127 – PuTTY
root@Moxa:~# date
Fri Jun 23 23:30:31 CST 2000
root@Moxa:~# hwclock
Fri Jun 23 23:30:35 2000 -0.557748 seconds
root@Moxa:~# date 120910002004
Thu Dec 9 10:00:00 CST 2004
root@Moxa:~# hwclock –w
root@Moxa:~# date ; hwclock
Thu Dec 9 10:01:07 CST 2004
Thu Dec 9 10:01:08 2004 -0.933547 seconds
root@Moxa:~#
NTP Client
The IA241/240 has a built-in NTP (Network Time Protocol) client that is used to initialize a time
request to a remote NTP server. Use
#ntpdate <this client utility>
to update the system time.
#ntpdate time.stdtime.gov.tw
#hwclock –w