Solved

how to disable crontab?

Posted on 2001-08-05
5
2,970 Views
Last Modified: 2009-02-06
I don't want to allow users to use crontab in linux server.
what can i do?
0
Comment
Question by:stanleyhuen
5 Comments
 
LVL 17

Expert Comment

by:dorward
ID: 6353736
The easiest way is to uninstall it!

How you do this depends on which distro you use.
0
 
LVL 40

Accepted Solution

by:
jlevie earned 20 total points
ID: 6354171
Easy, only list the users that should be able to have crontabs in /etc/cron.allow. If that file exists and has one or more names in it any users not listed in the file will not be allowed to create crontab files. For more information see "man crontab".
0
 
LVL 2

Expert Comment

by:olidel
ID: 6355931
Hi,

    Another way not very elegant but ...   If you don' run the crond daemon, nothing will happen.

Hope this help.

Bye

0
 
LVL 3

Expert Comment

by:mrn060900
ID: 6356037
or you could move /usr/bin/crontab to crontab.old

Regards Mike

www.unixonline.co.uk
0
 
LVL 40

Expert Comment

by:jlevie
ID: 6356379
The problem with removing crond or otherwise inactivating it is that you break other things, like log file rolling and other cleanup activities. The preferred solution is simply to restrict access. That's why there are cron.allow and cron.deny files.
0

Featured Post

Three Reasons Why Backup is Strategic

Backup is strategic to your business because your data is strategic to your business. Without backup, your business will fail. This white paper explains why it is vital for you to design and immediately execute a backup strategy to protect 100 percent of your data.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

This article will explain how to establish a SSH connection to Ubuntu through the firewall and using a different port other then 22. I have set up a Ubuntu virtual machine in Virtualbox and I am running a Windows 7 workstation. From the Ubuntu vi…
Fine Tune your automatic Updates for Ubuntu / Debian
Learn how to get help with Linux/Unix bash shell commands. Use help to read help documents for built in bash shell commands.: Use man to interface with the online reference manuals for shell commands.: Use man to search man pages for unknown command…
Learn how to navigate the file tree with the shell. Use pwd to print the current working directory: Use ls to list a directory's contents: Use cd to change to a new directory: Use wildcards instead of typing out long directory names: Use ../ to move…

679 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question