LinuxQuestions.org
Latest LQ Deal: Complete CCNA, CCNP & Red Hat Certification Training Bundle
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 09-03-2014, 11:56 AM   #1
andrewm659
Member
 
Registered: Oct 2004
Distribution: CentOS/Fedora/OpenSuse
Posts: 44

Rep: Reputation: 0
Cool setting up phpPgAdmin on CentOS 7


I'm having some trouble getting phpPgAdmin working on CentOS 7. Here are some of the configs. I am getting page forbidden.


[root@asm-sql01 phpPgAdmin]# pwd
/usr/share/phpPgAdmin
[root@asm-sql01 phpPgAdmin]# ls -lah
total 748K
drwxr-xr-x 12 root root 4.0K Sep 3 02:28 .
drwxr-xr-x. 103 root root 4.0K Sep 3 11:36 ..
-rw-r--r-- 1 root root 29K Apr 14 2013 admin.php
-rw-r--r-- 1 root root 16K Apr 14 2013 aggregates.php
-rw-r--r-- 1 root root 2.5K Apr 14 2013 ajax-ac-insert.php
-rw-r--r-- 1 root root 18K Apr 14 2013 all_db.php
-rw-r--r-- 1 root root 3.0K Apr 14 2013 browser.php
-rw-r--r-- 1 root root 2.1K Apr 14 2013 casts.php
drwxr-xr-x 3 root root 139 Sep 3 02:28 classes
-rw-r--r-- 1 root root 12K Apr 14 2013 colproperties.php
drwxr-xr-x 2 root root 53 Sep 3 10:28 conf
-rw-r--r-- 1 root root 23K Apr 14 2013 constraints.php
-rw-r--r-- 1 root root 1.9K Apr 14 2013 conversions.php
-rw-r--r-- 1 root root 30K Apr 14 2013 database.php
-rw-r--r-- 1 root root 11K Apr 14 2013 dataexport.php
-rw-r--r-- 1 root root 7.5K Apr 14 2013 dataimport.php
-rw-r--r-- 1 root root 4.3K Apr 14 2013 dbexport.php
-rw-r--r-- 1 root root 27K Apr 14 2013 display.php
-rw-r--r-- 1 root root 19K Apr 14 2013 domains.php
-rw-r--r-- 1 root root 36K Apr 14 2013 fulltext.php
-rw-r--r-- 1 root root 6.3K Apr 14 2013 functions.js
-rw-r--r-- 1 root root 38K Apr 14 2013 functions.php
-rw-r--r-- 1 root root 8.9K Apr 14 2013 groups.php
drwxr-xr-x 2 root root 4.0K Sep 3 02:28 help
-rw-r--r-- 1 root root 1.6K Apr 14 2013 help.php
-rw-r--r-- 1 root root 6.1K Apr 14 2013 history.php
drwxr-xr-x 3 root root 19 Sep 3 02:28 images
-rw-r--r-- 1 root root 1.8K Apr 14 2013 indexes.js
-rw-r--r-- 1 root root 14K Apr 14 2013 indexes.php
-rw-r--r-- 1 root root 861 Apr 14 2013 index.php
-rw-r--r-- 1 root root 12K Apr 14 2013 info.php
-rw-r--r-- 1 root root 2.0K Apr 15 2013 intro.php
drwxr-xr-x 2 root root 64 Sep 3 02:28 js
drwxr-xr-x 2 root root 4.0K Sep 3 02:28 lang
-rw-r--r-- 1 root root 1.6K Apr 14 2013 languages.php
drwxr-xr-x 4 root root 116 Sep 3 02:28 libraries
-rw-r--r-- 1 root root 520 Apr 14 2013 links.js
-rw-r--r-- 1 root root 2.4K Apr 14 2013 login.php
-rw-r--r-- 1 root root 265 Apr 14 2013 logout.php
-rw-r--r-- 1 root root 220 Apr 14 2013 multiactionform.js
-rw-r--r-- 1 root root 1.9K Apr 14 2013 opclasses.php
-rw-r--r-- 1 root root 7.9K Apr 14 2013 operators.php
-rw-r--r-- 1 root root 121 Apr 14 2013 plugin.php
drwxr-xr-x 4 root root 36 Sep 3 02:28 plugins
-rw-r--r-- 1 root root 12K Apr 14 2013 privileges.php
-rw-r--r-- 1 root root 667 Apr 14 2013 redirect.php
-rw-r--r-- 1 root root 221 Apr 14 2013 robots.txt
-rw-r--r-- 1 root root 32K Apr 14 2013 roles.php
-rw-r--r-- 1 root root 7.4K Apr 14 2013 rules.php
-rw-r--r-- 1 root root 16K Apr 14 2013 schemas.php
-rw-r--r-- 1 root root 24K Apr 14 2013 sequences.php
-rw-r--r-- 1 root root 4.3K Apr 14 2013 servers.php
-rw-r--r-- 1 root root 6.5K Apr 14 2013 sqledit.php
-rw-r--r-- 1 root root 8.1K Apr 14 2013 sql.php
-rw-r--r-- 1 root root 740 Apr 14 2013 tables.js
-rw-r--r-- 1 root root 9.8K Apr 14 2013 tablespaces.php
-rw-r--r-- 1 root root 37K Apr 14 2013 tables.php
-rw-r--r-- 1 root root 28K Apr 14 2013 tblproperties.php
drwxr-xr-x 5 root root 83 Sep 3 02:28 themes
-rw-r--r-- 1 root root 13K Apr 14 2013 triggers.php
-rw-r--r-- 1 root root 25K Apr 14 2013 types.php
-rw-r--r-- 1 root root 16K Apr 14 2013 users.php
-rw-r--r-- 1 root root 19K Apr 14 2013 viewproperties.php
-rw-r--r-- 1 root root 28K Apr 14 2013 views.php
drwxr-xr-x 2 root root 42 Sep 3 02:28 xloadtree
[root@asm-sql01 phpPgAdmin]# ls -lahd
drwxr-xr-x 12 root root 4.0K Sep 3 02:28 .
[root@asm-sql01 phpPgAdmin]#





[root@asm-sql01 phpPgAdmin]# cat /etc/httpd/conf.d/phpPgAdmin.conf
#
# This configuration file maps the phpPgAdmin directory into the URL space.
# By default this application is only accessible from the local host.
#

Alias /phpPgAdmin /usr/share/phpPgAdmin
Alias /phppgadmin /usr/share/phpPgAdmin

<Location /phpPgAdmin>
<IfModule mod_authz_core.c>
# Apache 2.4
Require local
#Require host example.com
</IfModule>
<IfModule !mod_authz_core.c>
# Apache 2.2
Order deny,allow
#Deny from all
Allow from All
</IfModule>
</Location>

[root@asm-sql01 phpPgAdmin]#

[root@asm-sql01 phpPgAdmin]# cat /etc/phpPgAdmin/config.inc.php
<?php

/**
* Central phpPgAdmin configuration. As a user you may modify the
* settings here for your particular configuration.
*
* $Id: config.inc.php-dist,v 1.55 2008/02/18 21:10:31 xzilla Exp $
*/

// An example server. Create as many of these as you wish,
// indexed from zero upwards.

// Display name for the server on the login screen
$conf['servers'][0]['desc'] = 'PostgreSQL';

// Hostname or IP address for server. Use '' for UNIX domain socket.
// use 'localhost' for TCP/IP connection on this computer
$conf['servers'][0]['host'] = '10.150.1.80';

// Database port on server (5432 is the PostgreSQL default)
$conf['servers'][0]['port'] = 5432;

// Database SSL mode
// Possible options: disable, allow, prefer, require
// To require SSL on older servers use option: legacy
// To ignore the SSL mode, use option: unspecified
$conf['servers'][0]['sslmode'] = 'allow';

// Change the default database only if you cannot connect to template1.
// For a PostgreSQL 8.1+ server, you can set this to 'postgres'.
$conf['servers'][0]['defaultdb'] = 'template1';

// Specify the path to the database dump utilities for this server.
// You can set these to '' if no dumper is available.
$conf['servers'][0]['pg_dump_path'] = '/usr/bin/pg_dump';
$conf['servers'][0]['pg_dumpall_path'] = '/usr/bin/pg_dumpall';

// Example for a second server (PostgreSQL for Windows)
//$conf['servers'][1]['desc'] = 'Test Server';
//$conf['servers'][1]['host'] = '127.0.0.1';
//$conf['servers'][1]['port'] = 5432;
//$conf['servers'][1]['sslmode'] = 'allow';
//$conf['servers'][1]['defaultdb'] = 'template1';
//$conf['servers'][1]['pg_dump_path'] = 'C:\\Program Files\\PostgreSQL\\8.0\\bin\\pg_dump.exe';
//$conf['servers'][1]['pg_dumpall_path'] = 'C:\\Program Files\\PostgreSQL\\8.0\\bin\\pg_dumpall.exe';


/* Groups definition */
/* Groups allow administrators to logicaly group servers together under
* group nodes in the left browser tree
*
* The group '0' description
*/
//$conf['srv_groups'][0]['desc'] = 'group one';

/* Add here servers indexes belonging to the group '0' seperated by comma */
//$conf['srv_groups'][0]['servers'] = '0,1,2';

/* A server can belong to multi groups. Here server 1 is referenced in both
* 'group one' and 'group two'*/
//$conf['srv_groups'][1]['desc'] = 'group two';
//$conf['srv_groups'][1]['servers'] = '3,1';

/* A group can be nested in one or more existing groups using the 'parents'
* parameter. Here the group 'group three' contains only one server and will
* appear as a subgroup in both 'group one' and 'group two':
*/
//$conf['srv_groups'][2]['desc'] = 'group three';
//$conf['srv_groups'][2]['servers'] = '4';
//$conf['srv_groups'][2]['parents'] = '0,1';

/* Warning: Only groups with no parents appears at the root of the tree. */


// Default language. E.g.: 'english', 'polish', etc. See lang/ directory
// for all possibilities. If you specify 'auto' (the default) it will use
// your browser preference.
$conf['default_lang'] = 'auto';

// AutoComplete uses AJAX interaction to list foreign key values
// on insert fields. It currently only works on single column
// foreign keys. You can choose one of the following values:
// 'default on' enables AutoComplete and turns it on by default.
// 'default off' enables AutoComplete but turns it off by default.
// 'disable' disables AutoComplete.
$conf['autocomplete'] = 'default on';

// If extra login security is true, then logins via phpPgAdmin with no
// password or certain usernames (pgsql, postgres, root, administrator)
// will be denied. Only set this false once you have read the FAQ and
// understand how to change PostgreSQL's pg_hba.conf to enable
// passworded local connections.
$conf['extra_login_security'] = false;

// Only show owned databases?
// Note: This will simply hide other databases in the list - this does
// not in any way prevent your users from seeing other database by
// other means. (e.g. Run 'SELECT * FROM pg_database' in the SQL area.)
$conf['owned_only'] = false;

// Display comments on objects? Comments are a good way of documenting
// a database, but they do take up space in the interface.
$conf['show_comments'] = true;

// Display "advanced" objects? Setting this to true will show
// aggregates, types, operators, operator classes, conversions,
// languages and casts in phpPgAdmin. These objects are rarely
// administered and can clutter the interface.
$conf['show_advanced'] = false;

// Display "system" objects?
$conf['show_system'] = false;

// Minimum length users can set their password to.
$conf['min_password_length'] = 1;

// Width of the left frame in pixels (object browser)
$conf['left_width'] = 200;

// Which look & feel theme to use
$conf['theme'] = 'default';

// Show OIDs when browsing tables?
$conf['show_oids'] = false;

// Max rows to show on a page when browsing record sets
$conf['max_rows'] = 30;

// Max chars of each field to display by default in browse mode
$conf['max_chars'] = 50;

// Send XHTML strict headers?
$conf['use_xhtml_strict'] = false;

// Base URL for PostgreSQL documentation.
// '%s', if present, will be replaced with the PostgreSQL version
// (e.g. 8.4 )
$conf['help_base'] = 'http://www.postgresql.org/docs/%s/interactive/';

// Configuration for ajax scripts
// Time in seconds. If set to 0, refreshing data using ajax will be disabled (locks and activity pages)
$conf['ajax_refresh'] = 3;

/** Plugins management
* Add plugin names to the following array to activate them
* Example:
* $conf['plugins'] = array(
* 'Example',
* 'Slony'
* );
*/
$conf['plugins'] = array();

/*****************************************
* Don't modify anything below this line *
*****************************************/

$conf['version'] = 19;

?>
[root@asm-sql01 phpPgAdmin]#
 
Old 09-06-2014, 08:55 AM   #2
halvy
Member
 
Registered: Aug 2005
Location: Anchorage, Alaska (soon EU, hopefully)
Distribution: Anything NOT SystemD (ie. M$) related.
Posts: 918

Rep: Reputation: 42
sounds like.. a permissions problem on your web server.
 
Old 09-07-2014, 10:23 PM   #3
andrewm659
Member
 
Registered: Oct 2004
Distribution: CentOS/Fedora/OpenSuse
Posts: 44

Original Poster
Rep: Reputation: 0
Thoughts on how to resolve?

Would it be in the /etc/httpd/conf.d/phpPgAdmin.conf file?
File perms?
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
setting up phppgadmin andrewm659 Linux - Server 3 07-04-2014 05:02 PM
What is the Username and Password of phpPgAdmin? chillyroll Linux - Software 2 10-25-2006 04:54 AM
How to start phpPGAdmin in Mandrake 10.1? bdika Mandriva 2 09-06-2005 05:59 PM
phpPgAdmin setup problems deadlock Linux - Software 3 12-18-2003 05:19 AM
problem with installing phppgadmin elea0612 Programming 0 05-22-2003 04:31 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 11:25 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration