1. 程式人生 > >linux中的at命令,啟動atd服務

linux中的at命令,啟動atd服務

查看了多個資料,並沒有在 /etc/init.d/ 這個目錄下發現 atd 檔案,所以命令

[root@localhost ~]# /etc/init.d/atd status
 /etc/init.d/atd start 

並不起作用。
使用命令:

[root@localhost ~]# systemctl start atd
[root@localhost ~]# ps -ef |grep atd
root      4717     1  0 14:36 ?        00:00:00 /usr/sbin/atd -f
root      4733  4429  0 14:36 pts/1    00:00:00
grep --color=auto atd

這樣就可以看到atd的程序了,然後重新啟動任務

[[email protected] ~]# at 14:40
at> date > /root/datetest.log
at> <EOT>
job 6 at Wed Feb  8 14:40:00 2017

搞定!