Xsan Troubleshooting Tip #1 : Duplicate entry in /Volumes

d4corp's picture

Let's start with a simple one. Sometimes an Xsan Volume won't mount after an unexpected shutdown.




Background


The Mac OS X operating system (as well as all other unices OS) mounts filesystems in a folder. That mean that every time we plug a USB thumb drive, external hard drive or Xsan volume, it creates a folder in /Volumes using the name of the volume. This folder will serve as a pointer to the actual content of the drive.


If a drive with the same name is already plugged-in (that is, a folder with this name already exists), Mac OS X creates a new folder, appending 1.



What happens

Sometimes, the created folder isn't removed because of an unexpected shutdown. This means that either the Volume doesn't mount (this is usually the case with Xsan), or file paths are different, causing file offline issues.



How to solve this

  1. Go to /Volumes (in Finder, Go > Go to folder… or CMD-SHIFT-G)
  2. Check the contents of the ghost folder (be careful as some processes might have written some data in it)
  3. Delete it
  4. Reboot, replug device or remount

I usually do it in command-line, to ensure that I'm deleting an empty folder :

Last login: Mon Jan 25 07:54:49 on ttys000
Bosco$ cd /Volumes/
Bosco$ ls
Macintosh HD  SANVolume 1
Bosco$ rmdir SANVolume 1/
Bosco$ sudo xsanctl mount SANVolume
Bosco$

References

Comments

1
francisyo's picture

Yes i always have this problem on my xsan 2 volumes. And deleting the said
ghost folder will solve the problem. Thanks for this wonderful tip. It really helps
a lot to those people who are still blank in troubleshooting xsan problems.