- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- The last(1) command does not show login
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-11-2006 01:51 AM
01-11-2006 01:51 AM
the last command doesn'z work, but the who and lastb command work fine.
The login is a telnet session (Not CDE)
the last command shor the last entry from 23.12.2005
>last |more
root pts/tb Tue Dec 23 12:23 - 12:23 (00:00)
konadm remshd Mon Dec 22 17:30 - 17:53 (00:23)
the who command works
>who
root pts/0 Jan 11 14:55
stuetzet pts/1 Jan 11 15:04
root pts/ta Jan 11 15:25
and also the lastb and finger command
>lastb |more
root pts/ta Wed Jan 11 15:25
ddd pts/ta Wed Jan 11 15:25
stuetzet pts/0 Wed Jan 11 14:54
root pts/tc Fri Dec 16 15:59
list contents of directory
>/var/adm#ls -al ?tmp*
-rw------- 1 root other 13860 Jan 11 15:25 btmp
-rw-rw-r-- 1 adm adm 995472 Jan 11 15:38 wtmp
-rw-r--r-- 1 root root 280 Jan 1 01:00 wtmpx
Any ideas are welcome.
Thanks an advance!
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-11-2006 01:57 AM
01-11-2006 01:57 AM
Re: The last(1) command does not show login
was the login via su ?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-11-2006 02:12 AM
01-11-2006 02:12 AM
Re: The last(1) command does not show login
the login was a telnet session, not via su.
Thomas
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-11-2006 02:20 AM
01-11-2006 02:20 AM
Solutionlast uses /var/adm/wtmp
lastb uses /var/adm/btmp
who uses /etc/utmp
The man page for finger doesn't say what it uses, but based on your situation, I'd say it uses /etc/utmp also.
I would guess maybe your /var/adm/wtmp file is corrupt somehow that's keeping new entries from being added after 12/23. Make a copy of it and then clear it (i.e. "> /var/adm/tmp"). See if new sessions show up in "last" after that.
Jeff Traigle
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-11-2006 03:14 AM
01-11-2006 03:14 AM
Re: The last(1) command does not show login
the wtmp file was not o.k.
see command wtmpfix
/usr/sbin/acct/wtmpfix < /var/adm/wtmp
Bad file at offset 494580
root root 28939 Thu Jan 1 09:02:19 1970
So I have decided to lost the date in file wtmp ( but have a backup file)
cp /var/adm/wtmp /var/adm/wtmp.old # backup
cat /dev/null > /var/adm/wtmp # delete data in wtmp
Now the last command is working fine
Thanks on all
Thomas
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-11-2006 03:21 AM
01-11-2006 03:21 AM
Re: The last(1) command does not show login
cat /dev/null > /var/adm/wtmp # new file
Now the last command is working fine
Thanks on all
Thomas