Howto install macOS El Capitan on a 2009 MacbookPro

I’m trying to sell a 2009 MacbookPro. It’s the model MacbookPro5.5 and Apple supports macOS El Capitan 10.11 as latest available version.

I’ve wiped all data from the installed SSD and had to boot from an external disk. Now I’ve got two problems:

  1. I’ve only got a Mac with Big Sur and Apple Silicon. I cannot use the package installer from the download provided by Apple to create the installer App for El Capitan. However, I need access to the installer so that I’m able to use the createinstallmedia command.
  2. The 2009 MacbookPro is already wiped and has only access to the recovery mode. You cannot execute the package installer in Recovery Mode to extract the media.

Luckily I’ve found this blog post from Chris Warrick who explained how to extract the installer App from the package:

  1. Attach an external Disk which contains the downloaded pkg from Apple. You’ll need enough space on that Disk to extract the pkg and it needs to be writeable
  2. Open the Terminal from inside the Recovery Mode
  3. Go to the mounted volume
  4. Extract the package:
$ pkgutil --expand InstallMacOSX.pkg elcapitan
$ ls -F elcapitan
Distribution*       InstallMacOSX.pkg/ Resources/
$ cd elcapitan/InstallMacOSX.pkg/
$ tar -xvf Payload
x .
x ./Install OS X El Capitan.app
x ./Install OS X El Capitan.app/Contents
…

Now we can try to create the install media from the installer app. Make sure you’ve attach another disk which can be overwritten by the installer. In this example its named “MyBlankUSBDrive”:

# "Install OS X El Capitan.app/Contents/Resources/createinstallmedia" --volume /Volumes/MyBlankUSBDrive --applicationpath "Install OS X El Capitan.app"
Install OS X El Capitan.app does not appear to be a valid OS installer application.

The InstallESD.dmg image is missing, which we’ll need to add to the right location:

$ mkdir "Install OS X El Capitan.app/Contents/SharedSupport"
$ mv InstallESD.dmg "Install OS X El Capitan.app/Contents/SharedSupport"
# "Install OS X El Capitan.app/Contents/Resources/createinstallmedia" --volume /Volumes/MyBlankUSBDrive --applicationpath "Install OS X El Capitan.app"
Ready to start.
To continue we need to erase the disk at /Volumes/MyBlankUSBDrive.
If you wish to continue type (Y) then press return:

Now we’ll have a valid installation medium which can be used to start the installer from. You can reboot from that disk and should be able to install El Capitan.

However, I’ve encountered another annoying issue which caused the installer to fail:

El Capitan Installer cannot be verified

Oh great… On to the next commands you can try from the Terminal inside the Recovery OS:

  1. installer -pkg /Volumes/Mac\ OS\ X\ Install\ DVD/Packages/OSInstall.mpkg -target /Volumes/"XXX" where XXX is the name of the disk you’re installing to.
  2. Wait for the installation to say it’s complete. You will not see any sort of progress display.

Great, you’ve got El Capitan installed! Apple had some issues with certificates and people found a way to either use the above commands for installation or you’ll have to tinker with your Macs time settings so that the signature is valid again. I would have expected that Apple resigned all installers so I wouldn’t have to use these commands at all but doesn’t look like they did.

Slow SMB transfers in Mac OS 10.12.2

I’m using a 802.11ac WLAN to connect to my Synology NAS. With the last Mac OS 10.12.2 update the network performance was catastrophic when I tried to access the NAS via SMB. At first I thought this might have been caused by the WLAN connection but even with a Gigabit LAN connection my transfer rates were around 3-5MB/s.

After a short search online, I’ve a few hits describing the actual problem:

Apple uses their own version of SMB and enabled client signing to mitigate against Man in the middel attacks. Therefore all connections underly this signing process and are way slower.

Therefore I’ve disabled client-signing on my mac using this command:

printf "[default]\nsigning_required=no\n" | sudo tee /etc/nsmb.conf >/dev/null

This will write this content

[default]
signing_required=no

 

to the file /etc/nsmb.conf. After you’ve set this value you need to unmount all samba shares. If you’ll reconnect now, you’ll witness a much better performance, starting with faster loading of network shares.

You can revert this change with

sudo rm /etc/nsmb.conf

 

Installing Mac OS Sierra (10.12) on a MacbookPro 5,5 (Mid 2009)

Mac OS Sierra was released yesterday. However, our good old MacbookPro 5,5 (Mid 2009) isn’t officially supported anymore. Luckily, there are people who figure out what is necessary to patch the official installation so that it can be installed again 😉

I’ve backuped the Macbook and gave the given instructions a try. Instead of reinstalling everything I only updated from El Capitan to Sierra. After the first restart, the Macbook shut down, as it didn’t found a valid boot partition.

So I rebooted again to the patched installation media and ran the proposed “macOS Post Install…”. I’ve selected my type of Macbook and let it patch. Additionally I’ve ran the “Force Cache Rebuild” command and rebooted.

The Macbook booted to Sierra 🙂 However, the FaceTime camera wasn’t detected and I wasn’t able to get it working again. Since there was a “Legacy USB Support injector” I think this might cause the problem. The FaceTime camera is connected internally over USB so it seems to have some problems.

I don’t think this is a big problem. You’ll probably get this somehow fixed with a little time and patience. However, since I’m running a real Mac hardware (and no Hackintosh), I don’t want to fiddle around with such basic hardware problems.

Therefore I can only recommend you to leave your Macbook on El Capitan (10.11) as the largest supported OS. Seems that Apple wants to get rid of devices older than 7 years, even if they are still doing great (with a SSD and 8GB RAM).

Automount network shares on Mac OS for use in iTunes

I’ve moved my iTunes library from my Macbook’s SSD to my Synology NAS on a network share. This is quite easy and can be made inside the iTunes preferences pane. After you’ve changed the path for the iTunes Media, all iTunes managed media will be moved to the new location (assuming you let iTunes manage your files of course :)).

This allows you to have your iTunes library on your Macbook while all the large files are stored on the NAS. This is especially important for larger libraries as well as the newer Macbooks which only have a limited flash drive instead of larger harddisks.

However, there is one important problem with this solution: Once you’ve disconnected from this network share for whatever reasons and you try to start iTunes, you’ll have your iTunes Media folder reset to your user’s music folder on your boot disk. You’ll now need to reset the path to your files again, and this will again cause iTunes to check all files if they are on the right location and moves them if necessary.

I thought I’ve taken care of this problem with auto connecting to the network share with a Login Item. However, this didn’t help me much since I sometimes have disconnections to my network (e.g. when I’m on the road) and the network connection will only be created once during the login of your current user. So this doesn’t help me at all and caused me to look for another better solution.

So I’ve found this gist (the link is dead) and modified it a little bit to my environment. Therefore here’s my short list of modifications for using autofs in combination with AFP or SMB volumes:

If you now start up iTunes again, it will try to locate the media files in the /Volumes/music folder, like I manually specified it. However, autofs will now automatically mount the network share for me and iTunes won’t complain about a missing volume. This way I won’t ever need to take care of manually updating the path once I forgot connecting to my NAS 🙂

Update:
Hm, it seems that the trick with /../Volumes does not work anymore on Mac OS 10.11.4 🙁 If I try to list the content of the mounted volume an error message is returned:

ls: : Unknown error: 118

So I need to mount the volume in a different folder and need to change the path in iTunes again.

Update 2:
I’m not able to mount afp volumes anymore so I’m using smbfs like it is described here (the link is dead). However, this will require a user and password in the configuration file 🙁

Update 3:

Mac OS Sierra breaks the autofs configuration. I had to change it a little bit according to this SuperUser entry. The Gist is updated accordingly.

Update 4:

This still works on Mac OS High Sierra. However, make sure that you enter the credentials correctly and that you spare special characters, according to this blog:

Note: If you have a password longer than 8 characters, or if the password has special characters in it (like “! # $ % & ‘ ( ) * + , – . / : ; & < = > ? @ [ \ ] ^ _ { | } ~”), you may receive a “No locks available” error message and the share will not mount under /home. You will also receive a “No locks available” or similar “Host is down” error if the password is wrong or missing.

I’ve encountered the “No locks available” today and had an error in my password which blocked the auto mounter from opening the folder.