Command last displays wrong hostname

Thread Tools Search this Thread
Operating Systems AIX Command last displays wrong hostname
# 1  
Old 01-05-2011
Command last displays wrong hostname

I faced an interesting problem on my AIX servers. When I checked last logins with command last I saw that hostnames are wrong. Let say, I made login from workstation xxxxx and with the command last I saw:

root pts/2 yyyyy 5 jan 15:38 still logged in

Ping xxxxx and ping yyyyy from AIX server are correct, nslookup is correct as well.
# 2  
Old 01-05-2011
Have you tried reverse as well as forward DNS resolution on the names?
Some unix (I know HP-UX is one) keep both a (truncated) hostname and an IP address in the /etc/utmpx and will use one in preference to the other, and I have seen times when they dont match.
# 3  
Old 01-05-2011
The server name recorded will normally be the same as "Name:" from "nslookup" when run on the server keeping the records (in this case your AIX server). This can be different from the actual name of the client.

Afterthought: Maybe you have a duplicate IP address.
# 4  
Old 01-06-2011
I got one explanation for this problem. Revers zone on DNS Servers are not deleted. As a result records of old workstations remain in cache.
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting


I use things like this a lot in ksh and bash, but lately bash has been printing the command for every loop: ... | while read f do if then echo Differ "$f" fi done How to prevent this? (5 Replies)
Discussion started by: DGPickett
5 Replies

2. Solaris

[SOLVED] Issue with hostname command

Hi, i'm having issues with one of my db servers, each time i run the hostname command i get "-a" as result this is the only zone on this server where i have this issue. could any one help me with this issue (5 Replies)
Discussion started by: EduardoDiaz
5 Replies

3. Red Hat

hostname command prints nothing a null value

Hi , On my box everything works fine. But whenever I run command It returns nothing as you see @(none) too. Its very strange issue I have never noticed on any other system yet. Any one have any idea about this. Thank you (2 Replies)
Discussion started by: pratapsingh
2 Replies

4. UNIX Desktop Questions & Answers

hostname in command prompt

Hello, all. Running 11.04. Is there a way that, in an ssh or telnet session, that hostname will not appear in the command prompt? Not logged in yet, so not seeking a user shell environment. I just want to see something like 'login>', not 'ubuntu login>'. ---------- Post updated at 07:50 PM... (3 Replies)
Discussion started by: mfearer
3 Replies

5. Red Hat

Hostname command issue

Hi All, I am using redhat Linux 5.2.2 on vmware. I have created VM Machine using kickstart & rest 10 machines i created using vmware cloning. On the base machine which i installed from kickstart its showing FQDN using hostname --fqdn but cloned machines are showing hosts name i have chnaged... (1 Reply)
Discussion started by: ajaincv
1 Replies

6. Solaris

Last command displays wrong information

Hi am having Solaris10 - Sun-Fire-V890 server, the information displayed by Last command is wrong how do i get this sorted without loosing any datas.. # uptime 12:32am up 20 day(s), 33 min(s), 1 user, load average: 1.54, 1.82, 1.93 # last reboot reboot system boot Sat... (9 Replies)
Discussion started by: Sojourner
9 Replies

7. UNIX for Dummies Questions & Answers

Creating a file that contains output from a command, and then displays itself

hey, I'm trying to create the command that will create a file named user.txt that contains the output of the command cut -d: -f1,5 /etc/passwd, and displays itself afterwards. I don't know how to bridge cat > user.txt with cut -d: -f1,5 /etc/passwd, or how display it afterwards. Any help would... (2 Replies)
Discussion started by: raidkridley
2 Replies

8. Linux

Hostname displays incorrectly

hiii, in many of the linux machines i have tried this but the result is the same everywhere. if there are double letters in a hostname then that is displayed as single letter. e.g. if hostname is set to nepttune then login into the shell will display : NEPTUNE(admin)@/ $ hostname... (15 Replies)
Discussion started by: shamik
15 Replies

9. Solaris

How to display hostname in command prompt

Anyone know How to configure solaris 8 to display hostname in command prompt , everytime when you open a terminal screen . (3 Replies)
Discussion started by: civic2005
3 Replies

10. UNIX for Advanced & Expert Users

Cisco Router command to get hostname

Hi All, I am connected to a cisco router and I want to know the hostname of this router. I connect as telnet <IPADDRESS> and the prompt shows vpnaccess-bristol> But I want to know the full hostname of the router how can i do that. When i type the hostname command the following... (3 Replies)
Discussion started by: rahulrathod
3 Replies
Login or Register to Ask a Question

Featured Tech Videos