- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Log about login users and log about script executi...
Operating System - HP-UX
1820355
Members
2744
Online
109623
Solutions
Forums
Categories
Company
Local Language
юдл
back
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Discussions
Forums
Forums
Discussions
юдл
back
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
Discussion Boards
Discussion Boards
Blogs
Information
Community
Resources
Community Language
Language
Forums
Blogs
Topic Options
- 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
тАО05-19-2006 08:26 AM
тАО05-19-2006 08:26 AM
Log about login users and log about script execution
Hi,
i need to know the time that an user logged in my server and the time that he/she left it.
Also, how to know (or where) about the time that a specific script was executed ...
Best regards,
Christian
i need to know the time that an user logged in my server and the time that he/she left it.
Also, how to know (or where) about the time that a specific script was executed ...
Best regards,
Christian
Christian Aguilar
2 REPLIES 2
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-19-2006 09:02 AM
тАО05-19-2006 09:02 AM
Re: Log about login users and log about script execution
You can check users login and logout times by using the 'last' command.
# last
will give all instances of a users logons.
# man last
for more details.
As to when a script was executed -- If it was from someones session, that is going to be almost impossible to tell. That kind of information is not kept anywhere.
# last
will give all instances of a users logons.
# man last
for more details.
As to when a script was executed -- If it was from someones session, that is going to be almost impossible to tell. That kind of information is not kept anywhere.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-19-2006 09:32 AM
тАО05-19-2006 09:32 AM
Re: Log about login users and log about script execution
From a normal shell login, you can enable a log of the commands issued by the user. Just put this into /etc/profile:
export HISTFILE=~/.sh_history
Now each command the user types will be logged. The size of the file can also be controlled in /etc/profile:
export HISTSIZE=1000
It sounds like you are having problems with users, either they are not properly trained or they are getting into trouble. That is a sure sign that these users should be getting a shell prompt but instead are given a special menu script to limit their capability.
Bill Hassell, sysadmin
export HISTFILE=~/.sh_history
Now each command the user types will be logged. The size of the file can also be controlled in /etc/profile:
export HISTSIZE=1000
It sounds like you are having problems with users, either they are not properly trained or they are getting into trouble. That is a sure sign that these users should be getting a shell prompt but instead are given a special menu script to limit their capability.
Bill Hassell, sysadmin
The opinions expressed above are the personal opinions of the authors, not of Hewlett Packard Enterprise. By using this site, you accept the Terms of Use and Rules of Participation.
Company
Learn About
News and Events
Support
© Copyright 2025 Hewlett Packard Enterprise Development LP