Install Logcheck

Posted: 2p in Linux

Install Logcheck

cd /tmp
wget http://heanet.dl.sourceforge.net/sourceforge/sentrytools/logcheck-1.1.1.tar.gz
tar xvfz logcheck-1.1.1.tar.gz
cd logcheck-1.1.1/systems/

Now change the variable SYSADMIN in logcheck.sh. SYSADMIN is the person that will receive logcheck’s output per email (this can be an email address or a user on the system where you install logcheck on):

[…]
# CONFIGURATION SECTION

PATH=/bin:/sbin:/usr/bin:/usr/sbin:/usr/ucb:/usr/local/bin

# Logcheck is pre-configured to work on most BSD like systems, however it
# is a rather dumb program and may need some help to work on other
# systems. Please check the following command paths to ensure they are
# correct.

# Person to send log activity to.
SYSADMIN=me@myself.tld

# Full path to logtail program.
# This program is required to run this script and comes with the package.

LOGTAIL=/usr/local/bin/logtail
[…]

cd ../../
mkdir -p /usr/local/etc/tmp
make
make linux

This will install logcheck under /usr/local/etc.

Now we have to create a cron job in order to run logcheck periodically. Edit root’s cron file (e.g. /var/spool/cron/crontabs/root, see section 2 “Install Chkrootkit”) and enter the following line:

0 3 * * * /usr/local/etc/logcheck.sh

Then run

chmod 600 /var/spool/cron/crontabs/root
/etc/init.d/crond restart

This will invoke logcheck once a day at 3 am. It will now inform you about unusual system events, security violations, system attacks, etc. If your system is exposed directly to the internet you will notice that there are lots of malicious activities in the internet, and you will get a feeling why security is very important.
==============================================================>

Advertisements
Comments
  1. I really like it when folks come together and share opinions.
    Great website, continue the good work!

  2. I enjoy looking through a post that can make people think.
    Also, thanks for allowing me to comment!

  3. Jerold says:

    WOW just what I was searching for. Came here by searching for mobile application designed

  4. I appreciate this post, I am a huge fan of this website and I would like to kept updated.

  5. Pasquale says:

    I found your blog on search engines and bookmark it currently.
    keep up the nice work.

  6. Thanks very nice blog!

  7. I read this post fully concerning the resemblance
    of newest and earlier technologies, it’s awesome article.

  8. Highly energetic blog, I enjoyed that bit. Will there be
    a part 2?

  9. Gavin says:

    A worthy read. Any chance for more like this one?

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s