5 Replies Latest reply on Nov 6, 2003 2:36 AM by frito

    RMI on fixed port(s)

    wil

      Hi,

      I'm using jboss 3.0.4 and I'm accessing (want to access) it through a firewall.
      What i really want is that RMI uses (a) fixed port(s), so that we can configure our firewall accordingly.

      It isn't clear to me which setting i have to edit:
      - */conf/standardjboss.xml or
      - */conf/jboss-service.xml or
      - */deploy/jmx-rmi-adaptor.sar/META-INF/jboss-service.xml (item: RMIObjectPort)
      or all of them ?!

      Please help, or point me to some usefull documents/articles (which for instance explain me when to use what).

      thank you,
      wil.

        • 1. Re: RMI on fixed port(s)
          wil

          anyone ?

          • 2. Re: RMI on fixed port(s)
            wil

            Or maybe everything directly over HTTP (JNDI and RMI). Some info, please.

            • 3. Re: RMI on fixed port(s)
              ioparra

              on 3.2.2, try using RmiBindAddress and RmiPort option.


              -Ivan

              • 4. Re: RMI on fixed port(s)
                wil

                > on 3.2.2, try using RmiBindAddress and RmiPort
                > option.
                >
                >
                > -Ivan
                Hi Ivan,
                Thanks.
                I've placed the RmiPort attribute in the jboss-service.xml. When i launch my jboss, the port i've chosen (11099) actually appears. At the moment i do a jndi-lookup from a client, a anonymous (server) socket is attached to it (until i close my initialContext in my client). This anonymous port is dynamically assigned. I guess this is made by de (default) RMIServerSocketFactory (which, i guess, create a serversocket with port 0).
                What i really want to do is also assign an fixed port for this RMIServerSocketFactory.
                (i guess you can also applie this JRMPInvoker-RMIObjectPort 4444).
                Do i need to write my own RMIServerSocketFactory ?
                Alternatives?
                TIA
                wil.

                • 5. Re: RMI on fixed port(s)
                  frito

                  You have to use RMI over SSL. There is an example with JBoss (see the test suite) how to do this.
                  Even you can search the forum. This has been discussed several times.

                  Greetings,
                  Frito