NETGEAR is aware of a growing number of phone and online scams. To learn how to stay safe click here.

Forum Discussion

RaedyNas's avatar
RaedyNas
Aspirant
Jun 28, 2023
Solved

Delete folder starting with double backslash

Usuing ssh, how to remove a folder that has 2 backslashes? I can't cd or rm on the folder. From pic I would like to remove \\2020servertower and \\NAS-EA-70-E5   ReadyNas OS6 Pro
  • StephenB's avatar
    Jun 29, 2023

    RaedyNas wrote:

    Usuing ssh, how to remove a folder that has 2 backslashes? I can't cd or rm on the folder. From pic I would like to remove \\2020servertower and \\NAS-EA-70-E5

     


    How did you manage to create them?

     

    Note the file names aren't \\2020servertower and \\NAS-EA-70-E5.  The single backslash isn't part of the path, so the full names include everything after the single backslash.  That includes the spaces.

     

    First do an ls -als to let you know if you are dealing with files or folders.  It wouldn't surprise me if these are actually soft links.  They could also somehow be mount points, so maybe run this also, and see if it returns any results:

    mount | grep '\\'

     

    You could try using wildcards - ??2020servertower* and ??NAS-EA-70-E5*

     

    Or you could try putting a single quote around the full file name.

     

    Either way, be very careful.  You are working in the system root, and if you use the wrong commands you could easily end up with an unbootable NAS.  I suggest using the -i option in rm (requiring confirmation before every deletion)

NETGEAR Academy

Boost your skills with the Netgear Academy - Get trained, certified and stay ahead with the latest Netgear technology! 

Join Us!

ProSupport for Business

Comprehensive support plans for maximum network uptime and business peace of mind.

 

Learn More