Locked folder Ubuntu

Lyreen -  
 Anonymous user -
Hello, I have a problem.

I recorded .mp3 files on a USB stick from another computer. On mine, I appear as the owner, but I still can't rename a file. I also can't change the permissions to set the file access for the owner to "read and write".

Thanks in advance.
Configuration: Linux Firefox 3.0.9

18 answers

  1. celuiquifumeplein
     
    Hi, if you want to give permissions, you need to be in sudo

    sudo chown +youruser yourfolder

    and there you go
    2
  2. Lyreen
     
    papa@ubuntu:/$ chmod 777 /media/disk-1
    chmod: changing permissions of `/media/disk-1': Read-only file system

    It's made no difference...
    1
    1. leon91490 Posted messages 200 Registration date   Status Member Last intervention   47
       
      because it's the partition that is read-only....


      a disk consists of tracks and sectors within those tracks.. it can be read from and written to. then the Windows, Linux and other systems create file systems that can be mounted as read or write... Mounting means saying that a folder, for example /home, is the file system /dev/sda1 and then you can mount it as read or write... or deny access. Under Windows you can also specify whether a folder is writable or not. Under Linux as well, but in a more nuanced way... the file has an owner, a group, and others.

      if the file system is read-only... you will never be able to write to it. you can mount it as writable but I absolutely discourage that without knowing the reasons for this read-only status. Often it's due to a disk error. For example, I mounted a photo disk as read-only after a very bad manipulation. Backup software also mounts as read-only.

      there are also services in Linux that kill programs trying to write to specific folders.
      0
  3. Lyreen
     
    Mmh, no, not cool.
    I can't delete the files; and therefore can't add more.
    1
  4. Lyreen
     
    When I enter the code in the Terminal, it gives me this, and I'm no further ahead...

    papa@ubuntu:~$ chmod u+w /media/disk-1
    chmod: changing permissions of `/media/disk-1': Read-only file system
    0
  5. Anonymous user
     
    To make a file maximally accessible ^^ do the following:

    In a terminal, go to the location where the file you want to modify is located.
    Type ls -l
    type chmod 777 file_name
    type ls -l again
    to see what has changed.

    (works for folders too)
    0
  6. Lyreen
     
    Mmh, I don't really know much about it, how do we get to the place where the file I want to modify is located in a terminal?
    0
  7. Anonymous user
     
    with the command " cd "

    %cd /directory_name
    %cd /directory_name2
    ...
    %pwd
    to find out where you are
    %ls -l
    to get the list of files/directories

    The " % " should not be typed

    https://www.commentcamarche.net/faq/4801-guide-d-utilisation-du-shell-pour-debutant#xxv-comment-se-deplacer-dans-l-arborescence
    0
  8. Anonymous user
     
    You need to go to the directories located in "disk-1"
    Disk-1 is your USB stick, right?
    Try with the files on your stick.
    0
  9. Lyreen
     
    papa@ubuntu:/$ chmod 777 /media/disk-1/SOAD
    chmod: changing permissions of `/media/disk-1/SOAD': Read-only file system

    Same as always.
    0
  10. Anonymous user
     
    Really weird all this. Copy the files into a folder on the PC and try again.
    Just type the name of the file and not the entire path.
    0
    1. leon91490 Posted messages 200 Registration date   Status Member Last intervention   47
       
      it's the file system that is blocking.


      otherwise your trick will work...
      0
  11. Lyreen
     
    That works. Still, it's quite annoying to have to go through the office to get my key...
    0
  12. celuiquifumeplein
     
    or sudo chmod +tonuser tondossier? So I'm having a doubt

    but sudo is for sure because to grant permissions you need to have them
    0
  13. Anonymous user
     
    Yes, to perform these actions, you need to be in superuser mode.
    sudo is for Ubuntu, otherwise for another distribution:
    $su
    $password
    0
  14. jisisv Posted messages 3678 Status Moderator 936
     
    sudo mount -o remount,rw /the/path/to/the/usb

    --
    Gates vous a donné ^H vendu les fenêtres.
    GNU nous a donné toute la maison. (Alexandrin)
    0
  15. Anonymous user
     
    you do
    cd "Folder name" (to avoid making mistakes with sudo rm -r because it's a dangerous command)
    then sudo rm -r "Folder name that is located in the path you set with the cd command"

    Example:

    cd Documents/

    sudo rm -r Folder
    0