Bug#617898: cron.d snippets have different default PATH from crontab/cron.{daily,...}

2023-08-27 Thread Georges Khaznadar
Hello, this bug report is now twelve years old.

As root users are supposed to read manpages of important commands, they
are aware of the possibility to define environment variables like PATH
in crontab files.

So, I consider this bug as fixed, per the manpages.

Best regards,   Georges.

Josip Rodin a écrit :
> severity 617898 normal
> thanks
> 
> Hi,
> 
> Recently I added a logrotate setup that was very similar to apache2's, but
> I ran it from a cron.d file, and it obviously failed because the normal
> logrotate runs from /etc/crontab, which has a different PATH set.
> 
> I think this is not a wishlist item to change this, rather it is a genuine
> bug, because I don't see the actual rationale for the behavior of
> /etc/crontab and cron(8) to differ in such a fundamental way, and it's
> clearly causing a number of users to have to amend their cron.d files
> in a way that is redundant and error-prone (having to redefine PATH
> everywhere reminds me of the dark days of 1990s Unix systems, and it is
> NOT something we want to replicate ever again).
> 
> I certainly don't see a downside with adding the sbin variants, because
> on Debian systems they're expected to be as reliable as bin variants,
> and there should be no confusing overlaps.
> 
> For local, an argument could be made that it exposes a possibility of
> problems with random local binaries getting in the way, but it would
> still probably be better to do this kind of a transition to get everything
> consistent. Random complexity just leads to more trouble.
> 
> Please fix this. TIA.
> 
> -- 
> Josip Rodin
> 

-- 
Georges KHAZNADAR et Jocelyne FOURNIER
22 rue des mouettes, 59240 Dunkerque France.
Téléphone +33 (0)3 28 29 17 70



signature.asc
Description: PGP signature


Bug#617898: cron.d snippets have different default PATH from crontab/cron.{daily,...}

2020-06-04 Thread Josip Rodin
severity 617898 normal
thanks

Hi,

Recently I added a logrotate setup that was very similar to apache2's, but
I ran it from a cron.d file, and it obviously failed because the normal
logrotate runs from /etc/crontab, which has a different PATH set.

I think this is not a wishlist item to change this, rather it is a genuine
bug, because I don't see the actual rationale for the behavior of
/etc/crontab and cron(8) to differ in such a fundamental way, and it's
clearly causing a number of users to have to amend their cron.d files
in a way that is redundant and error-prone (having to redefine PATH
everywhere reminds me of the dark days of 1990s Unix systems, and it is
NOT something we want to replicate ever again).

I certainly don't see a downside with adding the sbin variants, because
on Debian systems they're expected to be as reliable as bin variants,
and there should be no confusing overlaps.

For local, an argument could be made that it exposes a possibility of
problems with random local binaries getting in the way, but it would
still probably be better to do this kind of a transition to get everything
consistent. Random complexity just leads to more trouble.

Please fix this. TIA.

-- 
Josip Rodin