Thread: [HACKERS] Trouble with amcheck
I just cloned PostgreSQL to a new machine today (Ubuntu 17.04). "make install" and "make check-world" run fine but "make installcheck-world" is having trouble with amcheck:
In contrib/amcheck/results:
CREATE EXTENSION amcheck;
ERROR: could not open extension control file "/home/doole/pgCommunity/install/share/postgresql/extension/amcheck.control": No such file or directory
I expect I'm missing something in the machine set up, but I'm stumped as to what.
Any suggestions?
Thanks
- Doug
On Thu, Sep 14, 2017 at 5:03 PM, Douglas Doole <dougdoole@gmail.com> wrote: > I just cloned PostgreSQL to a new machine today (Ubuntu 17.04). "make > install" and "make check-world" run fine but "make installcheck-world" is > having trouble with amcheck: > > In contrib/amcheck/results: > > CREATE EXTENSION amcheck; > ERROR: could not open extension control file > "/home/doole/pgCommunity/install/share/postgresql/extension/amcheck.control": > No such file or directory > > I expect I'm missing something in the machine set up, but I'm stumped as to > what. I think you need to build and install contrib, so that it is available to the server that you're running an installcheck against. amcheck is alphabetically first among contrib modules that have tests, IIRC. -- Peter Geoghegan -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers
Peter, Douglas, * Peter Geoghegan (pg@bowt.ie) wrote: > On Thu, Sep 14, 2017 at 5:03 PM, Douglas Doole <dougdoole@gmail.com> wrote: > > I just cloned PostgreSQL to a new machine today (Ubuntu 17.04). "make > > install" and "make check-world" run fine but "make installcheck-world" is > > having trouble with amcheck: > > > > In contrib/amcheck/results: > > > > CREATE EXTENSION amcheck; > > ERROR: could not open extension control file > > "/home/doole/pgCommunity/install/share/postgresql/extension/amcheck.control": > > No such file or directory > > > > I expect I'm missing something in the machine set up, but I'm stumped as to > > what. > > I think you need to build and install contrib, so that it is available > to the server that you're running an installcheck against. amcheck is > alphabetically first among contrib modules that have tests, IIRC. Yes, I was working with someone earlier today who ran into exactly the same issue. If you don't 'make world' or make the individual contrib modules, then 'make installcheck-world' isn't going to work. I do think it'd be nice if we could provide a better error message in such a case.. Thanks! Stephen
On Fri, Sep 15, 2017 at 10:31 AM, Stephen Frost <sfrost@snowman.net> wrote: > Yes, I was working with someone earlier today who ran into exactly the > same issue. If you don't 'make world' or make the individual contrib > modules, then 'make installcheck-world' isn't going to work. Or should installcheck-world imply world? It is easy for newcomers or even advanced hackers to fall into this trap from time to time. -- Michael -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers
Thanks all. Making and installing the contribs got me rolling again. (I tried "make world" but ran into trouble with the XML docs. But that's pain and suffering for another day.)
I'd agree that "make installcheck-world" should imply that all prereqs are met - that's certainsly the normal behaviour for make.
- Doug
On 2017-09-15 02:22:49 +0000, Douglas Doole wrote: > Thanks all. Making and installing the contribs got me rolling again. (I > tried "make world" but ran into trouble with the XML docs. But that's pain > and suffering for another day.) > > I'd agree that "make installcheck-world" should imply that all prereqs are > met - that's certainsly the normal behaviour for make. I'm very unconvinced by this, given that one use of installcheck is to run against an existing server. For which one might not even have access to the relevant directories to install extensions into. Regards, Andres Freund -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers
Andres, * Andres Freund (andres@anarazel.de) wrote: > On 2017-09-15 02:22:49 +0000, Douglas Doole wrote: > > Thanks all. Making and installing the contribs got me rolling again. (I > > tried "make world" but ran into trouble with the XML docs. But that's pain > > and suffering for another day.) > > > > I'd agree that "make installcheck-world" should imply that all prereqs are > > met - that's certainsly the normal behaviour for make. > > I'm very unconvinced by this, given that one use of installcheck is to > run against an existing server. For which one might not even have access > to the relevant directories to install extensions into. Sure, but if the extensions aren't in place and you're trying to run make installcheck-world, it's not like it's somehow going to succeed. Failing earlier on the install seems like a reasonable thing to do rather than failing later halfway through the check process. Now, that said, perhaps a bit more smarts would be in order here to, instead, check that the extensions are available before trying to run the checks for them. I'm thinking about something like this: check if the extension is available and, if not, skip the check of that module, with a warning or notification that it was skipped because it wasn't available. Thanks! Stephen
On 2017-09-14 22:36:38 -0400, Stephen Frost wrote: > Andres, > > * Andres Freund (andres@anarazel.de) wrote: > > On 2017-09-15 02:22:49 +0000, Douglas Doole wrote: > > > Thanks all. Making and installing the contribs got me rolling again. (I > > > tried "make world" but ran into trouble with the XML docs. But that's pain > > > and suffering for another day.) > > > > > > I'd agree that "make installcheck-world" should imply that all prereqs are > > > met - that's certainsly the normal behaviour for make. > > > > I'm very unconvinced by this, given that one use of installcheck is to > > run against an existing server. For which one might not even have access > > to the relevant directories to install extensions into. > > Sure, but if the extensions aren't in place and you're trying to run > make installcheck-world, it's not like it's somehow going to succeed. > > Failing earlier on the install seems like a reasonable thing to do > rather than failing later halfway through the check process. But, uh, aren't you now provoking errors because of non-existing rights to install stuff on the system? I'm all for improving error messages and/or adding extra checks, but this doesn't seem to be a solution. > Now, that said, perhaps a bit more smarts would be in order here to, > instead, check that the extensions are available before trying to run > the checks for them. I'm thinking about something like this: check if > the extension is available and, if not, skip the check of that module, > with a warning or notification that it was skipped because it wasn't > available. I think that'd just lead to people not noticing that they're not executing all tests. I'm ok with adding a hard error with a better message or such tho. Greetings, Andres Freund -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers
Stephen Frost <sfrost@snowman.net> writes: > * Andres Freund (andres@anarazel.de) wrote: >> I'm very unconvinced by this, given that one use of installcheck is to >> run against an existing server. For which one might not even have access >> to the relevant directories to install extensions into. > Sure, but if the extensions aren't in place and you're trying to run > make installcheck-world, it's not like it's somehow going to succeed. I'm more or less with Andres: this is just pilot error. If you didn't do install-world you shouldn't expect installcheck-world to succeed. > Now, that said, perhaps a bit more smarts would be in order here to, > instead, check that the extensions are available before trying to run > the checks for them. I'm thinking about something like this: check if > the extension is available and, if not, skip the check of that module, > with a warning or notification that it was skipped because it wasn't > available. Meh. I'm worried that that would have undesirable failure modes, ie letting something pass when it should have failed. Maybe we need some documentation improvements, though, to clarify the relationships between these make targets. regards, tom lane -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers