Questions tagged [anacron]
Anacron can be used to execute commands periodically, with a frequency specified in days.
72
questions
0
votes
1
answer
130
views
Ubuntu 22.04 developed a data leak from about 19/05/23?
I am using a data limited ISP so data usage matters.
From about 19/05/23 22.04 (Jammy) seem to have started using 100M of data every (very approximate) hour.
I have rig with several flavours of Ubuntu ...
3
votes
1
answer
97
views
Difference between anacron command options - n and -f
I am currently using Ubuntu 20.04. My query is regarding the anacron command options -n and -f.
Does anacron -n command run all the jobs (daily, weekly and monthly) scheduled in anacron or it only ...
1
vote
1
answer
60
views
System hang-up while installing LTS 20.04 64 bit via USB-Flash over Win10 on HP-ENVY desktop
System hangs-up while installing LTS 20.04 64bit via USB-Flash over Win10 on HP-ENVY desktop. (Minimum install)
Been running for over 12 hours, stuck on the following...
Creating ext4 file system for /...
1
vote
0
answers
206
views
/etc/systemd/system/anacron.service.d missing
I'm using Lubuntu LTS 20.04.3 and I'm an unexperienced user. I'm trying to set my anacron service running on battery, since by default it only runs when on AC power. I'm running on systemd and I ...
1
vote
1
answer
491
views
How to schedule task on Linux Desktop
How to schedule task on Ubuntu Mate 20.04 Desktop, to run bash script.sh once a day on Tu/We/Thu/Fri/Sat, after laptop startup?
Note:
I can run job once a day by Anacron on laptop starup:
/etc/...
2
votes
0
answers
1k
views
How can I stop anacron.timer?
I stopped temporarily crons with
sudo service cron stop
sudo service anacron stop
I got message
Warning: Stopping anacron.service, but it can still be activated by:
anacron.timer
sudo service ...
0
votes
0
answers
1k
views
Understanding when anacron runs scripts at `/etc/cron.monthly`
I'm trying to understand how cron, anacron and systemd play together and in particular trying to understand how anacron schedule the jobs at /etc/cron.daily, /etc/cron.weekly and /etc/cron.monthly
...
0
votes
1
answer
680
views
Bash script works when called by run-parts, fails as cron job with exit code 1
The following script sits in cron.daily and succeeds when called with run-parts but exits with code 1 when called with anacron -f on Ubuntu 20.04 LTS. I have had many problems with various versions of ...
0
votes
2
answers
521
views
Scheduling boot using cron (Ubuntu Server 20.04)
I wonder if it is possible to schedule a machine to boot up at a determined time using cron. Imagine I want my server to shut down at night and boot back up in the morning. I've rad many docs and ...
0
votes
1
answer
260
views
How to display a message from anacrontab
I'm trying to display a message when the target time is reached from anacrontab and I suppose the best way is to use notification.
I've added this line to my user crontab achieve the same thing:
* * ...
0
votes
1
answer
456
views
How to use anacron with cron to perform missed tasks by cron?
My python script needs to run at 2pm every day. Another python script must run at 9pm every day. To accomplish that I have set up 2 cronjobs to run those scripts at the given times:
0 14 * * * python ...
0
votes
0
answers
75
views
Duplicity works with run-parts but not in anacron
I am working to set up backups from my computer to Google Cloud Storage using duplicity.
I used gsutil to create a ~/.boto configuration file, and created a simple bash script that includes a call to ...
2
votes
1
answer
173
views
How long does at(1) wait for a scheduled task to complete?
Say one scheduled a task with
at 11pm on Friday
> long-running-command
Ctrl-D
How long can the long-running command run? Will the at daemon force termination after a certain amount of time?
0
votes
2
answers
446
views
Anacron running running my daily task each hour [duplicate]
I wanted to schedule a daily task using anacron. After some reading I added the below line to /etc/anacrontab:
@daily 10 price_scrape /home/pawel/Project_Inflation/run.sh >> /home/pawel/...
0
votes
0
answers
28
views
dconf in Anacron
If I run the following script as a non-su user from a terminal it works and the dconf-settings.ini is updated with a file size of 17.2kB. However if I run the same script in Anacron the dconf-settings....
0
votes
1
answer
220
views
Why does Anacron need the full path to commands in $PATH
I have noticed that scripts which run perfectly from the command line fail to work properly in Anacron. Often the reason is that Anacron requires the full path to the commands. Is there a way to make ...
0
votes
0
answers
87
views
dconf-dump works in terminal but not in Anacron
I am running the following script daily via Anacron.
#!/bin/bash
if ! mount | grep /media/steve/6363-6333 >/dev/null
then
dpkg --get-selections > /home/steve/package_list
dconf dump / ...
1
vote
1
answer
940
views
Anacron daily job not being executed
I am running Ubuntu 18.10 on a laptop with no other OS. I recently added the following line to the /etc/anacrontab file:
1 15 sync.daily /home/steve/Scripts/syncStuff.sh
The script syncStuff.sh ...
2
votes
1
answer
3k
views
Anacron wants to use sendmail. Why?
I am using Ubuntu 18.10 and have added a short script to anacrontab. Now I get this log warning from Anacron:
Can't find sendmail at /usr/sbin/sendmail, not mailing output
I use the default ...
3
votes
1
answer
1k
views
How to ensure security upgrades run regularly on intermittent internet connection?
Ubuntu seems to have an enduring blind-spot for security upgrades on computers which are not connected permanently to the internet. These days there are surely a ton of them, mostly laptops.
In ...
19
votes
1
answer
11k
views
Run /etc/cron.daily from specific user
Do I properly understand that it is not possible to run /etc/cron.daily/my from arbitrary user, it will be run only from root according to /etc/crontab?
Can I drop root privilege to specific user in ...
0
votes
1
answer
263
views
Anacron exit status 128
I want to make a git commit every week, therefore i wanted to use anacron.
So I added the following line to my /etc/anacrontab
7 1 AGDienste.weekly /bin/sh /home/bjoern/Hockey/...
8
votes
1
answer
2k
views
Cron/Anacron vs. Systemd
Linux provides three different job schedulers i.e. Cron, Anacron and Systemd-Timer. What are the benefits of Cron/Anacron vs. Systemd-Timer?
2
votes
1
answer
2k
views
Why aren't my anacron jobs running?
cron is running, but no anacron jobs run. It's not a localized thing: none of them have been running for quite some time. (Clearly, I wasn't paying attention.)
I've checked all the usual cron-like ...
2
votes
1
answer
3k
views
How can I add a cronjob using a script? [duplicate]
I wrote this script, but it doesn't work:
#! /bin/bash
cront=$(crontab -e)
echo 00 23 * * 5 tar -cpzf /var/backup.tar.gz /home/$USER >> $cront
How can I add a cronjob using a script?
2
votes
3
answers
2k
views
How to allow unattended-upgrades to start even running on battery?
By default, unattended-upgrades is trigger by anacron and it only start when running on AC power, and don’t start when running on battery. This beviavor is easy to understand to avoid waste power. ...
0
votes
0
answers
73
views
Automating deja-dup with anacron: permissions problem?
I'm trying to get deja-dup automatically running via anacron, instead of via Unity, so that I have more control over job priorities.
In /etc/anacrontab, I'm hoping to use this row:
1 2 ...
0
votes
1
answer
93
views
Launching multiple scripts without waiting the end of the previous using anacron
On a small server, I would like to launch a selenium webdriver and a python script which will use the selenium webdriver consecutively at boot, without waiting the end of the other (of course).
I ...
4
votes
2
answers
3k
views
How to make Anacron startup reliably?
So, I'm using Anacron to be able to reliably run some scripts daily. However, this doesn't work when Anacron itself doesn't start on boot half the time. How would I get Anacron to start up reliably?
&...
1
vote
1
answer
433
views
Deciphering Ubuntu's /etc/crontab [duplicate]
The /etc/crontab on my machine is as follows:
17 * * * * root cd / && run-parts --report /etc/cron.hourly
25 6 * * * root test -x /usr/sbin/anacron || ( cd / && run-...
3
votes
1
answer
155
views
How do I find what is trying to use upstart on my system?
I set up email on my server last night so I could get error notification emails and I got a puzzling email:
The whole message is:
Subject:Cron <root@*redacted*> start -q anacron || :
Body: ...
2
votes
1
answer
2k
views
cron.daily not running with anacron
Sumary
I have a similar problem with cron.daily jobs not running, but the solutions there do not apply to me.
I have setup a script that should run daily through cron.daily. I placed my script in ...
2
votes
1
answer
1k
views
Setting daily backups on laptop with cron/anacron on 16.10
I have similar questions to confusion about cron and anacron (setting up backup schedule for rsnapshot), but there weren't answered either.
Problem
My problem is to have a backup routine on daily ...
1
vote
0
answers
193
views
How to manually delay Anacron for a few hours?
I have Ubuntu running on an older laptop. I have noticed that maintenance cron jobs slow things for a few minutes when they execute. This is a problem if, for example, I need the resources for a ...
2
votes
1
answer
2k
views
cron.daily hanging my system?
It happens about once a week and the system completely freezes. Doesn't react to Ctrl+Alt+F1, Ctrl+Alt+Delete, I need to hard reset it. Despite it happens different time of the day, every time I check ...
0
votes
1
answer
237
views
Daily anacron mails with failure
I'm receiving a daily mail from my Ubuntu with the current contents:
/etc/cron.daily/update-notifier-common:
Fetch:1 http://downloads.sourceforge.net/corefonts/andale32.exe [291 B]
Error:1 http://...
5
votes
1
answer
18k
views
How to setup cron.daily? [duplicate]
I put my shell script inside /etc/cron.daily
I was hoping everything that in that folder would be run daily but my script is not being ran.
34
votes
1
answer
21k
views
Confused about relationship between cron and anacron
I've been googling in vain to turn up a general explanation of how cron and anacron work together. The man pages are a bit too deep of a dive for me at this point.
I get confused because I add tasks ...
5
votes
1
answer
23k
views
Where Crontab? Ubuntu 16.04
I've been trying to suss out how to add a job using crontab from this video:
https://www.youtube.com/watch?v=vrPGRE6FV9g
Easy enough and understandable but I can't find the crontab in etc? Acutally ...
1
vote
1
answer
2k
views
How do I run a Supervisor task from cron.hourly?
I have a task defined in Supervisor that I would like to invoke hourly from /etc/cron.hourly. I can run it manually, but not from run-parts:
$ sudo supervisorctl start my-task -- works
# . /etc/cron....
2
votes
2
answers
439
views
Get a list of all scripts and their paths which are run as cron job
I am looking for some scripts or a terminal command to list all the active scripts (preferably with their paths), which run on a periodic basis by cron, cron.daily and/or anacron. I am not looking for ...
2
votes
2
answers
7k
views
confusion about cron and anacron (setting up backup schedule for rsnapshot)
I am trying to set up a not too complicated backup schedule with rsnapshot on a laptop running Ubuntu 16.04 LTS. The plan is to retain two daily backups and 24 hourly backups. I think this is the ...
14
votes
1
answer
13k
views
Manually run an Anacron Job
I have performed a minimal installation of UBUNTU. I trying to configure my system to take automatic backups using rsnapshot. I have successfully configured my rsnapshot.conf file and by running ...
1
vote
1
answer
3k
views
Anacron starts but does not run cron.daily
$ grep anacron /var/log/syslog
Feb 20 19:05:11 jesus-Custom-PC anacron[1410]: Anacron 2.3 started on 2016-02-20
Feb 20 19:05:11 jesus-Custom-PC anacron[1410]: Normal exit (0 jobs run)
Feb 20 19:05:13 ...
1
vote
1
answer
35
views
Everyday Ubuntu system reboots at fixed time
I am using Ubuntu system setup by someone else. It used to restart everyday around 8 am.
I checked for cron jobs, but I didn't find any.
Can anyone help, why I am getting such behavior ?
2
votes
1
answer
667
views
anacron cron.weekly only runs when logged in
I have a weekly cron job set up to run every Saturday morning at 00:01 AM. The anacron.weekly entry in the crontab is set to run at Saturdays at 00:01 AM crontab entry is:
1 0 * * 6 root test -x /...
3
votes
1
answer
3k
views
This anacron cron job is sending emails to me - how can I redirect the output to null? [duplicate]
$ cat update-notifier-common
#!/bin/sh
set -e
[ -x /usr/lib/update-notifier/package-data-downloader ] || exit 0
# Try to rerun any package data downloads that failed at package install time.
/usr/...
5
votes
1
answer
9k
views
Who runs scripts inside /etc/cron.hourly if anacron is enabled?
I've read that if anacron is enabled cron doesn't run the scripts inside cron.weekly/hourly/daily/hourly, as not to run them twice. So anacron takes responsability on that folders.
However anacron ...
3
votes
1
answer
2k
views
How to get exit status of anacron jobs to catch errors?
It is easy to find failed cron jobs by setting log_level but how to do it with anacron?
10
votes
1
answer
1k
views
Why 'nobody' always starts a new `find` program that always consume my memory?
$ ps -elf | grep
...
0 D nobody 27320 27319 2 90 10 - 353471 sleep_ 07:54 ? 00:02:19 /usr/bin/find / -ignore_readdir_race ( -fstype NFS -o -fstype nfs -o -fstype nfs4 -o -fstype afs -o -...