- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- run /usr/sbin/dmesg with a limited user account - ...
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
Discussions
Discussions
Forums
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
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
тАО07-14-2008 03:04 AM
тАО07-14-2008 03:04 AM
run /usr/sbin/dmesg with a limited user account - no root
I have an HP-UX box, and i need to run the dmesg command located in /usr/sbin. This command should be run using a limited user, permissions are given to everyone on that command, but it seems it goes to read from the kernel. could anyone help, how to make it possible to run this command with a specific user without giving him hight privileges ?
here is the output:
==============================
bash$ /usr/sbin/dmesg
Jul 14 14:04
Can't read kernel memory
==============================
Thanks guys
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-14-2008 03:19 AM
тАО07-14-2008 03:19 AM
Re: run /usr/sbin/dmesg with a limited user account - no root
regards,
ivan
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-14-2008 03:52 AM
тАО07-14-2008 03:52 AM
Re: run /usr/sbin/dmesg with a limited user account - no root
What information are you *rally* trying to discern from 'dmesg'?
Regards!
...JRF...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-14-2008 04:39 AM
тАО07-14-2008 04:39 AM
Re: run /usr/sbin/dmesg with a limited user account - no root
it is my system, it is a monitoring system, and it runs this command to get information related to the memory capacity and memory utilization.
file permissions or dmesg allows all users to run the file:
$ ls -l /usr/sbin/dmesg
lrwxr-xr-x 1 root sys 11 Feb 13 2002 dmesg -> /sbin/dmesg
$ ls -l /sbin/dmesg
-r-xr-xr-x 1 bin bin 212992 Nov 14 2000 /sbin/dmesg
So the rights are given to everybody to run the file, but it seems a part of this command tries to read the kernel which is not allowed to my user.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-14-2008 04:44 AM
тАО07-14-2008 04:44 AM
Re: run /usr/sbin/dmesg with a limited user account - no root
You can use crontab to schedule dmesg entries to be written into separate file - http://docs.hp.com/en/B3921-90010/dmesg.1M.html
regards,
ivan
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-14-2008 04:46 AM
тАО07-14-2008 04:46 AM
Re: run /usr/sbin/dmesg with a limited user account - no root
I suspected that is was memory information that you wanted. Why, is still unclear, but:
# echo "selclass qualifier memory;info;wait;infolog"|cstm > /var/tmp/meminfo
Regards!
...JRF...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-14-2008 05:02 AM
тАО07-14-2008 05:02 AM
Re: run /usr/sbin/dmesg with a limited user account - no root
but I really need the user to run that specific command as I cannot change in the source code of the monitoring system to use the other command.
besides, it still needs to calculate percentage of utilizewd memory.
I need to let a user run /usr/sbin/dmesg
Thanks guys
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-14-2008 05:14 AM
тАО07-14-2008 05:14 AM
Re: run /usr/sbin/dmesg with a limited user account - no root
Be aware that dmesg will NOT have this info if the system has been up for some time.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-14-2008 05:20 AM
тАО07-14-2008 05:20 AM
Re: run /usr/sbin/dmesg with a limited user account - no root
dmesg is a circular buffer of messages. Once the buffer is full, older messages will disappear as newer messages are received.
So, eventually you will NOT be able to find your memory info is the dmesg buffer.
You really need to look for an alternate means to get the information you need.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-14-2008 05:23 AM
тАО07-14-2008 05:23 AM
Re: run /usr/sbin/dmesg with a limited user account - no root
Hope this helps!
Regards
Torsten.
__________________________________________________
There are only 10 types of people in the world -
those who understand binary, and those who don't.
__________________________________________________
No support by private messages. Please ask the forum!
If you feel this was helpful please click the KUDOS! thumb below!