Announcement

Collapse
No announcement yet.

File permissions on Windows partitions (Solved - yippee!)

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    File permissions on Windows partitions (Solved - yippee!)

    Hi, help gratefully received!

    Last Friday I upgraded to Intrepid. The upgrade didn't work (long story)and as a result I reinstalled hardy from a ubuntu dvd, and now find myself back with an up to date hardy with KDE 3.5.10.

    My problem is that I have 2 windows partitions. I dual boot with Win XP. I finally seem to have got them to mount on start up with the disk and filesystems manager. However, these partitions are owned by root, and all files on them can only be changed by root. All my personal data is on one of these, a FAT 32 partition, which I have set up in this way to enable sharing. Not bothered about write access to the NTFS partition but the FAT 32 one is key.

    Using Konqueror or dolphin as sudo I can't change ownership but it appears I can change the permissions. I say "appears" because as soon as I close off that dialog everything has gone back again! The system is ignoring the changes I have just made. Can anyone shed some light on this please as it is driving me crazy?

    Thanks

    Ian

    #2
    Re: File permissions on Windows partitions

    I have a similar arrangement, XP on sda1, with Hardy on sda2/3, and (to add to my confusion ) Intrepid on sda5/6. Sda 7 is used as storage.

    On sdb1 is the backup of everything i really, really, need. It is formatted ntfs, so that i can see it from XP.

    When i installed Hardy, i mounted XP as user/windows/XP and sdb1 as user/windows/Non-local, and have no problems accessing either areas, nor deleting things - however, as you found out, i cannot change the permissions there, for they are owned by plugdev, so i leave things as they are.

    It sounds as though you may need to re-install, and tell the partitioner to mount your partitions differently, as mine mount automatically at boot, except the / of Intrepid, which i don't need to access from Hardy.

    When installing Intrepid, i also found it necessary to "Do not use this Partition" for / of Hardy, otherwise "All information on it will be Deleted".

    If you do re-install, when in the partitioning window, select the ntfs drive, tell it to use it as ntfs, and to mount it as /windows (or /dos) and put what name you like after that, so that it looks like (in the installer window); mount point: /windows/my-drive-name, and with the fat32 partition use it as fat32, mount it as: windows/my-drive-name - which must not be the same as the ntfs drive.

    Maybe someone will come along with an easier and better way, but that is i would be inclined to do it.

    I hope this helps. Good Luck.

    Comment


      #3
      Re: File permissions on Windows partitions

      Therein, it would seem, lies my mistake! During the install I only configured root and home and left the windows drives alone.

      I shall give it a whirl now.

      Thanks

      Ian

      Comment


        #4
        Re: File permissions on Windows partitions

        You are Most Welcome.

        I hope it works.... well, it does for me.

        Comment


          #5
          Re: File permissions on Windows partitions

          here is my fstab (Hardy) for my fat32 partition:
          UUID=47CC-6B54 /Data vfat utf8,umask=007,uid=0,gid=46,auto,rw,nouser 0 1

          I don't have a ntfs partition

          But you should be able to mount it from system settings->advanced->disks&files, tell it to mount automaticly at boot give it the permissions you want. Then you can edit your ntfs fstab to reflect the above (with out the:UUID=47CC-6B54 /Data vfat ) .
          HP Pavilion dv6 core i7 (Main)
          4 GB Ram
          Kubuntu 18.10

          Comment


            #6
            Re: File permissions on Windows partitions

            Hi Fintan - so I might not need to reinstall? Certainly worth a shot!

            Here is my /etc/fstab file (or at least the bit that relates to those 2 partitions)

            /dev/sda1: UUID="60A48E14A48DED3A" TYPE="ntfs"
            /dev/sda2: UUID="47DC-5B75" TYPE="vfat"

            /dev/sda2 /media/disk auto nouser,atime,auto,rw,nodev,noexec,nosuid 0 0
            /dev/sda1 /media/disk-1 auto nouser,atime,auto,ro,nodev,noexec,nosuid 0 0

            The mount point names disk and disk-1 were allocated on install by ubuntu 8.04. I would prefer Windows (for sda1) and data (for sda2)

            I assume the term Data is the name you have given to your mount point? So if I edited the lines so as to combine what I have and what you have suggested and wound up with the following line for sda2:

            /dev/sda2: UUID="47DC-5B75"/Data vfat utf8,umask=007,uid=0,gid=46,auto,rw,nouser 0 1

            That ought to produce the effect I need? If it can it would save me a whole load of work!

            Couple of points: The UUID is in "" on mine but isn't on yours. Is that a problem? Also, is there a space between the UUID number and the / that precedes data?

            Thanks, as always, for the help.

            Ian

            Comment


              #7
              Re: File permissions on Windows partitions

              I've played around a bit more, and think I have made some headway.

              Correct me if I am wrong, but would creating a mount point simply be for want of a better description creating a gateway or a link to the drive itself, rather than moving any data at all? The reason I ask is that in disks and file-system settings I configured the sda2 (FAT 32) drive with a mount point of Data and a folder with a setting enabling the user to enable/disable. I then found that a folder called data had appeared in my home directory. It worked perfectly in that as user I could open close and save files, and a test file that I saved to it was visible and accessible from Windows. So the conclusion I drew was that the mount point created within the home folder was simply a "view" of the drive and that no files were actually placed in the home directory. Would that be a realistic assumption?

              Switching the mount point back to sda2 resulted in the "data" folder being empty and I deleted it. I could access the files by going to the new location but even though I had configured it so that any user could enable or disable it write access was still restricted to root and even as root I could not change permissions.

              Is my understanding right, and having the mount point within the home directory a proper solution to this?

              Thanks

              ian

              Comment


                #8
                Re: File permissions on Windows partitions

                Putting the mount point in your home directory will limit access to the device to you (the user). That may be OK fine on a single-user desktop system -- if so, you're done.

                *buntu systems normally put mount points in /media, where they can be made available to multiple users of the system/network. Quite awhile back, I wrote a little "how-to" regarding a USB pen drive that was formatted NTFS. It may shed some light on the process, even though your situation is not exactly the same -- the principles still apply:

                http://kubuntuforums.net/forums/inde...opic=3084679.0

                Comment


                  #9
                  Re: File permissions on Windows partitions



                  Yes, that's where it's always been (well, not quite - when I started using Linux it was in the /mnt directory).

                  It is a single user machine - I don't expect anyone else to have a user account on it. Having copied the windows dlls into my home wine directory I don't think I need access to the ntfs drive any more. The files on the FAT 32 partition are all mine too so restricting access to my user account is not a problem.

                  Is my assumption about what a mount point actually is a correct one?

                  Thanks

                  Ian

                  Comment


                    #10
                    Re: File permissions on Windows partitions

                    You can "mount" anything anywhere. So as fa as I know your assumption is correct. (I am going to get flak from the real experts )

                    Since I always keep my /home on a different partition and "mount my other partitions on under /media (under #ubuntu)
                    i never have a problem.

                    I assume the term Data is the name you have given to your mount point? So if I edited the lines so as to combine what I have and what you have suggested and wound up with the following line for sda2:

                    /dev/sda2: UUID="47DC-5B75"/Data vfat utf8,umask=007,uid=0,gid=46,auto,rw,nouser 0 1

                    That ought to produce the effect I need? If it can it would save me a whole load of work!

                    Couple of points: The UUID is in "" on mine but isn't on yours. Is that a problem? Also, is there a space between the UUID number and the / that precedes data?
                    Yep /Data was t6he name I gave it at install, but you can do that at any time or give it another name. with sys settings-advanced disks & hardrives.

                    This:
                    UUID="47DC-5B75 /Data vfat utf8,umask=007,uid=0,gid=46,auto,rw,nouser 0 1
                    should look look this:

                    UUID=youruuid /Data vfat utf8,umask=007,uid=0,gid=46,auto,rw,nouser 0 1
                    if in doubt post your whole fstab
                    HP Pavilion dv6 core i7 (Main)
                    4 GB Ram
                    Kubuntu 18.10

                    Comment


                      #11
                      Re: File permissions on Windows partitions

                      Originally posted by The Liquidator

                      /dev/sda1: UUID="60A48E14A48DED3A" TYPE="ntfs"
                      /dev/sda2: UUID="47DC-5B75" TYPE="vfat"

                      /dev/sda2 /media/disk auto nouser,atime,auto,rw,nodev,noexec,nosuid 0 0
                      /dev/sda1 /media/disk-1 auto nouser,atime,auto,ro,nodev,noexec,nosuid 0 0
                      I just noticed the quote marks around the UUIDs -- Fintan is right, those are a deal-killer in the /etc/fstab file. They look that way in the output of
                      Code:
                      sudo blkid
                      as shown, but you can't have the quote marks in the line in /etc/fstab.

                      Comment


                        #12
                        Re: File permissions on Windows partitions

                        So, one way or another my fstab file has gone a bit flaky!

                        I have now set up a data mount point in my home directory from within system settings, and the output of my fstab file is now:

                        /dev/sda1: UUID="60A48E14A48DED3A" TYPE="ntfs"
                        /dev/sda2: UUID="47DC-5B75" TYPE="vfat"

                        /dev/sda2 Data vfat uid=1000,gid=0,auto,rw,users 0 0
                        /dev/sda1 auto nouser,atime,auto,rw,nodev,noexec,nosuid 0 0

                        Taking it one step at a time, if I copied Fintan and had the line


                        /dev/sda2: UUID=47DC-5B75/Data vfat utf8,umask=007,uid=0,gid=46,auto,rw,nouser 0 1 (note removal of quotes) I ought to get a mount point called data in the media directory which would be the VFAT partition which I can access as user?

                        Sorry to be a pest but I would like to understand this a bit more. Thanks as always!

                        Comment


                          #13
                          Re: File permissions on Windows partitions

                          Originally posted by The Liquidator

                          /dev/sda2: UUID=47DC-5B75/Data vfat utf8,umask=007,uid=0,gid=46,auto,rw,nouser 0 1 (note removal of quotes)
                          Also remove the orange stuff, and make sure there is a space between the UUID and the mount point /Data. If you need it for yourself, to remember what partition it is, do it on two lines like this:

                          # /dev/sda2
                          UUID=47DC-5B75 /Data vfat utf8,umask=007,uid=0,gid=46,auto,rw,nouser 0 1

                          Comment


                            #14
                            Re: File permissions on Windows partitions

                            Thanks a lot, that seems to work, although the data mount point is in the root directory rather than media (although when I access it via the system menu it's in storage media.

                            Also, the first time I needed to "enable" the partition via system settings (even though I rebooted after changing my fstab file) but it seems to have worked on subsequent test reboots so fingers crossed.

                            Many thanks to the 3 of you for your swift support, which really has helped me get going again. The moral? Don't just back up home.

                            Actually, whilst on the subject I know we all (should) backup our home and other data files regularly, but if I had backed up this file before a reinstall perhaps I would have been back up and running much quicker. I'm sure there must be other files to which this applies. Are there any other system files that you experts back up on a regular basis?

                            Thanks for saving me from a 3rd reinstall in as many days. However, I've noted the way you do things aged hippy and if I ever need to reinstall it again I'll follow your tips.

                            Thanks

                            Ian

                            Comment


                              #15
                              Re: File permissions on Windows partitions

                              You are most Welcome.

                              I'm glad you were able to get it back without a re-install, that's what i would have done.... but i just enjoy the excitement, and that wonderful feeling of .... ahhhh, home again - when it is all in place.

                              An install usually lasts anything up to a fortnight to three weks.

                              Comment

                              Working...
                              X