5 Replies Latest reply: Feb 19, 2014 6:05 AM by Dude! RSS

chown: changing ownership of u01: operation not permitted.

NitishKumar1989 Newbie
Currently Being Moderated

Hi

 

I am dual booting Window 8 and Oracle Linux 6 on my system. Both OS is working perfectly. I have one NTFS partition "/dev/sda4" which gets mounted with no issues, when using mount command.

 

In my / directory of linux system I have created u01 folder. I changed the ownership of this u01 folder from root:root to  oracle:oinstall (oracle user and oinstall group). Now when I am mounting /dev/sda4 to u01 using:
sudo mount /dev/sda4 /u01


It is getting mounted perfectly but the ownership of u01 is getting changed from oracle:oinstall to root:root again.

Now I am trying to change it back to oracle:oinstall using:
sudo chown oracle:oinstall /u01

 

But it is showing error: "chown: changing ownership of u01: operation not permitted. "

 

Note: My username is oracle and group is oinstall. I have put oracle user in  /etc/sudoers file:
      oracle ALL=(ALL) NOPASSWD:ALL

 

Thanks

Nitish

  • 1. Re: chown: changing ownership of u01: operation not permitted.
    Dude! Guru
    Currently Being Moderated

    I don't know what good it would do to mount a NTFS partition, but normally you need to change the permission while the device is mounted. When you remount the device or partition it should take the permissions from the mounted filesystem. If it is not working I suggest you try as root. Perhaps you have an error in you sudoers file, but anyway I see no point in giving Oracle full superuser privileges instead logging in as root account directly.

  • 2. Re: chown: changing ownership of u01: operation not permitted.
    NitishKumar1989 Newbie
    Currently Being Moderated

    Dude,

     

    Actually I wanted to install  oracle database in my linux system. I thought of putting database binaries in my NTFS partition. Everything was worknig fine. I was able to install oracle database such that the binaries are in NTFS partition.

    The only problem was that I was not able to change ownership from root:root to oracle:oinstall.  This is recommended by Oracle.

     

    It doesnt matter you are root user or any user you wont be able to change ownsership.

    I found out the probelm. Thing is that,  no user can change ownership of NTFS or FAT system. It will always be mounted as root:root. I formatted the partition in EXT2 format and mounted it to /u01 folder. It was root:root then I changed it to oracle:oinstall by chown command and it was successfull.

     

    If you have any other idea or workaround please let me know.

     

    Thanks

    Nitish

  • 3. Re: chown: changing ownership of u01: operation not permitted.
    Dude! Guru
    Currently Being Moderated

    That was actually my doubt about NTFS and why I asked what good it will do.

     

    Apparently The problem is that NTFS partitions does not support Linux file permissions. Here is some info about Ubuntu with a work-around that might apply to NTFS under Enterprise Linux too. So you might have to specify uid ,gid and umask with the mount command:

     

    HOWTO: Mount NTFS partitions with specific ownership/permissions


    Anyway, why bother using a partitions under Linux? What are you trying to accomplish?

  • 4. Re: chown: changing ownership of u01: operation not permitted.
    NitishKumar1989 Newbie
    Currently Being Moderated

    Dude,

     

    Thanks for the link, hope it will work.

    I wanted to create production server scenario in my home system where all products are installed in a partition which can be mounted from one linux machine to another. It was just for practical learning purpose.

     

    Anyways thanks for your help.

     


  • 5. Re: chown: changing ownership of u01: operation not permitted.
    Dude! Guru
    Currently Being Moderated

    What kind of production scenario uses a NTFS partition to store database files under Linux? And why would you consider NTFS? Are you sharing files between Linux and Windows? Can you mount a NTFS partition that is currently in use. There is no reason to use NTFS to share files under Linux. If you want to share files with a MS-Windows based system, use ftp, nfs, or samba. Or find a driver for Windows that allows you to read EXT3 if you want to mount the physical device.

Legend

  • Correct Answers - 10 points
  • Helpful Answers - 5 points