Bug 154711 - security/heimdal: kadmin: hdb_open: hdb_open failed initialize database /var/heimdal/heimdal
Summary: security/heimdal: kadmin: hdb_open: hdb_open failed initialize database /var/...
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: Niclas Zeising
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-02-12 16:30 UTC by Jason C. Wells
Modified: 2012-09-26 13:50 UTC (History)
0 users

See Also:


Attachments
patch.txt (596 bytes, text/plain; charset=US-ASCII)
2012-05-09 22:57 UTC, rsimmons0
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Jason C. Wells 2011-02-12 16:30:07 UTC
Install heimdal port, create new database

$ kadmin -l
kadmin> init REALM
kadmin: hdb_open: hdb_open failed initialize database /var/heimdal/heimdal
kadmin> quit
$

But /var/heimdal/heimdal.db is created, as it should be.  For some reason kadmin is looking for the wrong path.  Explicitly defining dbname=/var/heimdal/heimdal.db in kdc.conf just moves the path error over by an extra ".db" such that the error becomes 

kadmin: hdb_open: hdb_open failed initialize database /var/heimdal/heimdal.db

but /var/heimdal/heimdal.db.db is created.

Fix: 

unknown
Comment 1 mokomull 2011-11-21 00:14:51 UTC
I ran into similar issues a couple weeks back.  It came down to a
couple problems:

1) the default configuration for security/heimdal doesn't have any
backends turned on.  I ran "make config" and enabled BDB and then I
was able to use /usr/local/libexec/hpropd to initialize the database
and migrate from another running system.  Perhaps this should be on by
default.

2) security/heimdal builds using a newer version of BDB than the
minimal heimdal included in the base system.  Be sure to use
/usr/local/sbin/kadmin instead of /usr/bin/kadmin.  The latter cannot
read the database written by the daemons installed with
security/heimdal.

Along that last point, make sure you set the binary paths in /etc/rc.conf:
kerberos5_server="/usr/local/libexec/kdc"
kadmind5_server="/usr/local/libexec/kadmind"
kpasswdd_server="/usr/local/libexec/kpasswdd"
--
Matt Mullins
Comment 2 rsimmons0 2012-05-09 22:57:48 UTC
Here's a patch to fix this.
Comment 3 Edwin Groothuis freebsd_committer freebsd_triage 2012-07-04 14:14:51 UTC
Maintainer of security/heimdal,

Please note that PR ports/154711 has just been submitted.

If it contains a patch for an upgrade, an enhancement or a bug fix
you agree on, reply to this email stating that you approve the patch
and a committer will take care of it.

The full text of the PR can be found at:
    http://www.freebsd.org/cgi/query-pr.cgi?pr=ports/154711

-- 
Edwin Groothuis via the GNATS Auto Assign Tool
edwin@FreeBSD.org
Comment 4 Edwin Groothuis freebsd_committer freebsd_triage 2012-07-04 14:14:53 UTC
State Changed
From-To: open->feedback

Awaiting maintainers feedback (via the GNATS Auto Assign Tool)
Comment 5 Niclas Zeising freebsd_committer freebsd_triage 2012-07-04 14:26:55 UTC
Responsible Changed
From-To: freebsd-ports-bugs->zeising

I'll work on this.
Comment 6 dfilter service freebsd_committer freebsd_triage 2012-09-26 13:46:40 UTC
Author: zeising
Date: Wed Sep 26 12:46:26 2012
New Revision: 304905
URL: http://svn.freebsd.org/changeset/ports/304905

Log:
  Enable the Berkley DB backend by default.
  Bump portrevision.
  
  PR:		ports/154711
  Submitted by:	Jason C. Wells <jcw@speakeasy.net> (pr)
  		Robert Simmons <rsimmons0@gmail.com> (patch)
  Approved by:	maintainer timeout (12 weeks), kwm (mentor)

Modified:
  head/security/heimdal/Makefile

Modified: head/security/heimdal/Makefile
==============================================================================
--- head/security/heimdal/Makefile	Wed Sep 26 12:40:12 2012	(r304904)
+++ head/security/heimdal/Makefile	Wed Sep 26 12:46:26 2012	(r304905)
@@ -7,7 +7,7 @@
 
 PORTNAME=	heimdal
 PORTVERSION=	1.5.2
-PORTREVISION=	3
+PORTREVISION=	4
 CATEGORIES=	security ipv6
 MASTER_SITES=	http://www.h5l.org/dist/src/ \
 		http://ftp.pdc.kth.se/pub/heimdal/src/ \
@@ -21,7 +21,7 @@ CONFLICTS=	krb4-[0-9]* krb5-[0-9]* srp-[
 
 OPTIONS=	IPV6	"Enable IPV6 support"				on \
 		KCM	"Enable Kerberos Credentials Manager"		on \
-		BDB	"Enable BerkeleyDB KDC backend support"		off \
+		BDB	"Enable BerkeleyDB KDC backend support"		on \
 		SQLITE	"Enable SQLite KDC backend support"		off \
 		LDAP	"Enable OpenLDAP KDC backend support"		off \
 		PKINIT	"Enable PK-INIT support"			on \
_______________________________________________
svn-ports-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-ports-all
To unsubscribe, send any mail to "svn-ports-all-unsubscribe@freebsd.org"
Comment 7 Niclas Zeising freebsd_committer freebsd_triage 2012-09-26 13:46:53 UTC
State Changed
From-To: feedback->closed

Committed. Thanks!