Bug 829958

Summary: spacewalk-setup is very unfriendly about handling if postgresql plpgsql is not created
Product: [Community] Spacewalk Reporter: Ben Galliart <bgallia>
Component: InstallationAssignee: Jan Pazdziora <jpazdziora>
Status: CLOSED CURRENTRELEASE QA Contact: Red Hat Satellite QA List <satqe-list>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 1.7CC: jpazdziora
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2012-06-08 07:33:02 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 871344    

Description Ben Galliart 2012-06-07 21:29:03 UTC
Description of problem:
Following the directions at https://fedorahosted.org/spacewalk/wiki/HowToInstall results in an generic error that the database could not be populated.

The helpful error message that plpgsql must be loaded is hidden away in /var/log/rhn/populate_db.log  Given the project is now called spacewalk, this seems like an odd location for a spacewalk novice to go searching for logs.  Also, this log location is never stated in HowToInstall or by the output of the spacewalk-setup script.

Version-Release number of selected component (if applicable):
1.7

How reproducible:
Always

Steps to Reproduce:
1.Install CentOS 6
2.Follow the instructions at https://fedorahosted.org/spacewalk/wiki/HowToInstall
3.
  
Actual results:
spacewalk-setup script outputs:
"Could not populate database."

Expected results:
If the postgresql user provided to the script has superuser access, then I expect the script to attempt to issue the create language plpgsql itself.

For any error where the script fails to populate the database, my expectation is that the location of the populate_db.log would be provided as part of the error message.

Additional info:

Comment 1 Jan Pazdziora 2012-06-08 07:33:02 UTC
(In reply to comment #0)
> 
> The helpful error message that plpgsql must be loaded is hidden away in
> /var/log/rhn/populate_db.log  Given the project is now called spacewalk,
> this seems like an odd location for a spacewalk novice to go searching for
> logs.  Also, this log location is never stated in HowToInstall or by the
> output of the spacewalk-setup script.

I've now amended the HowToInstall page with reference to /var/log/rhn.

> Expected results:
> If the postgresql user provided to the script has superuser access, then I
> expect the script to attempt to issue the create language plpgsql itself.

The expectation is really wrong here -- Spacewalk expects the plpgsql language to be created in the database beforehand -- please see https://fedorahosted.org/spacewalk/wiki/PostgreSQLServerSetup.