1 Reply Latest reply on Dec 19, 2016 11:01 AM by Patrick A Van Der Hyde

    Postgres is refusing connection -  Check that the hostname and port are correct and that the postmaster is accepting TCP/IP connections.

    pinki sharma

      Hi,

       

      I am facing some issue with tableau server. Its not getting up.

      I have checked firewall also. Firewall is off.  I am not able to resolve this issue.

      Please help me to resolve this issue. Please find below logs-

       

      Clustercontroller.log

       

      016-12-13 07:23:00.124 +0000 pool-206-thread-1   INFO  : com.tableausoftware.cluster.postgres.WorkerNode - Removing listener for node /postgres/SYDOXFAPP13:8060

      2016-12-13 07:23:17.155 +0000 pool-16-thread-1   WARN  : com.tableausoftware.cluster.postgres.SpawnPostgresRunner - Monitoring thread for the master instance didn't start. Trying failover...

      org.postgresql.util.PSQLException: Connection to SYDOXFAPP13:8060 refused. Check that the hostname and port are correct and that the postmaster is accepting TCP/IP connections.

        at org.postgresql.core.v3.ConnectionFactoryImpl.openConnectionImpl(ConnectionFactoryImpl.java:239)

        at org.postgresql.core.ConnectionFactory.openConnection(ConnectionFactory.java:66)

        at org.postgresql.jdbc4.Jdbc4Connection.<init>(Jdbc4Connection.java:24)

        at org.postgresql.Driver.makeConnection(Driver.java:414)

        at org.postgresql.Driver.connect(Driver.java:282)

        at java.sql.DriverManager.getConnection(DriverManager.java:664)

        at java.sql.DriverManager.getConnection(DriverManager.java:270)

        at com.tableausoftware.cluster.postgres.SpawnPostgresRunner$PostgresConnection.createConnection(SpawnPostgresRunner.java:512)

        at com.tableausoftware.cluster.postgres.SpawnPostgresRunner$PostgresConnection$1.call(SpawnPostgresRunner.java:531)

        at com.tableausoftware.cluster.postgres.SpawnPostgresRunner.startMaster(SpawnPostgresRunner.java:143)

        at com.tableausoftware.cluster.postgres.PostgresManager.startMaster(PostgresManager.java:444)

        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)

        at java.util.concurrent.FutureTask.run(FutureTask.java:266)

        at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:180)

        at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:293)

        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)

        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)

        at java.lang.Thread.run(Thread.java:745)

      Caused by: java.net.ConnectException: Connection refused: connect

        at java.net.DualStackPlainSocketImpl.connect0(Native Method)

        at java.net.DualStackPlainSocketImpl.socketConnect(DualStackPlainSocketImpl.java:79)

        at java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:350)

        at java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:206)

        at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:188)

        at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:172)

        at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392)

        at java.net.Socket.connect(Socket.java:589)

        at org.postgresql.core.PGStream.<init>(PGStream.java:61)

        at org.postgresql.core.v3.ConnectionFactoryImpl.openConnectionImpl(ConnectionFactoryImpl.java:121)

        ... 35 more

      2016-12-13 07:23:17.155 +0000 pool-16-thread-1   ERROR : com.tableausoftware.cluster.postgres.PostgresManager - Failed to change the state of this node to null

      java.lang.IllegalStateException: Cannot failover Postgres process when it is not running

        at com.tableausoftware.cluster.postgres.SpawnPostgresRunner.failover(SpawnPostgresRunner.java:317)

        at com.tableausoftware.cluster.postgres.SpawnPostgresRunner.startMaster(SpawnPostgresRunner.java:149)

        at com.tableausoftware.cluster.postgres.PostgresManager.startMaster(PostgresManager.java:444)

        at com.tableausoftware.cluster.postgres.PostgresManager.processMasterValue(PostgresManager.java:392)

        at com.tableausoftware.cluster.postgres.PostgresManager.processMasterValue(PostgresManager.java:367)

        at com.tableausoftware.cluster.postgres.PostgresManager.access$1000(PostgresManager.java:46)

        at com.tableausoftware.cluster.postgres.PostgresManager$RunProcessMasterValue.call(PostgresManager.java:686)

        at com.tableausoftware.cluster.postgres.PostgresManager$RunProcessMasterValue.nodeChanged(PostgresManager.java:697)

        at com.tableausoftware.cluster.postgres.PostgresManager.run(PostgresManager.java:258)

        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)

        at java.util.concurrent.FutureTask.run(FutureTask.java:266)

        at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:180)

        at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:293)

        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)

        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)

        at java.lang.Thread.run(Thread.java:745)

      2016-12-13 07:23:17.155 +0000 pool-16-thread-1   INFO  : com.tableausoftware.cluster.postgres.PostgresManager - PostgresManager restart

      2016-12-13 07:23:17.155 +0000 pool-16-thread-1   INFO  : com.tableausoftware.cluster.postgres.PostgresManager - PostgresManager cleanup

      2016-12-13 07:23:17.155 +0000 pool-16-thread-1   INFO  : com.tableausoftware.cluster.postgres.PostgresManager - PostgresManager stop

      2016-12-13 07:23:17.155 +0000 pool-16-thread-1   INFO  : com.tableausoftware.cluster.postgres.PostgresManager - Stop heartbeat task...

      2016-12-13 07:23:17.155 +0000 pool-16-thread-1   INFO  : com.tableausoftware.cluster.postgres.SpawnPostgresRunner - Stopping Postgres on SYDOXFAPP13:8060

      2016-12-13 07:23:17.155 +0000 pool-16-thread-1   INFO  : com.tableausoftware.cluster.postgres.PostgresManager - PostgresManager disconnect

      2016-12-13 07:23:17.155 +0000 Curator-PathChildrenCache-2   INFO  : com.tableausoftware.cluster.postgres.PostgresController - Postgres worker node disconnected: "SYDOXFAPP13:8060"

      2016-12-13 07:23:17.155 +0000 Curator-PathChildrenCache-2   ERROR : com.tableausoftware.cluster.postgres.PostgresController - Current Postgres master node "SYDOXFAPP13:8060" disconnected.

      2016-12-13 07:23:17.155 +0000 Curator-PathChildrenCache-2   FATAL : com.tableausoftware.cluster.postgres.PostgresController - No Postgre nodes available to failover to.

      2016-12-13 07:23:18.170 +0000 pool-16-thread-1   INFO  : com.tableausoftware.cluster.postgres.PostgresManager - Starting PostgresManager for worker node "SYDOXFAPP13"

      2016-12-13 07:23:22.792 +0000 pool-16-thread-1   INFO  : com.tableausoftware.cluster.postgres.PostgresManager - Creating worker node "SYDOXFAPP13" as "CONNECTED"

      2016-12-13 07:23:22.795 +0000 Curator-PathChildrenCache-2   INFO  : com.tableausoftware.cluster.postgres.PostgresController - Postgres worker node connected: "SYDOXFAPP13:8060". This is a new node: true

      2016-12-13 07:23:22.796 +0000 Curator-PathChildrenCache-2   INFO  : com.tableausoftware.cluster.postgres.PostgresController - All 1 nodes connected. Selecting master node...

      2016-12-13 07:23:22.796 +0000 Curator-PathChildrenCache-2   INFO  : com.tableausoftware.cluster.postgres.WorkerNode - Choosing the most up-to-date node...

      2016-12-13 07:23:22.797 +0000 Curator-PathChildrenCache-2   INFO  : com.tableausoftware.cluster.postgres.WorkerNode - Only one Postgres node is available

      2016-12-13 07:23:22.797 +0000 Curator-PathChildrenCache-2   INFO  : com.tableausoftware.cluster.postgres.PostgresController - Most up-to-date Postgres node is "SYDOXFAPP13:8060". Starting as master.

      2016-12-13 07:23:30.380 +0000 pool-8-thread-1   INFO  : com.tableausoftware.cluster.notification.QueuedEmailNotifier - Start to process notification queue

      2016-12-13 07:23:30.866 +0000 pool-34-thread-1   INFO  : com.tableausoftware.cluster.postgres.PostgresController - All Postgres worker nodes are UP

      2016-12-13 07:23:30.866 +0000 pool-34-thread-1   ERROR : com.tableausoftware.cluster.postgres.PostgresController - Selected master Postgres node SYDOXFAPP13:8060/CONNECTED didn't start

      2016-12-13 07:23:30.866 +0000 pool-34-thread-1   INFO  : com.tableausoftware.cluster.postgres.PostgresController - Triggering failover...

      2016-12-13 07:23:30.866 +0000 pool-34-thread-1   INFO  : com.tableausoftware.cluster.postgres.WorkerNode - Choosing the most up-to-date node...

      2016-12-13 07:23:30.866 +0000 pool-34-thread-1   INFO  : com.tableausoftware.cluster.postgres.WorkerNode - No available Postgres nodes

      2016-12-13 07:23:30.866 +0000 pool-34-thread-1   FATAL : com.tableausoftware.cluster.postgres.PostgresController - No Postgre nodes available to start as master.

      2016-12-13 07:23:30.866 +0000 pool-34-thread-1   FATAL : com.tableausoftware.cluster.postgres.PostgresController - No Postgre nodes available to failover to.

      2016-12-13 07:23:37.838 +0000 pool-16-thread-1   INFO  : com.tableausoftware.cluster.postgres.PostgresManager - Adding a listener for master node to be selected

      2016-12-13 07:24:22.801 +0000 pool-209-thread-1   INFO  : com.tableausoftware.cluster.postgres.WorkerNode - Scheduled listener removal executing

      2016-12-13 07:24:22.801 +0000 pool-209-thread-1   INFO  : com.tableausoftware.cluster.postgres.WorkerNode - Removing listener for node /postgres/SYDOXFAPP13:8060

      2016-12-13 07:24:30.381 +0000 pool-8-thread-1   INFO  : com.tableausoftware.cluster.notification.QueuedEmailNotifier - Start to process notification queue

      2016-12-13 07:25:30.388 +0000 pool-8-thread-1   INFO  : com.tableausoftware.cluster.notification.QueuedEmailNotifier - Start to process notification queue

       

       

      Thanks in advance ...:-)

       

      Regards,

      Pinki Sharma