LinuxQuestions.org
Latest LQ Deal: Linux Power User Bundle
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 08-29-2012, 10:12 AM   #1
ruskie77
LQ Newbie
 
Registered: Aug 2012
Posts: 3

Rep: Reputation: Disabled
Cron Deamon Problem


Hi everyone, I'm a real newb, and could do with a little help.

I have a linux web server (a vps) and everything is running just fine, I don't tend to mess about with things too much.

anyway. A couple of days ago my administrator email account has started recieving emails like this (every 20 minutes!)

subject:
Cron <smmsp@mydomain> test -x /etc/init.d/sendmail && /usr/share/sendmail/sendmail cron-msp

message
mkdir: cannot create directory '/var/run/sendmail': Permission denied



Ok, I've had a good search around and I think I've been breached. I cannot find any scheduled tasks anywhere (I certainly havn't set any up) and I cannot find the cron script to remove it.

Any help would be really really good as my email goes ping every 20 minutes with the same email!

of course, I've changed all of my access passwords and updated the server software, just in case I have been breached.

Thanks in advance
 
Old 08-29-2012, 11:10 AM   #2
colucix
LQ Guru
 
Registered: Sep 2003
Location: Bologna
Distribution: CentOS 6.5 OpenSuSE 12.3
Posts: 10,509

Rep: Reputation: 1978Reputation: 1978Reputation: 1978Reputation: 1978Reputation: 1978Reputation: 1978Reputation: 1978Reputation: 1978Reputation: 1978Reputation: 1978Reputation: 1978
Hi and welcome to LinuxQuestions!

I don't think your system has been breached: have you looked for a crontab script in /etc/cron.d/? Is there a file named "sendmail" inside it?

Please, provide as many details as possible about your issue (Linux OS, sendmail version and so on). If it turns out that it's really a security issue, take in mind that you can report your own post and ask a moderator to move it into the Linux - Security forum (anyway, I think Linux - Server could be a more suitable place).
 
Old 08-29-2012, 11:24 AM   #3
ruskie77
LQ Newbie
 
Registered: Aug 2012
Posts: 3

Original Poster
Rep: Reputation: Disabled
Smile

Yes there is.
Most of it is commented out (I assume that starting a line with a # comments it)
the only bit that isn't commented out is,

#------------------------------------------------------------------------------
# Every so often, give sendmail a chance to run the MSP queues.
#
*/20 * * * * smmsp test -x /etc/init.d/sendmail && /usr/share/sendmail/sendmail cron-msp
#
#------------------------------------------------------------------------------
# Every so often, give sendmail a chance to run the MTA queues.
# Will also run MSP queues if enabled
#
#*/10 * * * * root test -x /etc/init.d/sendmail && /usr/share/sendmail/sendmail cron-mta
#
#------------------------------------------------------------------------------

which I guess is the instruction for it to send something every 20 minutes.
The only other line that's not commented is further up in the file,
MAILTO=root

that's it really... I can't see why this would suddenly cause a problem out of the blue, considering that I've not changed any folder permissions, or adjusted this file.

In the meantime I'll try commenting out that */20 line for now and see if that's a quick fix, but I am intruiged as to why it just started happening.


Thanks for your help!
 
Old 08-30-2012, 04:21 AM   #4
ruskie77
LQ Newbie
 
Registered: Aug 2012
Posts: 3

Original Poster
Rep: Reputation: Disabled
Well, for those of you that have a similar problem, commenting out that line did stop the emails from coming in...
Still a mystery as to why it all began though!

many thanks to colucix for his pointing me in the right direction
 
Old 08-30-2012, 07:07 AM   #5
segmentation_fault
Member
 
Registered: Sep 2008
Location: Ioannina, Greece
Distribution: Gentoo
Posts: 332

Rep: Reputation: 55
I think the script is fine the way it was. The problem is with the permissions of /var/run/sendmail
Could you post the output of
Code:
$ ls -l /var/run/sendmail
 
Old 07-14-2013, 11:29 AM   #6
thomassisson
LQ Newbie
 
Registered: Oct 2012
Location: Indianapolis, IN USA
Distribution: Ubuntu 12.04
Posts: 4

Rep: Reputation: 0
Output of ls -l /var/run/sendmail permissions for Sendmail program

Quote:
Originally Posted by segmentation_fault View Post
I think the script is fine the way it was. The problem is with the permissions of /var/run/sendmail
Could you post the output of
Code:
$ ls -l /var/run/sendmail
Since no one has responded to your request and no one else seems to understand the problem, I will post mine in hopes that you can help. This question is posted all over the Internet, but I have yet to find the solution.

Code:
$ ls -l /var/run/sendmail
total 0
drwxrwsr-x 2 smmsp smmsp  40 Jul 13 23:54 msp
drwxr-sr-x 2 root  smmta 100 Jul 14 11:39 mta
drwxrwsr-x 2 root  smmsp  60 Jul 14 12:21 stampdir
and just in case

Code:
$ ls -l /var/run
...
drwxr-sr-x 5 root       smmta       100 Jul 13 23:54 sendmail
...
 
  


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
CRON deamon lockup during startup. Dr.Jamescook SUSE / openSUSE 0 11-11-2004 08:56 PM
starting talk deamon on redhat 9.0 gives a problem , entries were made in xinetd ssharma_02 Linux - Networking 1 09-07-2004 01:23 PM
Cron deamon? eXor Slackware 4 07-02-2003 11:55 AM
[cron][mdk9.1]cron deamon seems to ignore some task... yannrichet Linux - Newbie 5 06-26-2003 09:57 AM
cron Deamon DJFauß Linux - General 2 01-22-2002 03:32 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

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