![]() |
|
|
grep unix.com with google
|
|||||||
| Forums | Register | Blog | Man Pages | Forum Rules | Links | Albums | FAQ | Our Members | Calendar | Search | Today's Posts | Mark Forums Read |
| UNIX for Advanced & Expert Users Expert-to-Expert. Learn advanced UNIX, UNIX commands, Linux, Operating Systems, System Administration, Programming, Shell, Shell Scripts, Solaris, Linux, HP-UX, AIX, OS X, BSD. |
![]() |
|
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|||
|
Do you KNOW (first hand knowledge from obervation with truss/trace/opensource) what finger does - what files it reads - on your box?
What OS do you have? My first guess is that there is a disconnect between finger's actual implementation and what you think it does. |
|
|||
|
Finger reads "wtmp". If wtmp does not exist, or is empty, or has wrong permissions, finger will return "Never logged in". What does this give? Code:
last -R username Last edited by methyl; 11-29-2009 at 09:29 PM.. Reason: Weird display corruption |
|
||||
|
@jim mcnamara I supposed the same... but I don't find any trace :-/ Code:
munmap(0xEF750000, 8192) = 0
open("/etc/passwd", O_RDONLY) = 3
open("/var/adm/lastlog", O_RDONLY) = 4
open("/var/adm/utmpx", O_RDWR|O_CREAT, 0644) Err#13 EACCES
open("/var/adm/utmpx", O_RDONLY) = 6
open("/var/adm/utmpx", O_RDONLY) = 7
access("/var/adm/utmp", 0)
SunOs 5.6 --- @methyl no -R option for last Code:
-rw-r--r-- 1 root group 33654 Nov 30 09:54 wtmp -rw-r--r-- 1 root group 894587 Nov 30 09:54 wtmpx /here/i/am% last $USER wtmp begins Wed Jul x xx:xx |
|
|||
|
methyl - I have not seen a POSIX specification for finger stating that it reads any given file. However, it does read other accounting files. See above. On Solaris, finger reads /var/adm/utmpx. Read the man page. Gogol - It looks like wtmp is being updated. last should work as methyl indicated but without the -R. There are also wtmpx entries on your system. wtmp is written to only if the file exists, and for you is not part of the picture for finger. what does Code:
ls -l /var/adm/utmp show? if you grep for your username in umtpx what do you get? -- if it works you will see a lot of garbage characters. If they trash the screen use the reset command. |
|
||||
|
finger is ready to try to match stuff in the gecos field and it marches to its own beat with respect to user names. You have concealed the user's real name and that is probably what is wrong. Is the is user name a mix of 8 characters or less of all lower case letters or digits?
|
|
|||
|
Looked more closely at the original post. Could multiple matches with text in the password file.
Preferable syntax makes an exact match on the username. Quote:
|
| Sponsored Links | ||
|
|
![]() |
| Bookmarks |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
More UNIX and Linux Forum Topics You Might Find Helpful
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| timestamp in .sh_history using ksh shell | Orbix | AIX | 4 | 03-11-2008 10:59 AM |
| history .sh_history sh_history | itik | AIX | 1 | 02-08-2008 06:27 AM |
| .sh_history file | krishna | UNIX for Advanced & Expert Users | 9 | 05-08-2003 09:33 AM |
| .sh_history contains the list of past commands | yls177 | UNIX for Dummies Questions & Answers | 1 | 12-03-2002 07:15 AM |
| How to create .sh_history file | b5fnpct | UNIX for Dummies Questions & Answers | 4 | 08-22-2001 12:29 PM |