Trouble with apache config on Fedora
Page 1 of 2

Author:  killboy [ Mon Jan 25, 2010 6:40 am ]
Post subject:  Trouble with apache config on Fedora

Hi all,

I'm struggling to get the Xplico interface working on Fedora 12, as far as i can see all the dependencies are present. It seems to redirect me to 'users/index' ... has anyone seen this behaviour before ? I can post the configs if necessary

thanks in advance


<edit>Sorry.. had to sign off before I was ready.. here are the relevant files:
# cat /etc/httpd/conf.d/xi.conf
NameVirtualHost *:9876

<VirtualHost *:9876>
   ServerAdmin info@xplico.org

   DocumentRoot /opt/xplico/xi
   <Directory "/opt/xplico/xi">
      Options All
      AllowOverride All
      Order allow,deny
      allow from all

   ScriptAlias /cgi-bin/ "/var/www/cgi-bin/"
   <Directory "/var/www/cgi-bin/">
      AllowOverride All
      Options +ExecCGI -MultiViews +SymLinksIfOwnerMatch
      Order allow,deny
      Allow from all

   ErrorLog /var/log/httpd/xplico_error.log

   # Possible values include: debug, info, notice, warn, error, crit,
   # alert, emerg.
   LogLevel warn

   CustomLog /var/log/httpd/xplico_access.log combined


Bits from /etc/httpd/conf/httpd.conf:
Listen 80
Listen 9876

LoadModule rewrite_module modules/mod_rewrite.so
LoadModule cgi_module modules/mod_cgi.so


Author:  carlos.gacimartin [ Mon Jan 25, 2010 10:55 am ]
Post subject:  Re: Trouble with apache config on Fedora

please, give us more tips:

a) Have you started Xplico binary? (sudo /opt/xplico/scripts/sqlite_demo.sh)
b) Your files seem to be ok. Which is the content of "/opt/xplico/xi/.htaccess" ?
c) Is there any interesting info at "/var/log/apache2/error.log" , "/var/log/apache2/access.log" , "/var/log/apache2/xplico_access.log", or "/var/log/apache2/xplico_error.log"? (or the Apache's log files at Fedora, I'm used to Debian/Ubuntu paths :)
d) Do you have these Apache's modules activated?

alias.conf       authz_default.load    autoindex.conf  deflate.load  mime.conf         php5.conf      setenvif.load
alias.load       authz_groupfile.load  autoindex.load  dir.conf      mime.load         php5.load      status.conf
auth_basic.load  authz_host.load       cgi.load        dir.load      negotiation.conf  rewrite.load   status.load
authn_file.load  authz_user.load       deflate.conf    env.load      negotiation.load  setenvif.conf

e) Have you restarted Apache?

Author:  killboy [ Mon Jan 25, 2010 12:56 pm ]
Post subject:  Re: Trouble with apache config on Fedora

Thanks very much for the response...

a) yes.. shows in ps output as './dema -d /opt/xplico -b sqlite'
b) # cat /opt/xplico/xi/.htaccess
<IfModule mod_rewrite.c>
    RewriteEngine on
    RewriteRule    ^$    app/webroot/    [L]
    RewriteRule    (.*) app/webroot/$1    [L]

c) Nothing interesting at all...
d) The modules are the default ones, I haven't tuned it as yet:
# grep LoadModule /etc/httpd/conf/httpd.conf
LoadModule auth_basic_module modules/mod_auth_basic.so
LoadModule auth_digest_module modules/mod_auth_digest.so
LoadModule authn_file_module modules/mod_authn_file.so
LoadModule authn_alias_module modules/mod_authn_alias.so
LoadModule authn_anon_module modules/mod_authn_anon.so
LoadModule authn_dbm_module modules/mod_authn_dbm.so
LoadModule authn_default_module modules/mod_authn_default.so
LoadModule authz_host_module modules/mod_authz_host.so
LoadModule authz_user_module modules/mod_authz_user.so
LoadModule authz_owner_module modules/mod_authz_owner.so
LoadModule authz_groupfile_module modules/mod_authz_groupfile.so
LoadModule authz_dbm_module modules/mod_authz_dbm.so
LoadModule authz_default_module modules/mod_authz_default.so
LoadModule ldap_module modules/mod_ldap.so
LoadModule authnz_ldap_module modules/mod_authnz_ldap.so
LoadModule include_module modules/mod_include.so
LoadModule log_config_module modules/mod_log_config.so
LoadModule logio_module modules/mod_logio.so
LoadModule env_module modules/mod_env.so
LoadModule ext_filter_module modules/mod_ext_filter.so
LoadModule mime_magic_module modules/mod_mime_magic.so
LoadModule expires_module modules/mod_expires.so
LoadModule deflate_module modules/mod_deflate.so
LoadModule headers_module modules/mod_headers.so
LoadModule usertrack_module modules/mod_usertrack.so
LoadModule setenvif_module modules/mod_setenvif.so
LoadModule mime_module modules/mod_mime.so
LoadModule dav_module modules/mod_dav.so
LoadModule status_module modules/mod_status.so
LoadModule autoindex_module modules/mod_autoindex.so
LoadModule info_module modules/mod_info.so
LoadModule dav_fs_module modules/mod_dav_fs.so
LoadModule vhost_alias_module modules/mod_vhost_alias.so
LoadModule negotiation_module modules/mod_negotiation.so
LoadModule dir_module modules/mod_dir.so
LoadModule actions_module modules/mod_actions.so
LoadModule speling_module modules/mod_speling.so
LoadModule userdir_module modules/mod_userdir.so
LoadModule alias_module modules/mod_alias.so
LoadModule rewrite_module modules/mod_rewrite.so
LoadModule proxy_module modules/mod_proxy.so
LoadModule proxy_balancer_module modules/mod_proxy_balancer.so
LoadModule proxy_ftp_module modules/mod_proxy_ftp.so
LoadModule proxy_http_module modules/mod_proxy_http.so
LoadModule proxy_connect_module modules/mod_proxy_connect.so
LoadModule cache_module modules/mod_cache.so
LoadModule suexec_module modules/mod_suexec.so
LoadModule disk_cache_module modules/mod_disk_cache.so
LoadModule cgi_module modules/mod_cgi.so

e) Yes.. many times

Further details:
Entering 'http://localhost:9876/' results in 'http://localhost:9876/users/index' with a blank page (no source)
Entering 'http://localhost:9876/index.php' results in 'http://localhost:9876/users/index' with a blank page (no source)
Entering 'http://localhost:9876/app/webroot' results in what looks like a complete page but with an error:
'Not Found
Error: The requested address '/app/webroot' was not found on this server.'

selinux is disabled
httpd version: 2.2.14
php version: 5.3.1

<edit>I downloaded DEFT to compare the configurations - does xplico care whether php is configured to run as a cgi binary or a module ? I noticed that there are php binaries under /usr/lib/cgi-bin in DEFT but on Fedora theres nothing under /var/www/cgi-bin ... </edit>

Author:  gianluca.costa [ Mon Jan 25, 2010 1:56 pm ]
Post subject:  Re: Trouble with apache config on Fedora

Hi Killboy,
DEFT uses Lighttpd as Web server and not Apache.
I do not know what webserver you are using, but if it is Lighttpd then from source code in directory system/web_cfg you can find lighttpd.conf and mod_fastcgi.conf, this files can be used to configure Lighttpd server.
Lighttpd is test only on 0.5.3 version, the new version (0.5.4) use a new version of CakePHP ant I think that those files will not work.


Author:  killboy [ Mon Jan 25, 2010 2:29 pm ]
Post subject:  Re: Trouble with apache config on Fedora

Yeah... I was running apache originally when I started this post, after looking at DEFT I set up lighttpd and fastcgi. I end up with exactly the same problem - blank pages. I'm wondering if it's the php version as I'm a minor version ahead of DEFT (5.3.1 vs 5.2.10) .. have you been testing under php 5.3.x yet ?

Author:  carlos.gacimartin [ Mon Jan 25, 2010 3:06 pm ]
Post subject:  Re: Trouble with apache config on Fedora

i had yesterday a similar error while testing Xplico on a Debian. It was caused (i think it is not your problem) because the database was not accesible.

To test this:
chmod 777 /opt/xplico/xplico.db  (just for discarding problems)
nano /opt/xplico/xi/app/config/database.php  (please check the path).

About PHP version, i haven't tested it in php 5.3, but Google says Cakephp 1.2.5 is not a good friend of 5.3, perhaps that's the problem. I'm using 5.2 and works fine
test@virtuakarmic:/etc/php5/apache2$ php5 -v
PHP 5.2.10-2ubuntu6.4 with Suhosin-Patch 0.9.7 (cli) (built: Jan  6 2010 22:41:56)
Copyright (c) 1997-2009 The PHP Group
Zend Engine v2.2.0, Copyright (c) 1998-2009 Zend Technologies


To check if this is the problem, please test with 5.3 this:

vi /opt/xplico/xi/app/config/core.php
Configure::write('debug', 1);

and test later with php 5.2 too. If it works with 5.2, please don't forget to give us feedback :)

Author:  killboy [ Mon Jan 25, 2010 10:23 pm ]
Post subject:  Re: Trouble with apache config on Fedora

Thanks, the debugging info helped... I got an error regarding not being able to write to /opt/xplico/xi/app/tmp/cache
so I updated the permissions. The error I get now is probably the culprit:

Fatal error: Call to undefined function sqlite_open() in /opt/xplico/xi/cake/libs/model/datasources/dbo/dbo_sqlite.php on line 108

I'll look into it today, but if you have any thoughts please let me know


Author:  carlos.gacimartin [ Tue Jan 26, 2010 10:23 am ]
Post subject:  Re: Trouble with apache config on Fedora

could you check (and paste here) the contents and permissions of:


Author:  killboy [ Tue Jan 26, 2010 2:59 pm ]
Post subject:  Re: Trouble with apache config on Fedora

I think the problem may be that php-pdo on Fed 12 provides sqlite3 support not sqlite/sqlite2, I'll have a go at installing it on Fed 11 (php 5.2.x) tomorrow amd let you know the results. The deprecation warnings were resolved by setting date.timezone in /etc/php.ini


As requested:

# ls -l /opt/xplico/xi/app/config/database.php
-rw-r--r--. 1 root root 2269 2010-01-27 01:34 /opt/xplico/xi/app/config/database.php

# cat /opt/xplico/xi/app/config/database.php
/* SVN FILE: $Id: database.php.default 4409 2007-02-02 13:20:59Z phpnut $ */
 * This is core configuration file.
 * Use it to configure core behaviour ofCake.
 * PHP versions 4 and 5
 * CakePHP(tm) :  Rapid Development Framework <http://www.cakephp.org/>
 * Copyright 2005-2007, Cake Software Foundation, Inc.
 *                        1785 E. Sahara Avenue, Suite 490-204
 *                        Las Vegas, Nevada 89104
 * Licensed under The MIT License
 * Redistributions of files must retain the above copyright notice.
 * @filesource
 * @copyright      Copyright 2005-2007, Cake Software Foundation, Inc.
 * @link            http://www.cakefoundation.org/projects/info/cakephp CakePHP(tm) Project
 * @package         cake
 * @subpackage      cake.app.config
 * @since         CakePHP(tm) v 0.2.9
 * @version         $Revision: 4409 $
 * @modifiedby      $LastChangedBy: phpnut $
 * @lastmodified   $Date: 2007-02-02 07:20:59 -0600 (Fri, 02 Feb 2007) $
 * @license         http://www.opensource.org/licenses/mit-license.php The MIT License
 * In this file you set up your database connection details.
 * @package      cake
 * @subpackage   cake.config
 * Database configuration class.
 * You can specify multiple configurations for production, development and testing.
 * driver =>
 * mysql, postgres, sqlite, adodb, pear-drivername
 * connect =>
 * MySQL set the connect to either mysql_pconnect of mysql_connect
 * PostgreSQL set the connect to either pg_pconnect of pg_connect
 * SQLite set the connect to sqlite_popen  sqlite_open
 * ADOdb set the connect to one of these
 *   (http://phplens.com/adodb/supported.databases.html) and
 *   append it '|p' for persistent connection. (mssql|p for example, or just mssql for not persistent)
 * host =>
 * the host you connect to the database
 * MySQL 'localhost' to add a port number use 'localhost:port#'
 * PostgreSQL 'localhost' to add a port number use 'localhost port=5432'
   var $default = array('driver' => 'sqlite',
                        'connect' => 'sqlite_open',
                        'host' => '',
                                                                'login' => '',
                                                                'password' => '',
                        'database' => '/opt/xplico/xplico.db',
                        'prefix' => '');

Author:  carlos.gacimartin [ Tue Jan 26, 2010 4:07 pm ]
Post subject:  Re: Trouble with apache config on Fedora

Yes, that sounds to be the problem, Xplico uses up to 0.5.4 version the sqlite v2.
From Xplico 0.5.5 it will be used Sqlite3. This one may be released at the end of February. Meanwhile, try with a Fedora with sqlite2 support. Or use a virtualbox image of Xplico, http://sourceforge.net/projects/xplico/files/

Page 1 of 2 All times are UTC
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group