在Ubuntu上使用shell脚本附加到crontab [英] Appending to crontab with a shell script on Ubuntu

查看:542
本文介绍了在Ubuntu上使用shell脚本附加到crontab的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想在Ubuntu上的crontab中添加一行。

I'm trying to add a line to the crontab on Ubuntu.

现在,我正在做 crontab -e 并编辑crontab那里。

Right now, I'm doing crontab -e and editing the crontab there.

但是,我似乎找不到真正的crontab文件,因为 crontab 似乎给您一个临时工作副本。

However, I can't seem to find the real crontab file, since crontab -e seems to give you a temporary working copy.

/ etc / crontab 系统crontab。

/etc/crontab looks like the system crontab.

crontab的路径是 crontab -e 保存到?

What is the path of the crontab that crontab -e saves to?

谢谢!

推荐答案

使用 crontab -l&文件将当前用户的crontab列表到文件 crontab文件 crontab。

Use crontab -l > file to list current user's crontab to the file, and crontab file, to install new crontab.

这篇关于在Ubuntu上使用shell脚本附加到crontab的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆