Solved

Does Chown give full rights to a folder

Posted on 2014-02-28
11
445 Views
Last Modified: 2014-03-01
I have given a user Test, ownership to a folder, but that user cannot remove the folder.
ownown
0
Comment
Question by:jskfan
  • 3
  • 3
  • 2
  • +3
11 Comments
 
LVL 34

Assisted Solution

by:Dan Craciun
Dan Craciun earned 83 total points
Comment Utility
Have you tried
rm -rf testfolder?

HTH,
Dan
0
 
LVL 23

Assisted Solution

by:savone
savone earned 166 total points
Comment Utility
The owner does not have any permissions to the folder according to your screenshot.

Try this:
chmod 770 testfolder

That will give the OWNER (first 7) and the GROUP (second 7) full access and everyone else NO access.
0
 
LVL 9

Assisted Solution

by:David Carr
David Carr earned 83 total points
Comment Utility
chown is used to change the owner.

chmod is used to change the permissions.

try chmod 755 testfolder
0
 
LVL 23

Expert Comment

by:savone
Comment Utility
@David Carr,  Why add read/execute permissions for everybody?
0
 

Author Comment

by:jskfan
Comment Utility
I guess even when you give  a group or a user ownership of a folder they cannot delete it, they can delete only whatever they create inside that folder.

permissions
0
Enabling OSINT in Activity Based Intelligence

Activity based intelligence (ABI) requires access to all available sources of data. Recorded Future allows analysts to observe structured data on the open, deep, and dark web.

 
LVL 34

Expert Comment

by:Seth Simmons
Comment Utility
did you just add testuser1 to testgroup1?
if so, try to log out and in again and remove that folder
0
 
LVL 23

Assisted Solution

by:savone
savone earned 166 total points
Comment Utility
@Seth Simmons has  a good point.

Can you show us the output of the following command:

id testuser1
0
 

Author Comment

by:jskfan
Comment Utility
testuser1 is member of testgroup1
pm
0
 
LVL 34

Assisted Solution

by:Seth Simmons
Seth Simmons earned 84 total points
Comment Utility
oh...should have noticed this before
you can't delete it because you're on the root of the file system
within testfolder you can do whatever you want as a normal user but you can't delete it or create anything because the root level is owned by root (755)

do ls -lha / and you'll see why

putty
0
 
LVL 26

Accepted Solution

by:
skullnobrains earned 84 total points
Comment Utility
I guess even when you give  a group or a user ownership of a folder they cannot delete it, they can delete only whatever they create inside that folder.

yes : you need write permissions on the parent folder in order to delete a file or folder and you don't even need any permissions on the file/folder you are deleting
0
 

Author Closing Comment

by:jskfan
Comment Utility
Thank you Guys!
0

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

After running Ubuntu some time, you will be asked to download updates for fixing bugs and security updates. All the packages you download replace the previous ones, except for the kernel, also called "linux-image". This is due to the fact that w…
It’s 2016. Password authentication should be dead — or at least close to dying. But, unfortunately, it has not traversed Quagga stage yet. Using password authentication is like laundering hotel guest linens with a washboard — it’s Passé.
Learn how to find files with the shell using the find and locate commands. Use locate to find a needle in a haystack.: With locate, check if the file still exists.: Use find to get the actual location of the file.:
Learn how to navigate the file tree with the shell. Use pwd to print the current working directory: Use ls to list a directory's contents: Use cd to change to a new directory: Use wildcards instead of typing out long directory names: Use ../ to move…

771 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now