Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[solved] sysstat - cron problem
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Desktop Environments
View previous topic :: View next topic  
Author Message
kajzer
Guru
Guru


Joined: 27 Nov 2014
Posts: 373

PostPosted: Fri Mar 09, 2018 11:25 am    Post subject: [solved] sysstat - cron problem Reply with quote

[Moderator note: updated title to reflect the true solution; original title was Non root Xorg - cron problem. -Hu]

I followed this guide : https://wiki.gentoo.org/wiki/Non_root_Xorg
all is well except that every 10 minutes I get email :

Code:
Subject: cron for user root root /usr/lib64/sa/sa1 1 1

/bin/sh: root: command not found


I'm using dcron, I didn't change anything regarding that or anything other than what's in that guide.
It's getting pretty annoying, any ideas how to solve this ?


Last edited by kajzer on Fri Mar 09, 2018 4:37 pm; edited 1 time in total
Back to top
View user's profile Send private message
steve_v
Tux's lil' helper
Tux's lil' helper


Joined: 20 Jun 2004
Posts: 113
Location: New Zealand

PostPosted: Fri Mar 09, 2018 1:33 pm    Post subject: Re: Non root Xorg - cron problem Reply with quote

kajzer wrote:
ISubject: cron for user root root /usr/lib64/sa/sa1 1 1
That's a sysstat cronjob, nothing to do with Xorg that I can fathom.
kajzer wrote:
/bin/sh: root: command not found
And it appears to have a spurious "root" at the start of the command line.
Grep for it in /etc and fix it.
Back to top
View user's profile Send private message
kajzer
Guru
Guru


Joined: 27 Nov 2014
Posts: 373

PostPosted: Fri Mar 09, 2018 2:06 pm    Post subject: Reply with quote

I understand that it has nothing to do with running Xorg as user, but somehow it does, as that's the only change that was done.

Anyway, seems like this is where the problem was :
Code:
/etc/cron.d/sysstat


I've deleted root from the line below :

Code:
# Run system activity accounting tool every 10 minutes
*/10 * * * * root /usr/lib64/sa/sa1 1 1
Back to top
View user's profile Send private message
mike155
l33t
l33t


Joined: 17 Sep 2010
Posts: 998
Location: Frankfurt, Germany

PostPosted: Fri Mar 09, 2018 2:46 pm    Post subject: Reply with quote

Quote:
I've deleted root from the line below:

I'm not an dcron expert. But according to the man-page I could grab, removing 'root' is the right thing to do. If you used vixie-cron instead, you would better not remove it...

Anyway: do you need the sysstat statistics at all? If not, comment out the whole line. That's what I do. I install sysstat to get the program 'iostat'. But I don't need the statistics-generator, so I comment out the whole line in the cron file.
Back to top
View user's profile Send private message
kajzer
Guru
Guru


Joined: 27 Nov 2014
Posts: 373

PostPosted: Fri Mar 09, 2018 4:46 pm    Post subject: Reply with quote

I don't need it.
I see now what happened, it has nothing to do with Xorg of course, I'm using i3wm with polybar, when I made that Xorg change only polybar refused to launch, segfaulting on launch in libfontconfig
Anyway, long story short, I couldn't figure out why is that happening so I decided to install i3blocks and solve polybar situation later, i3blocks has sysstat as dependency, which placed that sysstat cron job file.
That's why I connected that Xorg change with cron.

Thanks for all the help!
Back to top
View user's profile Send private message
Supersonic
n00b
n00b


Joined: 06 Apr 2019
Posts: 1

PostPosted: Sat Apr 06, 2019 2:49 pm    Post subject: Reply with quote

Sorry for bringing this somewhat old thread back up, but it's still an issue, so I thought I'd leave my findings here for others who might stumble about this:

The problem is known, apparently the cronjob included in sysstat is not compatible with dcron. For more info see https://bugs.gentoo.org/531032, where someone also submitted a user patch that changes the cron entries in /etc/cron.d/sysstat by removing the word "root" (compared to other cron demons, dcron doesn't support defining a user to run the job as).
Back to top
View user's profile Send private message
kajzer
Guru
Guru


Joined: 27 Nov 2014
Posts: 373

PostPosted: Sat Apr 06, 2019 7:57 pm    Post subject: Reply with quote

It's not just sysstat, I had this problem again with something else and I forgot about this thread completely.
Here's the recent one, solution is the same, remove 'root'
https://forums.gentoo.org/viewtopic-t-1094390-highlight-.html
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Desktop Environments All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum