Hidden .wdmc directories created by mcserver and photodbmerger and the deletion of them

You are right, I did get that part figured out. I was able to stop it again but I am unable delete those wdmc files???  Two of the drives I can remove and put in a dock to delete but the other two are raid’ed’; don’t think I can remove them and still access the files.  Don’t want to lose “my” files.  Dang WD anyway!  Can you give me a clue…

I decided to follow numanoid’s advice on how to delete all the .wdmc droppings on my system, since I don’t need them, and they’re taking up about 100MB of space:

find . -type d -name ‘.wdmc’ -print0 | xargs -0t rm -rf

Login in via SSH.

Before I did anything else, I went to the top level of the user file system:

cd /DataVolume/shares

At least if anything went wrong with the deletion, it should only delete my user data, and I have that all backed up…

I also stopped and disabled the wdmcserverd and wdphotodbmergerd sevices.

Just to check what this command was going to do (I had a pretty good idea already), I ran the find command on its own.

find . -type d -name ‘.wdmc’ -print > wcjunk.txt

Note the change from ‘print0’ to ‘print’.  print0 uses a null character /0 to separate output lines, which is a bit unwieldy in a text file.  print uses a normal line feed.

Result: yes, it’s found lots of .wdmc leaf directories, and only .wdmc leaf directories.

Now to look at the deletion part, as that ‘rm -rf’ is a bit scary…

I checked the xargs bit with Wiki

http://en.wikipedia.org/wiki/Xargs

It’s being used to allow the output of find to be sent to the rm command, and seems to be a nice safe way of avoiding the pitfalls of spaces and commas in piped text streams.

rm -rf deletes the directory and any files and subdirectories.  As I said, a bit scary, so I wanted to make sure if was going to be sent a correct list of directories.

All looked good, so I entered the command, checked and re-checked I’d typed it correctly, added a background task ‘&’ to the end, and hit return

find . -type d -name ‘.wdmc’ -print0 | xargs -0t rm -rf &

This allowed me to keep doing ‘ls’ as it ran, to make sure it wasn’t trashing the entire disk structure.

Some time later, I got the command complete message:

[1]+  Done                    find . -type d -name ‘.wdmc’ -print0 | xargs -0t rm -rf

Just to check, I re-ran the earlier command to list all the .wdmc directories.  Result: none found.

So, thanks to numanoids for the deletion advice.  It worked a treat.

2 Likes

Hi cpt_paranoia, can you describe the effect this has (if any) on the functionality of twonky and/or iTunes servers?

It has had no discernible impact on Twonky. All album artwork is still visible perfectly. I don’t use iTunes, but I suspect that will be fine too. If you’re concerned, login via SSH, go to an album folder and manually delete the .wdmc folder. Then check that the artwork is still visible in iTunes. I’d probably have iTunes shutdown while you delete, so it will read the store when it starts up.

As far as I understand it, these processes are for cloud access, to provide thumbnails for the MyCloud app. I don’t currently use cloud access or the MyCloud app.

Thanks, that’s good to know. Since I killed those services I was a bit reluctant to turn on the Twonky server again. Although I don’t really use it I’ll give it a try out of curiosity

Have you seen my Twonky FAQ?

http://community.wd.com/t5/WD-My-Cloud/FAQ-Twonky-DLNA-Media-Server-Setup-amp-Use/m-p/860697

ps. Twonky creates its own database, and I’m sure that, given how poorly Twonky is integrated into MyCloud, there’s no relationship between Twonky and these services. If you look at the default ‘Ignore Directories’ list in the Twonky UI, you’ll find .wdmc in the list.

It looks like enabling SSH will kill my warranty.  Really?  That’s just great. 

What choice do you have? We are all in the same situation, so either we live with the My Cloud “as is” or try to make it useful. I seriously doubt WD will change these useless files from being created nor give a script file to be initiated that will delete the files without losing your warranty. WD has enough issues with just firmware at the moment.

Really, you need to:

  1. Login via SSH as root (havign first enabled SSHD access via the web interface).

  2. Then use the three commands in this format to get rid of all the **bleep** directories:-

              find /DataVolume -name .wdmc -exec rm -rf {} ;

IOW: You want to start at the top of the data volume and work downwards until they’re all gone.

Starting the find command at ‘.’ will only do the current directory and any below it.

1 Like

If you followed my description, you’ll see that I changed directory to the appropriate place in my directory hierarchy:

cd /DataVolume/shares

Which puts me at the top level of the user data space.  There’s nothing above this point that has been indexed, or that I want to delete.

And, when using ‘rm -rf’, it’s wise to start in the right level of hierarchy, just in case you make an error with the find command.

It’s unix; there are a million and one ways to skin a cat. Will that ‘exec’ command cope with spaces in the paths?

1 Like

I can’t find a thread like this for the MyPassport.

On this drive the init.d there is no photoshare daemon but I did find these:

S85wdmcserverd

S92twonkyserver

S92wdnotifierd

I can’t stop the S92wdnotifierd

The update-rc.d commands don’t work.

Also there isn’t a specific veto file for samba, so I just made a back up of smb.conf and edited the veto line to remove the .* files.

Maybe it goes without saying but I changed the root password too.

Jacob

JacobChrist wrote:

I can’t find a thread like this for the MyPassport.

 

On this drive the init.d there is no photoshare daemon but I did find these:

 

S85wdmcserverd

S92twonkyserver

S92wdnotifierd

 

I can’t stop the S92wdnotifierd

 

The update-rc.d commands don’t work.

 

Also there isn’t a specific veto file for samba, so I just made a back up of smb.conf and edited the veto line to remove the .* files.

 

sounds like you did a wonderful job. Are you able to see the .wdmc files when viewing on a PC. You won’t be able to see them on a Mac because the . prefix hides them regardless of the samba veto file.

The wdmcserver will create these files.

You don’t need to stop wdnotifierd nor do you really need to stop the twonkyserver; just turn off twonky if you are not using it.

So copy and paste this in the MyPassport forum and you will become the MyPassport Guru. 

Congrats

I still don’t get it why WD stuffed alll the .wdmc directories to be indispersed with all the user’s data. Would have been a lot better under it’s own separate and hidden directory tree.  It’s more of an issue when used on the My Passport Wireless that’s connected to a computer by USB.

SectorGZ wrote:

What choice do you have? We are all in the same situation, so either we live with the My Cloud “as is” or try to make it useful. I seriously doubt WD will change these useless files from being created nor give a script file to be initiated that will delete the files without losing your warranty. WD has enough issues with just firmware at the moment.

I’m using My Cloud EX2

I enter /etc/init.d/wdmcserverd stop and keep getting permission denied. Then I tried chmod 644 /etc/init.d/wdmcserverd and still nothing. 

Thank you, BUT: In the Very First Line: What does it Mean to ‘SSH to the device’? The only place I see the letters SSH in my dashboard, says it will VOID MY WARRANTY if I click it, is this a trick?

then … Once I understand the first line, How exactly does one DO the next things you are listing? STOPPING things etc…? Can you PLEASE do an actual Step-by-Step with some actual STEPS ? :slight_smile: ;~)

1 Like

REALLY?
THE solution at WESTERN DIGITAL Support Forum, to fix this thing and make it not SUICIDE is to VOID THE WARRANTY? Am I the only (other :slight_smile: one that see’s this as not only insane but VERY CONVENIENT on WD’s Part? Get us to void our warranty on a defunct bad product then refuse to fix it after the fact. PERFECT.,… I am going to ask for a 4TB MYBOOK replacement.

Thanks for the tip. I can say that I am not happy with my WD Cloud device and I would never recommend this thing to anyone.

I can’t image why rebuild takes so long. I doubt it is scanning the content of each file so at most it needs an index of all the files, this shouldn’t take half a day.

1 Like

Any chance you could confirm that works on a a ext2 ultra too?

Sorry for reviving this thread.

I’m also curious about a procedure to stop this indexing on EX2U (with OS 5).

I had to disable “Cloud Service” after I copied ~1TB of data (photos, music, videos) into the NAS and the machine was running/clicking non-stop for several days, without any indication of “completed status” and the iOS app being totally unresponsive.