symbolic links get corrupted by system process?

Greetings Folks,


This was posted in another forum, so I'm reposting two messages here:


I am having a problem with symbolic links getting corrupted. I have a new Mac Pro running 10.7.3. I have defined symbolic links


/Users/walker/G2S -> /Volumes/L2A/G2S [this is pointing to a different partition on the same JBOD RAID]

/home -> /Users


The second link was created after unmounting /home and removing it from the /etc/auto_master file.


Both symbolic links worked for several days. But then for some reason, without a reboot, the links became corrupted:


> pwd

/Users/walker

> ls -al G2S

lrwxr-xr-x 1 walker staff 16 Mar 24 03:08 G2S -> X??G???Gҡ?G???G

> cd G2S

G2S: No such file or directory.


Same nonsensical definition for /home link. I repeat, this did not happen after a reboot. It first happened on /home. I thought that might have been related to a new OS handling of the "/home" label. So I deleted the /home link and did a clean reboot. The G2S link was created after that reboot, not before.


After the above two problems happened, I created a new symbolic link


/Users/walker/G2S2 -> /Volumes/L2A/G2S


I then did not use this new symbolic link in any of my processing scripts. A few weeks went by, then this link somehow got corrupted too:


lrwxr-xr-x 1 walker staff 16 Apr 2 17:22 G2S2 -> 꺄G???Gĺ?Gú?G


Does anyone here know how symbolic links are managed on a Mac (any process that controls their linking?), or have any information to help me figure out how to fix this? For example, could it be due to bad RAM? I have 32 GB.


Thank you,

Kris Walker

Mac Pro, Mac OS X (10.7.3)

Posted on Apr 20, 2012 3:44 PM

Reply
233 replies

May 9, 2013 11:03 AM in response to Ed Newman

This is just an update. I replaced my drives, and as I installed new software, I would periodically check for broken soft links.


Summary

===

* Wrote a busted link detector; runs much faster than the script versions. It reports all links that don't link to a file or directory.

* So far, no corrupted links have been detected: however there are broken links. I haven't looked into the broken links to determine if they are expected behavior or not.

* All Applications were installed via App Store

* HomeBrew and packages were installed without sudo

* No browser plugins were installed (flash, silverlight, etc.)

* No drivers were installed

* sudo was only used to detect broken links


Steps

===


Rebuilt my machine:

* MacPro Mid 2012; 2 x 2.4 GHz 6-Core Intel Xeon; 32 GB 1333 MHz DDR3 ECC; ATI Radeon HD 5770 1024 MB

* Replaced all 4 drives with WD Red 3TB

* Configured raid 0/1 striped pairs, and then mirror

* Install 10.8.3


Broken links:


Missing link target: /Library/Frameworks/AEProfiling.framework->../../Applications/Motion.app/Contents/Frameworks/AEProfiling.framework

Missing link target: /usr/share/java/Tools/Java VisualVM.app/Contents/Resources/VisualVM.icns->/System/Library/Java/Support/VisualVM.bundle/Contents/Resources/VisualVM.icns



* Install xcode via App Store


Missing link target: /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.7.sdk/System/Library/Frameworks/OpenGL.framework/PlugIns->Versions/Current/PlugIns

Missing link target: /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.7.sdk/System/Library/Frameworks/System.framework/Versions/B/Resources/BridgeSupport/System.bridgesupport->../../../../../../BridgeSupport/libSystem.bridgesupport

Missing link target: /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.7.sdk/usr/lib/python2.5->../../System/Library/Frameworks/Python.framework/Versions/2.5/lib/python2.5

Missing link target: /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.7.sdk/usr/libexec/SmartCardServices/drivers/ifd-ccid.bundle/Contents/MacOS/libccid.dylib->libccid.dylib.1.3.11

Missing link target: /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.8.sdk/System/Library/Frameworks/OpenGL.framework/Resources->Versions/Current/Resources

Missing link target: /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.8.sdk/System/Library/Frameworks/System.framework/Versions/B/Resources/BridgeSupport/System.bridgesupport->../../../../../../BridgeSupport/libSystem.bridgesupport

Missing link target: /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.8.sdk/usr/lib/python2.5->../../System/Library/Frameworks/Python.framework/Versions/2.5/lib/python2.5

Missing link target: /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.8.sdk/usr/libexec/SmartCardServices/drivers/ifd-ccid.bundle/Contents/MacOS/libccid.dylib->libccid.dylib.1.3.11

Missing link target: /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator6.1.sdk/System/Library/Frameworks/CoreServices.framework/Versions/A/Frameworks/OSServices.framework/Headers->Versions/Current/Headers

Missing link target: /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator6.1.sdk/System/Library/Frameworks/CoreServices.framework/Versions/A/Frameworks/WebServicesCore.framework/Headers->Versions/Current/Headers

Missing link target: /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator6.1.sdk/usr/include/c++/4.2.1/4.2.1->4.2.1

Missing link target: /Library/Frameworks/AEProfiling.framework->../../Applications/Motion.app/Contents/Frameworks/AEProfiling.framework

Missing link target: /Users/hans/Library/Containers/com.apple.ShareKitHelper/Data/Documents/iChats->../../../../../Documents/iChats

Missing link target: /Users/hans/Library/Containers/com.apple.ShareKitHelper/Data/Library/Application Scripts/com.apple.ShareKitHelper->../../../../../Application Scripts/com.apple.ShareKitHelper

Missing link target: /Users/hans/Library/Containers/com.apple.ShareKitHelper/Data/Library/ColorSync->../../../../ColorSync

Missing link target: /usr/share/java/Tools/Java VisualVM.app/Contents/Resources/VisualVM.icns->/System/Library/Java/Support/VisualVM.bundle/Contents/Resources/VisualVM.icns



* Install HomeBrew (does not require sudo)


<no new busted links>


* Install system updates


1 new busted link:


> Missing link target: /System/Library/StagedFrameworks/Safari/WebKit.framework/Frameworks->Versions/Current/Frameworks



* Install some HomeBrew packages, (go, fishfish, tree, git, mercurial)


< no new busted links>


* Install dozens of apps via App Store


< no new busted links>


* Install dozen more apps via App Store


< no new busted links>


* Configure settings via System Preferences (turn on photo stream, among other things), install font "SourceCodePro", customize terminal.app, configure prompt to show git status


New busted links:


> Missing link target: /Users/hans/Library/Containers/com.apple.ImageKit.RecentPictureService/Data/Documents/iChats->../../../../../Documents/iChats

> Missing link target: /Users/hans/Library/Containers/com.apple.ImageKit.RecentPictureService/Data/Library/Application Scripts/com.apple.ImageKit.RecentPictureService->../../../../../Application Scripts/com.apple.ImageKit.RecentPictureService

> Missing link target: /Users/hans/Library/Containers/com.apple.ImageKit.RecentPictureService/Data/Library/ColorSync->../../../../ColorSync

> Missing link target: /Users/hans/Library/Containers/com.apple.photostream-agent/Data/Documents/iChats->../../../../../Documents/iChats

> Missing link target: /Users/hans/Library/Containers/com.apple.photostream-agent/Data/Library/Application Scripts/com.apple.photostream-agent->../../../../../Application Scripts/com.apple.photostream-agent

> Missing link target: /Users/hans/Library/Containers/com.apple.photostream-agent/Data/Library/ColorSync->../../../../ColorSync

Jan 20, 2014 1:03 PM in response to ktwalker69

Bumping the thread to see if the concensus is that this problem is fixed. My bug report was marked as a duplicate of 12133587 and now this duplicate bug is listed as closed. I've not changed any of the hardware and I've not experienced any symlink corruption in months but I can't say when exactly the problem went away. There have been no mention of the issue in the relase notes unless I missed them.


Is anyone else from this post still experiencing a problem? If not perhaps we can get the thread closed for others that stumble upon it.


Jeff

Mar 9, 2015 12:02 PM in response to ktwalker69

I figure by now everyone has moved on, and Lion is officially no longer supported, but I do have one 10.7.5 server still running, and recently saw this bug appear again. This time though, I have solid evidence of what triggered it, and it was Carbon Copy Cloner (pre-pay version). I don't know that it contains the bug, but more likely something it calls triggers the bug under certain circumstances.


I was backing up an active mail server, and at the very time that it was reading /var, the symlink /var/spool/postfix became garbled. Around the same time /usr/libexec/dovecot/deliver suffered the same fate. I could see the mail literally stop flowing.


I had a weekly (midnight Saturday) backup process using CCC going for a couple of years without incident. What changed recently was converting from RAID6 to RAID10, a significantly faster file system, and that I started using CCC nightly. My best guess is it's probably some combination of a specific mechanism being invoked in combination with a very busy file system. I've ceased using CCC on this system, and in time it will be upgraded to 10.10.x.


I thought people that wrestled with this might be interested in this finding.

This thread has been closed by the system or the community team. You may vote for any posts you find helpful, or search the Community for additional answers.

symbolic links get corrupted by system process?

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.