[root@localhost ~]# crontab -l
0 */2 * * * sh /home/data-integration/run_logintop.sh
0 */2 * * * sh /home/data-integration/run_stationtj.sh
[root@localhost ~]# cat /home/data-integration/run_logintop.sh
#!/bin/bash
cd /home/data-integration
nohup /home/data-integration/pan.sh -file=/home/data-integration/logintop10.ktr &
[root@localhost ~]# cat /home/data-integration/run_stationtj.sh
#!/bin/bash
cd /home/data-integration
nohup /home/data-integration/pan.sh -file=station_tj01.ktr &
最后日志查看
[root@localhost ~]# tail -fn1000 /var/spool/mail/root |grep login
Subject: Cron <root@localhost> sh /home/data-integration/run_logintop.sh
2024/01/29 06:00:10 - logintop10 - 为了转换解除补丁开始 [logintop10]
2024/01/29 06:00:10 - logintop10 -
2024/01/29 06:00:10 - logintop10 - 进程 表输入.0 成功结束, 处理了 10 行. ( 10 行/秒)
2024/01/29 06:00:10 - logintop10 - 进程 执行SQL脚本.0 成功结束, 处理了 10 行. ( 10 行/秒)
2024/01/29 06:00:10 - logintop10 - 进程 表输出.0 成功结束, 处理了 10 行. ( 10 行/秒)
Subject: Cron <root@localhost> sh /home/data-integration/run_logintop.sh
2024/01/29 08:00:09 - logintop10 - 为了转换解除补丁开始 [logintop10]
2024/01/29 08:00:09 - logintop10 -
2024/01/29 08:00:09 - logintop10 - 进程 表输入.0 成功结束, 处理了 10 行. ( 10 行/秒)
2024/01/29 08:00:09 - logintop10 - 进程 执行SQL脚本.0 成功结束, 处理了 10 行. ( 10 行/秒)
2024/01/29 08:00:09 - logintop10 - 进程 表输出.0 成功结束, 处理了 10 行. ( 10 行/秒)
Subject: Cron <root@localhost> sh /home/data-integration/run_logintop.sh
2024/01/29 10:00:09 - logintop10 - 为了转换解除补丁开始 [logintop10]
2024/01/29 10:00:10 - logintop10 -
2024/01/29 10:00:10 - logintop10 - 进程 表输入.0 成功结束, 处理了 10 行. ( 10 行/秒)
2024/01/29 10:00:10 - logintop10 - 进程 执行SQL脚本.0 成功结束, 处理了 10 行. ( 10 行/秒)
2024/01/29 10:00:10 - logintop10 - 进程 表输出.0 成功结束, 处理了 10 行. ( 10 行/秒)
标签:10,00,01,logintop10,home,29,linux,小时,定时 From: https://www.cnblogs.com/vzhangxk/p/17993934