Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1ew8Zf-0007nh-Eu for pgsql-general@arkaria.postgresql.org; Wed, 14 Mar 2018 15:44:19 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1ew8Ze-0003gT-CK for pgsql-general@arkaria.postgresql.org; Wed, 14 Mar 2018 15:44:18 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1ew8Zd-0003gJ-Ue for pgsql-general@lists.postgresql.org; Wed, 14 Mar 2018 15:44:18 +0000 Received: from out1-smtp.messagingengine.com ([66.111.4.25]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1ew8Za-00084I-9q for pgsql-general@postgresql.org; Wed, 14 Mar 2018 15:44:17 +0000 Received: from compute6.internal (compute6.nyi.internal [10.202.2.46]) by mailout.nyi.internal (Postfix) with ESMTP id 1D61820C77; Wed, 14 Mar 2018 11:44:13 -0400 (EDT) Received: from frontend2 ([10.202.2.161]) by compute6.internal (MEProxy); Wed, 14 Mar 2018 11:44:13 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=aklaver.com; h= content-transfer-encoding:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-me-sender :x-me-sender:x-sasl-enc; s=fm2; bh=a2e0X/tQnUp3QXU6Vf0pcFUs4S0dI ygM3VRuN1hl0uY=; b=K7UfPvZKIWkHgB5M2yl/EjU2DAG17tejtGB1KfYaY98pz DVZ2iLFp42kyR0nhWysNjnM7zIgeTBvVWQe/8wDZUjKQ0KUDkWFZFUuM+BD1XjBi vsq7xmB5LtU9u8w6rAk+gbnWM6eczuVltziPmasD7zO3yutSjmlhfgFDSe+eX8RX 7rSC9VnM+kWI/EfnVOe76pbyw3dziLQUTEJOEGtH1903L40gbfjg+sklL64ycg/K NGq2Fe2s0vzF3Yj4nga/r+nKJnPhlY59Z5qxxRj5a0xBYu2aVLG0iOCLwnRo18j6 F2Al2wl+jU9nzaYQRpmDu6n0eyUvhG0GQD+7mEVuA== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-me-sender:x-me-sender:x-sasl-enc; s=fm2; bh=a2e0X/ tQnUp3QXU6Vf0pcFUs4S0dIygM3VRuN1hl0uY=; b=UFOdtyaE1euYKnf509Rt7b v46ZUVGsMg5ofcswj+l37mWj0w+W8A4sguVRilsprlTajNxIPZ9S2kGZOJ72DizQ WN1Km8/PVY6xokFdWuvmEqSpUL8xGBguTM2/QXGfrM//SKt9Ezj/mOJmMD3bPQdZ 05lBZspfSYl9mJp4Enl6HrweFdXv1MEWBZxDPUGwRnZwfZmuMA7h9GpR8uYyJkzi cTbsb+RSnqLn3+FurdaLKVwoPBRQgcJEcvoL5tJkZCIpkNAt6VgDyHjAy4FZ2hnj Vj3uF4pbH3D30lkIvdiZrTaniNH6K9OvCnNG4qVgx6PL0+mK8/lZw2BpML0fz2tg == X-ME-Sender: Received: from [192.168.1.2] (71-35-123-124.tukw.qwest.net [71.35.123.124]) by mail.messagingengine.com (Postfix) with ESMTPA id 364A724241; Wed, 14 Mar 2018 11:44:12 -0400 (EDT) Subject: Re: JDBC connectivity issue To: chris , Postgres General References: <0e087d67-6403-d0c8-c61e-68c674f992f1@pgsqlrocket.com> <1ba83003-3c02-dafe-1056-4e05d791fbc6@pgsqlrocket.com> <0b51cb72-bb1d-dfab-3a35-24c1f0f80b7e@aklaver.com> <09e943bd-47a5-1413-73a0-78cae26a0636@pgsqlrocket.com> From: Adrian Klaver Message-ID: Date: Wed, 14 Mar 2018 08:44:11 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.6.0 MIME-Version: 1.0 In-Reply-To: <09e943bd-47a5-1413-73a0-78cae26a0636@pgsqlrocket.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk On 03/14/2018 07:51 AM, chris wrote: > > I believe its Postgresql-9.4.1208.jre7.jar Pretty sure solving this is going to require knowing exactly what driver is in use. The failover syntax looks to be fairly recent, so being off by a little on the driver version can make a big difference. Or you could do as this post suggests: https://www.postgresql.org/message-id/CADK3HHJgdio_TZ-fpk4rguWaA-wWZFNZrjBft_T4jLBK_E_c8w%40mail.gmail.com That is install driver version 42.2.1. > On 03/13/2018 05:48 PM, Adrian Klaver wrote: >> On 03/13/2018 04:46 PM, chris wrote: >>> I'm sorry that took a few days but I am running; >>> >>> >>> Postgresql-9.4 >>> >>> and >>> >>> jre7.jar >> >> What we are looking for is the JDBC driver you are using? >> >>> >>> Thanks in advance. >>> >>> >>> On 03/08/2018 02:30 PM, chris wrote: >>>> Given that the syntax looks correct for the url, how would we go >>>> about debugging that it's not seeing the comma? >>>> >>>> >>>> On 03/08/2018 02:27 PM, Adrian Klaver wrote: >>>>> On 03/08/2018 01:12 PM, chris wrote: >>>>>> Hi, >>>>>> >>>>>> I have a JDBC temping to connect to 2 postgres nodes in a hot >>>>>> standby configuration. Running postgres 9.4 on centos6. >>>>>> >>>>>> What we are trying to accomplish is in an event of a failover, to >>>>>> first try to connect to the master. If that fails to then reach >>>>>> out to the standby. >>>>>> >>>>>> I looked online and found the suggested way to do this, but it's >>>>>> not working. >>>>>> >>>>>> This is the JDBC line we have: >>>>>> >>>>>> /jdbc.url=jdbc:postgresql://10.16.10.12:5432,10.16.10.13:5432/app_db/ >>>>>> >>>>>> Here is the error we are getting:/ >>>>>> / >>>>>> >>>>>> /2018-03-07 13:54:36, 994 ERROR:com.zaxxer.hikari.util.PropertyElf >>>>>> - failed to set properly port number on target class >>>>>> org.postgresql.ds.PGSimpleDataSource >>>>>> java.langNumberFormatException:for input string: >>>>>> "5432,10.16.10.13:5432"/ >>>>> >>>>> Lets try that again: >>>>> >>>>> To me it looks like whatever code you are using is trying to use >>>>> "5432,10.16.10.13:5432" as the port number for 10.16.10.12. In >>>>> other words it is not seeing the ',' as a separator for the two IP's'. >>>>> >>>>> Time to clean the glasses:) >>>>> >>>>>> >>>>>> It looks like the first IP address has disappeared or is not set >>>>>> right./ >>>>>> / >>>>>> >>>>>> Thanks in advance for the help. >>>>>> >>>>>> >>>>>> // >>>>>> >>>>>> >>>>> >>>>> >>>> >>> >>> >> >> > > -- Adrian Klaver adrian.klaver@aklaver.com