Skip to content
View in the app

A better way to browse. Learn more.

Unraid

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

I deleted a share in the command line - foolish?

Featured Replies

I had two shares I no longer wanted but unRAID refused to remove using the suggested method (ie, clear out the share then delete the share name in the Web GUI). I tried using rm -r * in the terminal in the correct folder, which appeared to work as once i'd listed the directory's contents (and hidden files) it showed nothing - but still in the Web GUI the share wasn't listed as empty.

 

So I went ahead and deleted the share in the command line using rm /mnt/user/deleteme (or something like that - I'm a bit of a trial-and-error noob) rebooted my server, and the share is no longer listed in the Shares list.

 

So I appear to have done it... but I have a niggling feeling that this wasn't the best way of doing it. Might I have cocked something up, and/or are there likely to be any other files left behind I need to tweak to remove all traces of the shares I deleted by this method? I notice in the /boot/config/shares folder it still lists the deleted shares' cfg files...

Sounds like you got it straightened out. Was this share set to use cache disk?

  • Author

Thanks trurl - no I don't have a cache disk.

Unless you delete the share from the WebGUI, unRAID will not delete the <share>.cfg file, but won't load it either, so it's safe to remove it or leave it there.

 

Next time you can use "find" to delete files, since it export also all hidden files; "rm" doesn't remove them.

 

$ find /mnt/user/Share -exec rm -rf '{}' \;

  • Author

Thanks gfjardim!

 

And thanks for the command suggestion. So does the ls -a command not list hidden files properly? Cos I tried that in both shared folders and they came up empty (well, they showed "." and "..").

What you did was fine. rm -r on the share will get rid of it.

 

Basically, on array starting unRAID reads each disk and every top level directory is turned into a user share. So, delete the share directory off every disk and the share goes away. You can delete the config file if you want to get rid of all traces it existed. All the file remaining means is that if you created a directory on any disk with that same share name it would appear as a user share again with the configuration that was previously set.

  • Author

Thanks lionelhutz. I'm confused though - I set up a share called "buffalo" through the cmd line while trying to mount an external drive with Snap (it didn't work in the end because it was formatted in ext4). The share doesn't appear in the unRAID web GUI, yet it's there when I look at my TOWER on my network (through Windows anyway).

 

I don't think I've rebooted my server since I tried this though so perhaps that's why it's not gone?

Maybe you have to stop and start the array.

Archived

This topic is now archived and is closed to further replies.

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.