- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - Linux
- >
- Change owner
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
01-07-2003 09:07 PM
01-07-2003 09:07 PM
Change owner
eg. ( On UNIX )
# whoami
UserA
# ll
-rw-rw-rw- userA ACC abc.prn
# chown UserB:ACC abc.prn
#ll
-rw-rw-rw- userB ACC abc.prn
(On Linux)
do the same thing,
# chown UserB:ACC abc.prn
chown: changing ownership of `./abc.prn': Operation not permitted
How to let the user to change the ownership to other ID? Thx.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-07-2003 10:49 PM
01-07-2003 10:49 PM
Re: Change owner
only root is empowered to use chown command in that way.
regards,
U.SivaKumar
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-08-2003 06:33 AM
01-08-2003 06:33 AM
Re: Change owner
You can indeed not "by default" do this on Linux, but you can make it equal to the Unix box by using sudo.
Important note : Unless you want everyone to be able to chown every file (not good !) you should specify this user by user and use the
"chown --from=CURRENT_USER" commandline to make sure the user can only chown his/her own files.
Regards,
Tom
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-08-2003 11:24 AM
01-08-2003 11:24 AM
Re: Change owner
It's a restriction on kernel level. But there's a way to circumvent this by compiling your own kernel. Before you do that you must change the following file in the kernel source tree (/usr/src/linux normally, if installed)
include/kernel/capability.h
Search in the file for the following line and change the 0 into a 1.
#define CAP_CHOWN 0
rgds.
Steven
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-08-2003 01:24 PM
01-08-2003 01:24 PM
Re: Change owner
Another agreement.
UserA can't take ownership.
UserB or root can only give ownership.
You can, as UserA, cp the file and get a copy with you as the owner.
Good Luck,
Kel