Menu
Menu
DaniWeb
Log In
Sign Up
Read
Contribute
Meet
Search
Search
About 415 results for
crontab
- Page 1
CRONTAB help
Programming
Software Development
15 Years Ago
by NewbieProgram
… address provided is ok too) -What was he doing The
crontab
should run every 30 mins and automatically email him all…
Re: CRONTAB help
Programming
Software Development
15 Years Ago
by NewbieProgram
I think what he means by catching him is that the
crontab
should run every 30 minutes; he'll be logging on at every 29th minute for a duration of 5-6 minutes.
Re: CRONTAB help
Programming
Software Development
15 Years Ago
by NewbieProgram
… very good. Now I have to setup the job for
crontab
to run this script every 30 minutes and email him…
Re: crontab output
Programming
Software Development
17 Years Ago
by wiz83
[QUOTE=DimaYasny;516057]after some googling, seems like perl scripts have trouble running from
crontab
. try to create a bash script which will launch the perl script, and make the bash script run from
crontab
[/QUOTE] cant i just run it through
crontab
,directly.i know it happens
crontab output
Programming
Software Development
17 Years Ago
by wiz83
… trying to do is iam running a perl script through
crontab
.the problem is iam getting an error message on my… mail. this is the
crontab
file: 24 16 22 1 * perl /rishi/s-branch/perl1…
Re: crontab output
Programming
Software Development
17 Years Ago
by DimaYasny
after some googling, seems like perl scripts have trouble running from
crontab
. try to create a bash script which will launch the perl script, and make the bash script run from
crontab
Re: crontab output
Programming
Software Development
17 Years Ago
by DimaYasny
don't think you're supposed to activate it by perl the script has the interpretor line in it change the
crontab
line to just the path to the script also, is the script working when run from the shell manually?
Re: crontab output
Programming
Software Development
17 Years Ago
by wiz83
… the script has the interpretor line in it change the
crontab
line to just the path to the script also, is…
Re: crontab output
Programming
Software Development
17 Years Ago
by eggi
chmod the script 755, and if you want to run it as perl scriptname in
crontab
, just be sure to give the absolute path to perl in your entry, like: /usr/bin/perl scriptname and it should work either way Hope that helps :) , Mike
Re: CRONTAB help
Programming
Software Development
15 Years Ago
by sknake
How does he propose that you catch him? Are you allowed to install applications on his machine, or will he be hitting a webserver and you need to grep the logs for a page he will visit?
Re: CRONTAB help
Programming
Software Development
15 Years Ago
by sknake
Sounds fun. Try something like this: [code] #!/bin/bash prof_acct_name="sk" x=`w` echo "${x}" | while read line; do if echo ${line} | egrep "^${prof_acct_name}\b.*" >> /dev/null 2>&1; then ip_addr=`echo ${line} | awk '{ print \$3 }'` process=`echo ${line} | awk '{ print \$9 }'` …
Re: CRONTAB help
Programming
Software Development
15 Years Ago
by sknake
Sounds good. Please mark this thread as solved if you have found an answer to your question and good luck!
Re: crontab - simple test script
Hardware and Software
Linux and Unix
11 Years Ago
by rch1231
… # mail any output to `paul', no matter whose
crontab
this is MAILTO=paul # # run five minutes after …sunday" The easiest way to create a
crontab
file is while logged in to a shell …the following:
crontab
-e To see your
crontab
use:
crontab
-l To remove the current
crontab
for the user:
crontab
-r …
Re: crontab - simple test script
Hardware and Software
Linux and Unix
11 Years Ago
by rubberman
Show the contents of the
crontab
itself. The script is one thing. The
crontab
is another.
Re: How do I? Edit Crontab using a Script?
Programming
Software Development
14 Years Ago
by egmik3
… -e '/Watchdog/s/^/#/' /tmp/
crontab
.a |
crontab
-e # Disable Watchdog rm /tmp/
crontab
.a [/CODE] [CODE]
crontab
-l > /tmp/
crontab
.a sed -e '/Watchdog… -e '/Watchdog/s/#//' /tmp/
crontab
.b > /tmp/
crontab
.a # Disable Watchdog
crontab
/tmp/
crontab
.a rm /tmp/
crontab
.a /tmp/
crontab
.b [/CODE] My other…
Re: How do I? Edit Crontab using a Script?
Programming
Software Development
14 Years Ago
by Aia
…
crontab
.a > /tmp/
crontab
.b sed -e '/Watchdog/s/#//' /tmp/
crontab
.b > /tmp/
crontab
.a # Disable Watchdog
crontab
/tmp/
crontab
….a rm /tmp/
crontab
.a /tmp/
crontab
.b … a file any schedule information from cron
crontab
-l > /tmp/
crontab
.a # # remove boiler plate information…
Re: How do I? Edit Crontab using a Script?
Programming
Software Development
16 Years Ago
by eggi
… both execute and feed through the pipe: [QUOTE]$
crontab
-l # DO NOT EDIT THIS FILE - edit …: Input is not from a terminal
crontab
: installing new
crontab
mgolvach@tlaum-pc1 ~ $
crontab
-l # DO NOT EDIT THIS FILE…: Input is not from a terminal
crontab
: installing new
crontab
mgolvach@tlaum-pc1 ~ $
crontab
-l # DO NOT EDIT THIS FILE…
Re: How do I? Edit Crontab using a Script?
Programming
Software Development
16 Years Ago
by egmik3
… -e 's=\(^.*/opt/watchdog/startwatchdog.sh$\)=#\1' /tmp/
crontab
.a |
crontab
rm /tmp/
crontab
.a[/code] [/QUOTE] I tried this as well. Just… error: file name must be specified for replace usage:
crontab
[-u user] file
crontab
[-u user] [ -e | -l | -r ] (default operation is…
I can't get crontab running
Hardware and Software
Linux and Unix
19 Years Ago
by Cr4nberry
… a hosting in a server and can't use the
crontab
for the hosting user. I get this error: [B]bash…:
crontab
: command not found[/B] Afortunately I can log in with … the activity log for the task I'm running in
crontab
, and It doesn't shows nothing because is not being…
Re: How do I? Edit Crontab using a Script?
Programming
Software Development
14 Years Ago
by Aia
[B]egmik3;1276213 >[/B] [CODE]
crontab
-l > /tmp/
crontab
.a sed -e '/Watchdog/s/^/#/' /tmp/
crontab
.a |
crontab
-e # Disable Watchdog rm /tmp…/
crontab
.a [/CODE] [CODE]
crontab
-l > /tmp/
crontab
.a sed -e '/Watchdog…
Re: How do I? Edit Crontab using a Script?
Programming
Software Development
16 Years Ago
by Fest3er
… commented. (no this is not all that is in my
crontab
) [CODE] */5 * * * * /opt/watchdog/startwatchdog… /tmp/
crontab
.a |
crontab
rm /tmp/
crontab
.a[/code] To uncomment the line: [code]
crontab
-l >/tmp/
crontab
.a sed… -e 's=\(^#.*/opt/watchdog/startwatchdog.sh$\)=\1' /tmp/
crontab
.a |
crontab
rm /tmp/
crontab
.…
Re: How do I? Edit Crontab using a Script?
Programming
Software Development
16 Years Ago
by egmik3
… to get rid of the "#" Here's my
crontab
: [CODE]USER=root JAVA_HOME=/usr/java/latest 59 20 * … #/5 * * * * /opt/watchdog/startupWatchdog.sh [/CODE] Heres
crontab
after "uncomment" code: [CODE]# DO NOT EDIT THIS…FILE - edit the master and reinstall. # (/tmp/
crontab
.XXXXs7xGhE installed on Wed Mar 11 20:53:46 2009…
Re: How do I? Edit Crontab using a Script?
Programming
Software Development
16 Years Ago
by Fest3er
… of code?[/B] [CODE] (echo ^[:g/watchdog/s/^/#/^[:wq!^M)|
crontab
-e[/CODE][/QUOTE] First, it assumes that the editor you… far clearer to make a temp copy of the
crontab
, then use sed |
crontab
to change the line (as illustrated in my… was[code] (echo -e ^[:g/watchdog/s/^/#/\r:wq!\r)|
crontab
-e[/code]Vim() might properly interpret the ^M, but I…
Re: How do I? Edit Crontab using a Script?
Programming
Software Development
14 Years Ago
by egmik3
Here is what I got for commenting the line: [CODE] #!/bin/bash
crontab
-l >/tmp/
crontab
.a sed '/Watchdog/s/^/#/' /tmp/
crontab
.a rm /tmp/
crontab
.txt[/CODE] Here is un-commenting it for reference to others: [CODE] #!/bin/bash
crontab
-l >/tmp/
crontab
.a sed '/Watchdog/s/#//' /tmp/
crontab
.a rm /tmp/
crontab
.txt[/CODE]
Re: How do I? Edit Crontab using a Script?
Programming
Software Development
14 Years Ago
by Tomaker
…. It is feeding vi() commands to the '
crontab
-e' command's standard input. Were you…by hand, you would:[code]shell prompt>
crontab
-e :g/watchdog/s/^/#/<ENTER>…make a temp copy of the
crontab
, then use sed |
crontab
to change the line (as …echo -e ^[:g/watchdog/s/^/#/\r:wq!\r)|
crontab
-e[/code]Vim() might properly interpret the ^M…
Re: How do I? Edit Crontab using a Script?
Programming
Software Development
14 Years Ago
by egmik3
… using sed. My problem is now inserting it into
crontab
-e. Anyone have any help? Here is my… code: [CODE]
crontab
-l > /tmp/
crontab
.a sed -e '/Watchdog/s/^/#/' /tmp/
crontab
.a |
crontab
-e # Disable Watchdog …reading input, exiting... Vim: preserving files... Vim: Finished.
crontab
: "/usr/bin/vi" exited with status 1 …
Re: I can't get crontab running
Hardware and Software
Linux and Unix
19 Years Ago
by ilaiy
Check if crond is running to make
crontab
work .. ./thanks ilaiy
Re: How do I? Edit Crontab using a Script?
Programming
Software Development
16 Years Ago
by egmik3
… NOT EDIT THIS FILE - edit the master and reinstall. # (/tmp/
crontab
.XXXXg27puR installed on Fri Jan 9 17:31:02 2009…) # (Cron version V5.0 -- $Id:
crontab
.c,v 1.12 2004/01/23 18:56:42… Vim: Error reading input, exiting... Vim: preserving files... Vim: Finished.
crontab
: "/usr/bin/vi" exited with status 1 Continuity…
Re: How do I? Edit Crontab using a Script?
Programming
Software Development
15 Years Ago
by Fest3er
…seem to work: [code] # Comment out the entry
crontab
-l | \ egrep -m 3 -v "^#…-e 's=\(^.*/opt/watchdog/startwatchdog.sh$\)=#\1=' | \
crontab
- # Uncomment the entry
crontab
-l | \ egrep -m 3 -v "^#…sed -e 's=^#\(.*/opt/watchdog/startwatchdog.sh$\)=\1=' | \
crontab
- [/code] This should make the file idempotent: there …
Re: How do I? Edit Crontab using a Script?
Programming
Software Development
16 Years Ago
by Fest3er
…quite easily. To comment out the line: [code]
crontab
-l |sed -e 's=\(^.*/opt/watchdog/startwatchdog.sh$\)=#\…1=' |
crontab
-[/code] To uncomment the line: [code]
crontab
-l | sed -e 's=^#\(.*/opt/watchdog…it comes to the first three lines of comments.
Crontab
() puts them in whether you like it or not.…
1
2
3
7
Next
Last
Search
Search
Forums
Forum Index
Hardware/Software
Recommended Topics
Programming
Recommended Topics
Digital Media
Recommended Topics
Community Center
Recommended Topics
Latest Content
Newest Topics
Latest Topics
Latest Posts
Latest Comments
Top Tags
Topics Feed
Social
Top Members
Meet People
Community Functions
DaniWeb Premium
Newsletter Archive
Markdown Syntax
Community Rules
Developer APIs
Connect API
Forum API Docs
Tools
SEO Backlink Checker
Legal
Terms of Service
Privacy Policy
FAQ
About Us
Advertise
Contact Us
© 2025 DaniWeb® LLC