Improved robustness of updating sqlconf.php.