From: Danny Milosavljevic <dannym@scratchpost.org>
To: "Ludovic Courtès" <ludo@gnu.org>
Cc: 22619@debbugs.gnu.org
Subject: bug#22619: postgresql-service error checking wtf
Date: Fri, 12 Feb 2016 20:48:58 +0100 [thread overview]
Message-ID: <20160212204858.56275e93@scratchpost.org> (raw)
In-Reply-To: <8760xu10e3.fsf@gnu.org>
Hi,
I've found out some more details. The message
> > initdb: directory "/var/lib/postgresql/data" exists but is not empty
> > If you want to create a new database system, either remove or empty
> > the directory "/var/lib/postgresql/data" or run initdb
> > with an argument other than "/var/lib/postgresql/data".
is not an error for the entire service. It's initdb refusing to clobber the existing database (which has been created by the postgresql-service instance with no #:config-file argument) and helpful in preventing data loss.
The actual problem only arises because guix reconfigure doesn't deem a change in service arguments as reason to restart (or reconfigure) a service.
I.e. before, my config was:
(postgresql-service )
Then I did guix reconfigure ...
Afterwards, I changed the config to:
(postgresql-service #:config-file ...)
Then I did giux reconfigure # this erroneously doesn't reload the postgres service!!
> > and the error message still references the default config file.
>
> I don’t see any references to a config file in what you pasted.
In the postgres-service definition in guix/gnu/services/databases.scm , there's a %default-postgres-config . That's what I meant.
At all times, the default config file was printed in the log - which was because the postgres service never actually was reconfigured.
>I’ve tested ‘postgresql-service’ in a pristine system with ‘guix system vm’ and it starts without any such message. So I guess there’s stale data in /var/lib/postgresql/data on your system?
It was left over from the first unsuccessful launch because bug# 22618 hadn't been fixed at the time.
Thanks,
Danny
next prev parent reply other threads:[~2016-02-12 19:50 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20160210200143.4a9f95c2@scratchpost.org>
2016-02-10 23:12 ` bug#22619: postgresql-service error checking wtf Glenn Morris
2016-02-12 14:14 ` Ludovic Courtès
2016-02-12 14:14 ` Ludovic Courtès
2016-02-12 19:48 ` Danny Milosavljevic [this message]
2016-02-21 11:38 ` Ludovic Courtès
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20160212204858.56275e93@scratchpost.org \
--to=dannym@scratchpost.org \
--cc=22619@debbugs.gnu.org \
--cc=ludo@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/guix.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.