I have a few shared ntfs partitions that I always want to mount when I log into opensuse and I am looking for advice on the best method to get that working. I found a few threads on this but all of them asked for specific information to taylor a solution.
The entries in red and those that I need to auto mount. I manually mounted these before running df. Please let me know if there is any other information that is necessary, the above is all I could think of.
This is a multi-boot box and these partitions are shared with other OSs. One of them contains my email and web apps and the other contains data that I always will need when I am in opensuse. At this point, I have to boot into suse and then manualy mount these partitions by doing something like clicking on the partition in dolphin and then entering the root password. This is not the end of the world to have to do, but since I will need to do this every time I boot into suse, I think it makes sense to automate the process. I also have a virtual machines partition that I will need to mount at some point a well.
When you want partitions to be mounted at boot, use YaST > System > Partition manager. It will create the mount point you define for you and the fstab entry. The most important thing there is NOT to format! The rest must be quite clear. Ask if you hesitate.
There is no application called exactly, “partition manager”. There is an application called, “expert partitioner”. If I “edit” one of the partitions I need to auto mount, there are options for mount point.
The options for mount point are,
I would have expected to mount these in
where partitions appear when I mount them through dolphin, or perhaps somewhere under /dev. It looks like I can type in a path for the mount location. Does it make any difference where I mount the partition? Should I use one of the locations in the list or try typing in my own location?
I may be over thinking this but I think that partition management is on of those tasks where it is better to ask more questions up front and fewer later on trying to fix the mess you made when you didn’t know what you were doing.
It seems like it would be straightforward to manually enter,
as the mount point. That would mount the partition where they are being mounted now thorught dolphin. Does that seem like a reasonable approach?
As explained above, those are (often used) suggestions. You can type there at will.
And as explained also, do not use mount points inside /var, /run or /media. A directory special “designed” to take mount points is /mnt. So something like /mnt/music is perfect. But when this is to be used by only one user, you can also mount inside that users home directory e.g. /home/<username>/music.
An alternate way of handling thisis mount at /mnt/music and then make a symlinkl
ln -s /mnt/music /home/<username>/music
It all depends on the usage (and of course music is just an example).
I created a new directory insde of /mnt for one of the partitions I need to auto-mount, /mnt/shared_data. I did this by changing to root (su), navigating to /mnt and doing mkdir. Is there anything I should know about as far as ownership or permissions for /mnt/shared_data?
The main reason I ask about permissions is that thought my partitions appear to be mounted (the content appears in dolphin), the applications that are reading profiles from that location can’t seem to open the profiles. Before, when I mounted the partitions by clicking on the partition in dolphin and entering the root password, I could then use the applications that were reading their profiles from the partition. Now, the application is acting like the profile is busy.
I suspect the issue is that I created the folder /mnt/applications as su and my <username> doesn’t have the right permissions for the /mnt folder. Do I need to add my user to a group for /mnt/applications or something like that or is the problem something else?
As I explained earlier, when you use YaST, it will create the mountpoint for you and of course with the correct owner and permissions.
Only thing might be that we have to adapt a few options (and maybe ownership of the mountpoint) later because I guess it is a non–Linux file system.
In Yast partition manager, there are some “fstab options” under the mounting options section. I don’t see anything there like assigning the user who owns the mount point. There is a variable value for “Arbitrary Option Value” that has the same value as the output from grep shared_volume /etc/fstab listed above. I guess that value can be edited from the partition manager.
OK, I guess the only thing we have to change is the following.
In the fstab entry you see the option gid=users. Add there (before or after does not matter)
(asuming that user1 is the user that should own the files) (the , should be in the correct place to function as separator of course)
Then umount and mount (or reboot) and check if it helps.
Report back if you have still problems.
It looks like I have it sorted now. Adding the user id didn’t fix the issue, so I looked at some other things and realized that my application was looking for the profile folder in the path from the old mount point in /var/run/media/ where the partition was mounted from dolphin. I changed the path in the application and now everything works. I can access all of the files in the partition with apps like kate, so I don’t think there are any permission issues. I don’t know if the uid fstab entry is necessary or not, but I guess it doesn’t do any harm.
Thanks again for the help, it is always nice to read posts from someone who takes the time to explain the rational behind the technique.