Software :: Cronjob And Feh / When Its Run Via Cron It Fails?

Aug 21, 2010

I wrote a small bash script to use feh to change my background every time its called. I use a cron job to have it execute every 5 minutes.

When I run the script manually it works perfectly, however for some reason when its run via cron it fails. I can see that it is executing but it seems to error for some reason.

Its kind of a drag to have a working script that when run as a cron job suddenly no longer works.

View 7 Replies


ADVERTISEMENT

Ubuntu :: Unison Run From Cron Fails

Aug 26, 2010

I have unison set up (using the .unison/default.prf config file) to sync certain directories on my work computer with my home computer.

View 2 Replies View Related

General :: Cron Backup Job Fails To Run?

Jan 5, 2011

I'm having a small issue where the backup jobs that I set to run in the crontab of the backup user do not appear to be running. Here's how I set it up (with crontab -e as the backup user):

run amanda every night (check at 2:45 and backup at 3)

[code]...

View 5 Replies View Related

Ubuntu :: Script Fails In Cron But Runs Fine In Regular Shell?

Jul 11, 2011

I have an Ubuntu server running Couch Potato, Sick Beard and Sabnzbdplus. Everything "works" pretty well in a sense that CP and SB push the NZB's to Sabnzbdplus, but Sab crashes regularly (haven't found the solution or the cause for this problem, so if you have some advice regarding that, it's welcome).To counter this problem (Sab crashing) I have a script written which checks if Sab is runnning and if it isn't start it:

Code:
bart@Pyro:~$ cat CheckSabRunning.sh
#!/bin/sh

[code]....

View 9 Replies View Related

Server :: Rsync Fails In Cron - Ssh Key - For Rsync?

Dec 8, 2010

I'm using Ubuntu 10.04 LTS server and Postgresql 8.4. I have a .sh script that is run by cron every other hour. That works fine. The .sh script includes an rsync command that copies a postgresql dump .tar file to a remote archive location via ssh. That fails when run by cron; I think because it is (quietly) asking for the remote user's password (and not getting it). I set up the public/private ssh key arrangement. The script succeeds when run manually as the same user that the cron job uses, and does not ask for the password. I am able to ssh to the remote server from the source server (using the same username) and not get the password prompt (both directions), so why doesn't rsync work? I even put a .pgpass file in the root of that user's directory with that user's password, and the user/password are identical on both servers.

I think the problem is rsync is not able to use the ssh key correctly. I tried adding this to my script but it didn't help.

Code:

Here is the rsync command embedding in the .sh script.

Code:

Here is the cron entry:

Code:

View 6 Replies View Related

Ubuntu Servers :: Cron Sending Email From Address / Change The Default Domain Name For Cron?

Apr 29, 2011

Can anyone tell me how i change the default domain name for cron?everything i cron runs it emails from and to user@com.com

this leaves me with a massive list of failed mails in postfix.i have mailto on my main crontab but i cant do it on all of them.

View 1 Replies View Related

Fedora :: No Output From Cron Jobs In /etc/cron.daily

Jan 29, 2011

I have added some executable scripts to /etc/cron.daily but don't get the stdout/stderr output from them as mail (or anywhere else I have found). At least one of them is running (because I can see that it has added a file to the disk).

The peculiar thing is that I do get the output from /etc/cron.daily/0logwatch (part of the logwatch package) as an email each day.

The MAILTO line in /etc/crontab is "MAILTO=root" (unchanged from default). Same for /etc/anacrontab.

I do have an alias at the end of /etc/aliases which redirects root's mail to my own account, but this alias works fine for mail I send manually. (It also appears to work fine for the output from the file /etc/cron.daily/0logwatch.)

View 3 Replies View Related

Ubuntu Installation :: Cron's /etc/cron.daily/apt Not Upgrading?

Feb 25, 2010

It seems that cron is not upgrading my Ubuntu 8.04 LTS Server, no GUI installed. I changed /etc/crontab and watched apt running:

Code:

ps -A | grep apt

showed it for a long time,

Code:

sudo tcpdump tcp

showed communication with canonical sites,

but:

Code:

top

did not show any apt using CPU

[code].....

View 2 Replies View Related

Ubuntu :: Do Cron Updates Erase Cron Entries

Sep 19, 2010

I put in my cron entries to run my backup script which rsyncs my data to my 2nd drive, however on a hunch I checked my backup drive which mounts automatically via fstab and I realize it had not ran in a while. I checked cron and there were no entries for it. I got to wondering if I should ever be worried about a cron update coming down and over-writing my existing cron file with the backup entries in it to run.

View 2 Replies View Related

CentOS 5 :: Setup A Cron In /var/spool/cron/root

Feb 16, 2010

I have set up a cron in /var/spool/cron/root

*/15 * * * * /usr/bin/phplist.sh

I can see in /var/log/cron that it is running every 15 minutes but it has no effect. It is not doing the commands in the bash script.

If I run /usr/bin/phplist.sh right in the shell it works great.

View 3 Replies View Related

Software :: Vixie-Cron Not Running /etc/cron.d/

Feb 9, 2011

Is my vixie-cron broken? i have "0-59 * * * * root /usr/sbin/logrotate /etc/logrotate.conf" but it is not running in /etc/cron.d.

Code:

View 2 Replies View Related

General :: How To Set Cronjob In /etc/crontab

Apr 10, 2011

I know crontab -e sets a cronjob in /var/spool/cron but how do I set a cronjob to run from /etc/crontab? Is there a command used for this or would I have to manually edit a certain file?

View 2 Replies View Related

Server :: Run Cronjob Once Every Three Months?

Apr 30, 2010

I am trying to run the following only once every three months but looks like it runs every day. I edited crontab -e and added the following:

Code:

0 23 * jul,oct,jan,apr * /path/to/script > /var/log/script.log 2>&1

View 2 Replies View Related

Ubuntu :: Cronjob Stops After Several Seconds?

Sep 13, 2010

I want to use a cronjob to start a script running streamripper to record radioshows when I'm not at home. I'm running 10.04 server 32 bit.

I've setup a cronjob via Webmin to start the recording. It runs the following script:

Code:
ORDNER=`date +%Y"_"%m"_"%d"-"%H"_"%M"(FM4)"` # 'ORDNER' means Folder and creates a folder with time/date to save the stream
streamripper http://mp3stream1.apasf.apa.at:8000/ -d /mnt/Samsung/Radio/$ORDNER --xs_padding=2000:500 -a -q -s

[Code]....

Is there any logfile or way to see why the script is killed or what stops the recording? When executing the script manually the recording runs just fine until I kill the process.

View 2 Replies View Related

Ubuntu :: Send A Libnotify From A Cronjob?

Feb 24, 2011

Is it possible to send a libnotify from a cronjob? I'd like a notify message when my daily backup is done. When I run my script from terminal everything is working fine, when (ana)cron runs it, it works as well but the notify is surpressed. My Guess was, that it happens because the jobs are run as root. Nevertheless is it possible to get a notification message?

View 4 Replies View Related

Ubuntu :: Cronjob Not Starting Backupscript?

Apr 18, 2011

I wrote a little backupscript wich is working fine if i start it from the shell manualy. But I'm not able to let it start automaticaly via cron in ubuntu 10.10.

Here the bashscript:

#!/bin/sh
####################################
#
#
#
####################################

[Code]......

View 1 Replies View Related

Ubuntu :: Changing Fb Background Cronjob?

Jun 6, 2011

I'm trying to change my desktop background on my fluxbox desktop every minute using cronjob to a random picture within my Pictures folderthis is crontab -e file;

Code:
# Edit this file to introduce tasks to be run by cron.
#

[code]....

View 2 Replies View Related

General :: Cronjob / Run The Files Everyday At 11.00 Pm?

Apr 23, 2010

I need to run the files everyday at 11.00 pm (Monday to Friday).

How would I put on cronjob? I have files ready.

View 5 Replies View Related

General :: Configure Cronjob To Run Every 45 Days

Nov 19, 2010

we have requirement like we need to run the sql script, which needs to be executed for every 45 days.

View 1 Replies View Related

General :: Pop Up Message From Cronjob Run Script?

Dec 22, 2010

I'm working on a bash script that will be run regularly via a cronjob. As there is no easy way for the user to see if it's running in the background, I'd like a have some kind of pop up window what say's something like "Process started" and "Process finished" when it's complete. Ive read though some similar threads and came across xmessage. It kind of does what I want, with the exception of:-Id like the message Process started to stay up for the whole process, but it looks like the script wont continue until the xmessage window is closed. I cant get any xmessages to appear when the script is run from a cronjob. It only appears if I run the script manually from a terminal window. Which is no good for me. If anyone has any suggestions that would be great and just to add, it's doesn't have to be xmessage, any text box would do. I'm working with Redhat 4 and 5, if that makes a difference. Chuck Norris destroyed the periodic table, because he only recognises the element of surprise.

View 2 Replies View Related

General :: Return Value Of Tftp Is Always Zero In Cronjob?

May 15, 2010

I have called an script in cronjob named get_mac.sh as follows:

#!/bin/sh
MAC=`ifconfig eth0 |sed -n 1p|awk '{print $5}'|awk -F : '{print $1$2$3$4$5$6}'`
ARG_FILE="/etc/asterisk/scripts/server.params"

[code]....

View 1 Replies View Related

Server :: Way To Setup Cronjob For Configuration?

May 27, 2010

I'm trying to setup a cronjob that needs to run every 40 minutes between 10am and 3.30pm.I generally used cronjob for simple configuration, but now I'm a bit lost.There is a way to setup cronjob for that configuration? (better if all in one line of code, not multilines).

View 4 Replies View Related

Server :: Email Myself Output Of Cronjob?

May 10, 2010

I have the following Cron job scheduled on my Postfix mail server: Code: 00 18 * * * /usr/bin/clamscan -r --remove /home/.This is just running a scan on my entire /home/ directory and removing any infected files it finds. My question is since this is being ran at 6pm via Cron, how can I get the results of this job emailed to me via text? Does anyone recommend a command I can add to the end which will dump the results into a file or email and send it to a specific email address? This server is my company Postfix MTA for everyone.

View 14 Replies View Related

Software :: Not Able To Open Web Browser With Cronjob

Jan 4, 2010

I have to run one testcase which opens a web_browser on Linux machine. When a run with cygwin it works but I can't always keep it open. I want to schedule a cronjob to run this testcase.

View 1 Replies View Related

Debian Multimedia :: Cronjob No Longer Running

Aug 4, 2015

I am running Debian 8 with the Xfce Desktop Environment.

A few weeks ago I created a cronjob which randomly changed my desktop wallpaper every two minutes. Here is that cronjob:

Code: Select all*/2 * * * * DISPLAY=:0 /home/alessandro/bin/random_wallpaper

Today, however, this cronjob stopped working. (The random_wallpaper script still works as intended.) The only changes I made to my system were

1) I modified my compton configuration settings; and
2) I installed a new display manager, SLiM.

I'm not sure why any of these changes would prevent my cronjob from running though.

View 0 Replies View Related

Ubuntu :: Cronjob Results Filling Up / Directory?

Feb 22, 2011

Some of my cronjobs are filling up files in my / directory. How do I make this stop? One of my cron jobs uses wget:[URL].. The bexcb0.php file writes a file and then echos a result if it is sucsesfull. These echo results are being put into bexcb0.php files in my /root folder and are piling up.

My / folder is filling up with files bexcb0.php etc bexcb0.php bexcb0.php.1 bexcb0.php.2 bexcb0.php.3 bexcb0.php.4 bexcb0.php.5 etc How do I make this stop? If I just remove the echo will they stop writing to the / folder?

View 1 Replies View Related

Ubuntu :: Root Cronjob Not Working On Schedule

Jun 27, 2011

I have added "@daily shutdown -r now" to my root crontab (sudo crontab -e) but it does not seem to ever run. When I look at the chron log using webmin I can see that it tried to run and there was no error. Also when I run it manually using webmin the system reboots fine. I also tried using reboot -f in the crontab instead and that also worked when manually run but not on schedule. The reason I know it didn't run is on webmin it shows the system uptime. This is the output of the chron log:

Code:
Jun 26 21:17:02 GrantLaptop CRON[3467]: (root) CMD (cd / && run-parts --report /etc/cron.hourly)
Jun 26 22:17:01 GrantLaptop CRON[3873]: (root) CMD (cd / && run-parts --report /etc/cron.hourly)
Jun 26 23:17:01 GrantLaptop CRON[4269]: (root) CMD (cd / && run-parts --report /etc/cron.hourly)
Jun 27 00:00:01 GrantLaptop CRON[4530]: (root) CMD (shutdown -r now)
Jun 27 00:17:01 GrantLaptop CRON[4630]: (root) CMD (cd / && run-parts --report /etc/cron.hourly)
Jun 27 01:17:01 GrantLaptop CRON[5005]: (root) CMD (cd / && run-parts --report /etc/cron.hourly)
Jun 27 02:17:01 GrantLaptop CRON[5416]: (root) CMD (cd / && run-parts --report /etc/cron.hourly)

View 5 Replies View Related

General :: Change Rsyn Cronjob Via PHP Script ?

Apr 13, 2010

Currently we have to comment out an rsync task every now and then. Is there a way to have a PHP script on the server so we can simply browse to it to uncomment the rsync task and another one to comment it out again ?

The rsync job is the only job in crontab so even if it means deleting / re-creating the job wouldn't be a problem. I just want to avoid connecting via SSH and VPN every time I am asked to disable it

View 1 Replies View Related

General :: Cronjob / Execute At 4:30 Pm On 2nd Monday Of Each Month?

May 10, 2010

Cron setup for execute at 4:30 pm on 2nd monday of each month.

50 16 8-14 * mon /home/user/script.sh

It seems to be ignoring the date range 8-14?

View 1 Replies View Related

General :: Receive Emails About A Cronjob Execution?

Jun 15, 2011

how I can receive emails about a cronjob execution or where to go to read about that? I am using CentOS 5.4.

View 2 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved