[Touch-packages] [Bug 1821566] Re: cron ignores whole crontab if one line has error
I'm afraid that this is by design, to prevent a malicious user from dumping basically anything into one of the crontab directories. An attacker once compromised a debian.org host by triggering a crafted core dump in one of the crontab directories, and the daemon kept trying to execute lines until it hit a valid one. ** Changed in: cron (Ubuntu) Status: New => Invalid -- You received this bug notification because you are a member of Ubuntu Touch seeded packages, which is subscribed to cron in Ubuntu. https://bugs.launchpad.net/bugs/1821566 Title: cron ignores whole crontab if one line has error Status in cron package in Ubuntu: Invalid Bug description: Ubuntu 18.04. Let's create error entry in /etc/crontab: 00 09 * * 4 1 root /usr/local/bin/geoiprenew.sh restart cron systemctl restart cron мар 25 10:29:02 ovpn1 cron[12403]: Error: bad username; while reading /etc/crontab мар 25 10:29:02 ovpn1 cron[12403]: (*system*) ERROR (Syntax error, this crontab file will be ignored) Expected behavoir is only line with error is ignired. Thank you! To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/cron/+bug/1821566/+subscriptions -- Mailing list: https://launchpad.net/~touch-packages Post to : touch-packages@lists.launchpad.net Unsubscribe : https://launchpad.net/~touch-packages More help : https://help.launchpad.net/ListHelp
[Touch-packages] [Bug 1110147] Re: Error in manual
This was fixed in -121. ** Changed in: cron (Ubuntu) Status: Confirmed => Fix Released -- You received this bug notification because you are a member of Ubuntu Touch seeded packages, which is subscribed to cron in Ubuntu. https://bugs.launchpad.net/bugs/1110147 Title: Error in manual Status in cron package in Ubuntu: Fix Released Bug description: The manual for crontab(5) shows various examples of using the date command as such: $(date +%u) This contradicts the note specifying that any % sign needs to be escaped Entering something like that as a command for execution fails to interpret anything past the % sign. so, for example: * * * * * echo $(date +%Y) fails with /bin/sh: 1: Syntax error: end of file unexpected (expecting ")") The syslog shows this CRON[10104]: (root) CMD (echo $(date +) Simply escaping the % resolves it, so in this example, the manual should be updated so that each 'date' example looks as $(date +\%u) - or whatever the format character example is. My example cron from above executes as expected as * * * * * echo $(date +\%Y) which send me an email simply with "2013" To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/cron/+bug/1110147/+subscriptions -- Mailing list: https://launchpad.net/~touch-packages Post to : touch-packages@lists.launchpad.net Unsubscribe : https://launchpad.net/~touch-packages More help : https://help.launchpad.net/ListHelp
Re: [Touch-packages] [Bug 1819369] Re: When specifying minute, hour, day-of-month, month, day-of-week values/ranges, given day-of-month range is *ignored*
On 10.03.19 21:05, Markus Ueberall wrote: > # m h dom mon dow user command > 00 05 1-7 1,3,5,7,9,11 SAT sys-maint some-task some-option > #host1 > 00 05 8-14 1,3,5,7,9,11 SAT sys-maint some-task some-option > #host2 > 00 05 15-21 1,3,5,7,9,11 SATsys-maint some-task some-option > #host3 > 00 05 22-28 1,3,5,7,9,11 SATsys-maint some-task some-option > #host4 > The expectation was that none of the entries is executed in parallel > at any given point in time due to column three> (day-of-month range) This frequently occurring mistake is an unfortunate result of the crontab(5) specification. Quoting the man page: > Note: The day of a command's execution can be specified by two fields — > day of month, and day of week. If both fields are restricted (i.e., > aren't *), the command will be run when either field matches the current > time. For example, ``30 4 1,15 * 5'' would cause a command to be run at > 4:30 am on the 1st and 15th of each month, plus every Friday. In short: it's not dom AND dow, but dom OR dow. Consequently, your specification of SAT in column 5 trumps your specification of column 3. The man page contains an example for how to work around this. -- Christian Kastner ** Changed in: cron (Ubuntu) Status: New => Invalid -- You received this bug notification because you are a member of Ubuntu Touch seeded packages, which is subscribed to cron in Ubuntu. https://bugs.launchpad.net/bugs/1819369 Title: When specifying minute,hour,day-of-month,month,day-of-week values/ranges, given day-of-month range is *ignored* Status in cron package in Ubuntu: Invalid Bug description: 1) The release of Ubuntu you are using, via 'lsb_release -rd' # lsb_release -rd Description:Ubuntu 16.04.6 LTS Release:16.04 2) The version of the package you are using, via 'apt-cache policy pkgname' # apt-cache policy cron cron: Installed: 3.0pl1-128ubuntu2 Candidate: 3.0pl1-128ubuntu2 Version table: *** 3.0pl1-128ubuntu2 500 500 http://de.archive.ubuntu.com/ubuntu xenial/main amd64 Packages 100 /var/lib/dpkg/status 3) What you expected to happen /etc/crontab contains the following entries (each line lives on a separate host with identical setup, system clocks are in sync): # m h dom mon dow user command 00 05 1-7 1,3,5,7,9,11 SAT sys-maint some-task some-option #host1 00 05 8-14 1,3,5,7,9,11 SAT sys-maint some-task some-option #host2 00 05 15-21 1,3,5,7,9,11 SATsys-maint some-task some-option #host3 00 05 22-28 1,3,5,7,9,11 SATsys-maint some-task some-option #host4 The expectation was that none of the entries is executed in parallel at any given point in time due to column three (day-of-month range). (Note: All other (default) entries work as expected, syntax of all crontab files has been checked using https://code.google.com/archive/p/chkcrontab/wikis/CheckCrontab.wiki) 4) What happened instead Yesterday (Saturday, March 9th), the same script was executed in parallel on all four hosts. To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/cron/+bug/1819369/+subscriptions -- Mailing list: https://launchpad.net/~touch-packages Post to : touch-packages@lists.launchpad.net Unsubscribe : https://launchpad.net/~touch-packages More help : https://help.launchpad.net/ListHelp
Re: [Touch-packages] [Bug 1534377] Re: cron does not read $PATH
On 2016-01-19 04:01, Humphrey van Polanen Petel wrote: > Just so you know, it *is* a cron command. > Gnome Schedule is nothing but a pretty gui to crontab. And that pretty GUI is from an entirely separate package than package cron, against which you reported the bug. > I suggest you be a bit more charitable when reading bug reports. Please follow your own suggestion. I already explained how cron works: via crontabs, ie plaintext files in a specific directory. If a client program (be it from Gnome, KDE, or whatever) uses this interface incorrectly, then it is up to the client program to fix this. Hence why I said "you'll have to report it against Gnome". If you had read crontab(5) as I suggested, then you would know that to modify the $PATH of a job, one must specify a PATH variable in the crontab file. You seem to expect Gnome Schedule to do this for you (when it presumably generates a crontab), but evidently it isn't doing it. That is clearly not a problem in cron, but in Gnome Schedule. > After some study of the documentation, I have come to the conclusion > that cron/crontab is very much in need of a revamp. Certainly, it does > the job, but then that depends on how the job-requirements are defined. > To be sure, it is probably very difficult and much more complex than I > can imagine, but being used to the Windows Task Scheduler I suggest that > it could be a lot more user-friendly. I agree that the mode in which cron operates is antiquated. Nevertheless, it is mandated by POSIX: http://pubs.opengroup.org/onlinepubs/9699919799/utilities/crontab.html More powerful job schedulers exist, but the intention behind cron is to provide a simple, consistent, and ever-present interface in POSIX-compliant environments. Regards, Christian -- You received this bug notification because you are a member of Ubuntu Touch seeded packages, which is subscribed to cron in Ubuntu. https://bugs.launchpad.net/bugs/1534377 Title: cron does not read $PATH Status in cron package in Ubuntu: Invalid Bug description: PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games Gnome _schedule command preview=/usr/local/bin/bup && tail -f /var/mail/humphrey >~/Desktop/bup-log /usr/local/bin contains bin log contains -- Content-Type: text/plain; charset=ANSI_X3.4-1968 X-Cron-Env:
Re: [Touch-packages] [Bug 1534377] [NEW] cron does not read $PATH
On 2016-01-15 00:47, Humphrey van Polanen Petel wrote: > PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games > > Gnome _schedule command preview=/usr/local/bin/bup ^^ That's not a cron command, that is some independent Gnome frontend. cron only reads crontabs from /var/spool/cron/crontabs. You create and edit crontabs by executing "crontab -e". For information on how to set PATH for cron jobs, please see crontab(5). Anything else you'll have to report against Gnome. Regards, Christian ** Changed in: cron (Ubuntu) Status: New => Invalid -- You received this bug notification because you are a member of Ubuntu Touch seeded packages, which is subscribed to cron in Ubuntu. https://bugs.launchpad.net/bugs/1534377 Title: cron does not read $PATH Status in cron package in Ubuntu: Invalid Bug description: PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games Gnome _schedule command preview=/usr/local/bin/bup && tail -f /var/mail/humphrey >~/Desktop/bup-log /usr/local/bin contains bin log contains -- Content-Type: text/plain; charset=ANSI_X3.4-1968 X-Cron-Env:
[Touch-packages] [Bug 1451286] Re: crontab -r deletes cron entries without asking for confirmation
This is a valid request. I've linked this bug to the corresponding bug in Debian's cron. ** Changed in: cron (Ubuntu) Status: Invalid = Confirmed ** Bug watch added: Debian Bug tracker #561295 http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=561295 ** Also affects: cron (Debian) via http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=561295 Importance: Unknown Status: Unknown -- You received this bug notification because you are a member of Ubuntu Touch seeded packages, which is subscribed to cron in Ubuntu. https://bugs.launchpad.net/bugs/1451286 Title: crontab -r deletes cron entries without asking for confirmation Status in cron package in Ubuntu: Confirmed Status in cron package in Debian: Unknown Bug description: type: crontab -r Expected use case : should ask user if they really want to delete this file, of which there are no backups on the system by default, and may take hours to restore by hand, if it's even possible. what happens: user's cron entry is deleted with no warning. To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/cron/+bug/1451286/+subscriptions -- Mailing list: https://launchpad.net/~touch-packages Post to : touch-packages@lists.launchpad.net Unsubscribe : https://launchpad.net/~touch-packages More help : https://help.launchpad.net/ListHelp
Re: [Touch-packages] [Bug 1429427] [NEW] Unexplainable time jumps in CRON
Hi, On 2015-03-07 18:16, sgofferj wrote: On my main server I see unexplainable time jumps backwards in the syslog. Those jumps affect CRON. Example: Feb 10 06:48:01 nostromo CRON[20351]: (root) CMD ( /storage/exec/checkinternet.sh 2/dev/null 1/dev/null) Feb 10 06:49:01 nostromo CRON[20364]: (root) CMD ( /storage/exec/checkinternet.sh 2/dev/null 1/dev/null) Feb 10 06:50:01 nostromo CRON[20386]: (root) CMD ( /storage/exec/status-nostromo.sh /dev/null 21) Feb 7 05:40:01 nostromo CRON[20389]: (root) CMD ( /storage/exec/checkinternet.sh 2/dev/null 1/dev/null) Feb 10 06:50:01 nostromo CRON[20390]: (root) CMD ( /storage/exec/checkinternet.sh 2/dev/null 1/dev/null) Feb 10 06:50:01 nostromo CRON[20391]: (root) CMD ( /storage/exec/checkip.sh 2/dev/null 1/dev/null) I'm afraid this is not a cron bug. The cron daemon does not write any logs itself: as it is customary, it uses the syslog(3) facilities to log all its messages. Therefore, the timestamp you are seeing is not generated by cron, but by your syslog daemon. Note that the PIDs of the individual cron processes are close together (20386, 20389, 20390, 20391), which usually indicates that they were started in close succession. So, despite the bogus timestamp, your cron execution schedule appears to be fine. I'd say this is either a bug in your syslog implementation, or a hardware issue affecting syslog. By reassigning this bug to your syslog implementation, the respective maintainers might be able to help you in tracking down this issue. Regards, Christian For debugging I did the following: Start xclock and watch xclock and tail -f /var/log/syslog in parallel. When CRON logged a wrong time, xclock did NOT show any time jump but seemed to freeze for a fraction of a second. Open a screen and start a script that will once per second read the time (in unix seconds) and compare the read time with the time read a second ago. If the current time was smaller, the script would send an email with a process list from before and after the jump. The script also never detected any time jump. In summary, my current impression is that there might be a bug in CRON because no other programm seems to be able to see the wrong time. The server in question is syslog server for 4 servers and 3 network devices. The time jumps exclusively show in syslog entries from the local CRON instance. Not in any remote syslog entry and not in any other local syslog entry, e.g. from DHCPD, bind, tftpd, etc. etc. Also, after a reboot, things work ok for several days upto about 2 or 3 weeks. Then the time jumps start to occur with increasing frequency. I don't use user crontabs but maintain all jobs in /etc/crontab. I have number of jobs which are triggered every minute and another number of jobs which are triggered every 5 minutes (maybe some CRON internal counter overflow problem?). -- You received this bug notification because you are a member of Ubuntu Touch seeded packages, which is subscribed to cron in Ubuntu. https://bugs.launchpad.net/bugs/1429427 Title: Unexplainable time jumps in CRON Status in cron package in Ubuntu: Confirmed Bug description: On my main server I see unexplainable time jumps backwards in the syslog. Those jumps affect CRON. Example: Feb 10 06:48:01 nostromo CRON[20351]: (root) CMD ( /storage/exec/checkinternet.sh 2/dev/null 1/dev/null) Feb 10 06:49:01 nostromo CRON[20364]: (root) CMD ( /storage/exec/checkinternet.sh 2/dev/null 1/dev/null) Feb 10 06:50:01 nostromo CRON[20386]: (root) CMD ( /storage/exec/status-nostromo.sh /dev/null 21) Feb 7 05:40:01 nostromo CRON[20389]: (root) CMD ( /storage/exec/checkinternet.sh 2/dev/null 1/dev/null) Feb 10 06:50:01 nostromo CRON[20390]: (root) CMD ( /storage/exec/checkinternet.sh 2/dev/null 1/dev/null) Feb 10 06:50:01 nostromo CRON[20391]: (root) CMD ( /storage/exec/checkip.sh 2/dev/null 1/dev/null) For debugging I did the following: Start xclock and watch xclock and tail -f /var/log/syslog in parallel. When CRON logged a wrong time, xclock did NOT show any time jump but seemed to freeze for a fraction of a second. Open a screen and start a script that will once per second read the time (in unix seconds) and compare the read time with the time read a second ago. If the current time was smaller, the script would send an email with a process list from before and after the jump. The script also never detected any time jump. In summary, my current impression is that there might be a bug in CRON because no other programm seems to be able to see the wrong time. The server in question is syslog server for 4 servers and 3 network devices. The time jumps exclusively show in syslog entries from the local CRON instance. Not in any remote syslog entry and not in any other local syslog entry, e.g. from DHCPD, bind, tftpd, etc. etc. Also, after a reboot, things work ok for several days upto
[Touch-packages] [Bug 327190] Re: User Crontab is outside of GUI session
cron jobs are started by the cron daemon which is completely unrelated to your GUI session, or any other session that might be active for the user. As ccooke pointed out, if you want access to an unrelated session, you're going to have to do it manually. ** Changed in: cron (Ubuntu) Status: New = Opinion ** Changed in: cron (Ubuntu) Status: Opinion = Invalid -- You received this bug notification because you are a member of Ubuntu Touch seeded packages, which is subscribed to cron in Ubuntu. https://bugs.launchpad.net/bugs/327190 Title: User Crontab is outside of GUI session Status in “cron” package in Ubuntu: Invalid Bug description: When trying to execute programs that require variables from the GUI session. the crontab fails. It can no longer execute tasks which relate to editing gnome gconf or any other session settings. I believe this is because the crontab is outside of the gnome session. There are two possible fixes, 1) Somehow allow the system cron to access session variables when users are logged in, 2) Create a special cron which runs when users log in. To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/cron/+bug/327190/+subscriptions -- Mailing list: https://launchpad.net/~touch-packages Post to : touch-packages@lists.launchpad.net Unsubscribe : https://launchpad.net/~touch-packages More help : https://help.launchpad.net/ListHelp
[Touch-packages] [Bug 790173] Re: Cron doesn't send output properly
Fix ** Changed in: cron (Ubuntu) Status: New = Fix Released ** Package changed: cron (Ubuntu) = speech-dispatcher (Ubuntu) -- You received this bug notification because you are a member of Ubuntu Touch seeded packages, which is subscribed to cron in Ubuntu. https://bugs.launchpad.net/bugs/790173 Title: Cron doesn't send output properly Status in “speech-dispatcher” package in Ubuntu: Fix Released Bug description: Binary package hint: cron I have a bash script checking for new versions of Vim (in Bram Moolenaar's Mercurial repository) that's run by cron. The script saves its output into a log file and, if there is something interesting to say, at the and does 'cat $LOG_FILE'. The problem is that when run by cron on my newly installed Ubuntu 10.04.2 I don't get the output in mail but only 'expr: syntax error' line instead. Obviously I thought there was some error in the script at first, but after trying and checking I've found none. Besides, the script runs OK from command line and the same script runs OK from cron on Ubuntu 8.04. And I've also found (via checking the script's log whilst it was running) that it actually runs OK even here on Ubuntu 10.04.2, only I don't get the output. Therefore I'm not even sure whether this bug belongs to Cron or Postfix. I've also tried to run by cron different parts of the script separately, they worked OK and output in mail was OK too. I think this might perhaps be related with this discussion I've googled: http://www.howtoforge.com/forums/showthread.php?t=45202 Thx. To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/speech-dispatcher/+bug/790173/+subscriptions -- Mailing list: https://launchpad.net/~touch-packages Post to : touch-packages@lists.launchpad.net Unsubscribe : https://launchpad.net/~touch-packages More help : https://help.launchpad.net/ListHelp
[Touch-packages] [Bug 1067779] Re: missing pam_loginuid.so breaks getlogin()
3.0pl1-124.1ubuntu1 contains a fix for this. ** Changed in: cron (Ubuntu) Status: Confirmed = Fix Committed -- You received this bug notification because you are a member of Ubuntu Touch seeded packages, which is subscribed to cron in Ubuntu. https://bugs.launchpad.net/bugs/1067779 Title: missing pam_loginuid.so breaks getlogin() Status in “at” package in Ubuntu: Fix Committed Status in “cron” package in Ubuntu: Fix Committed Status in “openssh” package in Ubuntu: Fix Released Status in “shadow” package in Ubuntu: Confirmed Status in “at” package in Debian: Fix Released Status in “cron” package in Debian: Fix Released Status in “openssh” package in Debian: Fix Released Status in “shadow” package in Debian: Fix Released Bug description: getlogin() call in new glibc checks /proc/self/loginuid presence and trust its value as most safe source (due it's audit-related nature). But default /etc/pam.d/common-account doesn't contains entry to pam_loginuid.so which modify /proc/self/loginuid properly. This breaks getlogin() at many scenarios like this: (pam session without pam_loginuid)$ perl -e '$t=getlogin; print $t\n;' root (pam session without pam_loginuid)$ id uid=1000(... just because /proc/self/loginuid contains '0' value If I add pam_loginuid.so to /etc/pam.d/common-account like http://manpages.ubuntu.com/manpages/precise/man8/pam_loginuid.8.html recommend, everything worked as expected: (pam session with pam_loginuid)$ perl -e '$t=getlogin; print $t\n;' user (pam session with pam_loginuid)$ id uid=1000(... # cat /etc/lsb-release DISTRIB_ID=Ubuntu DISTRIB_RELEASE=12.04 DISTRIB_CODENAME=precise DISTRIB_DESCRIPTION=Ubuntu 12.04 LTS # dpkg -l|fgrep libpam ii libpam-ck-connector 0.4.5-2 ConsoleKit PAM module ii libpam-modules 1.1.3-7ubuntu2 Pluggable Authentication Modules for PAM ii libpam-modules-bin 1.1.3-7ubuntu2 Pluggable Authentication Modules for PAM - helper binaries ii libpam-runtime 1.1.3-7ubuntu2 Runtime support for the PAM library ii libpam0g 1.1.3-7ubuntu2 Pluggable Authentication Modules library To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/at/+bug/1067779/+subscriptions -- Mailing list: https://launchpad.net/~touch-packages Post to : touch-packages@lists.launchpad.net Unsubscribe : https://launchpad.net/~touch-packages More help : https://help.launchpad.net/ListHelp
[Touch-packages] [Bug 794141] Re: cron needs to re-lookup users when trying to run a job
** Changed in: cron (Ubuntu) Status: Confirmed = Fix Released -- You received this bug notification because you are a member of Ubuntu Touch seeded packages, which is subscribed to cron in Ubuntu. https://bugs.launchpad.net/bugs/794141 Title: cron needs to re-lookup users when trying to run a job Status in “cron” package in Ubuntu: Fix Released Bug description: Binary package hint: cron Please backport the fix for LP: #27520 to all supported releases. It breaks, among others, on lucid. ProblemType: Bug DistroRelease: Ubuntu 10.04 Package: cron 3.0pl1-106ubuntu5 ProcVersionSignature: Ubuntu 2.6.32-32.62-generic 2.6.32.38+drm33.16 Uname: Linux 2.6.32-32-generic x86_64 Architecture: amd64 Date: Tue Jun 7 18:32:53 2011 ProcEnviron: PATH=(custom, user) LANG=de_DE.UTF-8 SHELL=/bin/bash SourcePackage: cron To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/cron/+bug/794141/+subscriptions -- Mailing list: https://launchpad.net/~touch-packages Post to : touch-packages@lists.launchpad.net Unsubscribe : https://launchpad.net/~touch-packages More help : https://help.launchpad.net/ListHelp
[Touch-packages] [Bug 934337] Re: cron truncates command before execution, gives no erro
*** This bug is a duplicate of bug 826702 *** https://bugs.launchpad.net/bugs/826702 ** This bug has been marked a duplicate of bug 826702 crontab cuts off file names at 100 characters -- You received this bug notification because you are a member of Ubuntu Touch seeded packages, which is subscribed to cron in Ubuntu. https://bugs.launchpad.net/bugs/934337 Title: cron truncates command before execution, gives no erro Status in “cron” package in Ubuntu: Confirmed Bug description: cron truncates commands at 999 characters, then executes them, giving no errors or warnings. I'd prefer that cron NOT run the job, and instead throw an error. Much less important, it would be nice if the limit were increased. Worst case actually happened to me, rsync --del output directory got truncated just right, deleting lots of data. That was fun to figure out. Length was due to many --excludes. I suspect that the truncation is related to the MAX_COMMAND value. As a test case, I created the job: * * * * * echo a; date /home/darxus/tmp/a Which should create a file in /home/darxus/tmp/ 93 characters long, but truncates it at 72 characters long. rsync mailing list discussion: http://www.mail- archive.com/rs...@lists.samba.org/msg26564.html ProblemType: Bug DistroRelease: Ubuntu 11.04 Package: cron 3.0pl1-116ubuntu1 ProcVersionSignature: Ubuntu 2.6.38-13.55-generic 2.6.38.8 Uname: Linux 2.6.38-13-generic x86_64 NonfreeKernelModules: nvidia Architecture: amd64 Date: Fri Feb 17 11:59:40 2012 InstallationMedia: Ubuntu 9.10 Karmic Koala - Release amd64 (20091027) ProcEnviron: PATH=(custom, user) LANG=en_US.UTF-8 SHELL=/bin/bash SourcePackage: cron UpgradeStatus: Upgraded to natty on 2011-05-02 (290 days ago) To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/cron/+bug/934337/+subscriptions -- Mailing list: https://launchpad.net/~touch-packages Post to : touch-packages@lists.launchpad.net Unsubscribe : https://launchpad.net/~touch-packages More help : https://help.launchpad.net/ListHelp
[Touch-packages] [Bug 872552] Re: Too long line in crontab isn't executed
*** This bug is a duplicate of bug 826702 *** https://bugs.launchpad.net/bugs/826702 ** This bug has been marked a duplicate of bug 826702 crontab cuts off file names at 100 characters -- You received this bug notification because you are a member of Ubuntu Touch seeded packages, which is subscribed to cron in Ubuntu. https://bugs.launchpad.net/bugs/872552 Title: Too long line in crontab isn't executed Status in “cron” package in Ubuntu: Confirmed Bug description: I'm using Ubuntu 11.10 dev with cron 3.0pl1-116ubuntu3. Too long entries in a crontab seems to make problems. For example create the file /etc/cron.d/test and write in it: * * * * * root dash -c '/bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1 /bin/sleep 1' The command should be executed every minute but it doesn't (or maybe it is executed and failing immediately). If the last sleep command is removed the cronjob is working fine. To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/cron/+bug/872552/+subscriptions -- Mailing list: https://launchpad.net/~touch-packages Post to : touch-packages@lists.launchpad.net Unsubscribe : https://launchpad.net/~touch-packages More help : https://help.launchpad.net/ListHelp
[Touch-packages] [Bug 826702] Re: crontab cuts off file names at 100 characters
A fix has been prepared that recognizes too long commands and produces an error message when attempting to create one, both via crontab(1) and cron(8). Furthermore, this limit has been documented in the man pages. ** Changed in: cron (Ubuntu) Status: Confirmed = Fix Committed -- You received this bug notification because you are a member of Ubuntu Touch seeded packages, which is subscribed to cron in Ubuntu. https://bugs.launchpad.net/bugs/826702 Title: crontab cuts off file names at 100 characters Status in “cron” package in Ubuntu: Fix Committed Bug description: The crontab command silently cuts off file names after 100 characters. This means that it won't work if you have a file with a path longer than 100 characters, and want to feed it into crontab. Example: $ crontab _123456789_123456789_123456789_123456789_123456789_123456789_123456789_123456789_123456789_123456789_this_will_be_cut_off _123456789_123456789_123456789_123456789_123456789_123456789_123456789_123456789_123456789_12345678: No such file or directory This is due to a MAX_FNAME constant set to 100 characters in cron.h. I updated the code to use PATH_MAX instead. This will still cut off the paths, but at least after a more reasonable number of characters. To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/cron/+bug/826702/+subscriptions -- Mailing list: https://launchpad.net/~touch-packages Post to : touch-packages@lists.launchpad.net Unsubscribe : https://launchpad.net/~touch-packages More help : https://help.launchpad.net/ListHelp
[Touch-packages] [Bug 826702] Re: crontab cuts off file names at 100 characters
In the mean time, this limit has been raised to 1000 chars. -- You received this bug notification because you are a member of Ubuntu Touch seeded packages, which is subscribed to cron in Ubuntu. https://bugs.launchpad.net/bugs/826702 Title: crontab cuts off file names at 100 characters Status in “cron” package in Ubuntu: Fix Committed Bug description: The crontab command silently cuts off file names after 100 characters. This means that it won't work if you have a file with a path longer than 100 characters, and want to feed it into crontab. Example: $ crontab _123456789_123456789_123456789_123456789_123456789_123456789_123456789_123456789_123456789_123456789_this_will_be_cut_off _123456789_123456789_123456789_123456789_123456789_123456789_123456789_123456789_123456789_12345678: No such file or directory This is due to a MAX_FNAME constant set to 100 characters in cron.h. I updated the code to use PATH_MAX instead. This will still cut off the paths, but at least after a more reasonable number of characters. To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/cron/+bug/826702/+subscriptions -- Mailing list: https://launchpad.net/~touch-packages Post to : touch-packages@lists.launchpad.net Unsubscribe : https://launchpad.net/~touch-packages More help : https://help.launchpad.net/ListHelp
[Touch-packages] [Bug 985924] Re: Permission denied for custom entries in /etc/crontab
Closed as per submitter's request ** Changed in: cron (Ubuntu) Status: New = Invalid -- You received this bug notification because you are a member of Ubuntu Touch seeded packages, which is subscribed to cron in Ubuntu. https://bugs.launchpad.net/bugs/985924 Title: Permission denied for custom entries in /etc/crontab Status in “cron” package in Ubuntu: Invalid Bug description: Upon upgrade to Precise from Oneiric, my custom cron jobs stopped working. Custom entries in '/etc/crontab' result in these errors: Apr 19 14:59:01 hostname CRON[5898]: Permission denied Apr 19 14:59:01 hostname CRON[5899]: Permission denied Jobs in '/var/spool/cron/crontabs' are not executed either, but there are no error messages. I expected these jobs to run normally. Using full paths made no difference. The commands run manually. Description: Ubuntu 12.04 LTS Release: 12.04 Installed: 3.0pl1-120ubuntu3 Candidate: 3.0pl1-120ubuntu3 Version table: *** 3.0pl1-120ubuntu3 0 500 http://us.archive.ubuntu.com/ubuntu/ precise/main amd64 Packages 100 /var/lib/dpkg/status To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/cron/+bug/985924/+subscriptions -- Mailing list: https://launchpad.net/~touch-packages Post to : touch-packages@lists.launchpad.net Unsubscribe : https://launchpad.net/~touch-packages More help : https://help.launchpad.net/ListHelp
[Touch-packages] [Bug 1148594] Re: [12.04] crontab -e is not showing PATH in the example, so the example with tar will fail
The man page for crontab(5) states that PATH is initialized with /usr/bin:/bin, so the tar invocation in the example is correct. Or did I misunderstand your question? -- You received this bug notification because you are a member of Ubuntu Touch seeded packages, which is subscribed to cron in Ubuntu. https://bugs.launchpad.net/bugs/1148594 Title: [12.04] crontab -e is not showing PATH in the example, so the example with tar will fail Status in “cron” package in Ubuntu: New Bug description: crontab -e is showing # # Each task to run has to be defined through a single line # indicating with different fields when the task will be run # and what command to run for the task # # To define the time you can provide concrete values for # minute (m), hour (h), day of month (dom), month (mon), # and day of week (dow) or use '*' in these fields (for 'any').# # Notice that tasks will be started based on the cron's system # daemon's notion of time and timezones. # # Output of the crontab jobs (including errors) is sent through # email to the user the crontab file belongs to (unless redirected). # # For example, you can run a backup of all your user accounts # at 5 a.m every week with: # 0 5 * * 1 tar -zcf /var/backups/home.tgz /home/ # # For more information see the manual pages of crontab(5) and cron(8) # # m h dom mon dow command There is no line with PATH but in the example tar is used (instead of /bin/tar), so the example should be include PATH or /bin/tar instead of tar ProblemType: Bug DistroRelease: Ubuntu 12.04 Package: cron 3.0pl1-120ubuntu4 ProcVersionSignature: Ubuntu 3.2.0-38.61-generic 3.2.37 Uname: Linux 3.2.0-38-generic x86_64 ApportVersion: 2.0.1-0ubuntu17.1 Architecture: amd64 Date: Wed Mar 6 06:01:04 2013 EcryptfsInUse: Yes InstallationMedia: Ubuntu 12.04 LTS Precise Pangolin - Release amd64 (20120425) MarkForUpload: True ProcEnviron: TERM=xterm PATH=(custom, no user) LANG=de_DE.UTF-8 SHELL=/bin/bash SourcePackage: cron UpgradeStatus: Upgraded to precise on 2013-01-15 (49 days ago) To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/cron/+bug/1148594/+subscriptions -- Mailing list: https://launchpad.net/~touch-packages Post to : touch-packages@lists.launchpad.net Unsubscribe : https://launchpad.net/~touch-packages More help : https://help.launchpad.net/ListHelp
[Touch-packages] [Bug 1280808] Re: Support for afterwards execution of missing jobs
The feature you are describing is the exact purpose of anacron. Could you elaborate what you mean by hasn't the precision of cron? What can cron do that you can't do with /etc/anacrontab? BTW, it doesn't make sense for anacron to be a full-time daemon, because when the system is up, you already have the cron daemon executing your jobs. -- You received this bug notification because you are a member of Ubuntu Touch seeded packages, which is subscribed to cron in Ubuntu. https://bugs.launchpad.net/bugs/1280808 Title: Support for afterwards execution of missing jobs Status in “cron” package in Ubuntu: New Bug description: I'm using Ubuntu 14.04 dev with cron 3.0pl1-124ubuntu2 and maybe cron can get the ability to run missing jobs on booting like anacron. The question why I'm not using anacron: It has limitations as it is not a full time deamon and hasn't the precision of cron. For example if I'm defining a job to run every day at 02:30 but the computer gets a power loss at 2:29 and is online at 2:31 it would be nice if cron does calculate on startup if there were jobs that had to be executed. For this case cron needs to store the last execution time of a job and an extra column on the job entry as option list to en-/disable this feature. To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/cron/+bug/1280808/+subscriptions -- Mailing list: https://launchpad.net/~touch-packages Post to : touch-packages@lists.launchpad.net Unsubscribe : https://launchpad.net/~touch-packages More help : https://help.launchpad.net/ListHelp
[Touch-packages] [Bug 1316036] Re: cron package does not install MTA
Apparently the MTA dependency in Ubuntu's cron has been demoted from Recommends (as it is in Debian), to a Suggests, so this bug should be re-assigned to Ubuntu's installation documentation. -- You received this bug notification because you are a member of Ubuntu Touch seeded packages, which is subscribed to cron in Ubuntu. https://bugs.launchpad.net/bugs/1316036 Title: cron package does not install MTA Status in “cron” package in Ubuntu: New Bug description: I just did a fresh install of trusty and deliberately made a failing entry in the crontab: * * * * * mkdir /qwer/qwer In /var/syslog, this results in: May 4 16:04:01 dekker CRON[2395]: (root) CMD (mkdir /qwer/qwer) May 4 16:04:01 dekker CRON[2394]: (CRON) info (No MTA installed, discarding output) When I look in the documentation (https://help.ubuntu.com/14.04 /installation-guide/amd64/ch08s05.html), it says: For this reason the packages exim4 and mutt will be installed by default (provided you did not unselect the “standard” task during the installation). exim4 is a combination MTA/MDA that is relatively small but very flexible. By default it will be configured to only handle e-mail local to the system itself and e-mails addressed to the system administrator (root account) will be delivered to the regular user account created during the installation. Still, mutt and exim4 appear not to be installed, although I did not exclude or remove any packages. ProblemType: Bug DistroRelease: Ubuntu 14.04 Package: cron 3.0pl1-124ubuntu2 ProcVersionSignature: Ubuntu 3.13.0-24.46-generic 3.13.9 Uname: Linux 3.13.0-24-generic x86_64 ApportVersion: 2.14.1-0ubuntu3 Architecture: amd64 CurrentDesktop: XFCE Date: Mon May 5 09:52:04 2014 InstallationDate: Installed on 2014-03-26 (39 days ago) InstallationMedia: Xubuntu 14.04 LTS Trusty Tahr - Beta amd64 (20140325.1) SourcePackage: cron UpgradeStatus: No upgrade log present (probably fresh install) To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/cron/+bug/1316036/+subscriptions -- Mailing list: https://launchpad.net/~touch-packages Post to : touch-packages@lists.launchpad.net Unsubscribe : https://launchpad.net/~touch-packages More help : https://help.launchpad.net/ListHelp
[Touch-packages] [Bug 1277493] Re: MAILTO Environment Variable is ignored when set in a file in /etc/cron.d/
Could you check your MTA's log files (and /var/log/cron.*, if you have it) for clues as to what could be going on? I just tried this locally and it works fine: both mails are sent, and the MAILTO header is included. -- You received this bug notification because you are a member of Ubuntu Touch seeded packages, which is subscribed to cron in Ubuntu. https://bugs.launchpad.net/bugs/1277493 Title: MAILTO Environment Variable is ignored when set in a file in /etc/cron.d/ Status in “cron” package in Ubuntu: Confirmed Bug description: I have a cron job definition file with the following: # Runs every 5 minutes, logging into the proftpd database checking for expired accounts and disabling them. MAILTO=sysadmin@[redacted].com,io@[redacted].com */5 * * * * root/usr/local/sbin/proftpd-expire.sh Any output from the script ought to be emailed to both the sysadmin io group addresses, but instead output is always sent to 'root@[local FQDN]', presumably becasue the cron job is being executed as root. For some reason, the MAILTO environment variable is being ignored, as can be confirmed when looking at the email (sent to root) for all the X-cron-env headers: X-cron-env: SHELL=/bin/sh X-cron-env: HOME=/root X-cron-env: PATH=/usr/bin:/bin X-cron-env: LOGNAME=root There is clearly no MAILTO header in this email, and obviously the main proof is that this still only went to root@fqdn. All documentation appears to say that the combination of MAILTO and a file in /etc/cron.d/ should work. To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/cron/+bug/1277493/+subscriptions -- Mailing list: https://launchpad.net/~touch-packages Post to : touch-packages@lists.launchpad.net Unsubscribe : https://launchpad.net/~touch-packages More help : https://help.launchpad.net/ListHelp
[Touch-packages] [Bug 1148594] Re: [12.04] crontab -e is not showing PATH in the example, so the example with tar will fail
OK, closing then. Thank you for your quick reply! ** Changed in: cron (Ubuntu) Status: New = Invalid -- You received this bug notification because you are a member of Ubuntu Touch seeded packages, which is subscribed to cron in Ubuntu. https://bugs.launchpad.net/bugs/1148594 Title: [12.04] crontab -e is not showing PATH in the example, so the example with tar will fail Status in “cron” package in Ubuntu: Invalid Bug description: crontab -e is showing # # Each task to run has to be defined through a single line # indicating with different fields when the task will be run # and what command to run for the task # # To define the time you can provide concrete values for # minute (m), hour (h), day of month (dom), month (mon), # and day of week (dow) or use '*' in these fields (for 'any').# # Notice that tasks will be started based on the cron's system # daemon's notion of time and timezones. # # Output of the crontab jobs (including errors) is sent through # email to the user the crontab file belongs to (unless redirected). # # For example, you can run a backup of all your user accounts # at 5 a.m every week with: # 0 5 * * 1 tar -zcf /var/backups/home.tgz /home/ # # For more information see the manual pages of crontab(5) and cron(8) # # m h dom mon dow command There is no line with PATH but in the example tar is used (instead of /bin/tar), so the example should be include PATH or /bin/tar instead of tar ProblemType: Bug DistroRelease: Ubuntu 12.04 Package: cron 3.0pl1-120ubuntu4 ProcVersionSignature: Ubuntu 3.2.0-38.61-generic 3.2.37 Uname: Linux 3.2.0-38-generic x86_64 ApportVersion: 2.0.1-0ubuntu17.1 Architecture: amd64 Date: Wed Mar 6 06:01:04 2013 EcryptfsInUse: Yes InstallationMedia: Ubuntu 12.04 LTS Precise Pangolin - Release amd64 (20120425) MarkForUpload: True ProcEnviron: TERM=xterm PATH=(custom, no user) LANG=de_DE.UTF-8 SHELL=/bin/bash SourcePackage: cron UpgradeStatus: Upgraded to precise on 2013-01-15 (49 days ago) To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/cron/+bug/1148594/+subscriptions -- Mailing list: https://launchpad.net/~touch-packages Post to : touch-packages@lists.launchpad.net Unsubscribe : https://launchpad.net/~touch-packages More help : https://help.launchpad.net/ListHelp
[Touch-packages] [Bug 1337576] Re: dash inability - cron starts binary with /bin/sh
Perhaps I should have been more clearer: the POSIX standard mandates that the command field (that's everything in the sixth column of a crontab file) be passed as arguments to /bin/sh: | The sixth field of a line in a crontab entry is a string | that shall be executed by sh at the specified times. Therefore, this cannot be changed. Furthermore, exec'ing the command directly would severely break existing crontabs. Take the following entry for example, which utilizes output redirection: 15 * * * * df -h $HOME/disk.log As you correctly identified, /bin/sh points to /bin/dash. But you can point that to any other Bourne-compatible shell, eg bash, if you want. ** Changed in: cron (Ubuntu) Status: New = Invalid -- You received this bug notification because you are a member of Ubuntu Touch seeded packages, which is subscribed to cron in Ubuntu. https://bugs.launchpad.net/bugs/1337576 Title: dash inability - cron starts binary with /bin/sh Status in “cron” package in Ubuntu: Invalid Bug description: -- Problem Description -- CRON uses shell to start a binary executable defined in crontab, which is a waste of the resources for the extra shell process hanging in the system. It's supposed to run it directly with exec system call. *** Here are some command outputs to see the extra process(12327) and relevant information: *** # ps -ef | grep -e CRON -e PMLnx root 12326 771 0 13:59 ?00:00:00 CRON root 12327 12326 0 13:59 ?00:00:00 /bin/sh -c /var/perf/pm/bin/daemon_PMLnx --- extra layer, a waste root 12328 12327 0 13:59 ?00:00:00 /var/perf/pm/bin/daemon_PMLnx # crontab -l 59 * * * * /var/perf/pm/bin/daemon_PMLnx # file /var/perf/pm/bin/daemon_PMLnx /var/perf/pm/bin/daemon_PMLnx: ELF 64-bit LSB executable, 64-bit PowerPC or cisco 7500, version 1 (SYSV), dynamically linked (uses shared libs), for GNU/Linux 3.0.0, BuildID[sha1]=1761d6d97eabb4e52870cb517fe6bf457e5bf89e, stripped # uname -a Linux ubuntu 3.13.0-24-generic #46-Ubuntu SMP Thu Apr 10 19:09:21 UTC 2014 ppc64le ppc64le ppc64le GNU/Linux # dpkg -l cron Name VersionArchitecture Description +++-=-==-=-= ii cron 3.0pl1-124ubuntu2 ppc64el process scheduling daemon *** Expect cron to directly execute a binary like this *** # ps -ef | grep -e CRON -e PMLnx root 2293 2223 0 09:59 ?00:00:00 /usr/sbin/CRON -n root 2294 2293 0 09:59 ?00:00:00 /var/perf/pm/bin/daemon_PMLnx # uname -a Linux hulala 3.12.15-3-default #1 SMP Wed Apr 2 17:08:55 UTC 2014 (69c2ea8) ppc64le ppc64le ppc64le GNU/Linux # cat /etc/SuSE-release SUSE Linux Enterprise Server 12 (ppc64le) VERSION = 12 PATCHLEVEL = 0 To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/cron/+bug/1337576/+subscriptions -- Mailing list: https://launchpad.net/~touch-packages Post to : touch-packages@lists.launchpad.net Unsubscribe : https://launchpad.net/~touch-packages More help : https://help.launchpad.net/ListHelp
[Touch-packages] [Bug 1337576] Re: dash inability - cron starts binary with /bin/sh
Re-assigning to dash then. ** Package changed: cron (Ubuntu) = dash (Ubuntu) -- You received this bug notification because you are a member of Ubuntu Touch seeded packages, which is subscribed to cron in Ubuntu. https://bugs.launchpad.net/bugs/1337576 Title: dash inability - cron starts binary with /bin/sh Status in “dash” package in Ubuntu: New Bug description: -- Problem Description -- CRON uses shell to start a binary executable defined in crontab, which is a waste of the resources for the extra shell process hanging in the system. It's supposed to run it directly with exec system call. *** Here are some command outputs to see the extra process(12327) and relevant information: *** # ps -ef | grep -e CRON -e PMLnx root 12326 771 0 13:59 ?00:00:00 CRON root 12327 12326 0 13:59 ?00:00:00 /bin/sh -c /var/perf/pm/bin/daemon_PMLnx --- extra layer, a waste root 12328 12327 0 13:59 ?00:00:00 /var/perf/pm/bin/daemon_PMLnx # crontab -l 59 * * * * /var/perf/pm/bin/daemon_PMLnx # file /var/perf/pm/bin/daemon_PMLnx /var/perf/pm/bin/daemon_PMLnx: ELF 64-bit LSB executable, 64-bit PowerPC or cisco 7500, version 1 (SYSV), dynamically linked (uses shared libs), for GNU/Linux 3.0.0, BuildID[sha1]=1761d6d97eabb4e52870cb517fe6bf457e5bf89e, stripped # uname -a Linux ubuntu 3.13.0-24-generic #46-Ubuntu SMP Thu Apr 10 19:09:21 UTC 2014 ppc64le ppc64le ppc64le GNU/Linux # dpkg -l cron Name VersionArchitecture Description +++-=-==-=-= ii cron 3.0pl1-124ubuntu2 ppc64el process scheduling daemon *** Expect cron to directly execute a binary like this *** # ps -ef | grep -e CRON -e PMLnx root 2293 2223 0 09:59 ?00:00:00 /usr/sbin/CRON -n root 2294 2293 0 09:59 ?00:00:00 /var/perf/pm/bin/daemon_PMLnx # uname -a Linux hulala 3.12.15-3-default #1 SMP Wed Apr 2 17:08:55 UTC 2014 (69c2ea8) ppc64le ppc64le ppc64le GNU/Linux # cat /etc/SuSE-release SUSE Linux Enterprise Server 12 (ppc64le) VERSION = 12 PATCHLEVEL = 0 To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/dash/+bug/1337576/+subscriptions -- Mailing list: https://launchpad.net/~touch-packages Post to : touch-packages@lists.launchpad.net Unsubscribe : https://launchpad.net/~touch-packages More help : https://help.launchpad.net/ListHelp