LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 09-28-2009, 07:16 AM   #1
abefroman
Senior Member
 
Registered: Feb 2004
Location: lost+found
Distribution: CentOS
Posts: 1,430

Rep: Reputation: 55
Is there a way to list all crontabs for all users?


Is there a way to list all crontabs for all users?

crontab -l -u*
did not work

TIA
 
Old 09-28-2009, 07:20 AM   #2
GrapefruiTgirl
LQ Guru
 
Registered: Dec 2006
Location: underground
Distribution: Slackware64
Posts: 7,594

Rep: Reputation: 556Reputation: 556Reputation: 556Reputation: 556Reputation: 556Reputation: 556
Maybe:

sh-4.0# ls /var/spool/cron/crontabs

? Sasha
 
Old 09-28-2009, 07:27 AM   #3
pwc101
Senior Member
 
Registered: Oct 2005
Location: UK
Distribution: Slackware
Posts: 1,847

Rep: Reputation: 128Reputation: 128
I should think
Code:
less /var/spool/cron/crontabs/*
would work.
 
Old 09-28-2009, 07:28 AM   #4
druuna
LQ Veteran
 
Registered: Sep 2003
Posts: 10,532
Blog Entries: 7

Rep: Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405
Hi,

Minor detail: /var/spool/cron/crontabs

The bold part could be different depending on the crontab you are using. I use fcron and all resides in /var/spool/fcron (no subdir).

I'm not a centos user, but I do believe they use this convention: /var/spool/cron/<username>
 
Old 09-28-2009, 08:09 AM   #5
abefroman
Senior Member
 
Registered: Feb 2004
Location: lost+found
Distribution: CentOS
Posts: 1,430

Original Poster
Rep: Reputation: 55
Quote:
Originally Posted by druuna View Post
Hi,

I'm not a centos user, but I do believe they use this convention: /var/spool/cron/<username>
That is correct, thanks!
 
Old 09-28-2009, 10:14 PM   #6
Smartpatrol
Member
 
Registered: Sep 2009
Posts: 196

Rep: Reputation: 38
...

Last edited by Smartpatrol; 03-11-2010 at 09:36 PM.
 
Old 09-29-2009, 04:14 AM   #7
chandramani_yadav
Member
 
Registered: Jan 2007
Location: Vienna
Distribution: Redhat
Posts: 47

Rep: Reputation: 19
for user in $(cut -f1 -d: /etc/passwd); do crontab -u $user -l; done
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Crontabs usmansamad Linux - Newbie 2 07-29-2009 08:05 AM
How can I let non-root users build crontabs? dthacker SUSE / openSUSE 2 06-02-2006 03:22 PM
List all users eam Linux - Newbie 7 05-15-2005 11:55 PM
Whats the difference between all the crontabs (system, root, users) ? glenn69 Linux - Newbie 2 10-12-2004 07:41 PM
Crontabs kd5giv Slackware 8 05-08-2004 04:37 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 02:19 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration