mod_myuserdir is Apache module for dynamically configured mass userdirs hosting, all configurations are stored in DB. Also, it is capable to manage settings of PHP4/5 dynamically for every user. By default, it sets open_basedir as homedir and safe_mode.