Distributions
Ubuntu
Fedora
CentOS
中文资源站
网易开源镜像站
panxianhai
V2EX  ›  Linux

今天在服务器上不小心敲了一个 crontab -r,然后就悲剧了

  •  
  •   panxianhai · Dec 16, 2014 via Android · 4144 views
    This topic created in 4241 days ago, the information mentioned may be changed or developed.
    这样子的命令是不是应该设计成提示用户,这个操作会把计划任务都清掉?
    另外,敲命令的时候一定要看清楚再确认。
    12 replies    2014-12-18 12:50:16 +08:00
    Jaylee
        1
    Jaylee  
       Dec 16, 2014
    自己作死都喜欢吐槽设计不人性化
    panxianhai
        2
    panxianhai  
    OP
       Dec 16, 2014 via Android
    @Jaylee r和e相隔挺近的,现在直接alias一下,避免误操作。
    pubby
        3
    pubby  
       Dec 16, 2014
    不常用的我都会先man或者 --help一下
    pubby
        4
    pubby  
       Dec 16, 2014
    尤其在 freebsd 和 linux 间穿越的时候
    panxianhai
        5
    panxianhai  
    OP
       Dec 16, 2014 via Android
    @pubby 我是想打-e的,结果误打…穿越的时候有什么不同么?
    onlyice
        6
    onlyice  
       Dec 16, 2014
    学习了,crontab 这么坑。。
    zeeler
        7
    zeeler  
       Dec 16, 2014
    我都习惯性先-l
    irainy
        8
    irainy  
       Dec 16, 2014
    nooper
        9
    nooper  
       Dec 16, 2014 via iPhone
    还手动敲命令吗?自动化搞定
    panxianhai
        10
    panxianhai  
    OP
       Dec 16, 2014
    @irainy 装东西的话运维会对我有意见的

    @nooper 怎么个自动化?比如我想添加一个计划任务
    nooper
        11
    nooper  
       Dec 16, 2014
    likuku
        12
    likuku  
       Dec 18, 2014
    为啥 crontab 不放在 /etc/cron.d/ 里?
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   1114 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 41ms · UTC 23:19 · PVG 07:19 · LAX 16:19 · JFK 19:19
    ♥ Do have faith in what you're doing.