Uploaded image for project: 'Geode'
  1. Geode
  2. GEODE-2364

gfsh cannot connect to a remote locator

    XMLWordPrintableJSON

Details

    Description

      Environment
      locator running on Ubuntu 64-bit (192.168.1.45)
      server running on OSX (192.168.1.187)

      Steps to Reproduce
      1. Start locator on ubuntu:

      gfsh start locator --name=locator1 --bind-address=192.168.1.45

      2. Start server on Mac:

      gfsh start server --name=server1 --locators=192.168.1.45[10334]

      3. Start gfsh on Mac and try to connect to the locator:

      > gfsh
      gfsh> connect --locator=192.168.1.45[10334]

      Validate

      gfsh>list members
        Name   | Id
      -------- | -------------------------------------------------
      server1  | 192.168.1.187(server1:4242)<v1>:1024
      locator1 | 192.168.1.45(locator1:12646:locator)<ec><v0>:1024
      

      Result

      gfsh>connect --locator=192.168.1.45[10334]
      Connecting to Locator at [host=192.168.1.45, port=10334] ..
      Connecting to Manager at [host=192.168.1.45, port=1099] ..
      Could not connect to : [host=192.168.1.45, port=1099]. Connection refused to host: 127.0.1.1; nested exception is: 
          java.net.ConnectException: Operation timed out
      
      Input/output error
      Exiting... 
      Exception in thread "main" java.lang.NullPointerException
      	at org.apache.geode.management.internal.cli.Launcher.parseOptions(Launcher.java:252)
      	at org.apache.geode.management.internal.cli.Launcher.parseCommandLine(Launcher.java:260)
      	at org.apache.geode.management.internal.cli.Launcher.main(Launcher.java:107)
      Could not connect to : [host=192.168.1.45, port=1099]. Connection refused to host: 127.0.1.1; nested exception is: 
          java.net.ConnectException: Operation timed out
      

      Work Around
      Start the locator up with additional flags to return the correct address of the JMX server.

      gfsh start locator --name=locator1 --bind-address=192.168.1.45 --J=-Dgemfire.jmx-manager-hostname-for-clients=192.168.1.45
      

      The error should be more informative, guiding the user to these parameters that need to be specified on startup of the locator. Or the locator should bind to the JMX port, honoring the --bind-address flag.

      Attachments

        Activity

          People

            Unassigned Unassigned
            kduling Kevin Duling
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated: