Announcement

Collapse
No announcement yet.

Cant copy folder with read access?

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

    Cant copy folder with read access?

    I have a little newbie problem here. What I want to do is to change ownership of the thunderbird (mozilla e-mail program) profile folder, so that it is not owned by root, but by me as ordinary user. This seems to be required as the user needs write access

    first, this is what it looks like now:
    Code:
    myuser@mycomp:~$ ls -ltrhp /windows/
    totalt 8,0K
    drwxr-xr-x  3 root root 4,0K 2006-03-06 23:20 thunderbird_sharedmail/
    I need to change both ownership and group on that file and I thought
    Code:
    sudo chown -R myuser. /windows/thunderbird_sharedmail
    should do the necessary trick.

    Except it did not, all I got was the reply:
    this and that filename  ... operation not permitted

    I have been trying to find out why it is not permitted, but I am kind of stuck with that now

    I tried another way to fix the problem: I renamed the folder (as root, using sudo), and then tried to copy it as myuser:
    Code:
    myuser@mycomp:/windows$ sudo mv thunderbird_sharedmail thunderbird_sharedmail.old
    myuser@mycomp:/windows$ cp thunderbird_sharedmail.old thunderbird_sharedmail
    cp: omitting directory «thunderbird_sharedmail.old»
    That pretty much sums it up, another failure - what is wrong, anybody have an idea? Help will be greatly appreciated.

    (irc: heinkel_111 on #kubuntu)








    #2
    Re: Cant copy folder with read access?

    Is /windows your NTFS Windows partition? If so, then it's read-only, because the NTFS kernel module doesn't have (safe) write support.

    Comment


      #3
      Re: Cant copy folder with read access?

      Thanks for helping, but no,  /windows/ a FAT32 partition.

      However I am increasingly sure there must be something wrong with permissions on the filesystem level, can anyone tell by looking at my /etc/fstab ?

      Code:
      myuser@mycomp:/$ more etc/fstab
      # /etc/fstab: static file system information.
      #
      # <file system> <mount point>   <type>  <options>       <dump>  <pass>
      proc            /proc           proc    defaults        0       0
      /dev/hda5       /               reiserfs notail          0       1
      /dev/hda1       /media/winxpsys   ntfs    ro,auto,user,fmask=0111,dmask=0000        0       0
      /dev/hda2       /media/windoc     ntfs    ro,auto,user,fmask=0111,dmask=0000        0       0
      /dev/hda6       /windows        vfat    defaults        0       0
      /dev/hda4       none            swap    sw              0       0
      /dev/hdc        /media/cdrom0   udf,iso9660 user,noauto     0       0
      /dev/hdd        /media/cdrom1   udf,iso9660 user,noauto     0       0
      /dev/fd0        /media/floppy0  auto    rw,user,noauto  0       0
      EDIT: question would be, what kind of  permission is really "defaults", where can I check that?

      Comment


        #4
        Re: Cant copy folder with read access?

        defaults won't give you permission.

        Go to KMenu > System > Konsole and type
        Code:
        sudo umount /windows
        sudo cp /etc/fstab /etc/fstab_backup
        sudo kwrite /etc/fstab
        Replace this line
        Code:
        /dev/hda6    /windows    vfat  defaults    0    0
        with this line
        Code:
        /dev/hda6    /windows    vfat  iocharset=utf8,umask=000    0    0
        Save and exit KWrite. Then type
        Code:
        sudo mount -a
        Linux is ready for the desktop--but whose desktop?<br />How to install software in Kubuntu

        Comment


          #5
          Re: Cant copy folder with read access?

          thanks for the reply! I was getting to the point it could be nothing but how the filesystem was mounted as I could not change permissions even as root using chown, chmod, etc.

          2 questions:
          in/out characterset: will utf-8 work for me - nordic special characters like æøå ÆØÅ will be ok in filenames etc vs files stored from "windows side"?

          defaults: where is "defaults" (for permissions) defined? Is it an alternative to modify default permissions instead of setting custom permissions per filesystem? (There will be more fielsystems later, i am adding a new physical disk to the system within the next couple of weeks).

          Comment


            #6
            Re: Cant copy folder with read access?

            Easy way:

            You can set the option "user".
            So every time a user mounts a filesystem without rightsmanagement (e.g. fat) the fs has the same rights as the user.

            Sorry, I don know about UTF-8 encoding for your nordic special characters.

            Comment


              #7
              Re: Cant copy folder with read access?

              Originally posted by heinkel_111
              in/out characterset: will utf-8 work for me - nordic special characters like æøå ÆØÅ will be ok in filenames etc vs files stored from "windows side"?
              It should work, AFAIK

              Originally posted by heinkel_111
              defaults: where is "defaults" (for permissions) defined? Is it an alternative to modify default permissions instead of setting custom permissions per filesystem? (There will be more fielsystems later, i am adding a new physical disk to the system within the next couple of weeks).
              It's possible (but IMO not advisable) to change the default permissions, but the default (write for owner, read for others) should be fine in most cases...different mounts, media and filesystem will need different permissions, so you'll have to set permissions individually even with changing the 'default'.

              Originally posted by MrBoe
              You can set the option "user".
              So every time a user mounts a filesystem without rightsmanagement (e.g. fat) the fs has the same rights as the user.
              'user' is not the best option to use with filesystems that are 'auto' mounted during boot, 'user' will allow a regular user to mount the filesystem, but since the boot process is run as root, all auto-mounted file-systems will still be owned by root.
              Instead you can use the 'uid=USER' option to (auto)mount the filesystem owned by USER.

              'user' is fine with filesystems that are not set to 'auto' mount, like removable media.

              Edit: 'man mount' will give you information on all possible options, if you're interested

              Comment

              Working...
              X