易截截图软件、单文件、免安装、纯绿色、仅160KB

linux time synchronization (linux 时间同步设置)

1.check ntp is installed or not
[root@myvm1 server-tar]# whereis npt
npt:
#:(..not install
2.get ntp from official website(http://psp2.ntp.org/bin/view/Main/SoftwareDownloads) and install.
[root@myvm1 server-tar]# wget http://archive.ntp.org/ntp4/ntp-4.2/ntp-4.2.6.tar.gz
[root@myvm1 server-tar]#cp ntp-4.2.6.tar.gz ../
[root@myvm1 server-tar]#cd ..
[root@myvm1 server-tar]#tar -zxvf ntp-4.2.6.tar.gz
[root@myvm1 server-tar]#cd ntp-4.2.6
[root@myvm1 ntp-4.2.6]# vim README
[root@myvm1 ntp-4.2.6]# vim INSTALL
[root@myvm1 ntp-4.2.6]# ./configure --help
######################
By default, `make install' will install all the files in
`/usr/local/bin', `/usr/local/lib' etc.  You can specify
an installation prefix other than `/usr/local' using `--prefix',
for instance `--prefix=$HOME'.
######################
i will install it in the path "/usr/local/ntp"
[root@myvm1 ntp-4.2.6]# mkdir /usr/local/ntp
[root@myvm1 ntp-4.2.6]# ./configure --prefix=/usr/local/ntp
[root@myvm1 ntp-4.2.6]# make
[root@myvm1 ntp-4.2.6]# make install
[root@myvm1 ntp-4.2.6]# whereis ntp
ntp: /usr/local/ntp
#synchronization time from time server(time.nist.gov).
[root@myvm1 ntp-4.2.6]# date
Tue Feb  2 18:59:22 CST 2010
[root@myvm1 ntp-4.2.6]# /usr/local/ntp/bin/ntpdate time.nist.gov
[root@myvm1 ntp-4.2.6]# hwclock -w
#write time into bios
[root@myvm1 ntp-4.2.6]# date             
Sat Feb 20 10:29:59 CST 2010
#successful!
#you must create crontab list to make sure synchronize time.
#########
#Update Time Everyday
0 0 * * * /usr/local/ntp/bin/ntpdate time.nist.gov > /dev/null 2>&1


相关文档:

linux下配置静态路由

Internet------(eth1)router1(eth2)------(eth1)router2(eth0)------(eth0)router3(eth1)------(eth0)pc
上面就是我的网络拓扑结构,其中路由器1是用来连接外部网络的一台linux机器,图中所有路由器都是普通的pc机,这些pc都安装了ubuntu桌面系统,除了最右边的pc,其余的pc都装了3张网卡(其中一张备用)。
由于Debian系 ......

Linux下常用的关机实例

Linux下关机最要有以下方法,我想这些方法足以满足你的需要:
[root@localhost /]# shutdown [-t秒] [-arkhcncfF] [时间] [提示信息]
[root@localhost /]# shutdown -h 10 'I will shutdown after 10 mins'
-t sec : -t 后加秒数,即‘过几秒钟后关机’的意思。
-k : 不要真的关机,只是发送提示信息。
......

Linux 驱动 hello

#include <linux/module.h>
MODULE_LICENSE("GPL");
static void hello_init(void);
static void hello_exit(void);
static void hello_init(void)
{
     printk("init");
}
static void hello_exit(void)
{
    printk("exit");
}
.
module_init(hello_init);
m ......

编译 linux 2.6.18出错解决方法

HOSTCC scripts/mod/sumversion.o
scripts/mod/sumversion.c: In function ‘get_src_version’:
scripts/mod/sumversion.c:384: error: ‘PATH_MAX’ undeclared (first use in
this function)
scripts/mod/sumversion.c:384: error: (Each undeclared identifier is reported
only once
script ......

我的Linux安装之路

         明天就回家了。今晚去火车站买了明早的车票,感觉蛮匆忙的。这两天,除了整电脑,啥事都没干。我那可怜的电脑,隔三差五的就被我整一次。开始只是应用软件层面上的,接着是系统,再接着就是接近硬件。
        花了这么多时间 ......
© 2009 ej38.com All Rights Reserved. 关于E健网联系我们 | 站点地图 | 赣ICP备09004571号