Page 1 of 2 12 LastLast
Results 1 to 10 of 20

Thread: [SOLVED] Changing group ownership.

  1. #1
    Join Date
    Apr 2006
    Location
    Galloway Twp. NJ
    Beans
    99
    Distro
    Ubuntu 10.04 Lucid Lynx

    [SOLVED] Changing group ownership.

    I'm attempting to use 8.04 server edition to make a centralized storage computer in my house, and I've encountered a pretty big problem right off the bat.

    The storage partition on my first drive is mounted into /share/public (which i created). I made a new user group to include the other members of my house, but when I try to change the folder's group ownership I am denied, even as root.

    Code:
    root@storage:/# chgrp 666 /d1storage/ -R
    chgrp: changing group of `/d1storage/music': Operation not permitted
    chgrp: changing group of `/d1storage/installers': Operation not permitted
    chgrp: changing group of `/d1storage/video/gamow.wmv': Operation not permitted
    chgrp: changing group of `/d1storage/video': Operation not permitted
    chgrp: changing group of `/d1storage/': Operation not permitted
    this method doesn't work either.

    Code:
    root@storage:/share# chown -hR alex:sharers /share/public/
    chown: changing ownership of `/share/public/music': Operation not permitted
    chown: changing ownership of `/share/public/installers': Operation not permitted
    chown: changing ownership of `/share/public/video/gamow.wmv': Operation not permitted
    chown: changing ownership of `/share/public/video': Operation not permitted
    chown: changing ownership of `/share/public/': Operation not permitted
    I can't figure out what I'm doing wrong. Sorry to be such a noob, but I need to get past this.

    Thanks
    Alex
    "Think your Yourself, Question Authority"

  2. #2
    Join Date
    Nov 2007
    Location
    NC, USA
    Beans
    829
    Distro
    Ubuntu 12.04 Precise Pangolin

    Re: Changing group ownership.

    Either become root or use sudo in front of the command.


    EDIT: Didnt read the last part. Unmount the share, chown it, then remount.
    Linux User #460341 || Ubuntu User #19510 || Unanswered Posts Team

  3. #3
    Join Date
    Apr 2006
    Location
    Galloway Twp. NJ
    Beans
    99
    Distro
    Ubuntu 10.04 Lucid Lynx

    Re: Changing group ownership.

    Please take a look at the code. note that I am logged in as root.

    I'm noob, but not that noob

    EDIT - ok saw your edit, trying that now, thanks
    "Think your Yourself, Question Authority"

  4. #4
    Join Date
    Apr 2006
    Location
    Galloway Twp. NJ
    Beans
    99
    Distro
    Ubuntu 10.04 Lucid Lynx

    Re: Changing group ownership.

    Awesome, thanks so much!
    "Think your Yourself, Question Authority"

  5. #5
    Join Date
    Apr 2006
    Location
    Galloway Twp. NJ
    Beans
    99
    Distro
    Ubuntu 10.04 Lucid Lynx

    Re: Changing group ownership.

    I spoke to soon on this one. When I unmount and run a recursive chgrp on the parent folder of the mount i get no errors, but when I remount the folder is still owned by the plugdev group, not my sharers group. Any more thoughts?
    "Think your Yourself, Question Authority"

  6. #6
    Join Date
    Mar 2008
    Location
    City of Pines
    Beans
    3,585

    Re: Changing group ownership.

    Quote Originally Posted by Aximilli View Post
    I spoke to soon on this one. When I unmount and run a recursive chgrp on the parent folder of the mount i get no errors, but when I remount the folder is still owned by the plugdev group, not my sharers group. Any more thoughts?
    To change group ownership, follow this format:

    Code:
    sudo chgrp system_groupname /location_of_files_or_folders
    Steady movement is more important than speed, much of the time. So long as there is a regular progression of Stimuli to get your mental hooks into, there is room for lateral movement. Once this begins, its rate is a matter of discretion.

  7. #7
    Join Date
    Apr 2006
    Location
    Galloway Twp. NJ
    Beans
    99
    Distro
    Ubuntu 10.04 Lucid Lynx

    Re: Changing group ownership.

    I thought it might help to show step by step what is happening to me.

    Code:
    alex@storage:/share$ cd /
    alex@storage:/$ ls -al
    total 104
    drwxr-xr-x  24 root root     4096 2008-06-05 15:45 .
    drwxr-xr-x  24 root root     4096 2008-06-05 15:45 ..
    drwxr-xr-x   2 root root     4096 2008-06-02 20:17 bin
    drwxr-xr-x   3 root root     4096 2008-06-03 20:02 boot
    lrwxrwxrwx   1 root root       11 2008-06-02 20:00 cdrom -> media/cdrom
    drwxr-xr-x   2 root root     4096 2008-06-02 20:00 d1storage
    drwxr-xr-x  14 root root    14460 2008-06-03 21:00 dev
    drwxr-xr-x 127 root root    12288 2008-06-05 23:31 etc
    drwxr-xr-x   5 root root     4096 2008-06-02 20:23 home
    drwxr-xr-x   2 root root     4096 2008-06-02 20:01 initrd
    lrwxrwxrwx   1 root root       32 2008-06-02 20:04 initrd.img -> boot/initrd.img-2.6.24-16-server
    drwx------   3 root root     4096 2008-06-03 20:53 .kde
    drwxr-xr-x  16 root root     4096 2008-06-03 19:37 lib
    drwx------   2 root root    16384 2008-06-02 20:00 lost+found
    drwxr-xr-x   4 root root     4096 2008-06-02 20:00 media
    drwxr-xr-x   2 root root     4096 2008-04-15 01:53 mnt
    drwxr-xr-x   2 root root     4096 2008-06-02 20:01 opt
    dr-xr-xr-x 106 root root        0 2008-06-03 20:59 proc
    drwxr-xr-x   5 root root     4096 2008-06-03 20:26 root
    drwxr-xr-x   2 root root     4096 2008-06-03 19:36 sbin
    drwxr-xr-x   3 root sharers  4096 2008-06-05 15:57 share
    drwxr-xr-x   2 root root     4096 2008-06-02 20:01 srv
    drwxr-xr-x  12 root root        0 2008-06-03 20:59 sys
    drwxrwxrwt  10 root root     4096 2008-06-05 07:35 tmp
    drwxr-xr-x  11 root root     4096 2008-06-02 20:21 usr
    drwxr-xr-x  17 root root     4096 2008-06-03 19:59 var
    lrwxrwxrwx   1 root root       29 2008-06-02 20:04 vmlinuz -> boot/vmlinuz-2.6.24-16-server
    -rw-------   1 root root        0 2008-06-03 20:52 .Xauthority
    alex@storage:/$ cd /share/
    alex@storage:/share$ ls -al
    total 40
    drwxr-xr-x  3 root sharers  4096 2008-06-05 15:57 .
    drwxr-xr-x 24 root root     4096 2008-06-05 15:45 ..
    drwxrwx---  5 root plugdev 32768 1969-12-31 19:00 public
    alex@storage:/share$ sudo umount /share/public/
    alex@storage:/share$ sudo chgrp -R sharers /share/public/
    alex@storage:/share$ ls -al
    total 12
    drwxr-xr-x  3 root sharers 4096 2008-06-05 15:57 .
    drwxr-xr-x 24 root root    4096 2008-06-05 15:45 ..
    drwxr-xr-x  2 alex sharers 4096 2008-06-05 15:57 public
    alex@storage:/share$ sudo mount -a
    alex@storage:/share$ ls -al
    total 40
    drwxr-xr-x  3 root sharers  4096 2008-06-05 15:57 .
    drwxr-xr-x 24 root root     4096 2008-06-05 15:45 ..
    drwxrwx---  5 root plugdev 32768 1969-12-31 19:00 public
    I assume this means that at every reboot the folders group ownership will change back to plugdev. I hope this information is helpful, despite being overly verbose.

    Thanks a lot for your time.

    Alex
    Last edited by Aximilli; June 6th, 2008 at 04:49 AM. Reason: make the code a little easier to spot out important stuff
    "Think your Yourself, Question Authority"

  8. #8
    Join Date
    Apr 2006
    Location
    Galloway Twp. NJ
    Beans
    99
    Distro
    Ubuntu 10.04 Lucid Lynx

    Re: Changing group ownership.

    Quote Originally Posted by iaculallad View Post
    To change group ownership, follow this format:

    Code:
    sudo chgrp system_groupname /location_of_files_or_folders

    I do believe that is the format I'm using, is it not?
    "Think your Yourself, Question Authority"

  9. #9
    Join Date
    Apr 2006
    Location
    Galloway Twp. NJ
    Beans
    99
    Distro
    Ubuntu 10.04 Lucid Lynx

    Re: Changing group ownership.

    well, Yay. My thread has just been spammed. Yippy for me.

    EDIT: Looks like this guy is spamming alot of other threads. Ban time.
    "Think your Yourself, Question Authority"

  10. #10
    Join Date
    Aug 2007
    Location
    Kottawa, Sri Lanka
    Beans
    7,387
    Distro
    Ubuntu 10.04 Lucid Lynx

    Re: Changing group ownership.

    Quote Originally Posted by Aximilli View Post
    well, Yay. My thread has just been spammed. Yippy for me.

    EDIT: Looks like this guy is spamming alot of other threads. Ban time.
    Don't worry, he's been taken care of. But in future, if you actually want spam to be taken care of then you should report it instead of going around posting threats to the spammer since it is pointless and is just wasting time.
    Think carefully before executing commands containing "rm", especially "sudo rm -rf ", if you require more information concerning this matter, read this.
    I am an experimenter, give me the most stable OS and I can make it unstable in a few hours.

    C == seriously fast == FTW!

Page 1 of 2 12 LastLast

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •