Announcement

Collapse
No announcement yet.

remove a directory that is busy?

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

    remove a directory that is busy?

    kubuntu 13.04
    Am installing systemrescuecd on a usb stick to bootup using ext4 filesystem.
    I copied the systemrescuecd files to isocdrom folder. Unfortunately I screwed up & used
    sudo cp cd /mnt/isocdrom, instead of sudo cp cd -r /mnt/isocdrom.
    How can I delete the contents of folder isocdrom, or delete folder completely?
    Am not that familiar with coding, so sure would appreciate some expert help.
    Last edited by Bumpalot; May 11, 2013, 02:12 PM. Reason: Correct a mistake!

    #2
    sudo rm -R /mnt/isocdrom
    Windows no longer obstructs my view.
    Using Kubuntu Linux since March 23, 2007.
    "It is a capital mistake to theorize before one has data." - Sherlock Holmes

    Comment


      #3
      Thanks for replying!
      sudo rm -R /mnt/isocdrom did not work - read only file! Any other suggestionss??

      Comment


        #4
        Is the CD 'unmounted' -- removed?
        Windows no longer obstructs my view.
        Using Kubuntu Linux since March 23, 2007.
        "It is a capital mistake to theorize before one has data." - Sherlock Holmes

        Comment


          #5
          There is no CD. Folder contains all the files extracted from the iso file.

          Comment


            #6
            Try sudo chattr -iR /mnt/isocdrom followed by sudo rm -R /mnt/isocdrom
            Windows no longer obstructs my view.
            Using Kubuntu Linux since March 23, 2007.
            "It is a capital mistake to theorize before one has data." - Sherlock Holmes

            Comment


              #7
              Code:
              bumpy@bumpyputer:~$ sudo chattr -iR /mnt/isocdrom
              [sudo] password for bumpy: 
              chattr: Inappropriate ioctl for device while reading flags on /mnt/isocdrom
              bumpy@bumpyputer:~$ sudo rm -R /mnt/isocdrom
              rm: cannot remove ‘/mnt/isocdrom/boot/grub/efi.img’: Read-only file system
              rm: cannot remove ‘/mnt/isocdrom/boot/grub/font.pf2’: Read-only file system
              rm: cannot remove ‘/mnt/isocdrom/boot/grub/grub-351.cfg’: Read-only file system
              rm: cannot remove ‘/mnt/isocdrom/boot/grub/x86_64-efi/acpi.mod’: Read-only file system
              rm: c

              Comment


                #8
                Code:
                sudo rm -rfv /mnt/isocdrom

                Comment


                  #9
                  Code:
                  bumpy@bumpyputer:~$ sudo rm -rfv /mnt/isocdrom
                  [sudo] password for bumpy: 
                  rm: cannot remove ‘/mnt/isocdrom/boot/grub/efi.img’: Read-only file system
                  rm: cannot remove ‘/mnt/isocdrom/boot/grub/font.pf2’: Read-only file system
                  rm: cannot remove ‘/mnt/isocdrom/boot/grub/grub-351.cfg’: Read-only file system
                  rm: cannot remove ‘/mnt/isocdrom/boot/grub/x86_64-efi/acpi.mod’: Read-only file system
                  rm: cannot remove ‘/mnt/isocdrom/boot/grub/x86_64-efi/adler32.mod’: Read-only file system
                  rm: cannot remove ‘/mnt/isocdrom/boot/grub/x86_64-efi/affs.mod’: Read-only file system
                  etc
                  etc

                  Comment


                    #10
                    This is weird.

                    What's the output of
                    Code:
                    sudo ls -al /mnt

                    Comment


                      #11
                      Code:
                      bumpy@bumpyputer:~$ sudo ls -al /mnt
                      [sudo] password for bumpy: 
                      total 20
                      drwxr-xr-x  5 root root 4096 May 12 07:36 .
                      drwxr-xr-x 29 root root 4096 May 11 23:05 ..
                      drwxr-xr-x  2 root root 4096 May 11 23:48 isocdrom
                      drwxrwxrwx  8 root root 4096 May 11 20:45 sdb7
                      drwxr-xr-x  2 root root 4096 May 12 17:16 usbstick
                      bumpy@bumpyputer:~$

                      Comment


                        #12
                        What says
                        Code:
                        sudo mount | grep isocdrom
                        ?

                        Comment


                          #13
                          SOLVED THE PROBLEM!!
                          rm --recursive yyy

                          Thanks for sticking with me - very much appreciated besides giving this Forum more credibility!!
                          Have opened a new Thread - Format a USB device from Linux
                          Hope you are around to assist!!

                          Comment


                            #14
                            Originally posted by Bumpalot View Post
                            rm --recursive yyy
                            The -r in the command I suggested is the same thing as --recursive. I'm not sure why it didn't work before but did this time. And, uh, what is yyy?

                            Comment

                            Working...
                            X