FutureQuest, Inc. FutureQuest, Inc. FutureQuest, Inc.

FutureQuest, Inc.
Go Back   FutureQuest Community > General Site Owner Support (All may read/respond) > General Coding/Development
User Name
Password  Lost PW

Reply
 
Thread Tools Search this Thread Display Modes
Old 04-14-2003, 02:05 PM   Postid: 85822
Evoir
Registered User
 
Evoir's Avatar

Forum Notability:
574 pts: Most Valuable Insight
[Post Feedback]
 
Join Date: Apr 2000
Location: San Francisco, CA
Posts: 1,935
crontab -e help

Howdie,

I am trying to edit my crontab file (Is that the right lingo?) and I have logged in using MacSSH and typed crontab -e

It gives me two lines of code, that I can use the delete button to edit. But, how do I save my changes? I tried using the esc button, but nothing happened. The Tutorial is very helpful, but I can't find info on how to save my changes. It is all bring back memories of Pine and IRC. whoa.

In the past, I have simply erased the cronjob and restarted, but I don't want to do that this time. I want to learn how do do it.

Anyway, any help would be greatly appreciated.

Thanks!
Evie
Evoir is offline   Reply With Quote
Old 04-14-2003, 03:35 PM   Postid: 85829
hobbes
Have you hugged a tiger today?
 
hobbes's Avatar

Forum Notability:
1238 pts: A True Crowd-pleaser!
[Post Feedback]
 
Join Date: Mar 2000
Location: Third Sol Planet Posts: Far too many. Oh ok -
Posts: 2,705
crontab uses the default editor, likely vi (aka vim). From the command line issue "man vi" or "info vi" to learn how to use it. Short answer to save (write) the file and quit the editor, after you hit ESC to stop editing, type in :wq[ENTER] (colon-w-q-ENTER). Yes, there are other ways of doing this, but for a newbie the long winded way is sometimes best:)
hobbes is offline   Reply With Quote
Old 04-14-2003, 04:35 PM   Postid: 85834
lepton
Site Owner
 
lepton's Avatar

Forum Notability:
10 pts: User-friendly
[Post Feedback]
 
Join Date: Jan 2002
Posts: 149
While not an option in this case (crontab picks the editor), I'd like to stick in a plug for Midnight Commander.

If you're still new to using shell sessions (like I am), you'll love it!
__________________
Learn more about the standard model.
lepton is offline   Reply With Quote
Old 04-14-2003, 04:39 PM   Postid: 85835
 Terra
CTO FutureQuest, Inc.
 
Terra's Avatar
 
Join Date: Jun 1998
Location: Z'ha'dum
Posts: 7,678
If you want crontab to use mcedit, then this is simple...

While at the command line, type in:
$ export EDITOR=/usr/bin/mcedit

then run 'crontab -e', it will pull up as desired now...

--
Terra
--for extra credit, make this change permanent via .bashrc--
FutureQuest
Terra is offline   Reply With Quote
Old 04-14-2003, 06:13 PM   Postid: 85854
Rich
Merchant Rep
 
Rich's Avatar

Forum Notability:
153 pts: Ambassador of Goodwill
[Post Feedback]
 
Join Date: Nov 1998
Location: Indiana, USA
Posts: 1,658
-OR-

(1) FTP Download

(2) Edit

(3) FTP Upload

__________________
Rich
E-Commerce Solutions:
www.rsmarketing.com
Domain Name Registrations:
www.domain-registration-zone.com
Time Zone Converter:
www.timezoneconverter.com
Rich is offline   Reply With Quote
Old 04-14-2003, 06:26 PM   Postid: 85857
hobbes
Have you hugged a tiger today?
 
hobbes's Avatar

Forum Notability:
1238 pts: A True Crowd-pleaser!
[Post Feedback]
 
Join Date: Mar 2000
Location: Third Sol Planet Posts: Far too many. Oh ok -
Posts: 2,705
Or better yet ...

(1) SCP remote local

(2) Edit (using vi, of course)

(3) SCP local remote

hobbes is offline   Reply With Quote
Old 04-16-2003, 06:06 PM   Postid: 86016
Evoir
Registered User
 
Evoir's Avatar

Forum Notability:
574 pts: Most Valuable Insight
[Post Feedback]
 
Join Date: Apr 2000
Location: San Francisco, CA
Posts: 1,935
Hey, finally got around to editing the cron file. Thanks, it worked. I also liked seeing all these other options.
Quote:
Originally posted by Rich:
-OR-

(1) FTP Download

(2) Edit

(3) FTP Upload

Rich, how does this work? What file do you download and then upload?
Evoir is offline   Reply With Quote
Old 04-16-2003, 07:49 PM   Postid: 86027
Rich
Merchant Rep
 
Rich's Avatar

Forum Notability:
153 pts: Ambassador of Goodwill
[Post Feedback]
 
Join Date: Nov 1998
Location: Indiana, USA
Posts: 1,658
Quote:
Rich, how does this work? What file do you download and then upload?
Well, the short answer is: you download the file that contains your crontab commands. Where is this file? Where ever you put it...

Remember, that to start your crontab file you had to use:

crontab filename

where filename could be a fully qualified path to the crontab definition file. I usually just keep mine in the home directory with the name crontab.txt.
__________________
Rich
E-Commerce Solutions:
www.rsmarketing.com
Domain Name Registrations:
www.domain-registration-zone.com
Time Zone Converter:
www.timezoneconverter.com
Rich is offline   Reply With Quote
Old 04-17-2003, 09:36 AM   Postid: 86060
hobbes
Have you hugged a tiger today?
 
hobbes's Avatar

Forum Notability:
1238 pts: A True Crowd-pleaser!
[Post Feedback]
 
Join Date: Mar 2000
Location: Third Sol Planet Posts: Far too many. Oh ok -
Posts: 2,705
The default cron file on FQ's servers may be unreadable to users.
hobbes is offline   Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 visitors)
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -4. The time now is 02:31 AM.


Running on vBulletin®
Copyright © 2000 - 2013, Jelsoft Enterprises Ltd.
Hosted & Administrated by FutureQuest, Inc.
Images & content copyright © 1998-2013 FutureQuest, Inc.
FutureQuest, Inc.