Permissions check successful, but install hangs at database setup, stating "***Installation Error*** Database query error". I tried both with MySQL and SQLite. In MySQL I created a new database and a user, and am able to log in as that user with full privileges . In SQLite I created a database and then used chmod 777 on the file to remove permissions issues. Have tried with firewall off, but results unchanged.
System details:
psychdesktop 1.0 Beta 1 (have also tried latest subversion)
OpenSUSE 11.0
Apache 2.2.8-28.1
MySQL 5.0.51a-27.1
SQLite 2.8.17-136.1
SQLite 3.5.7-17.1
PHP 5.2.6-0.4
Firefox 2
Opera 9
Any advice would be appreciated! I'm excited to test this software out!
Thanks,
Mike
Could you copy and paste the
Could you copy and paste the full installation log? That would help us figure out which specific component is acting up. Thanks.
This is the apache log...not sure if you needed a different log
# FIRST ATTEMPT WITH MYSQL
[Sun Sep 21 16:04:03 2008] [warn] Init: Session Cache is not configured [hint: SSLSessionCache]
[Sun Sep 21 16:04:03 2008] [notice] Apache/2.2.8 (Linux/SUSE) mod_ssl/2.2.8 OpenSSL/0.9.8g PHP/5.2.6 with Suhosin-Patch configured -- resuming normal operations
[Sun Sep 21 16:04:14 2008] [error] [client 127.0.0.1] PHP Notice: Use of undefined constant MDB2 - assumed 'MDB2' in /srv/www/htdocs/backend/lib/includes.php on line 16
[Sun Sep 21 16:04:40 2008] [error] [client 127.0.0.1] PHP Notice: Use of undefined constant MDB2 - assumed 'MDB2' in /srv/www/htdocs/backend/lib/includes.php on line 16
[Sun Sep 21 16:04:41 2008] [error] [client 127.0.0.1]
[Sun Sep 21 16:04:41 2008] [error] [client 127.0.0.1] Lucid Error: db_query_err (Creation of table failed: "MDB2 Error: not found")
#SECOND ATTEMPT WITH SQLITE
[Sun Sep 21 16:11:22 2008] [error] [client 127.0.0.1] PHP Notice: Use of undefined constant MDB2 - assumed 'MDB2' in /srv/www/htdocs/backend/lib/includes.php on line 16
[Sun Sep 21 16:11:23 2008] [error] [client 127.0.0.1]
[Sun Sep 21 16:11:23 2008] [error] [client 127.0.0.1] Lucid Error: db_query_err (Creation of table failed: "MDB2 Error: unknown error")
Ok, so it's hard for me to
Ok, so it's hard for me to tell what's going on. I've just committed something that will help troubleshoot the problem more.
If you don't feel like checking out again, you can just find this section in backend/models/base.php (it's all the way at the bottom):
if (PEAR::isError($p)) { if($p->getMessage() == "MDB2 Error: connect failed") internal_error("db_connect_err", 'Creation of table failed: "'.$p->getMessage().'"'); else internal_error("db_query_err", 'Creation of table failed: "'.$p->getMessage().'"'); }and change it to this:
if (PEAR::isError($p)) { if($p->getMessage() == "MDB2 Error: connect failed") internal_error("db_connect_err", 'Creation of table failed: "'.$p->getMessage().'"'.' ' . $p->getDebugInfo()); else internal_error("db_query_err", 'Creation of table failed: "'.$p->getMessage().'"'.' ' . $p->getDebugInfo()); }Then post up the logs again. Thanks.
Edited base.php and retried only with MySQL
#From apache error_log
[Sun Sep 21 18:25:07 2008] [error] [client 127.0.0.1] PHP Notice: Use of undefined constant MDB2 - assumed 'MDB2' in /srv/www/htdocs/backend/lib/includes.php on line 16
[Sun Sep 21 18:25:34 2008] [error] [client 127.0.0.1] PHP Notice: Use of undefined constant MDB2 - assumed 'MDB2' in /srv/www/htdocs/backend/lib/includes.php on line 16
[Sun Sep 21 18:25:34 2008] [error] [client 127.0.0.1] PHP Fatal error: Class 'Base~' not found in /srv/www/htdocs/install/backend.php on line 140
#From within the browser now it hangs indefinitely, "***Installation Error*** Database query error" no longer displayed
Oh, your text editor left
Oh, your text editor left behind a backup file, so when the installer tried to use the class it contained to create a table, it failed.
Remove the Base.php~ file and post the log again. Thanks.
[Sun Sep 21 18:43:42 2008]
[Sun Sep 21 18:43:42 2008] [error] [client 127.0.0.1] PHP Notice: Use of undefined constant MDB2 - assumed 'MDB2' in /srv/www/htdocs/backend/lib/includes.php on line 16
[Sun Sep 21 18:44:11 2008] [error] [client 127.0.0.1] PHP Notice: Use of undefined constant MDB2 - assumed 'MDB2' in /srv/www/htdocs/backend/lib/includes.php on line 16
[Sun Sep 21 18:44:12 2008] [error] [client 127.0.0.1] PHP Warning: Header may not contain more than a single header, new line detected. in /srv/www/htdocs/backend/lib/util.php on line 34
[Sun Sep 21 18:44:12 2008] [error] [client 127.0.0.1]
[Sun Sep 21 18:44:12 2008] [error] [client 127.0.0.1] Lucid Error: db_query_err (Creation of table failed: "MDB2 Error: not found" [Error message: extension mysql is not compiled into PHP]\n)
#Installing MySQL php module and retrying
Much more progress this time
[Sun Sep 21 18:47:33 2008] [error] [client 127.0.0.1] PHP Notice: Use of undefined constant MDB2 - assumed 'MDB2' in /srv/www/htdocs/backend/lib/includes.php on line 16
[Sun Sep 21 18:47:36 2008] [error] [client 127.0.0.1] PHP Notice: Use of undefined constant MDB2 - assumed 'MDB2' in /srv/www/htdocs/backend/lib/includes.php on line 16
[Sun Sep 21 18:47:36 2008] [error] [client 127.0.0.1] PHP Notice: Undefined index: icon in /srv/www/htdocs/backend/lib/package.php on line 106
[Sun Sep 21 18:47:36 2008] [error] [client 127.0.0.1] PHP Notice: Undefined index: permissions in /srv/www/htdocs/backend/lib/package.php on line 105
[Sun Sep 21 18:47:37 2008] [error] [client 127.0.0.1] PHP Notice: Undefined index: permissions in /srv/www/htdocs/backend/lib/package.php on line 105
[Sun Sep 21 18:47:37 2008] [error] [client 127.0.0.1] PHP Notice: Undefined index: icon in /srv/www/htdocs/backend/lib/package.php on line 106
[Sun Sep 21 18:47:37 2008] [error] [client 127.0.0.1] PHP Notice: Undefined index: permissions in /srv/www/htdocs/backend/lib/package.php on line 105
[Sun Sep 21 18:47:37 2008] [error] [client 127.0.0.1] PHP Notice: Undefined index: permissions in /srv/www/htdocs/backend/lib/package.php on line 105
[Sun Sep 21 18:47:37 2008] [error] [client 127.0.0.1] PHP Notice: Undefined index: icon in /srv/www/htdocs/backend/lib/package.php on line 106
[Sun Sep 21 18:47:37 2008] [error] [client 127.0.0.1] PHP Notice: Undefined index: permissions in /srv/www/htdocs/backend/lib/package.php on line 105
[Sun Sep 21 18:47:37 2008] [error] [client 127.0.0.1] PHP Notice: Undefined index: permissions in /srv/www/htdocs/backend/lib/package.php on line 105
[Sun Sep 21 18:47:37 2008] [error] [client 127.0.0.1] PHP Notice: Undefined index: permissions in /srv/www/htdocs/backend/lib/package.php on line 105
[Sun Sep 21 18:47:37 2008] [error] [client 127.0.0.1] PHP Notice: Undefined index: icon in /srv/www/htdocs/backend/lib/package.php on line 106
[Sun Sep 21 18:47:37 2008] [error] [client 127.0.0.1] PHP Notice: Undefined index: permissions in /srv/www/htdocs/backend/lib/package.php on line 105
[Sun Sep 21 18:47:37 2008] [error] [client 127.0.0.1] PHP Notice: Undefined index: icon in /srv/www/htdocs/backend/lib/package.php on line 106
[Sun Sep 21 18:47:37 2008] [error] [client 127.0.0.1] PHP Notice: Undefined index: permissions in /srv/www/htdocs/backend/lib/package.php on line 105
[Sun Sep 21 18:47:37 2008] [error] [client 127.0.0.1] PHP Notice: Undefined index: permissions in /srv/www/htdocs/backend/lib/package.php on line 105
[Sun Sep 21 18:47:37 2008] [error] [client 127.0.0.1] PHP Notice: Undefined index: permissions in /srv/www/htdocs/backend/lib/package.php on line 105
[Sun Sep 21 18:47:37 2008] [error] [client 127.0.0.1] PHP Notice: Undefined index: permissions in /srv/www/htdocs/backend/lib/package.php on line 105
[Sun Sep 21 18:47:37 2008] [error] [client 127.0.0.1] PHP Notice: Undefined index: permissions in /srv/www/htdocs/backend/lib/package.php on line 105
[Sun Sep 21 18:47:37 2008] [error] [client 127.0.0.1] PHP Notice: Undefined index: icon in /srv/www/htdocs/backend/lib/package.php on line 106
[Sun Sep 21 18:47:37 2008] [error] [client 127.0.0.1] PHP Notice: Undefined index: permissions in /srv/www/htdocs/backend/lib/package.php on line 105
[Sun Sep 21 18:47:37 2008] [error] [client 127.0.0.1] PHP Warning: Cannot modify header information - headers already sent by (output started at /srv/www/htdocs/backend/lib/unzip.php:111) in /srv/www/htdocs/backend/lib/output.php on line 97
#And inside the browser:
* Parsing form values...: ...done
* Generating encryption hash...: ...done
* Saving new configuration...: ...done
* Reloading configuration...: ...done
* Creating table for 'permission' class...: ...done
* Creating table for 'app' class...: ...done
* Creating table for 'user' class...: ...done
* Creating table for 'registry' class...: ...done
* Creating table for 'crosstalk' class...: ...done
* Creating table for 'auth' class...: ...done
* Creating table for 'config' class...: ...done
* Creating table for 'group' class...: ...done
* Creating table for 'quota' class...: ...done
***Installation Error***
Unknown error
Well that's strange, the
Well that's strange, the tables are suddenly created after adding the debug message, heh. Did you change anything else besides that?
Anyways, I've opened up a ticket regarding the package library here: http://trac.psychdesktop.net/ticket/156
I'll fix this tomorrow afternoon, right now I've got my hands full with something else. I'll try to get to it tonight if time permits.
Thanks.
Yes, I made a second backup
Yes, I made a second backup of base.php out of habit, in the same directory. I deleted both backups at the same time, but changed nothing else.
Thank you for the quick responses!
-Mike
Ok, I've fixed the issue.
Ok, I've fixed the issue. Sorry it took a day longer then expected.
I've also added you as a cc to the ticket. Can you confirm that my changes fixed the issue?
Thanks.
Should I check out the
Ok, in the browser it seems to stop at the same place, but in the apache error log it reads:
[Tue Sep 23 16:17:04 2008] [error] [client 127.0.0.1] PHP Warning: Cannot modify header information - headers already sent by (output started at /srv/www/htdocs/backend/lib/unzip.php:111) in /srv/www/htdocs/backend/lib/output.php on line 97
When you go to
When you go to http://site.com/install/backend.php?action=installapps, it should prompt you to download a file. When you open it in a text editor, what does it say?
Edit: I just committed something that shows the full error message when the installer fails. You may want to try that as well.
Following
Following http://localhost/install/backend.php?action=installapps nothing happens in my browser.
The now-visible installation error message is here: http://tinypaste.com/966d634
And in the apache error log:
[Tue Sep 23 18:20:03 2008] [error] [client 127.0.0.1] PHP Warning: Cannot modify header information - headers already sent by (output started at /srv/www/htdocs/backend/lib/unzip.php:111) in /srv/www/htdocs/backend/lib/output.php on line 97
Oh, wow. I can't believe I
Oh, wow. I can't believe I missed that.
in /backend/lib/unzip.php, change "<?" to "<?php". It's on the first line.
I've committed a fix, and I'll get to releasing another beta tomorrow, since others have probably had problems with this (also, I've fixed a lot of bugs since the first beta).
Thanks for helping me find that, I'm glad that got resolved :)
If you have any other problems, feel free to reply.
Hey, no problem. I'm no
Hey, no problem. I'm no programmer, but I'm happy to help break it! Anyway it's all in the spirit of open source :).
You've done a great job on this project!
Post new comment