Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 387225

Summary: net-im/ejabberd should quit before dev-db/postgresql-server
Product: Gentoo Linux Reporter: Stefan de Konink <stefan>
Component: Current packagesAssignee: Gentoo Net-im project <net-im>
Status: RESOLVED WORKSFORME    
Severity: enhancement CC: bug
Priority: Normal    
Version: unspecified   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---

Description Stefan de Konink 2011-10-15 18:15:00 UTC
Ejabberd could depend on modules such as pgsql, mysql or odbc. It is therefore better if ejabberd would shutdown before -a database- does.

Reproducible: Always
Comment 1 Marcin Mirosław 2011-10-17 07:43:56 UTC
Ejabberd doesn't contains any postgres/mysql flag only has "odbc". Imho valid solution is add "rc_need=postgresql" to /etc/conf.d/ejabberd if your ejabberd uses postgresql. It's rather nothing to do in ebuild.
Comment 2 Stefan de Konink 2011-10-17 08:13:58 UTC
Maybe I should implement the 'native' pgsql and mysql modules eJabberd can use. It actually uses the odbc interface to configure them. But given the odbc flag, shouldn't this rc_need be there anyway?
Comment 3 Marcin Mirosław 2011-10-17 08:30:42 UTC
With odbc you can connect for many databases or databases which are remote. Even if ejabberd will have native foosql driver it will only needs proper libraries to link against them. We can have database on other host, portage doesn't know about local configuration. It's sysadmin role to prepare start dependencies correctly.
If ejabberd could use only one database - foobarsql and it such database would be required by ejjaberd to work then yes, in default conf.d file it should be "rc_need=foobarsql".
Comment 4 Peter Volkov (RETIRED) gentoo-dev 2011-10-18 14:08:36 UTC
Yes, it's impossible to provide all db backends in init script, thus it's better to use provided my Marcin configuration suggestion.