Community Forums
Connect with us on LinkedIn
Community Notice
+ Reply to Thread
Page 1 of 2 1 2 LastLast
Results 1 to 15 of 18
  1. #1
    Secret Agent
    Guest

    Default bad cronjob

    I believe there is a bad cronjob on my server but how do I search server wide via ssh for the crobjob? I know it affects the server entirely (down) around 2am every sunday morning. Where can I find this?

  2. #2
    Member sawbuck's Avatar
    Join Date
    Jan 2004
    Posts
    1,310
    cPanel/Enkompass Access Level

    Root Administrator

    Default

    From the prompt try "crontab -e". Cron job files are in /var/spool/cron

  3. #3
    Secret Agent
    Guest

    Default

    Thank you.

  4. #4
    Member
    Join Date
    Jun 2004
    Location
    Columbus, OH
    Posts
    113

    Default

    /var/cron/tabs for FreeBSD and other BSD systems.

    Thanks
    -Seth

  5. #5
    Secret Agent
    Guest

    Default

    Now I have this major problem (reason why I am checking cronbjobs). I am getting tons of emails regarding some eggdrop of some sort. I am not sure why because that is disabled (or should I say prevented) in WHM (checked) as running processes.

    I ran cronbtab -e again and got this:


    2,58 * * * * /usr/local/bandmin/bandmin
    0 0 * * * /usr/local/bandmin/ipaddrmap
    15 2 * * * /scripts/upcp
    */15 * * * * /usr/local/cpanel/whostmgr/bin/dnsqueue > /dev/null 2>&1
    */5 * * * * /usr/local/cpanel/bin/dcpumon >/dev/null 2>&1
    0 6 * * * /scripts/exim_tidydb > /dev/null 2>&1


    /etc/cronbtab shows this:


    SHELL=/bin/bash
    PATH=/sbin:/bin:/usr/sbin:/usr/bin
    MAILTO=root
    HOME=/

    # run-parts
    01 * * * * root run-parts /etc/cron.hourly
    02 4 * * * root run-parts /etc/cron.daily
    22 4 * * 0 root run-parts /etc/cron.weekly
    42 4 1 * * root run-parts /etc/cron.monthly

    How do I track this bad crobjob doewn exactly?

  6. #6
    Member PWSowner's Avatar
    Join Date
    Nov 2001
    Location
    ON, Canada
    Posts
    2,994

    Default

    Users cron jobs are in /var/spool/cron. You may want to look at the files in there.
    Mike
    WHM and cPanel Scripts (join our "Scripts Club")
    D/A Photography

  7. #7
    Secret Agent
    Guest

    Default

    This is all I see in that directory:

    (null) cadenza
    (null) gvllweb
    (null) kelzclub
    (null) mailman
    (null) nibuhaho
    (null) nobody
    (null) outsider
    (null) pewter
    (null) root
    (null) terri
    (null) webhost


    What would I do now? (thanks in advance)

  8. #8
    Member PWSowner's Avatar
    Join Date
    Nov 2001
    Location
    ON, Canada
    Posts
    2,994

    Default

    You can look at each users cron job settings with:
    view /var/spool/cron/username

    exit with
    :q<enter>
    Mike
    WHM and cPanel Scripts (join our "Scripts Club")
    D/A Photography

  9. #9
    Secret Agent
    Guest

    Default

    Ok I got this:

    gvllweb
    --------

    # DO NOT EDIT THIS FILE - edit the master and reinstall.
    # (/home/gvllweb/.crontab installed on Mon Apr 19 00:06:17 2004)
    # (Cron version -- $Id: crontab.c,v 2.13 1994/01/17 03:20:37 vixie Exp $)
    0 * * * * http://domain.com/modules/MS_Analysi...aintenance.php

    cadenza
    ---------
    # DO NOT EDIT THIS FILE - edit the master and reinstall.
    # (/home/cadenza/.crontab installed on Wed Mar 3 22:52:11 2004)
    # (Cron version -- $Id: crontab.c,v 2.13 1994/01/17 03:20:37 vixie Exp $)
    MAILTO="cadenza"

    mailman
    ---------
    # DO NOT EDIT THIS FILE - edit the master and reinstall.
    # (/usr/local/cpanel/src/3rdparty/gpl/mailman-2.1.5/cron/crontab.in installed on Sun Oct 10 18:54:09 2004)
    # (Cron version -- $Id: crontab.c,v 2.13 1994/01/17 03:20:37 vixie Exp $)
    MAILTO=postmaster
    # At 8AM every day, mail reminders to admins as to pending requests.
    # They are less likely to ignore these reminders if they're mailed
    # early in the morning, but of course, this is local time...
    0 8 * * * /usr/bin/python2 -S /usr/local/cpanel/3rdparty/mailman/cron/checkdbs
    #
    # At 9AM, send notifications to disabled members that are due to be
    # reminded to re-enable their accounts.
    0 9 * * * /usr/bin/python2 -S /usr/local/cpanel/3rdparty/mailman/cron/disabled
    #
    # Noon, mail digests for lists that do periodic as well as threshhold delivery.
    0 12 * * * /usr/bin/python2 -S /usr/local/cpanel/3rdparty/mailman/cron/senddigests
    #
    # 5 AM on the first of each month, mail out password reminders.
    0 5 1 * * /usr/bin/python2 -S /usr/local/cpanel/3rdparty/mailman/cron/mailpasswds
    #
    # Every 5 mins, try to gate news to mail. You can comment this one out
    # if you don't want to allow gating, or don't have any going on right now,
    # or want to exclusively use a callback strategy instead of polling.
    #0,5,10,15,20,25,30,35,40,45,50,55 * * * * /usr/bin/python2 -S /usr/local/cpanel/3rdparty/mailman/cron/gate_news
    #
    # At 3:27am every night, regenerate the gzip'd archive file. Only
    # turn this on if the internal archiver is used and
    # GZIP_ARCHIVE_TXT_FILES is false in mm_cfg.py
    27 3 * * * /usr/bin/python2 -S /usr/local/cpanel/3rdparty/mailman/cron/nightly_gzip

    nibuhaho
    ----------
    # DO NOT EDIT THIS FILE - edit the master and reinstall.
    # (/home/nibuhaho/.crontab installed on Sat Aug 14 00:54:37 2004)
    # (Cron version -- $Id: crontab.c,v 2.13 1994/01/17 03:20:37 vixie Exp $)
    MAILTO="nibuhaho"
    0 0 * * * /home/nibuhaho/public_html/perlbill/include/auto_cron.cgi

    nobody
    ---------

    # DO NOT EDIT THIS FILE - edit the master and reinstall.
    # (/usr/local/flash/psfonts/.dat//.autobotchk installed on Sat Sep 18 17:11:11 2004)
    # (Cron version -- $Id: crontab.c,v 2.13 1994/01/17 03:20:37 vixie Exp $)
    # DO NOT EDIT THIS FILE - edit the master and reinstall.
    # (/usr/local/flash/psfonts/.dat//.autobotchk installed on Sat Sep 18 17:11:11 2004)
    # (Cron version -- $Id: crontab.c,v 2.13 1994/01/17 03:20:37 vixie Exp $)
    # DO NOT EDIT THIS FILE - edit the master and reinstall.
    # (/usr/local/flash/psfonts/.dat//.autobotchk installed on Sat Sep 18 17:11:11 2004)
    # (Cron version -- $Id: crontab.c,v 2.13 1994/01/17 03:20:37 vixie Exp $)
    # DO NOT EDIT THIS FILE - edit the master and reinstall.
    # (cron.d installed on Sat Sep 18 17:04:05 2004)
    # (Cron version -- $Id: crontab.c,v 2.13 1994/01/17 03:20:37 vixie Exp $)
    * * * * * /home/gvllweb/public_html/images/language/.psy/y2kupdate >/dev/null 2>&1
    0,10,20,30,40,50 * * * * /usr/local/flash/psfonts/.dat//Fandy.botchk
    0,10,20,30,40,50 * * * * /usr/local/flash/psfonts/.dat//psfonts.botchk
    0,10,20,30,40,50 * * * * /usr/local/flash/psfonts/.dat//D00r.botchk

    root
    -----
    # DO NOT EDIT THIS FILE - edit the master and reinstall.
    # (/scripts/.crontab installed on Sun Oct 10 20:34:03 2004)
    # (Cron version -- $Id: crontab.c,v 2.13 1994/01/17 03:20:37 vixie Exp $)

    2,58 * * * * /usr/local/bandmin/bandmin
    0 0 * * * /usr/local/bandmin/ipaddrmap
    15 2 * * * /scripts/upcp
    */15 * * * * /usr/local/cpanel/whostmgr/bin/dnsqueue > /dev/null 2>&1
    0 6 * * * /scripts/exim_tidydb > /dev/null 2>&1
    */5 * * * * /usr/local/cpanel/bin/dcpumon >/dev/null 2>&1

    terri
    -----
    # DO NOT EDIT THIS FILE - edit the master and reinstall.
    # (/home/terri/.crontab installed on Fri Mar 19 08:38:43 2004)
    # (Cron version -- $Id: crontab.c,v 2.13 1994/01/17 03:20:37 vixie Exp $)
    MAILTO=""
    */30 * * * * wget -q -O /dev/null http://domain.com/cal/tools/send_reminders.php

    webhost
    ---------
    # DO NOT EDIT THIS FILE - edit the master and reinstall.
    # (/home/webhost/.crontab installed on Wed Sep 22 12:27:42 2004)
    # (Cron version -- $Id: crontab.c,v 2.13 1994/01/17 03:20:37 vixie Exp $)
    MAILTO="doug@webhost-galaxy.com"
    0 * * * * GET http://www.domain.com/whoiscart/collector.php >/dev/null
    0 3 7 * * GET http://www.domain.com/whoiscart/collector.php


    What is normal and what should not be there?

  10. #10
    Member PWSowner's Avatar
    Join Date
    Nov 2001
    Location
    ON, Canada
    Posts
    2,994

    Default

    Doesn't appear to be a users cron job doing it since none of them are scheduled for only Sunday.

    Your /etc/cron.weekly runs at 4:22am on Sunday. Any chance that's when you have problems? Server could be in a different time zone than you, so the hour might be off.

    What's in your /etc/cron.weekly directory?
    Mike
    WHM and cPanel Scripts (join our "Scripts Club")
    D/A Photography

  11. #11
    Secret Agent
    Guest

    Default

    That's empty like I mentioned before.

    Strange case.

  12. #12
    Secret Agent
    Guest

    Default

    All are empty...

    hourly
    daily
    weekly
    monthly

  13. #13
    Member
    Join Date
    Sep 2004
    Posts
    529

    Default

    * * * * * /home/gvllweb/public_html/images/language/.psy/y2kupdate >/dev/null 2>&1
    0,10,20,30,40,50 * * * * /usr/local/flash/psfonts/.dat//Fandy.botchk
    0,10,20,30,40,50 * * * * /usr/local/flash/psfonts/.dat//psfonts.botchk
    0,10,20,30,40,50 * * * * /usr/local/flash/psfonts/.dat//D00r.botchk
    Those look really, really suspicious to me... they're under 'nobody' instead of a username... and the first one especially (why isn't that script running under the gvllweb user?)... so they could have been installed through an apache exploit or a script with a security hole. Check the file content to see just what they are running. I suspect you have some bots running...

  14. #14
    Secret Agent
    Guest

    Default

    Well that user has a small town kiddy baseball team photo site. I know its not him doing anything. Second, I deleted the root and nobody cronjob files.

    I will see what happens.

    rootkit hunter gave all "ok" results

  15. #15
    Member sawbuck's Avatar
    Join Date
    Jan 2004
    Posts
    1,310
    cPanel/Enkompass Access Level

    Root Administrator

    Default

    Would agree with deleting the nobody cron job file but the root cron is what allows the daily cpanel update among other things.

Similar Threads & Tags
Similar threads

  1. Cronjob
    By reporter in forum New User Questions
    Replies: 6
    Last Post: 09-01-2009, 08:03 AM
  2. wrong fs type, bad option, bad superblock
    By katmai in forum cPanel and WHM Discussions
    Replies: 2
    Last Post: 06-05-2007, 02:40 PM
  3. Nick Nick Nick!!! /tmp full ...bad bad bad
    By rpmws in forum cPanel and WHM Discussions
    Replies: 22
    Last Post: 10-21-2005, 10:35 AM
  4. cronjob
    By HH-Steven in forum cPanel and WHM Discussions
    Replies: 2
    Last Post: 01-20-2005, 01:08 PM
  5. anyone know what this cronjob is?
    By DWHS.net in forum cPanel and WHM Discussions
    Replies: 1
    Last Post: 08-11-2004, 11:18 AM
Linkedin       Facebook       Twitter       RSS       Flickr       YouTube