LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 01-13-2005, 04:55 PM   #1
sjblasko82
LQ Newbie
 
Registered: Nov 2004
Posts: 8

Rep: Reputation: 0
Delete Access


Is it at all possible to give one user read and write access and keep them from deleting that file?

At the same time is it possible to give another user full permission (even delete) to that same file?

Just curious.
 
Old 01-13-2005, 05:28 PM   #2
Tinkster
Moderator
 
Registered: Apr 2002
Location: earth
Distribution: slackware by choice, others too :} ... android.
Posts: 23,067
Blog Entries: 11

Rep: Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928
Re: Delete Access

Quote:
Originally posted by sjblasko82
Is it at all possible to give one user read and write access and keep them from deleting that file?
Yes.

Quote:
At the same time is it possible to give another user full permission (even delete) to that same file?
And yes, again.


Cheers,
Tink
 
Old 01-13-2005, 05:32 PM   #3
sjblasko82
LQ Newbie
 
Registered: Nov 2004
Posts: 8

Original Poster
Rep: Reputation: 0
How would you go about doing this??
 
Old 01-13-2005, 05:49 PM   #4
Tinkster
Moderator
 
Registered: Apr 2002
Location: earth
Distribution: slackware by choice, others too :} ... android.
Posts: 23,067
Blog Entries: 11

Rep: Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928
If you e.g. had a directory
/share/documents ...

You have user1 and user2

Create a group editors.
Add user2 to editors..

chown user1:editors /share/documents
chmod u=rwx,g=rx,o-rwx /share/documents

create the document that user2 should be
able to edit but not delete in /share/documents
e.g. as user1
date > /share/documents/some_file
chgrp editors /share/documents/some_file
chmod g=rw /share/documents/some_file



Cheers,
Tink
 
Old 01-13-2005, 06:24 PM   #5
sjblasko82
LQ Newbie
 
Registered: Nov 2004
Posts: 8

Original Poster
Rep: Reputation: 0
That works wonderfully on Linux side. The problem I am having now is the that I am trying to use a Samba server that has the same restrictions. Unfortunately, even if I give read only permission to the files and folders on Linux side (which works) I can still delete those files on the Windows side. Is there a way around this problem?
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
How to delete files that won't delete? di11rod Linux - Security 7 10-19-2005 09:14 PM
Allow two users write access, but not delete jimieee Linux - General 4 03-29-2005 08:37 AM
Samba access by Windows users locking out directory access with Konqueror harry_fine SUSE / openSUSE 1 12-18-2004 05:33 AM
can't access/delete/list files even as root... tenshi Linux - General 7 10-13-2004 04:29 AM
Tried to delete file as root but it says I don't have permission to delete it! beejayzed Mandriva 23 03-12-2004 02:46 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 03:15 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration