From: andrew on
Hi,

I am using Leafnode 2 on Slackware 12 and have a user 'news'. All is
working well but for some reason news will not do the following cron
jobs:

10 21 * * * /usr/sbin/texpire -vvv >/home/andrew/.texpirelog 2>&1
15 * * * * /usr/sbin/fetchnews -vvv >/home/andrew/.fetchnewslog 2>&1

But this works flawlessly as a /root/ crontab. I do /not/ have a
cron.allow or .deny file and I am more than a little puzzled as to why
this does not work. I can set a crontab for myself as a user quite
easily.

Any thoughts?

Andrew

PS I have posted a similar question on Linuxquestions.org and I hope
this does not count as multi-posting.
--
http://www.andrews-corner.org
From: Grant on
On Wed, 23 Jan 2008 18:09:01 +1100, andrew <andrew(a)ilium.invalid> wrote:

>Hi,
>
>I am using Leafnode 2 on Slackware 12 and have a user 'news'. All is
>working well but for some reason news will not do the following cron
>jobs:
>
>10 21 * * * /usr/sbin/texpire -vvv >/home/andrew/.texpirelog 2>&1
>15 * * * * /usr/sbin/fetchnews -vvv >/home/andrew/.fetchnewslog 2>&1
>
>But this works flawlessly as a /root/ crontab. I do /not/ have a
>cron.allow or .deny file and I am more than a little puzzled as to why
>this does not work. I can set a crontab for myself as a user quite
>easily.
>
>Any thoughts?

Permissions? You're mixing 'news' with 'andrew', do the commands work
when manually invoked?

Grant.
--
http://bugsplatter.mine.nu/
From: andrew on
On 2008-01-23, Grant <g_r_a_n_t_(a)dodo.com.au> wrote:
> On Wed, 23 Jan 2008 18:09:01 +1100, andrew <andrew(a)ilium.invalid> wrote:

>>I am using Leafnode 2 on Slackware 12 and have a user 'news'. All is
>>working well but for some reason news will not do the following cron
>>jobs:
>>
>>10 21 * * * /usr/sbin/texpire -vvv >/home/andrew/.texpirelog 2>&1
>>15 * * * * /usr/sbin/fetchnews -vvv >/home/andrew/.fetchnewslog 2>&1
>>
>>But this works flawlessly as a /root/ crontab. I do /not/ have a
>>cron.allow or .deny file and I am more than a little puzzled as to why
>>this does not work. I can set a crontab for myself as a user quite
>>easily.

[...]

> Permissions? You're mixing 'news' with 'andrew', do the commands work
> when manually invoked?

Thanks Grant, you have hit the nail on the head and I curse myself for
not having seen this sooner. 'news' could not access the log which was
owned by 'andrew'with permissions 600. Once I changed the permissions
all was well.

Thanks,

Andrew
--
http://www.andrews-corner.org
From: Scott McMillan on
On Wed, 23 Jan 2008 18:09:01 +1100, andrew <andrew(a)ilium.invalid>
wrote:

>Hi,
>
>I am using Leafnode 2 on Slackware 12 and have a user 'news'. All is
>working well but for some reason news will not do the following cron
>jobs:
>
>10 21 * * * /usr/sbin/texpire -vvv >/home/andrew/.texpirelog 2>&1
>15 * * * * /usr/sbin/fetchnews -vvv >/home/andrew/.fetchnewslog 2>&1
>
>But this works flawlessly as a /root/ crontab. I do /not/ have a
>cron.allow or .deny file and I am more than a little puzzled as to why
>this does not work. I can set a crontab for myself as a user quite
>easily.
>
>Any thoughts?
>
> Andrew
>
>PS I have posted a similar question on Linuxquestions.org and I hope
>this does not count as multi-posting.

Does your 'news' user have execute permissions for /usr/sbin/texpire
and /usr/sbin/fetchnews?

Does your 'news' user have write permissions within /home/andrew? And,
if they already exist, write permissions on /home/andrew/.texpirelog
and /home/andrew/.fetchnewslog?

Does /var/log/cron give any clues?


Scott McMillan
From: andrew on
On 2008-01-23, Scott McMillan <smcmillan(a)twmi.rr.com> wrote:
> On Wed, 23 Jan 2008 18:09:01 +1100, andrew <andrew(a)ilium.invalid>
> wrote:

>>I am using Leafnode 2 on Slackware 12 and have a user 'news'. All is
>>working well but for some reason news will not do the following cron
>>jobs:
>>
>>10 21 * * * /usr/sbin/texpire -vvv >/home/andrew/.texpirelog 2>&1
>>15 * * * * /usr/sbin/fetchnews -vvv >/home/andrew/.fetchnewslog 2>&1

[...]

> Does your 'news' user have write permissions within /home/andrew? And,
> if they already exist, write permissions on /home/andrew/.texpirelog
> and /home/andrew/.fetchnewslog?

Exactly! This turned out to be the problem: 'news' did not have
permission to write the log. This has now been rectified and all is
running smoothly.

Thanks for your trouble,

Andrew

--
http://www.andrews-corner.org