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
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.
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.
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:
Anyway, why bother using a partitions under Linux? What are you trying to accomplish?
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.
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.