- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: how to write su in shell script
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
тАО11-25-2010 04:51 AM
тАО11-25-2010 04:51 AM
Re: how to write su in shell script
You need to retroactively assign points to all of your replies:
http://forums.itrc.hp.com/service/forums/pageList.do?userId=WW229563&listType=unassigned
>sudo su - kumar -c "id"
Password:
>kindly help to sort out this issue
This means that sudo is not switching to root for this particular user and/or command.
What is it configured to allow?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-25-2010 05:21 AM
тАО11-25-2010 05:21 AM
Re: how to write su in shell script
/usr/bin/su - kumar
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-25-2010 05:36 AM
тАО11-25-2010 05:36 AM
Re: how to write su in shell script
/usr/bin/su - kumar
Does it check to see that the "-c ..." is different?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-26-2010 08:22 AM
тАО11-26-2010 08:22 AM
Re: how to write su in shell script
i am not understand your input
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-26-2010 08:59 AM
тАО11-26-2010 08:59 AM
Re: how to write su in shell script
Does sudo check for an exact match of the command and ALL the options or only a prefix match?
Does your "/usr/bin/su - kumar" allow:
sudo su - kumar -c "id"
sudo su - kumar -c "cd /home/kumar/lic && /path/to/lmstat lic"
- « Previous
-
- 1
- 2
- Next »