Welcome to the most active Linux Forum on the web.
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
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!


  Search this Thread
Old 10-08-2009, 06:41 PM   #1
LQ Newbie
Registered: Oct 2009
Location: Everett, WA
Posts: 1

Rep: Reputation: 0
Exclamation Commands to show all failed login attempts


I'm trying to learn Linux by myself and i have a list of projects.
for this project i have to use the grep command to show all failed login's attempts in my machine.

i believe the attempts are saved at /var/share/messages.log but i cannot figure it out.

Please let me know how i can do this or just a suggestion would help

Old 10-08-2009, 06:47 PM   #2
Registered: Nov 2008
Location: ~/
Distribution: Arch || Sidux
Posts: 393

Rep: Reputation: 45
You can set up filters in your logger, to filter all logins, and attempts. Such as rsyslog, syslogk, syslogd, syslog-ng

The usual location for the filter is located at /var/log/auth.log If you don't have this, then you need to check your logging configuration config file.

As for grepping, you could grep the string "uid=" or the username. It sounds like homework to me, so I wont give the command to do this. Try looking at the man pages on grep, and look at examples by searching this site.


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
ssh logs show numerous failed attempts schneidz Linux - Security 12 06-22-2009 01:30 PM
Question about failed ssh login attempts natv Linux - Security 3 02-11-2007 06:46 AM
Constant failed login attempts... seanferd Linux - Security 8 11-09-2006 08:42 AM
Timeout between failed login attempts wuicci Linux - Security 3 06-01-2006 04:40 AM
Failed SSH login attempts Capt_Caveman Linux - Security 38 01-03-2006 03:22 PM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 04:33 AM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration