Search Postgresql Archives

Re: EnterpriseDB installed PostgreSQL 9.6 vs. REPMGR. Round 4 - compilation issues on RHEL 7.2

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 18/05/2017 15:20, Adrian Klaver wrote:

If I remove that link then I can compile. Have no idea why.


Hi! OP here, and here's the feedback on what I'm getting after unlinking as suggested yesterday:

I tried removing/unlinking as suggested and, just like Adrian, it worked OK for me! :)

The advice was:

 Whoever does it needs to unlink:

 /lib64/libldap_r-2.4.so.2


So that's what I did.

Output of ls -l command:
lrwxrwxrwx 1 root root 23 May 11 12:42 /lib64/libldap_r-2.4.so.2 -> libldap_r-2.4.so.2.10.3

Unlink the file:
$ sudo unlink /lib64/libldap_r-2.4.so.2

Verify gone:
$ ls -l /lib64/libldap_r-2.4.so.2
ls: cannot access /lib64/libldap_r-2.4.so.2: No such file or directory

Attempt build again:

$ PATH=/db_demo/app/postgres/9.6.2-3/bin:$PATH make USE_PGXS=1 clean all

No errors this time! It worked, except for the following warning we've seen before:

/bin/ld: warning: libssl.so.1.0.0, needed by /db_demo/app/postgres/9.6.2-3/lib/libpq.so, may conflict with libssl.so.10

Moving onto the install (didn't need sudo, as the userid I'm using is the owner of the PostgreSQL software):

$ PATH=/db_demo/app/postgres/9.6.2-3/bin:$PATH make USE_PGXS=1 install

make -C sql
make[1]: Entering directory `/home/pginst/repmgr-3.3.1/sql'
make[1]: Nothing to be done for `all'.
make[1]: Leaving directory `/home/pginst/repmgr-3.3.1/sql'
/bin/mkdir -p '/db_demo/app/postgres/9.6.2-3/share/postgresql/contrib'
mkdir -p '/db_demo/app/postgres/9.6.2-3/bin'
/usr/bin/install -c  repmgrd '/db_demo/app/postgres/9.6.2-3/bin/'
/usr/bin/install -c  repmgr '/db_demo/app/postgres/9.6.2-3/bin/'
make -C sql install
make[1]: Entering directory `/home/pginst/repmgr-3.3.1/sql'
/bin/mkdir -p '/db_demo/app/postgres/9.6.2-3/lib/postgresql'
/bin/mkdir -p '/db_demo/app/postgres/9.6.2-3/share/postgresql/contrib'
/usr/bin/install -c -m 755 repmgr_funcs.so '/db_demo/app/postgres/9.6.2-3/lib/postgresql/repmgr_funcs.so' /usr/bin/install -c -m 644 .//uninstall_repmgr_funcs.sql repmgr_funcs.sql '/db_demo/app/postgres/9.6.2-3/share/postgresql/contrib/'
make[1]: Leaving directory `/home/pginst/repmgr-3.3.1/sql'
/usr/bin/install -c -m 644 .//repmgr.sql .//uninstall_repmgr.sql '/db_demo/app/postgres/9.6.2-3/share/postgresql/contrib/'

Seems to have worked OK! I went looking within the postgresql tree to see if it had built anything:
$ find . -name *repmgr* -print

./lib/postgresql/repmgr_funcs.so
./share/contrib/repmgr.sql
./share/contrib/repmgr_funcs.sql
./share/contrib/uninstall_repmgr_func.sql
./share/contrib/uninstall_repmgr.sql
./share/contrib/uninstall_repmgr_funcs.sql
./share/postgresql/contrib/repmgr.sql
./share/postgresql/contrib/repmgr_funcs.sql
./share/postgresql/contrib/uninstall_repmgr.sql
./share/postgresql/contrib/uninstall_repmgr_funcs.sql
./bin/repmgr
./bin/repmgrd

Success!

I then relinked the library:

$ sudo ln -s /lib64/libldap_r-2.4.so.2.10.3 /lib64/libldap_r-2.4.so.2

$ ls -l the file to see if it's back:
lrwxrwxrwx 1 root root 30 May 18 15:51 /lib64/libldap_r-2.4.so.2 -> /lib64/libldap_r-2.4.so.2.10.3

Try executing the command from the database owner id:

$ repmgr -V

repmgr 3.3.1 (PostgreSQL 9.6.2)

Didn't barf, so hopefully relinking the file makes no difference to the already compiled repmgr :)

Bit of a mystery still on that linking/unlinking (if we can find a way to avoid doing that, that would be great) but success!

Now I get to start playing with it properly - but I'm relatively confident that should be OK, I was getting good results on my little ubuntu box at home ...

Of course, I said the same think about compiling it :)

Huge thanks to EVERYONE who helped on this! If anyone is going to be at PG Day UK, I'll buy you a drink :)

Regards,

Martin.
--
Martin Goodson

"Have you thought up some clever plan, Doctor?"
"Yes, Jamie, I believe I have."
"What're you going to do?"
"Bung a rock at it."


--
Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]

  Powered by Linux