Unix: Not able to edit crontab file

You try to edit the crontab file using “crontab -e” and you see something like this:

# sudo crontab -e
I can’t tell you how many times I’ve forgotten the resolution. Here it is:

By default you are using the “ed” editor. You need an environment variable to change to vi or the editor of your choice. The following entry works for me. (using bash shell)


If that doesn’t work then do this:

EDITOR=vi; export EDITOR

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s