Maisystem module not saving my custom class on production server
http://php.net/manual/en/features.safe-mode.php
notes


  This feature has been DEPRECATED as of PHP 5.3.0 and REMOVED as of PHP 5.4.0.


So in general it is not very useful feature and turns out to be causing issues with some applications when they try to write to the file system.