- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- su shows wrong user
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
04-25-2003 08:20 AM
04-25-2003 08:20 AM
su shows wrong user
su from root to another user, but sulog shows another user. e.g.
SU 04/25 11:09 + 0 panama-maestro
Also mail from root is recorded as from "panama".
pwck -s does not display any errors, and there are no duplicate UID's.
I assume problem is with authentication database, but have no idea how to fix it!
Any help would be greatly appreciated.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-25-2003 08:32 AM
04-25-2003 08:32 AM
Re: su shows wrong user
I am login as user sachin then run su - to become root then run su - patel and look what happen.
# whoami
root
# who am i
sachin pts/3 Apr 25 11:05
#su - patel
patel%exit
#tail -2 /var/adm/sulog
SU 04/25 11:25 + 3 sachin-root
SU 04/25 11:27 + 3 sachin-patel
But if you login to system via telnet as user root look what happens
#telnet rem1
Trying...
Connected to rem1.test.com.
Escape character is '^]'.
Local flow control on
Telnet TERMINAL-SPEED option ON
HP-UX sagan B.11.00 U 9000/800 (t0)
login: root
Password:
#su - patel
patel%exit
#tail -1 /var/adm/sulog
SU 04/25 11:29 + t0 root-patel
Conclusion: if you run su - then it source your profile so you have entry like
SU 04/25 11:09 + 0 panama-maestro
Sachin
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-25-2003 08:34 AM
04-25-2003 08:34 AM
Re: su shows wrong user
If its not an Ingite problem then:
1) A manual change has been made to /etc/passwd
2) The user panama actually did su to root and knows the password.
I am gessing there is an error in /etc/passwd that doesn't show up on pwck -s
log on.
Try this:
whoami
who am i
Do the su thing.
whoami
who am i
See if that sheds any light on the situation.
SEP
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-25-2003 11:39 AM
04-25-2003 11:39 AM
Re: su shows wrong user
When logging in as root, we do not 'su' to root but are logged in using SSH. While logged in, running a tail on the sulog you can see the message "su : + 0 panama-maestro".
Also, all mail messages generated by root appear to come from 'panama' -- which does NOT have UID=0.
We have 25 HP systems, and this is the only one that does this.... It does not interfere with production, as it only seems to occur to the 'root' account -- but it is really weird.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-25-2003 11:44 AM
04-25-2003 11:44 AM
Re: su shows wrong user
Run the id command in both accounts and compare the output.
Regards,
DR
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-25-2003 03:12 PM
04-25-2003 03:12 PM
Re: su shows wrong user
I had a similar problem back in December.
http://forums.itrc.hp.com/cm/QuestionAnswer/1,,0x92640fe6d0f7d61190050090279cd0f9,00.html
I never did solve it, and it has not come back to play either. I have a feeling it ended up being some corruption in the /etc/utmp or /var/adm/wtmp file. Once that system rebooted and new Xtmp files were created the lady with the tarot cards never dealt me another hand.
Regards
Michael
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-28-2003 04:40 PM
04-28-2003 04:40 PM
Re: su shows wrong user
If the machine can be easily rebooted I would be tempted to try renaming /etc/utmp and /etc/utmpx, 'touch'ing them back and resetting the original owner/group/mode then rebooting.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-13-2003 03:10 AM
11-13-2003 03:10 AM
Re: su shows wrong user
When I login using tty tyb and su to root it shows the su as a different user. It only happens on tyb and it is always the same user.