I have Ubuntu 16.04. From here Run Scripts on Start UP. I followed this answer:
One approach is to add an @reboot cron task:
Running
crontab -ewill allow you to edit your cron. Adding a line like this to it:@reboot /path/to/scriptwill execute that script once your computer boots up.
I was successfully able to edit file crontab.
but I couldn't be able to save it using:
:q:wqCTRL+x
None of them worked. I got this message on command :q:
No write since Last Change (add ! to override
After executing command -
EDITOR=vi crontab -eOutput -
no crontab for admin - using an empty oneAgain on executing command -
sudo EDITOR=vi crontab -eOutput -
no crontab for root - using an empty one
:q, then:wqshould work. – muru Jun 08 '17 at 04:48:wqexit the window but it not savecronfile. – Utkarsh Dubey Jun 08 '17 at 04:59crontab -lshow after you edit and do:wq? – muru Jun 08 '17 at 05:00:q:wqCtrl+xNone of them are work.
– Utkarsh Dubey Jun 08 '17 at 05:05:q, but you said nothing of the others. Without knowing what you mean by that, sentences like that are ignored as garbage. – muru Jun 08 '17 at 05:06crontab -lproduce please put that in your OP! – George Udosen Jun 08 '17 at 05:06crontab -loutputno crontab for admin– Utkarsh Dubey Jun 08 '17 at 05:08vimornano? Ifnanosee update on my answer – George Udosen Jun 08 '17 at 05:31nanoeditor. Only havevieditor. – Utkarsh Dubey Jun 08 '17 at 05:33which nanoto see if its there. It should be. – George Udosen Jun 08 '17 at 05:34EDITOR=vi crontab -eplease simply usecrontab -eand let it use the default editor which I believe isnano– George Udosen Jun 08 '17 at 05:40which nanoOutput - Nothing get print
– Utkarsh Dubey Jun 08 '17 at 05:40