小编spo*_*rty的帖子

作为 root,我如何在其他用户的 crontab 中创建一个条目

我正在尝试在 shell 脚本中使用以下命令.. 任何建议以正确的方式执行此操作?

[root@testserver ~]# crontab -u oracle -e >> 0 0 * * * /usr/local/scrips/setup.sh
crontab: usage error: no arguments permitted after this option
Usage:
 crontab [options] file
 crontab [options]
 crontab -n [hostname]

Options:
 -u <user>  define user
 -e         edit user's crontab
 -l         list user's crontab
 -r         delete user's crontab
 -i         prompt before deleting
 -n <host>  set host in cluster to run users' crontabs
 -c         get host in cluster to run users' crontabs
 -s         selinux context
 -x <mask> …
Run Code Online (Sandbox Code Playgroud)

shell bash cron

3
推荐指数
1
解决办法
149
查看次数

标签 统计

bash ×1

cron ×1

shell ×1