indypan wrote:
我後來是乾脆在開機完成後,再把 /tmp/www 資料夾給覆寫掉,這樣就可以了,
不過您的方法更棒,直接 mount 就行,對 unix 指令不熟,再研究看看 ...
...(恕刪)
我的 web 相關程式是放置在 /mnt/hda/usr/DIY/var/www
所以我下的指令是 mount -o -bind /mnt/hda/usr/DIY/var/www /var/www
您若要在外網控制家中機上盒, 建議要設密碼喔!
Yuan0825 wrote:
請問你在多久以前抓的img?...(恕刪)^
jocoliu wrote:
我的 cron 是在 /opt/sbin/cron...(恕刪)
#ps
.
322 root 6092 S DvdPlayer
325 root 6092 S DvdPlayer
392 root 1940 S N smbd -D
406 root SW [kjournald]
407 root 1932 S N smbd -D
421 root 368 S /opt/sbin/cron
426 root 440 S ./bftpd -d -c /opt/etc/bftpd.conf
889 root 308 S telnetd
890 root 536 S -sh
913 root 360 R ps
/opt/etc # crontab -e
-sh: crontab: not found
/opt/etc # more crontab
SHELL=/bin/sh
PATH=/sbin:/bin:/usr/sbin:/usr/bin:/opt/sbin:/opt/bin:/opt/etc
MAILTO=""
HOME=/
# ---------- ---------- Default is Empty ---------- ---------- #
*/1 * * * * root echo hello
/opt/etc #
indypan wrote:
/opt/etc # crontab -e
-sh: crontab: not found
...(恕刪)
indypan wrote:
所以我參考了鳥哥的網站,直接編輯 crontab...(恕刪)
/ # cat /opt/etc/crontab
SHELL=/bin/sh
PATH=/sbin:/bin:/usr/sbin:/usr/bin:/opt/sbin:/opt/bin
MAILTO=""
HOME=/
# ---------- ---------- Default is Empty ---------- ---------- #
*/35 * * * * root /mnt/hdb/connection_check.sh
Yuan0825 wrote:
建議你把要執行的指令用script包起來,還有時間中間的間隔要用Tab來跳空(恕刪)
Yuan0825 wrote:
還有,"echo hello"因為cron執行時,不知道console是誰吧?
建議"echo hello >> test.log"
然後去看看test.log有沒有東西多出來.(恕刪)