You Asked: How Do I Edit a Crontab File in Linux?
Contents How Do You Edit and Save Crontab File in Linux? It Can Be a Little Confusing and Scary the First Time You Use It, So Here’s What to Do: Press Esc...
Contents
How do you edit and save crontab file in Linux?
It can be a little confusing and scary the first time you use it, so here’s what to do:
- press esc.
- press i (for “insert”) to begin editing the file.
- paste the cron command in the file.
- press esc again to exit editing mode.
- type :wq to save ( w – write) and exit ( q – quit) the file.
Where can I edit crontab?
Note: The crontab file is located in the /var/spool/cron directory. The vi editor will open by default when calling crontab -e. Note: To edit the crontab file using Nano editor, you can optionally enter the EDITOR=nano crontab -e command.