Bug 161774 - databases/postgresql84-server: postgresql init script error
Summary: databases/postgresql84-server: postgresql init script error
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: Palle Girgensohn
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-10-18 16:20 UTC by kritek
Modified: 2011-10-19 19:30 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description kritek 2011-10-18 16:20:07 UTC
Postgresql port upgrade from 8.4.8_2 to 8.4.9 introduces changes to /usr/local/etc/rc.d/postgresql init script that cause database start to fail with error:

/usr/local/etc/rc.d/postgresql start
su: unknown login: %%PG_USER%%

This is the line from /usr/local/etc/rc.d/postgresql:

postgresql_user=${postgresql_user:-"%%PG_USER%%"}

Fix: 

Set postgresql_user="pgsql" in /etc/rc.conf.
This was the definition as set in the init script prior to the port upgrade.
How-To-Repeat: Execute /usr/local/etc/rc.d/postgresql start
Comment 1 Mark Linimon freebsd_committer freebsd_triage 2011-10-18 16:28:50 UTC
Responsible Changed
From-To: freebsd-ports-bugs->girgen

Fix synopsis and assign.
Comment 2 Chris Rees freebsd_committer freebsd_triage 2011-10-18 17:10:51 UTC
Hey Palle,

Great to see you've changed pgsql to use the USERS vars, thanks a lot.

This looks like the original problem I had when I changed the others
(hence my revert of the change before)-- although pkg-install.in no
longer uses the PG_USER var the rc script does.

Out of curiosity, why did you replace the ${} style with $() style? I
think that's what may have broken the replacements...

Chris
Comment 3 Chris Rees freebsd_committer freebsd_triage 2011-10-19 18:41:13 UTC
State Changed
From-To: open->closed

Duplicate of ports/161771
Comment 4 dfilter service freebsd_committer freebsd_triage 2011-10-19 19:21:39 UTC
crees       2011-10-19 18:21:25 UTC

  FreeBSD ports repository

  Modified files:
    databases/postgresql82-server Makefile 
    databases/postgresql83-server Makefile 
    databases/postgresql84-server Makefile 
    databases/postgresql90-server Makefile 
    databases/postgresql91-server Makefile 
  Log:
  Fix SUB_LIST issue by deconditionalising it.
  
  Temporary fix, but will stop the flurry of incoming PRs related.
  
  PR:             ports/161779 ports/161774 ports/161791 ports/161771 ports/161769
  Submitted by:   Many people, original fix suggested by Jason Helfman (jhelfman@e-e.com)
  Approved by:    portmgr (pav)
  
  Revision  Changes    Path
  1.202     +4 -3      ports/databases/postgresql82-server/Makefile
  1.215     +4 -3      ports/databases/postgresql83-server/Makefile
  1.233     +4 -3      ports/databases/postgresql84-server/Makefile
  1.228     +4 -3      ports/databases/postgresql90-server/Makefile
  1.229     +4 -3      ports/databases/postgresql91-server/Makefile
_______________________________________________
cvs-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/cvs-all
To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"