how do I reset or clear the list of Volumes? I am running into this problem when I accidentally remove a USB drive without properly ejecting it or similar and then plug it back in.

When my drive is plugged back in it will apear normally, for example 'My Drive' but in the volumes folder in Terminal it will apear as 'My Drive 1' thus certain softwares will not be able to find it.

When I try to clear the list I get this kind of problem:

durp:Volumes user$ ls
128 3000
durp:Volumes user$ diskutil umount 3000
Unmount failed for 3000
durp:Volumes user$ sudo umount -f 3000
Password:
umount: 3000: not currently mounted
durp:Volumes user$ ls
128 3000
durp:Volumes user$ 


As you see the drive is not mounted or plugged in but still exists to the system. 

Thus when I plug it in it will apear as '3000 1' and my backup software wont find it.

I can fix this by restarting easily but was wondering if there is any other way.
It should be enough to just delete the folder

sudo rmdir /Volumes/3000