0

I'm working with Xcode Server and continuous integrations. We're experiencing really slow build times.

My first attempt at speed up is using a RAM DISK and storing build files there. We are using mac mini with a SATA drive so I'm attempting to see how much time could be saved by eliminating that drive from part of the build process.

I created a RAM DISK with: diskutil erasevolume HFS+ 'XcodeData' `hdiutil attach -nomount ram://8388608

I started by trying to set the DerivedData location onto the ram disk, but when running a CI build data isn't stored there.

I found what looks to be the build data for every CI at /Library/Developer/Integrations/Caches.

I tried symlinking ln -s /XcodeData/IntegrationCaches/ /Library/Developer/Integrations/Caches but I get permission errors when running the CI.

I tried chmod 777 /XcodeData/IntegrationCaches/ and I still get permission issues.

I also tried to chown my ramdisk folder to chown _xcsbuildd IntegrationsCaches for ram disk folder.

Haven't had any luck so far.

Has anyone else tried doing something like this?

gngrwzrd
  • 5,902
  • 4
  • 43
  • 56
  • When I need to see what's inside the integration caches folder I open the inspector window on it in the finder and I add my user account to the list of approved users that can read/write to it. – bolnad May 27 '16 at 10:21
  • @bolnad yep that's what I ended up figuring out. By default the ram disk has ignore ownership set, which can be turned off in the Get Info window in finder for that volume. Thanks! – gngrwzrd May 27 '16 at 23:13
  • Glad it helped, I am sure you know this but it's a place where you can waste way too much time, good luck! – bolnad May 27 '16 at 23:39
  • @bolnad Yep I figured that out pretty quickly. – gngrwzrd May 27 '16 at 23:41

1 Answers1

0

Like @bolnad mentioned in the comments, it turned out that the RAM DISK by default ignores ownership. You can "Get Info" in the finder for that volume, then uncheck "Ignore Ownership", this will allow you to use chmod and tools to change users where required.

gngrwzrd
  • 5,902
  • 4
  • 43
  • 56