Hi Iñaki,
I applied the patch and then tried to execute the command
php -f ldapname.php ldap2
But I am getting this message
Default exception handler: <p>Error: Database connection failed</p>
<p>It is possible that the database is overloaded or otherwise not running properly.</p>
<p>The site administrator should also check that the database details have been correctly specified in config.php</p> Debug:
Warning: mysqli::mysqli(): [2002] No such file or directory (trying to connect via unix:///var/mysql/mysql.sock) in /Applications/MAMP/htdocs/moodle232/lib/dml/mysqli_native_moodle_database.php on line 377
Warning: mysqli::mysqli(): (HY000/2002): No such file or directory in /Applications/MAMP/htdocs/moodle232/lib/dml/mysqli_native_moodle_database.php on line 377
Error code: dbconnectionfailed
* line 384 of /lib/dml/mysqli_native_moodle_database.php: dml_connection_exception thrown
* line 344 of /lib/dmllib.php: call to mysqli_native_moodle_database->connect()
* line 476 of /lib/setup.php: call to setup_DB()
* line 30 of /config.php: call to require_once()
* line 28 of /ldapname.php: call to require()
!!! <p>Error: Database connection failed</p>
<p>It is possible that the database is overloaded or otherwise not running properly.</p>
<p>The site administrator should also check that the database details have been correctly specified in config.php</p> !!!
I have macbook and MAMP to run my Moodle. MySQL is connected, I can even access the Moodle in browser. But dont know why I am getting database connection failed message with ldapname.php script.
Please advise.
Thanks,
Jaswant