:huh:
After alot of messing around the install seems to go through ok, then i open up a browser and go to the address
XXX.XXX.XX.XXX/msm/core/web/
The page takes forever to load and then displays
MySource Error
DB Error: no such database
(in a little maroon box)
Whats going on?
Im running RHEL3, pre postgresql 7.4 (index disabled in tables.xml) added plpgsql language, php-cli install.
Install ok DB ERROR
You never reference the /core/web location – Apache aliases will handle that for you.
I assume you have successfully run (in order):
- step_01.php
(and edited /path/to/mysource_matrix/data/private/conf/main.inc to specify the SQ_CONF_DB_DSN and SQ_CONF_DB_DSN2, as well as the SQ_CONF_SYSTEM_ROOT_URLS values),
- step_02.php
- compile_locales.php (if running Matrix v3.6)
- step_03.php.
- compile_locales.php (if running Matrix v3.6)
Once that is done, you will need to add the following Aliases to Apache's httpd.conf:
Alias "/__fudge" /path/to/mysource_matrix/fudge Alias "/__data" /path/to/mysource_matrix/data/public Alias "/__lib" /path/to/mysource_matrix/core/lib Alias "/" /path/to/mysource_matrix/core/web/index.php/
You will also need to set AcceptPathInfo On somewhere appropriate in httpd.conf for that last alias line to work properly in RHEL3.
Sorry I should have said yes I installed version 3.6
Followed the install forum.
System root url 192.168.25.153/msm
I added the Alias and the AcceptPath.
Take forever to load, then comes back with same error. MySource Error. DB Error: no such database.
Can you post the contents of your data/private/conf/main.inc?
With that URL set as the System Root URL, you should have the following aliases:
Alias "/msm/__fudge" /path/to/mysource_matrix/fudge Alias "/msm/__data" /path/to/mysource_matrix/data/public Alias "/msm/__lib" /path/to/mysource_matrix/core/lib Alias "/msm/" /path/to/mysource_matrix/core/web/index.php
Note the lack of trailling slash on the last alias line.
[quote]Can you post the contents of your data/private/conf/main.inc?
With that URL set as the System Root URL, you should have the following aliases:
Alias "/msm/__fudge" /path/to/mysource_matrix/fudge Alias "/msm/__data" /path/to/mysource_matrix/data/public Alias "/msm/__lib" /path/to/mysource_matrix/core/lib Alias "/msm/" /path/to/mysource_matrix/core/web/index.php
Note the lack of trailling slash on the last alias line.
[right][post="7177"]<{POST_SNAPBACK}>[/post][/right][/quote]
Changed the Alias same error.
Here is my main.inc
<?php
define('SQ_CONF_DB_DSN', 'pgsql://user:pass@source()/source');
define('SQ_CONF_DB2_DSN', 'pgsql://user:pass@source()/source');
define('SQ_CONF_PEAR_PATH', SQ_SYSTEM_ROOT.'/php_includes');
$inc_dir = ini_get('include_path');
$inc_dir = (substr($inc_dir, 0, 2) == '.:') ? '.:'.SQ_CONF_PEAR_PATH.':'.substr($inc_dir, 2) : SQ_CONF_PEAR_PATH.':'.$inc_dir;
ini_set('include_path', $inc_dir);
define('SQ_CONF_BACKEND_SUFFIX', '_admin');
define('SQ_CONF_LIMBO_SUFFIX', '_edit');
define('SQ_CONF_ASSET_TREE_BASE', 64);
define('SQ_CONF_ASSET_TREE_SIZE', 4);
define('SQ_CONF_ASSET_CACHE_SIZE_WEB', -1);
define('SQ_CONF_ASSET_CACHE_SIZE_CLI', -1);
define('SQ_CONF_ROLLBACK_ENABLED', '1');
define('SQ_CONF_DEBUG', 0);
define('SQ_CONF_SYSTEM_NAME', 'The System');
define('SQ_CONF_SYSTEM_OWNER', '');
define('SQ_CONF_SYSTEM_ROOT_URLS', '192.168.25.153/msm');
define('SQ_CONF_DEFAULT_EMAIL', 'matrix-team@squiz.net');
define('SQ_CONF_TECH_EMAIL', 'matrix-team@squiz.net');
define('SQ_CONF_MAX_LOGIN_ATTEMPTS', 3);
define('SQ_CONF_REFRESH_INTERVAL', 120);
define('SQ_CONF_LOCK_LENGTH', 600);
define('SQ_CONF_LOG_FILE', '');
define('SQ_CONF_LOG_ERRORS', true);
ini_set('log_errors', '1');
define('SQ_CONF_ERRORS_HIDE_FRONTEND', false);
define('SQ_CONF_DEFAULT_FRONTEND_LANGUAGE', 'en');
define('SQ_CONF_DEFAULT_BACKEND_LOCALE', 'en_AU');
define('SQ_CONF_DEFAULT_CHARACTER_SET', 'iso-8859-1');
define('SQ_CONF_ALLOW_IP_CHANGE', '0');
define('SQ_CONF_ALLOW_HTTP_LOGIN', '0');
define('SQ_CONF_COMMIT_BUTTON_TEXT', 'Commit');
define('SQ_CONF_LOG_EXTENSION', '.log');
define('SQ_CONF_LOG_FILE_SYSTEM', 'system');
define('SQ_CONF_LOG_FILE_ERROR', 'error');
ini_set('error_log', SQ_LOG_PATH.'/'.SQ_CONF_LOG_FILE_ERROR.SQ_CONF_LOG_EXTENSION);
define('SQ_CONF_SESSION_GC_MAXLIFETIME', 604800);
ini_set('session.gc_maxlifetime', 604800);
define('SQ_CONF_EDITING_TIME', 3600);
?>
Cheers.
[quote]define(‘SQ_CONF_DB_DSN’, ‘pgsql://user:pass@source()/source’);
define(‘SQ_CONF_DB2_DSN’, ‘pgsql://user:pass@source()/source’);
[right][post=“7181”]<{POST_SNAPBACK}>[/post][/right][/quote]
These should probably be:
define('SQ_CONF_DB_DSN', 'pgsql://user:pass@unix()/source'); define('SQ_CONF_DB2_DSN', 'pgsql://user:pass@unix()/source');
If you're connecting to PostgreSQL on the local machine. Also, check your /var/lib/pgsql/data/pg_hba.conf file to ensure that PostgreSQL trusts local connections.
[quote]These should probably be:
define('SQ_CONF_DB_DSN', 'pgsql://user:pass@unix()/source'); define('SQ_CONF_DB2_DSN', 'pgsql://user:pass@unix()/source');
If you're connecting to PostgreSQL on the local machine. Also, check your /var/lib/pgsql/data/pg_hba.conf file to ensure that PostgreSQL trusts local connections.
[right][post="7182"]<{POST_SNAPBACK}>[/post][/right][/quote]
This is a section of my pg_hba.conf
# ----------------------------------
#
# CAUTION: The default configuration allows any local user to connect
# using any PostgreSQL user name, including the superuser, over either
# Unix-domain sockets or TCP/IP. If you are on a multiple-user
# machine, the default configuration is probably too liberal for you.
# Change it to use something other than "trust" authentication.
#
# If you want to allow non-local connections, you need to add more
# "host" records. Also, remember TCP/IP connections are only enabled
# if you enable "tcpip_socket" in postgresql.conf.
# TYPE DATABASE USER IP-ADDRESS IP-MASK METHOD
local all all trust
host source user trust
# Using sockets credentials for improved security. Not available everywhere,
# but works on Linux, *BSD (and probably some others)
local all all ident sameuser
I thought the format was like this
pgsql://user:pass@hostname()/dbname
pgsql://user:pass@source()/source - this would be mine.
Thank you.
[quote]pgsql://user:pass@hostname()/dbname
pgsql://user:pass@source()/source - this would be mine.
[right][post=“7184”]<{POST_SNAPBACK}>[/post][/right][/quote]
Your pg_hba.conf is fine – you have local being trusted.
The format for the DSN is either:
pgsql://user:pass@hostname/dbname
or
pgsql://user:pass@unix()/dbname
The second one only works to local PostgreSQL installations (connects via Unix Socket instead of via TCP/IP). If you use the first one, not only do you need an entry for the source host in pg_hba.conf, you also need to enable the TCP/IP socket in postgresql.conf (some distros disable this by default).
[quote]Your pg_hba.conf is fine – you have local being trusted.
The format for the DSN is either:
pgsql://user:pass@hostname/dbname
or
pgsql://user:pass@unix()/dbname
The second one only works to local PostgreSQL installations (connects via Unix Socket instead of via TCP/IP). If you use the first one, not only do you need an entry for the source host in pg_hba.conf, you also need to enable the TCP/IP socket in postgresql.conf (some distros disable this by default).
[right][post=“7186”]<{POST_SNAPBACK}>[/post][/right][/quote]
Here is a section of my postgresql.conf
#========================================================================
#
Connection Parameters
#
tcpip_socket = true
#ssl = false
#max_connections = 32
#superuser_reserved_connections = 2
#port = 5432
#hostname_lookup = false
#show_source_port = false
#unix_socket_directory = ''
#unix_socket_group = ''
#unix_socket_permissions = 0777 # octal
#virtual_host = ''
#krb_server_keyfile = ''
#
Seems we are running out of options?
[quote]Seems we are running out of options?
[right][post=“7188”]<{POST_SNAPBACK}>[/post][/right][/quote]
No, your DSNs are still incorrect. If you have a single server, you should be using the unix() style DSNs. If you have multiple servers, you need to use the hostname (or IP address) in the DSN without () characters.
[quote]No, your DSNs are still incorrect. If you have a single server, you should be using the unix() style DSNs. If you have multiple servers, you need to use the hostname (or IP address) in the DSN without () characters.
[right][post=“7189”]<{POST_SNAPBACK}>[/post][/right][/quote]
I set in main.inc
pgsql://user:pass@unix()/source
This still doesnt work, or do i have to start again and specify this option before the installation roles out?
[quote]This still doesnt work, or do i have to start again and specify this option before the installation roles out?
[right][post=“7190”]<{POST_SNAPBACK}>[/post][/right][/quote]
You will need this correct before running step_02.php – though, step_02.php will not run properly unless it can successfully connect to the database, which implies that your installation is not complete.
Is the database named “source” created? Have you installed the PL/pgSQL language into that database using the createlang tool? Have you created the user in PostgreSQL? Have you set the password for that user (though, with local connections, you don’t need to specify the password, as you have already told PostgreSQL to trust the inbound connection).
[quote]You will need this correct before running step_02.php – though, step_02.php will not run properly unless it can successfully connect to the database, which implies that your installation is not complete.
Is the database named “source” created? Have you installed the PL/pgSQL language into that database using the createlang tool? Have you created the user in PostgreSQL? Have you set the password for that user (though, with local connections, you don’t need to specify the password, as you have already told PostgreSQL to trust the inbound connection).
[right][post=“7191”]<{POST_SNAPBACK}>[/post][/right][/quote]
The Plpgsql is on the DB
DB = source
user = user
pass = pass
A user was create VIA sql
CREATE DATABASE source OWNER user;
then the createlang tool was done.
steps 1-3 seemed to run fine, previsouly to make sure it wasnt lying to me i changed the name of source to something else and i recieved a DB connect error, so its connecting fine (i would assume from that it is).
[quote]steps 1-3 seemed to run fine, previsouly to make sure it wasnt lying to me i changed the name of source to something else and i recieved a DB connect error, so its connecting fine (i would assume from that it is).
[right][post=“7192”]<{POST_SNAPBACK}>[/post][/right][/quote]
Have you changed your aliases and restarted Apache? If step_01.php (and 02, 03) all work properly, then it means those scripts are connecting to the database correctly.
[quote]Have you changed your aliases and restarted Apache? If step_01.php (and 02, 03) all work properly, then it means those scripts are connecting to the database correctly.
[right][post=“7193”]<{POST_SNAPBACK}>[/post][/right][/quote]
Yeah thats what i thought, i have run into several issues before and have resolved all of them up to this stage.
Just restarted httpd and…same error.
If the Aliases were wrong i wouldnt get the DB error: no such database?
[quote]If the Aliases were wrong i wouldnt get the DB error: no such database?
[right][post=“7194”]<{POST_SNAPBACK}>[/post][/right][/quote]
I’m at a loss now. If the install scripts are working, I can’t think of a reason why you’d be getting this error when accessing via the website.
[quote]I’m at a loss now. If the install scripts are working, I can’t think of a reason why you’d be getting this error when accessing via the website.
[right][post=“7196”]<{POST_SNAPBACK}>[/post][/right][/quote]
I’ll start again from scratch tonight. I’ll let you know in <5hrs.
[quote]I’ll start again from scratch tonight. I’ll let you know in <5hrs.
[right][post=“7197”]<{POST_SNAPBACK}>[/post][/right][/quote]
Ok.
Rebuilt RHEL3 ES update5
httpd-2.0.46-46
rh-postgresql-7.3.9-2
php-4.3.2-cli
PEAR-1.4.2
Archive_Tar-1.3.1
Mail-1.1.9
DB-1.7.6
Cache-1.5.5.RC4
XML_Parser-1.2.7
And some others.
MySource 3.6
mods;
DB info;
DBNAME = tomato
DBUSER = sauce
PASS = NULL (no pass)
followed php-cli build on other forum using source from redhat (-openssl)
edited tables.xml remove indexs
added alias to httpd.conf
added local/host 127.0.0.1 all db all users to pg_hba.conf
added tcp/ip socket = true to postrgresql.conf
added pgsql://sauce@unix()/tomato + rollback + 10.10.0.3 to main.inc
followed step_02.php . - one prob forgot to change createlang plpgsql. fixed, dropped db started again. then success. locale=en_AU
followed step_03.php . - no error then locale=en_AU
all worked.
http://10.10.0.3 - DHCP
Thinks about it then…DB Error: no such database
Hope this helps.
[quote]Ok.
Rebuilt RHEL3 ES update5
httpd-2.0.46-46
rh-postgresql-7.3.9-2
php-4.3.2-cli
PEAR-1.4.2
Archive_Tar-1.3.1
Mail-1.1.9
DB-1.7.6
Cache-1.5.5.RC4
XML_Parser-1.2.7
And some others.
MySource 3.6
mods;
DB info;
DBNAME = tomato
DBUSER = sauce
PASS = NULL (no pass)
followed php-cli build on other forum using source from redhat (-openssl)
edited tables.xml remove indexs
added alias to httpd.conf
added local/host 127.0.0.1 all db all users to pg_hba.conf
added tcp/ip socket = true to postrgresql.conf
added pgsql://sauce@unix()/tomato + rollback + 10.10.0.3 to main.inc
followed step_02.php . - one prob forgot to change createlang plpgsql. fixed, dropped db started again. then success. locale=en_AU
followed step_03.php . - no error then locale=en_AU
all worked.
http://10.10.0.3 - DHCP
Thinks about it then…DB Error: no such database
Hope this helps.
[right][post=“7204”]<{POST_SNAPBACK}>[/post][/right][/quote]
Also when i access the 10.10.0.3 page i’m doing this from another machine on the same network.
RHEL3 has no gui,
[quote]added tcp/ip socket = true to postrgresql.conf
[right][post=“7204”]<{POST_SNAPBACK}>[/post][/right][/quote]
If you’re using unix() then you don’t need to turn on tcpip = true in postgresql.conf, though I say that just for informational purposes rather than anything else.
Do you have the following RPMs installed:
php
php-gd
php-pear
php-pgsql
I’m just wondering if your CLI binary has PgSQL support, but the Apache mod_php4 doesn’t (i.e. the php-pgsql RPM is not installed).