Solved

take ownership of directory

Posted on 2014-02-22
3
317 Views
Last Modified: 2014-03-15
Ive somehow lost ownership of a directory on an ext3 drive attached to my asus n56u.  I have terminal access to my router, but have very limited knowledge of linux.  there are a total of 4 folders on the drive.  I have write access to 2 out of 4 of the directories.  If i run a frisk -l, i get

Disk /dev/sda: 2000.3 GB, 2000398934016 bytes
255 heads, 63 sectors/track, 243201 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks  Id System
/dev/sda1               1      243201  1953512001  83 Linux

how can i switch to the drive and get ownership of the troubled directories?
0
Comment
Question by:colonialiu20
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 40

Expert Comment

by:omarfarid
ID: 39879709
You need to access the system as user root, then mount the filesystems, then as root you run

chown -R username:groupname /filesystem_mount

You need to put actual username , groupname and filesystem_mount
0
 
LVL 21

Accepted Solution

by:
Mazdajai earned 500 total points
ID: 39880015
>>how can i switch to the drive and get ownership of the troubled directories? See sample output:

# df -h
/dev/sda1             485M   34M  427M   8% /

Open in new window


To list the ownership:
# ls -lah /
total 114K
dr-xr-xr-x.  27 root root 4.0K Feb 22 20:17 .

Open in new window

0
 
LVL 13

Expert Comment

by:Sandy
ID: 39880263
this is just FS listing... Please provide directory names and the ownership details and use the same command which was provided by Mazdajai.

TY/SA
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Trying to install php56 on CentOS 7 get GPG error 5 39
Apache LDAP Authentication 20 52
plsql job on oracle 18 74
exchange, squid, proxy, linux 6 35
rdate is a Linux command and the network time protocol for immediate date and time setup from another machine. The clocks are synchronized by entering rdate with the -s switch (command without switch just checks the time but does not set anything). …
Setting up Secure Ubuntu server on VMware 1.      Insert the Ubuntu Server distribution CD or attach the ISO of the CD which is in the “Datastore”. Note that it is important to install the x64 edition on servers, not the X86 editions. 2.      Power on th…
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
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…

756 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