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

Oct 21, 2012 11:17 AM in response to etresoft

Here is my System Report from the harddrive. This is a 3TB WD Green drive that I installed myself. (was an upgrade from the 1TB drive I had also installed earlier). I mention this now as the previous user also used the same o similar drive (WD/Green). Perhaps there is a trend of those of us using the same hardware?


Hardware Overview:


Model Name: iMac

Model Identifier: iMac8,1

Processor Name: Intel Core 2 Duo

Processor Speed: 3.06 GHz

Number of Processors: 1

Total Number of Cores: 2

L2 Cache: 6 MB

Memory: 4 GB

Bus Speed: 1.07 GHz

Boot ROM Version: IM81.00C1.B00

SMC Version (system): 1.30f1


Intel ICH8-M AHCI:


Vendor: Intel

Product: ICH8-M AHCI

Link Speed: 3 Gigabit

Negotiated Link Speed: 3 Gigabit

Description: AHCI Version 1.10 Supported


WDC WD30EZRX-00MMMB0:


Capacity: 3 TB (3,000,592,982,016 bytes)

Model: WDC WD30EZRX-00MMMB0

Revision: 80.00A80

Serial Number: WD-WMAWZ0081750

Native Command Queuing: Yes

Queue Depth: 32

Removable Media: No

Detachable Drive: No

BSD Name: disk0

Medium Type: Rotational

Partition Map Type: GPT (GUID Partition Table)

S.M.A.R.T. status: Verified

Volumes:

disk0s1:

Capacity: 209.7 MB (209,715,200 bytes)

BSD Name: disk0s1

Content: EFI

Machintosh HD:

Capacity: 3 TB (2,999,733,223,424 bytes)

Available: 1.62 TB (1,617,339,432,960 bytes)

Writable: Yes

File System: Journaled HFS+

BSD Name: disk0s2

Mount Point: /

Content: Apple_HFS

Volume UUID: 7AEFC0EC-7776-3464-A76D-61EF15F3954E

Recovery HD:

Capacity: 650 MB (650,002,432 bytes)

BSD Name: disk0s3

Content: Apple_Boot

Volume UUID: 71B47D8C-035A-3468-84AC-C8E1C8B45DCA

Oct 22, 2012 4:11 AM in response to etresoft

Well I did the zeroing-out. It ran through without issues. Reinstalled Mountain Lion. No problems.

Info from Disk Util:


Name : WDC WD30EURS-63R8UY0 Media

Type : Disk


Partition Map Scheme : GUID Partition Table

Disk Identifier : disk0

Media Name : WDC WD30EURS-63R8UY0 Media

Media Type : Generic

Connection Bus : SATA

Device Tree : IODeviceTree:/PCI0@0/SATA@1F,2/PRT0@0/PMP@0

Writable : Yes

Ejectable : No

Location : Internal

Total Capacity : 3 TB (3,000,592,982,016 Bytes)

Disk Number : 0

Partition Number : 0

S.M.A.R.T. Status : Verified

Raw Error Rate : 000000000000

Spinup Time : 0000000023CE

Start/Stop Count : 00000000004C

Reallocated Sectors : 000000000000

Seek Error Rate : 000000000000

Power-On Hours : 00000000006F

Spinup Retries : 000000000000

Calibration Retries : 000000000000

HDD Temperature : 00000000001A

Reallocated Sector Events : 000000000000

Current Pending Sectors : 000000000000

Offline Scan Uncorrectable Sectors : 000000000000

CRC Error Rate : 000000000000

Multi-Zone Error Rate : 000000000000


I beleive if the drive was flaky, I'd be seeing an awful lot less zeros here.


Thinking about it, when I was moving stuff over from my flaked-out old Seagate (through FW800), OSX actually FROZE once during copy, and I had to hard reboot the thing. That may have been the culprit.

Oct 23, 2012 2:52 AM in response to Iosepho

There are other users that are likely experiencing symlink corruption on the following thread:

https://discussions.apple.com/thread/4431990?answerId=20106545022#20106545022&ac_cid=tw123456#20106545


The symptom they are experiencing is manifested in Mail.app. I'm experiencing the same issues with Mail.app and have identified numerous corrupted links in the ~/Library/Containers folder. For mail its in the ~/Library/Containers/com.apple.Mail but I went ahead and looked through the entire parent and found corrupted links throughout.


Just more data for the fire.


J

Oct 29, 2012 2:53 PM in response to Iosepho

Okay, no freezes this time, just a bunch of links getting corrupted wholesale. Disk stats still report zero error rate.


This is getting on my nerves now, I wrote the service who did the HDD replacement if they have any idea what we could do about this. It's not the links, sure that's a problem too, but I can no longer trust the bloody thing with sensitive data like video, audio or books, what if those are next.


I'm planning of selling the machine now, hopefully the average idiot who buys it won't notice a thing out of the problem, and I'll try grabbing a newer model.

Oct 30, 2012 4:19 AM in response to ktwalker69

IMPORTANT! 😀

I have an idea. Please everyone who had symlink corruption, post the SIZE of your root file system! I'm starting to suspect a problem with "too large" volumes, maybe an integer overflow of something similar.


Mine is 3T.


Also, I'm trying something new. I'll move the entire Users folder to a secondary slice formatted as ZFS using Zevo. Since ZFS is extremely robust, I expect it will catch any disk error... And first of all, I'll boot in a Linux rescue cd, and run badblocks -w on the entire disk.

Oct 30, 2012 11:01 AM in response to Iosepho

Iosepho wrote:


IMPORTANT! 😀

I have an idea. Please everyone who had symlink corruption, post the SIZE of your root file system! I'm starting to suspect a problem with "too large" volumes, maybe an integer overflow of something similar.


Mine is 3T.


Also, I'm trying something new. I'll move the entire Users folder to a secondary slice formatted as ZFS using Zevo. Since ZFS is extremely robust, I expect it will catch any disk error... And first of all, I'll boot in a Linux rescue cd, and run badblocks -w on the entire disk.


Interesting idea - I hadn't thought of that!


On the machine where I am having symlink problems, everything is on one 3TB disk (no partitions, just one 3TB partition spanning the whole disk)


On the machine that seems to be problem-free (laptop), my hard drive is 1 TB, but it is split into two partitions; a Mac partition of ~600 GB and a Windows (Boot Camp) partition comprising the rest of the drive.


Perhaps you're on to something here...

Oct 31, 2012 5:35 PM in response to ktwalker69

I've installed Mountain Lion on about twenty Macs. The only one I have seen the sym link corruption rather reguraly is my iMac which has a 3TB drive. All the other Macs have 2TB or smaller drives and have had no issue. It very well may be a bug with large filesystems. HFS+ really needs to be replaced with something more modern.


I suppose we're waiting for Apple to come up with a fix.

Nov 1, 2012 2:51 PM in response to ktwalker69

Here's a "me, too."


One of my clients has a Mac Pro 5,1 with Apple RAID Card creating a 3.6TB volume that we boot from running 10.7.5.


Their initial issue centered around a MySQL database not backing up (/usr/local/mysql symlink was broken). But in the course of that we saw Apple apps not opening, crashing... Since discovering this thread, I replaced broken symlinks by comparing a list of their symlinks with those of a fresh install of 10.7.5 and it appears to cure all ills... for now. There were a lot, mostly in /System/Library - but the /usr/local/mysql symlink may be interesting because that's not part of the base OS install.


As you might expect, the broken symlink is backed up via Carbon Copy Cloner and Time Machine (so your backups are screwed too unless you catch it quickly enough to find a good symlink in archived deltas).


The big volume theory is interesting enough for us to try and test against that. Will report back if I find anything.


Here's hoping for 10.7.6 and/or 10.8.3.

Nov 1, 2012 5:49 PM in response to Brian Best

Brian Best wrote:


Here's a "me, too."


One of my clients has a Mac Pro 5,1 with Apple RAID Card creating a 3.6TB volume that we boot from running 10.7.5.


Their initial issue centered around a MySQL database not backing up (/usr/local/mysql symlink was broken). But in the course of that we saw Apple apps not opening, crashing... Since discovering this thread, I replaced broken symlinks by comparing a list of their symlinks with those of a fresh install of 10.7.5 and it appears to cure all ills... for now. There were a lot, mostly in /System/Library - but the /usr/local/mysql symlink may be interesting because that's not part of the base OS install.


As you might expect, the broken symlink is backed up via Carbon Copy Cloner and Time Machine (so your backups are screwed too unless you catch it quickly enough to find a good symlink in archived deltas).


The big volume theory is interesting enough for us to try and test against that. Will report back if I find anything.


Here's hoping for 10.7.6 and/or 10.8.3.


Now that I think about it some more, my problems seem to have begun when I upgraded my Mac Pro from a 1.5 TB drive to a 3 TB drive. So the big volume theory could very well be plausible.

Nov 1, 2012 5:59 PM in response to Iosepho

Now that I think about it, I seem to recall a similar problem cropping up around the time when they shifted from the HFS system to HFS+ (or maybe I'm having a memory thing, who knows? 😉). I don't have time to research it, but I thought I'd throw the thought out - maybe someone found an applicable solution back then. Or maybe this is just what happens to HFS when it gets close to some critical size limit...

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.