Community Forums
Connect with us on LinkedIn
+ Reply to Thread
Results 1 to 3 of 3
  1. #1
    Member shanit's Avatar
    Join Date
    Dec 2005
    Posts
    46

    Default setting a cron in ssh using root

    Hi I am attempting to put in
    crontab -e when in ssh and it tells me this

    root@server [~]# crontab -e
    /bin/sh: pico: command not found
    crontab: "pico" exited with status 127

    can someone help me fix this issue I think when i had my other server i had same problem and someone told me something to do and it fixed it. but now i have a new one and its been a while since i had to do it. Thanks

    Shannon

  2. #2
    Member
    Join Date
    Jan 2005
    Location
    Earth
    Posts
    1,050

    Default

    pico is set as a default editor on your server and it seems it is not installed. To change the default editor to 'vi', do the following :-
    ]# which vi << This will give you the path for 'vi'.
    ]# export EDITOR= path/of/vi << normally it will be /bin/vi or /usr/bin/vi.

    To check whether the default editor is changed :-
    ]# set | grep EDITOR

    Editor is now changed to 'vi'. Now you can use 'crontab -e' to edit cronjob's on server.

    OR install pico.

  3. #3
    Member nettigritty's Avatar
    Join Date
    Jan 2004
    Location
    Bangalore, India
    Posts
    196

    Default

    Quote Originally Posted by shanit
    Hi I am attempting to put in
    crontab -e when in ssh and it tells me this

    root@server [~]# crontab -e
    /bin/sh: pico: command not found
    crontab: "pico" exited with status 127

    can someone help me fix this issue I think when i had my other server i had same problem and someone told me something to do and it fixed it. but now i have a new one and its been a while since i had to do it. Thanks

    Shannon
    You might have nano instead. create a symlink from pico to nano. that should work.

Similar Threads & Tags
Similar threads

  1. Proper way to restart apache via SSH? (and therefore root cron)
    By Ishware in forum cPanel and WHM Discussions
    Replies: 7
    Last Post: 10-11-2009, 01:28 AM
  2. Cron <root@xxx> run-parts /etc/cron.hourly
    By mmarch in forum New User Questions
    Replies: 0
    Last Post: 03-31-2009, 11:45 PM
  3. Replies: 2
    Last Post: 07-04-2007, 08:12 AM
  4. Replies: 12
    Last Post: 08-16-2006, 10:56 PM
  5. Cron <root@server> root run-parts /etc/cron.hourly
    By vishal in forum cPanel and WHM Discussions
    Replies: 5
    Last Post: 11-29-2003, 08:47 AM
Linkedin       Facebook       Twitter       RSS       Flickr       YouTube