cron.daily gives apt error. “not found”Crontab Output problemApt errors since upgrade to 12.04Ubuntu...
Can a wizard cast a spell during their first turn of combat if they initiated combat by releasing a readied spell?
What are substitutions for coconut in curry?
Should I be concerned about student access to a test bank?
What does "^L" mean in C?
Can other pieces capture a threatening piece and prevent a checkmate?
Is there a hypothetical scenario that would make Earth uninhabitable for humans, but not for (the majority of) other animals?
What is the English word for a graduation award?
How to terminate ping <dest> &
Fewest number of steps to reach 200 using special calculator
Can you move over difficult terrain with only 5 feet of movement?
Would it be believable to defy demographics in a story?
두음법칙 - When did North and South diverge in pronunciation of initial ㄹ?
Am I eligible for the Eurail Youth pass? I am 27.5 years old
How does 取材で訪れた integrate into this sentence?
Could Sinn Fein swing any Brexit vote in Parliament?
Knife as defense against stray dogs
How could an airship be repaired midflight?
Hausdorff dimension of the boundary of fibres of Lipschitz maps
In Aliens, how many people were on LV-426 before the Marines arrived?
Recruiter wants very extensive technical details about all of my previous work
Synchronized implementation of a bank account in Java
Help prove this basic trig identity please!
Why is there so much iron?
Does the attack bonus from a Masterwork weapon stack with the attack bonus from Masterwork ammunition?
cron.daily gives apt error. “not found”
Crontab Output problemApt errors since upgrade to 12.04Ubuntu 13.10 won't update. apt update and apt upgrade failPATH is not getting exported by default in Ubuntu 12.04Broken package ubuntu-keyring (ubuntu 15.04 64 bit)Error while installing Oracle 12c on Ubuntu 17.04Errors every time I use 'apt install' because of old kernelsMeaning of the following messages on terminaldependency, sudo, and apt-get errors in KubuntuHow to configure mail in Ubuntu for crontab service?
I recently upgrade to Ubuntu 15.04 and after that I get these strange errors in my cron e-mail. Sadly I didn't remember what version of ubuntu I was upgrading from but I think it was the latest before 15.04.
The rsync script called by backup_nas still works, it's just a simple bash script that calls rsync.
/etc/cron.daily/apt:
/etc/cron.daily/apt: 91: /etc/cron.daily/apt: date: not found
/etc/cron.daily/apt: 97: /etc/cron.daily/apt: rm: not found
/etc/cron.daily/apt: 448: /etc/cron.daily/apt: pidof: not found
/etc/cron.daily/apt: 176: /etc/cron.daily/apt: date: not found
/etc/cron.daily/apt: 176: /etc/cron.daily/apt: date: not found
/etc/cron.daily/backup_nas:
sending incremental file list
My /etc/crontab
:
SHELL=/bin/sh
PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin
My /etc/anacrontab
:
SHELL=/bin/sh
PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin
HOME=/root
LOGNAME=root
# These replace cron's entries
1 5 cron.daily run-parts --report /etc/cron.daily
7 10 cron.weekly run-parts --report /etc/cron.weekly
@monthly 15 cron.monthly run-parts --report /etc/cron.monthly
What could be the problem?
I have done a apt-get dist-upgrade
and it does not give me any errors. Also I tried to reinstall unattended-upgrade but that didn't change anything.
apt bash cron
add a comment |
I recently upgrade to Ubuntu 15.04 and after that I get these strange errors in my cron e-mail. Sadly I didn't remember what version of ubuntu I was upgrading from but I think it was the latest before 15.04.
The rsync script called by backup_nas still works, it's just a simple bash script that calls rsync.
/etc/cron.daily/apt:
/etc/cron.daily/apt: 91: /etc/cron.daily/apt: date: not found
/etc/cron.daily/apt: 97: /etc/cron.daily/apt: rm: not found
/etc/cron.daily/apt: 448: /etc/cron.daily/apt: pidof: not found
/etc/cron.daily/apt: 176: /etc/cron.daily/apt: date: not found
/etc/cron.daily/apt: 176: /etc/cron.daily/apt: date: not found
/etc/cron.daily/backup_nas:
sending incremental file list
My /etc/crontab
:
SHELL=/bin/sh
PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin
My /etc/anacrontab
:
SHELL=/bin/sh
PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin
HOME=/root
LOGNAME=root
# These replace cron's entries
1 5 cron.daily run-parts --report /etc/cron.daily
7 10 cron.weekly run-parts --report /etc/cron.weekly
@monthly 15 cron.monthly run-parts --report /etc/cron.monthly
What could be the problem?
I have done a apt-get dist-upgrade
and it does not give me any errors. Also I tried to reinstall unattended-upgrade but that didn't change anything.
apt bash cron
Does your/etc/crontab
contain an appropriatePATH
? if in doubt, please edit your question to include the contents of that file as well
– steeldriver
Jul 13 '15 at 14:58
I have never changed anything there so I hop it's correct. Updated accordingly.
– Sun_Blood
Jul 13 '15 at 17:58
Please edit your question and add the output ofcat /etc/anacrontab
– heemayl
Jul 13 '15 at 20:03
Sure. I have updated the post.
– Sun_Blood
Jul 13 '15 at 20:35
add a comment |
I recently upgrade to Ubuntu 15.04 and after that I get these strange errors in my cron e-mail. Sadly I didn't remember what version of ubuntu I was upgrading from but I think it was the latest before 15.04.
The rsync script called by backup_nas still works, it's just a simple bash script that calls rsync.
/etc/cron.daily/apt:
/etc/cron.daily/apt: 91: /etc/cron.daily/apt: date: not found
/etc/cron.daily/apt: 97: /etc/cron.daily/apt: rm: not found
/etc/cron.daily/apt: 448: /etc/cron.daily/apt: pidof: not found
/etc/cron.daily/apt: 176: /etc/cron.daily/apt: date: not found
/etc/cron.daily/apt: 176: /etc/cron.daily/apt: date: not found
/etc/cron.daily/backup_nas:
sending incremental file list
My /etc/crontab
:
SHELL=/bin/sh
PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin
My /etc/anacrontab
:
SHELL=/bin/sh
PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin
HOME=/root
LOGNAME=root
# These replace cron's entries
1 5 cron.daily run-parts --report /etc/cron.daily
7 10 cron.weekly run-parts --report /etc/cron.weekly
@monthly 15 cron.monthly run-parts --report /etc/cron.monthly
What could be the problem?
I have done a apt-get dist-upgrade
and it does not give me any errors. Also I tried to reinstall unattended-upgrade but that didn't change anything.
apt bash cron
I recently upgrade to Ubuntu 15.04 and after that I get these strange errors in my cron e-mail. Sadly I didn't remember what version of ubuntu I was upgrading from but I think it was the latest before 15.04.
The rsync script called by backup_nas still works, it's just a simple bash script that calls rsync.
/etc/cron.daily/apt:
/etc/cron.daily/apt: 91: /etc/cron.daily/apt: date: not found
/etc/cron.daily/apt: 97: /etc/cron.daily/apt: rm: not found
/etc/cron.daily/apt: 448: /etc/cron.daily/apt: pidof: not found
/etc/cron.daily/apt: 176: /etc/cron.daily/apt: date: not found
/etc/cron.daily/apt: 176: /etc/cron.daily/apt: date: not found
/etc/cron.daily/backup_nas:
sending incremental file list
My /etc/crontab
:
SHELL=/bin/sh
PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin
My /etc/anacrontab
:
SHELL=/bin/sh
PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin
HOME=/root
LOGNAME=root
# These replace cron's entries
1 5 cron.daily run-parts --report /etc/cron.daily
7 10 cron.weekly run-parts --report /etc/cron.weekly
@monthly 15 cron.monthly run-parts --report /etc/cron.monthly
What could be the problem?
I have done a apt-get dist-upgrade
and it does not give me any errors. Also I tried to reinstall unattended-upgrade but that didn't change anything.
apt bash cron
apt bash cron
edited Jul 13 '15 at 20:28
Sun_Blood
asked Jul 13 '15 at 14:51
Sun_BloodSun_Blood
135
135
Does your/etc/crontab
contain an appropriatePATH
? if in doubt, please edit your question to include the contents of that file as well
– steeldriver
Jul 13 '15 at 14:58
I have never changed anything there so I hop it's correct. Updated accordingly.
– Sun_Blood
Jul 13 '15 at 17:58
Please edit your question and add the output ofcat /etc/anacrontab
– heemayl
Jul 13 '15 at 20:03
Sure. I have updated the post.
– Sun_Blood
Jul 13 '15 at 20:35
add a comment |
Does your/etc/crontab
contain an appropriatePATH
? if in doubt, please edit your question to include the contents of that file as well
– steeldriver
Jul 13 '15 at 14:58
I have never changed anything there so I hop it's correct. Updated accordingly.
– Sun_Blood
Jul 13 '15 at 17:58
Please edit your question and add the output ofcat /etc/anacrontab
– heemayl
Jul 13 '15 at 20:03
Sure. I have updated the post.
– Sun_Blood
Jul 13 '15 at 20:35
Does your
/etc/crontab
contain an appropriate PATH
? if in doubt, please edit your question to include the contents of that file as well– steeldriver
Jul 13 '15 at 14:58
Does your
/etc/crontab
contain an appropriate PATH
? if in doubt, please edit your question to include the contents of that file as well– steeldriver
Jul 13 '15 at 14:58
I have never changed anything there so I hop it's correct. Updated accordingly.
– Sun_Blood
Jul 13 '15 at 17:58
I have never changed anything there so I hop it's correct. Updated accordingly.
– Sun_Blood
Jul 13 '15 at 17:58
Please edit your question and add the output of
cat /etc/anacrontab
– heemayl
Jul 13 '15 at 20:03
Please edit your question and add the output of
cat /etc/anacrontab
– heemayl
Jul 13 '15 at 20:03
Sure. I have updated the post.
– Sun_Blood
Jul 13 '15 at 20:35
Sure. I have updated the post.
– Sun_Blood
Jul 13 '15 at 20:35
add a comment |
1 Answer
1
active
oldest
votes
Replace all instances of date with /usr/bin/date and do the same for every command/path.
Use absolute paths in cron scripts, expect the shell to be dumb and not use any PATH or environmental variables. Also the shell used by default is /bin/sh not bash.
date: not found
which date
/usr/bin/date
add a comment |
Your Answer
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "89"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f647912%2fcron-daily-gives-apt-error-not-found%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
Replace all instances of date with /usr/bin/date and do the same for every command/path.
Use absolute paths in cron scripts, expect the shell to be dumb and not use any PATH or environmental variables. Also the shell used by default is /bin/sh not bash.
date: not found
which date
/usr/bin/date
add a comment |
Replace all instances of date with /usr/bin/date and do the same for every command/path.
Use absolute paths in cron scripts, expect the shell to be dumb and not use any PATH or environmental variables. Also the shell used by default is /bin/sh not bash.
date: not found
which date
/usr/bin/date
add a comment |
Replace all instances of date with /usr/bin/date and do the same for every command/path.
Use absolute paths in cron scripts, expect the shell to be dumb and not use any PATH or environmental variables. Also the shell used by default is /bin/sh not bash.
date: not found
which date
/usr/bin/date
Replace all instances of date with /usr/bin/date and do the same for every command/path.
Use absolute paths in cron scripts, expect the shell to be dumb and not use any PATH or environmental variables. Also the shell used by default is /bin/sh not bash.
date: not found
which date
/usr/bin/date
answered 6 mins ago
SHOTbyGUNSHOTbyGUN
1
1
add a comment |
add a comment |
Thanks for contributing an answer to Ask Ubuntu!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f647912%2fcron-daily-gives-apt-error-not-found%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Does your
/etc/crontab
contain an appropriatePATH
? if in doubt, please edit your question to include the contents of that file as well– steeldriver
Jul 13 '15 at 14:58
I have never changed anything there so I hop it's correct. Updated accordingly.
– Sun_Blood
Jul 13 '15 at 17:58
Please edit your question and add the output of
cat /etc/anacrontab
– heemayl
Jul 13 '15 at 20:03
Sure. I have updated the post.
– Sun_Blood
Jul 13 '15 at 20:35