HPE GreenLake Administration
- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - Linux
- >
- Re: File mode
Operating System - Linux
1828243
Members
2668
Online
109975
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
Forums
Discussions
Discussions
Discussions
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
Blogs
Information
Community
Resources
Community Language
Language
Forums
Blogs
Go to solution
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
02-12-2004 07:11 PM
02-12-2004 07:11 PM
I have a file on the system , many users can access and update it , how can I fix the file mode ( eg. 666 ) , to prevent the user change the mode ? thx.
Solved! Go to Solution.
3 REPLIES 3
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-12-2004 07:18 PM
02-12-2004 07:18 PM
Solution
This can be done by closing the directory for writing... Just do: 'chmod go-w .' while in the directory. This means they can't create files too, btw.
Another way: set the 'sticky' bit on the directory: 'chmod o+s .' This has some other side effects (users can't remove files not owned by them.
Test to see what's best for your situation.
Another way: set the 'sticky' bit on the directory: 'chmod o+s .' This has some other side effects (users can't remove files not owned by them.
Test to see what's best for your situation.
Every problem has at least one solution. Only some solutions are harder to find.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-13-2004 01:48 AM
02-13-2004 01:48 AM
Re: File mode
just make sure the file is not own by any users which you do not want to have ownership; maybe you want to own the file. AFAIK, you can only change mod if you own the file (besides all mighty powerfull root, offcourse).
Reputation of a thousand years can be determined by the conduct of an hour
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-13-2004 06:48 AM
02-13-2004 06:48 AM
Re: File mode
Hello Peter,
exactly which mode to set really depends on how this file is supposed to be used. Do all users on the system need rw to the fil? In that case 666 is the right protection. Do only users of one group need access? Chmod 660 would do that.
Ist is it a few users from different groups, add a new group, add the members to it, make the file owned by the group and again go 660. Users might need to do a chgrp to the right group in this case to gain access. If you need finegrained access have a look at ACLs.
Greetings, Martin
exactly which mode to set really depends on how this file is supposed to be used. Do all users on the system need rw to the fil? In that case 666 is the right protection. Do only users of one group need access? Chmod 660 would do that.
Ist is it a few users from different groups, add a new group, add the members to it, make the file owned by the group and again go 660. Users might need to do a chgrp to the right group in this case to gain access. If you need finegrained access have a look at ACLs.
Greetings, Martin
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
Support
Events and news
Customer resources
© Copyright 2025 Hewlett Packard Enterprise Development LP