Find the answer to your Linux question:
Results 1 to 4 of 4
I wanted to ask about this just so that...I understand the logic of what happened. I was reinstalling Ubuntu, tried renaming my home folder from User to user (using the ...
  1. #1
    Linux Guru jmadero's Avatar
    Join Date
    Jul 2007
    Location
    California
    Posts
    1,958

    rm -R behaviour?

    I wanted to ask about this just so that...I understand the logic of what happened.

    I was reinstalling Ubuntu, tried renaming my home folder from User to user (using the live distro)

    Told me that the folder already existed (but I didn't see anything, I saw User but not user)

    After several attempts I just thought "why not do sudo rm for the folder I don't see"

    so I did sudo rm -R /home/user

    my entire home folder named User was deleted.

    Does Ubuntu not know the difference for capitals with the rm command? Just curious more than anything, I doubt I'll make the mistake twice....
    Bodhi 1.3 & Bodhi 1.4 using E17
    Dell Studio 17, Intel Graphics card, 4 gigs of RAM, E17

    "The beauty in life can only be found by moving past the materialism which defines human nature and into the higher realm of thought and knowledge"

  2. #2
    Linux Guru coopstah13's Avatar
    Join Date
    Nov 2007
    Location
    NH, USA
    Posts
    3,149
    if you look at the man page for rm, -r and -R are the same option, i should add that this is even true on my centos4 box

  3. #3
    Just Joined!
    Join Date
    Dec 2007
    Location
    Bangalore
    Posts
    33
    rm -R

    Recursively deletes everything, the directory and all the contents inside it.
    as a fool i tried this a long time back and I removed some 20 + GB of data.

    Be very sure before running it next time.

  4. #4
    Linux Guru
    Join Date
    Nov 2007
    Location
    Córdoba (Spain)
    Posts
    1,513
    Quote Originally Posted by jmadero View Post
    Does Ubuntu not know the difference for capitals with the rm command? Just curious more than anything, I doubt I'll make the mistake twice....
    I can only think of one reason why this could happen: the partition was vfat or something similar. On vfat you can't have two files named "file" and "File" on the same directory, since it's intended to be compatible with windows.

    If that wasn't the case, then either your shell or the basic linux tools have been patched in a way that they should never be. I can't be sure about that because I am not an Ubuntu user (and this would be yet another reason to add to the long list of reasons not to use Ubuntu). But until we can find the real reason, I will assume for good that the Ubuntu developers are not that insane.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
...