- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Trying to run SAM with SUDO.
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
09-19-2002 06:15 AM
09-19-2002 06:15 AM
In the sudoers file i have the command line as /usr/sbin/sam.
But when i run sudo sam it gives me the error (sudo: sam: command not found.
Any ideas anyone.
Thanks
Jeff
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-19-2002 06:18 AM
09-19-2002 06:18 AM
Re: Trying to run SAM with SUDO.
All you need to do here is to configure Restricted Sam.. (run sam -r as root)
When you run restricted sam, you can give the user access to any root functions in sam and deny other functions that you don't wish them to execute.
Mike Elleby
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-19-2002 06:20 AM
09-19-2002 06:20 AM
Re: Trying to run SAM with SUDO.
Jeff
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-19-2002 06:22 AM
09-19-2002 06:22 AM
Re: Trying to run SAM with SUDO.
Restrictied Sam Builder is what is used to give non-root users access to root functions in sam without giving them root access.
The user(s) that you configure would login as themselves and run Sam, but would only be allowed to execute functions in Sam that you authorize.
Just wanted to give you an idea to use..
Hope this helps..
Mike Elleby
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-19-2002 06:25 AM
09-19-2002 06:25 AM
Re: Trying to run SAM with SUDO.
Sorry it wasn't what you were looking for...
Mike...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-19-2002 06:28 AM
09-19-2002 06:28 AM
Re: Trying to run SAM with SUDO.
You probably do not have /usr/sbin in your secured-path of sudoers file.
Did you try using the full path?.
sudo /usr/sbin/sam
-Sri
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-19-2002 06:30 AM
09-19-2002 06:30 AM
Re: Trying to run SAM with SUDO.
Whilst Michael did not answer your initial question he has given you a more secure and correct way to allow users controlled (restricted) sam.
Paula
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-19-2002 06:37 AM
09-19-2002 06:37 AM
Re: Trying to run SAM with SUDO.
Yes if type sudo /usr/sbin/sam it works no problem.
But not - sudo sam
However if i type eg - sudo make_recovery it works without having to put in the full path.
Not sure what you mean about the secure part in the sudoers file.
Jeff
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-19-2002 06:41 AM
09-19-2002 06:41 AM
Re: Trying to run SAM with SUDO.
Thanks for the reply, it's not sam i am looking to restrict but users access to root in general.
Thanks
Jeff
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-19-2002 06:51 AM
09-19-2002 06:51 AM
Re: Trying to run SAM with SUDO.
I know what its like, you have to drag them kicking and screaming back to a normal login.
Have a serious look at restricted sam as you can build menus within to allow then to carry out almost anything.
AS root fire up sam and at first screen the options:_
Add Custom Application...
Add Custom Application Group...
are displayed.
HTH
Paula
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-19-2002 06:58 AM
09-19-2002 06:58 AM
Re: Trying to run SAM with SUDO.
It's the path you specify with the configure option (--secure_path) of SUDO while compiling it. It will overwrite the the PATH of the user executing SUDO.
/usr/sbin is not defined by default in ordinary user PATH. You can try it by exporting the PATH of the user to include /usr/sbin and then executing sudo.
-Sri
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-19-2002 07:04 AM
09-19-2002 07:04 AM
Re: Trying to run SAM with SUDO.
Restricted SAM as more restricted access and custom menus allow further restrictions.
For security reasons, I believe restricted SAm is the way to go.
HTH
Marty
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-19-2002 07:12 AM
09-19-2002 07:12 AM
Re: Trying to run SAM with SUDO.
I appreciate all the comments about sam, but a. i don't want everybody going into sam and b. i only need some users to run root command prompts.
I'm sorry if i have lost the plot abit here, i just wanted to know how to run sam with SUDO.
I have added a the PATH /usr/sbin/sam into the users .profile but still no joy.
Looks like i will have to type in the full path (sudo /usr/sbin/sam to get sam to work.
Thanks
Jeff
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-19-2002 07:43 AM
09-19-2002 07:43 AM
SolutionLink your sudo to /usr/local/bin
Then add path to SAM
export PATH=$PATH:/usr/sbin
Run
sudo sam
I believe you should be good to go.
If you still get that error, try doing this
whereis sudo
/usr/local/bin/sudo
whereis sam
/usr/sbin/sam
I believe this will give you a good idea where sam is.
Regards,
Anil
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-19-2002 08:14 AM
09-19-2002 08:14 AM
Re: Trying to run SAM with SUDO.
That cracked it.
Jeff
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-19-2002 08:55 AM
09-19-2002 08:55 AM
Re: Trying to run SAM with SUDO.
-Sri