Latest Posts

OSX El Capitan and Virtualbox

Jul 15,2016 at 10:30 am By Ben Hutton

OSX El Capitan and Virtualbox has a little issue. If you’re one of the people who uses Filevault on your Mac then there appears to be an issue with Virtualbox. That being once Virtualbox is installed the boot time in El Capitan takes a long time, like 5 minutes plus.

This is due to some issue with OSX and the Virtualbox kernel modules that automatically load during the boot cycle. Thankfully there is a easy though less than elegant way of getting around this.

All you need to do is move the modules out of “/Library/Application Support/VirtualBox” and into a different location. This will stop OSX loading them during the boot cycle.

Before you can run Virtualbox you will need to load the modules. An easy way to do this is to automate it via a bash script, like the following:

sudo kextload *.kext
virtualbox &

So now all you need to do to run Virtualbox is run this script instead of the normal desktop icon. The script runs Virtualbox after loading the required modules.

Optimising OpenLDAP

Jul 15,2016 at 10:30 am By Ben Hutton

I recently had an issue with full listing of directories for NFS mounts. That is when you do an ‘ls -l’ it took a long time to list the files. It didn’t effect ‘ls’ though, so it pointed to an issue with something that the full listing showed. After some investigation I determined that LDAP was the cause of the issue so I had to work out a way of optimising OpenLDAP, as this was the LDAP server that I was using.

Issue with LDAP

Disabling LDAP lookups within /etc/nsswitch (the server was authenticated to LDAP) speed things up so NFS wasn’t the issue. It turned out it was also slow on the NFS server for that folder.

Indexes are important

In investigating the LDAP server and possible issues I discovered that indexes were missing. Since LDAP is a database indexes are important in improving the speed of searches.

In this case the directory listing was the /usr/home folder. This of course contained most of the users within the directory. Being that the indexes for user and group names wasn’t set this slowed down retrieving individual users. It didn’t become an issue until there was at least 50 users within the directory.

A simple fix

To resolve this issue is very straight forward. Find the slapd.conf file which in linux is in /etc/ and in BSD you will find it in /usr/local/etc/openldap/.

Add the following indexes to the slapd.conf file:

index uidNumber eq
index....... Read More

Copyright © 2017 | Ben Hutton