LinuxQuestions.org
View the Most Wanted LQ Wiki articles.
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, 08:16 AM   #1
abefroman
Senior Member
 
Registered: Feb 2004
Location: Chicago
Distribution: CentOS
Posts: 1,277

Rep: Reputation: 53
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, 08:20 AM   #2
GrapefruiTgirl
Guru
 
Registered: Dec 2006
Location: underground
Distribution: Slackware64
Posts: 7,594

Rep: Reputation: 550Reputation: 550Reputation: 550Reputation: 550Reputation: 550Reputation: 550
Maybe:

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

? Sasha
 
Old 09-28-2009, 08: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, 08:28 AM   #4
druuna
LQ Veteran
 
Registered: Sep 2003
Posts: 10,532
Blog Entries: 7

Rep: Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374
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, 09:09 AM   #5
abefroman
Senior Member
 
Registered: Feb 2004
Location: Chicago
Distribution: CentOS
Posts: 1,277

Original Poster
Rep: Reputation: 53
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, 11:14 PM   #6
Smartpatrol
Member
 
Registered: Sep 2009
Posts: 196

Rep: Reputation: 38
...

Last edited by Smartpatrol; 03-11-2010 at 10:36 PM.
 
Old 09-29-2009, 05: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 09:05 AM
How can I let non-root users build crontabs? dthacker Suse/Novell 2 06-02-2006 04:22 PM
List all users eam Linux - Newbie 7 05-16-2005 12:55 AM
Whats the difference between all the crontabs (system, root, users) ? glenn69 Linux - Newbie 2 10-12-2004 08:41 PM
Crontabs kd5giv Slackware 8 05-08-2004 05:37 AM


All times are GMT -5. The time now is 07:53 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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration