glassfish
  1. glassfish
  2. GLASSFISH-20567

CLI report wrong server port, although I have changed the port in the domain.xml

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Minor Minor
    • Resolution: Works as designed
    • Affects Version/s: 4.0_b89_RC5
    • Fix Version/s: None
    • Component/s: command_line_interface
    • Labels:
      None
    • Environment:

      Windows 7 SP1
      Mac OS X 10.8

      Description

      Scenario:

      1- from command line type the following command or any wrong command as the following:

       
      asadmin> start
      

      2- You will get the following error:

       
      Remote server does not listen for requests on [localhost:4848]. Is the server up?
      Unable to get remote commands.
      Closest matching local command(s):
          restart-domain
          restart-local-instance
          start-database
          start-domain
          start-local-instance
      
      Command start failed.
      

      The port should be 4242 instead of 4848 as I have changed in the domain.xml as the following:

       
      <network-listeners>
         <network-listener port="2020" protocol="http-listener-1" transport="tcp" name="http-listener-1" thread-pool="http-thread-pool"></network-listener>
         <network-listener port="2121" protocol="http-listener-2" transport="tcp" name="http-listener-2" thread-pool="http-thread-pool"></network-listener>
         <network-listener port="4242" protocol="admin-listener" transport="tcp" name="admin-listener" thread-pool="admin-thread-pool"></network-listener>
      </network-listeners>
      

        Activity

        Hide
        Tom Mueller added a comment -

        The domain.xml file controls the port on which the server listens, not the port to which the asadmin client connects. To change the asadmin connect port, use the --port option.

        For example, in your case, do:

        $ asadmin --port 4242
        Use "exit" to exit and "help" for online help.
        asadmin> start
        Remote server does not listen for requests on [localhost:4242]. Is the server up?
        Unable to get remote commands.
        Closest matching local command(s):
        restart-domain
        restart-local-instance
        start-database
        start-domain
        start-local-instance

        Command start failed.

        Show
        Tom Mueller added a comment - The domain.xml file controls the port on which the server listens, not the port to which the asadmin client connects. To change the asadmin connect port, use the --port option. For example, in your case, do: $ asadmin --port 4242 Use "exit" to exit and "help" for online help. asadmin> start Remote server does not listen for requests on [localhost:4242] . Is the server up? Unable to get remote commands. Closest matching local command(s): restart-domain restart-local-instance start-database start-domain start-local-instance Command start failed.

          People

          • Assignee:
            Tom Mueller
            Reporter:
            Mohamed Taman
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: