Suse/NovellThis Forum is for the discussion of Suse Linux.
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Introduction to Linux - A Hands on Guide
This guide was created as an overview of the Linux Operating System, geared toward new users as an exploration tour and getting started guide, with exercises at the end of each chapter.
For more advanced trainees it can be a desktop reference, and a collection of the base knowledge needed to proceed with system and network administration. This book contains many real life examples derived from the author's experience as a Linux system and network administrator, trainer and consultant. They hope these examples will help you to get a better understanding of the Linux system and that you feel encouraged to try out things on your own.
Click Here to receive this Complete Guide absolutely free.
Trying to add this to my root's cron but it does not work.
All i get is this bash: syntax error near unexpected token `('
Any help would be great
If you want to get the output of chkrootkit once a day per email at 3 am you can put the following line in root's cron file (the location depends on your distribution; under Debian it is under /var/spool/cron/crontabs/root; you might also find it under /var/spool/cron/tabs/root or something similar):
First of all, I don't think you should edit the file straight away; use crontab -e instead, as root. Second, why are there "(" and ")"? I suppose you don't need them. To me it looks like that should work without them..
0 3 * * * cd /usr/local/chkrootkit; ./chkrootkit 2>&1 | mail -s "chkrootkit output" firstname.lastname@example.org
That does the job I'm quite sure. I have no clue where you got the "()" around it..
EDIT: unless the writer of the "help" text wanted you to notice that the whole thing inside "(" and ")" was the cron job to be run, so you wouldn't be confused about the semicolons or anything..well sounds stupid but that's all I can think of.
Just run crontab -e as root and write the above (quoted) line there, save and that's it. If you use VI as you probably do, then after running "crontab -e" you get the file open, press down-arrow until you're at the last line, then press shift-a to go to Append mode, press ENTER to start a new line and write the above (quoted) line there. If the file is empty, just press shift-a and start typing. When you've written it, press ESC button once (or twice if you're unsure, you should hear a beep) and type :wq and press ENTER to save and exit. You're done.