From mboxrd@z Thu Jan 1 00:00:00 1970 From: Danny Milosavljevic Subject: bug#23064: herd has incomplete status reporting, not so helpful Date: Sat, 19 Mar 2016 16:13:37 +0100 Message-ID: <20160319161337.609ada55@scratchpost.org> Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:37833) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ahIZq-0004wa-6F for bug-guix@gnu.org; Sat, 19 Mar 2016 11:14:07 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ahIZm-0005Yv-QY for bug-guix@gnu.org; Sat, 19 Mar 2016 11:14:06 -0400 Received: from debbugs.gnu.org ([208.118.235.43]:56690) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ahIZm-0005Yr-Na for bug-guix@gnu.org; Sat, 19 Mar 2016 11:14:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1ahIZm-0005ze-K2 for bug-guix@gnu.org; Sat, 19 Mar 2016 11:14:02 -0400 Sender: "Debbugs-submit" Resent-Message-ID: Received: from eggs.gnu.org ([2001:4830:134:3::10]:37757) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ahIZU-0004jx-Jb for bug-guix@gnu.org; Sat, 19 Mar 2016 11:13:45 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ahIZR-0005VO-AQ for bug-guix@gnu.org; Sat, 19 Mar 2016 11:13:44 -0400 Received: from dd1012.kasserver.com ([85.13.128.8]:37648) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ahIZR-0005VH-3c for bug-guix@gnu.org; Sat, 19 Mar 2016 11:13:41 -0400 Received: from localhost (91.141.2.247.wireless.dyn.drei.com [91.141.2.247]) by dd1012.kasserver.com (Postfix) with ESMTPSA id 1077D1CA0551 for ; Sat, 19 Mar 2016 16:13:39 +0100 (CET) List-Id: Bug reports for GNU Guix List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-guix-bounces+gcggb-bug-guix=m.gmane.org@gnu.org Sender: bug-guix-bounces+gcggb-bug-guix=m.gmane.org@gnu.org To: 23064@debbugs.gnu.org So there was a postgresql update where the data format was incompatible. That happens regularily and is ... acceptable, I guess (even more acceptable in guix because I can easily switch back to the old release). However, in order to find that out, I had to: $ psql ... something about a socket not being reachable $ sudo herd status postgres Status of postgres: It is started. Running value is 18438. It is enabled. Provides (postgres). Requires (user-processes loopback). Conflicts with (). Will be respawned. So it claimed that everything was just peachy. $ sudo herd stop postgres $ sudo herd start postgres ... which reported nothing out of the ordinary either. $ ps -ef |grep postgres [xxxx] Aha! finally an indication that something is amiss. So I tried to find the log entries, to no avail so far. (I found: /gnu/store/b073csgl56g2wnq7azj4wrswb6azsvc0-postgresql-9.5.1/bin/pg_ctl -D /var/lib/postgresql/data -l logfile start, not sure how that helps) $ man pg_ctl No manual entry for pg_ctl In the mean time, I decided I can just start up the postgres server process manually and it will tell me. $ postgres --config-file=/etc/postgresql.conf -D /var/lib/postgresql/data FATAL: data directory "/var/lib/postgresql/data" has wrong ownership HINT: The server must be started by the user that owns the data directory. $ sudo -i # su - postgres Password: errr... what password? # passwd postgres ... # su - postgres Password: su: Authentication failure # passwd -u postgres # su - postgres Password: This account is currently not available. Hmmm... $ sudo -u postgres postgres --config-file=/etc/postgresql.conf -D /var/lib/postgresql/data FATAL: database files are incompatible with server DETAIL: The data directory was initialized by PostgreSQL version 9.3, which is not compatible with this version 9.5.1. $ Aha! It says so right there in the standard output (or error?). Where did that message go in the shepherd case? $ cd /var/log $ grep -r incompatible . $ ??? Anyway, it works again now but we shouldn't have to do this kind of digging.