Jump to content

Recommended Posts

Posted

This is driving me mad...

 

I am trying to run a Veeam tape backup on a large staff shared area where all the departments have their own folders and keep their resources in them. There seems to be an issue with Veeam that it will fall over if it finds a folder that doesn't have a name, and until they fix this bug I need to find these folders and remove them.

 

Trouble is that there are thousands of folders on the shared area and are nested beyond belief. Does anyone have any suggestions how I might go about finding them all before my head explodes!

 

Thanks!

 

BTW If this is the wrong area then apologies as the share is hosted on a 2012 server!

Posted

I'm sure someone will be along with a better solution soon, but have you tried running tree from the command prompt?

 

Do this on the server itself and open a command prompt, cd to the shared folder and run

tree /A >> "%userprofile%\desktop\folders.txt"

 

this will output a list of all the folders within the shared drive and write it all to a text file called folders.txt in the desktop folder of the currently logged on user. the /A switch tells it to use ascii characters otherwise the output will have unicode characters in it

 

you will have to look through the list manually but it should make it a bit easier for you

  • Thanks 1
Posted
I'm sure someone will be along with a better solution soon, but have you tried running tree from the command prompt?

 

Do this on the server itself and open a command prompt, cd to the shared folder and run

tree /A >> "%userprofile%\desktop\folders.txt"

 

this will output a list of all the folders within the shared drive and write it all to a text file called folders.txt in the desktop folder of the currently logged on user. the /A switch tells it to use ascii characters otherwise the output will have unicode characters in it

 

you will have to look through the list manually but it should make it a bit easier for you

 

Thanks... I hadn't thought of this so will give it a go and see what I get. Anything has got to be better than trying to find them manually. I don't think there are many of them, it's just it's a huge share!

Posted
Out of curiosity, what do you mean by a file with no name? Surely it's got "a" name? :s

 

Steve

 

No... they don't have a name - there is just a folder icon! They all seem to relate to some sort of Microsoft install as the folders beneath them are always the same and are empty. We have also found a load of folders with what appears to be Chinese/Korean characters in the name which has caused the same problem with Veeam.

 

Very odd

Posted

Are you sure the writing of the folder name isn't white ?

(erm, joke)

 

 

You're client machines had viruses on them? Never seen that unless on a really :censored: machine.

How unusual.

 

Can you not get Veeam to ignore them ? Why Veeam anyway. Can't you just dump them on an external HDD and leave them ?

 

I'd be slightly tempted to xcopy them to somewhere else and see if it copied those blank folders. If not, delete them.

 

Otherwise you've got a large folder trawling task on your hands m8.

Posted

Alt+0160? Would be the blank char it's using i bet, if you try to rename it does it show as like 1 space?

 

Not sure if you can search by that though.

 

Steve

  • Thanks 2
Posted
Are you sure the writing of the folder name isn't white ?

(erm, joke)

 

 

You're client machines had viruses on them? Never seen that unless on a really :censored: machine.

How unusual.

 

Can you not get Veeam to ignore them ? Why Veeam anyway. Can't you just dump them on an external HDD and leave them ?

 

I'd be slightly tempted to xcopy them to somewhere else and see if it copied those blank folders. If not, delete them.

 

Otherwise you've got a large folder trawling task on your hands m8.

 

No unfortunately Veeam falls over (the tape backup part, that is) when it encounters these folders as it can't enumerate the size of the backup. I could copy/backup the the whole share onto a big HDD but as we have a unused tape library it seems a shame to let it stand idle. The share is also backed up to the cloud so this isn't critical - hence there isn't any real urgency.

 

It sure is mind numbing trying to find them though!

Posted (edited)

This seems to work fine on my system for testing it:

 

get-childitem $Path -attributes D -recurse -include " "

(Note the " " isn't a space you need to type it as ALT+255)

 

Searches through whatever folder your powershell is in (e.g. shared area) and when it hits a bad one:

 

PS C:\test\test> get-childitem $Path -attributes D -recurse -include " "


   Directory: C:\test\test


Mode                LastWriteTime     Length Name
----                -------------     ------ ----
d----        02/06/2015     08:33            test
get-childitem : [b][color="#FF0000"]Could not find item C:\test\test\test\ \[/color][/b].
At line:1 char:1
+ get-childitem $Path -attributes D -recurse -include " "
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   + CategoryInfo          : ObjectNotFound: (C:\test\test\test\\:String) [Get-ChildItem], IOException
   + FullyQualifiedErrorId : ItemNotFound,Microsoft.PowerShell.Commands.GetChildItemCommand

 

Might be a pain if you got hundreds, but easier than manual :D

 

Steve

Edited by Steve21
  • Thanks 1
Posted
This seems to work fine on my system for testing it:

 

get-childitem $Path -attributes D -recurse -include " "

(Note the " " isn't a space you need to type it as ALT+255)

 

Searches through whatever folder your powershell is in (e.g. shared area) and when it hits a bad one:

 

PS C:\test\test> get-childitem $Path -attributes D -recurse -include " "


   Directory: C:\test\test


Mode                LastWriteTime     Length Name
----                -------------     ------ ----
d----        02/06/2015     08:33            test
get-childitem : [b][color="#FF0000"]Could not find item C:\test\test\test\ \[/color][/b].
At line:1 char:1
+ get-childitem $Path -attributes D -recurse -include " "
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   + CategoryInfo          : ObjectNotFound: (C:\test\test\test\\:String) [Get-ChildItem], IOException
   + FullyQualifiedErrorId : ItemNotFound,Microsoft.PowerShell.Commands.GetChildItemCommand

 

Might be a pain if you got hundreds, but easier than manual :D

 

Steve

 

Thanks Steve

 

Its throwing up lots of errors because many of the path names are more than 248 chars long.

 

The scary thing about this is that many of the folders are backups of memory sticks etc and they will re-appear when they backup them up again :deadhorse:

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now



×
×
  • Create New...