500.thttpd-rotate

来自「MiniWeb 在嵌入式平台上运行的WEB源代码」· THTTPD-ROTATE 代码 · 共 19 行

THTTPD-ROTATE
19
字号
#!/bin/sh## thttpd-rotate - nightly script to rotate thttpd's log files on FreeBSD 3.x## This goes in /etc/periodic/daily.  It rotates the log files and then# tells thttpd to shutdown cleanly.  The wrapper script will then start# up a new copy, writing to the new log file.cd /usr/local/www/logsrm -f thttpd_log.7mv thttpd_log.6 thttpd_log.7mv thttpd_log.5 thttpd_log.6mv thttpd_log.4 thttpd_log.5mv thttpd_log.3 thttpd_log.4mv thttpd_log.2 thttpd_log.3mv thttpd_log.1 thttpd_log.2mv thttpd_log thttpd_log.1kill -USR1 `cat /var/run/thttpd.pid`

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?