Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-4059690

Can not load more than 6 RMI servers on same machine (Win '95)

    XMLWordPrintable

    Details

    • Subcomponent:
    • CPU:
      x86
    • OS:
      windows_95

      Description

      I am using JDK 1.1.2 to develop client/server games.
      I use the RMI in JDK1.1.2, I have 12 game servers ready.
      All the servers can be load into the memory one after the other.
      But, when I try to port the servers code to another machine,
      It show me error message after I load 6 of the servers.
      If I close one of the servers, then the other one can be loaded.
      Otherwise, the total servers can be load into memory is 6 ?



      1.Code:
      I use the sample in Stock in JDK1.1 as my template.
      All the servers use the same code module as following.
      Following is the main() of my server module.

          public static void main(String args[])
          {
              String ServerName = "//:2005/Server1";

              System.setSecurityManager(new RMISecurityManager());
              try {
                  LocateRegistry.createRegistry(2005);
                  Company companyServer = new Company();
                  Naming.rebind(ServerName, companyServer);
              } catch (Exception e) {
                  System.out.println("Main: an exception occurred: " +
                                     e.getMessage());
                  e.printStackTrace();
              }
          }

      2.I used javac and rmic to compile the code, everything works fine.
        Then I use "start java Company" to load the server into memory.
        One after the other.
        P.S. Company is the name of the server.

      3.Load servers
      So all the 12 servers (it will be more in the future) will be loaded
      into memory as following
      Port Number ServerName
      2005 Server1
      2010 Server2
      2012 Server3
      2014 Server4
      ...

      4.Error
      Everything works fine on my development machine which contain all
      kinds of software. And both of them works well with only one
      server module loaded in memory.
      Error occurred when I try to port the servers to another machine.
      It occurred when I loaded the 7th server into memory.
      createRegistry() works fine.

      It stop at Naming.rebind(ServerName, companyServer)

      Error log:
      ***************************************************
      Creating registry
      Creating Company
      Binding server...
      Company main: an exception occurred: Server RemoteException; nested
      exception is:
      java.rmi.ConnectIOException: Error creating connection to:
      [liwha:1046]; nested exception is:
      java.net.SocketException: connect
      java.rmi.ServerException: Server RemoteException; nested exception is:
              java.rmi.ConnectIOException: Error creating connection to:
      [liwha:1046]; nested exception is:
              java.net.SocketException: connect
      ****************************************************
      P.S. [liwah] is the name of my new host computer.


      5.System Hardware
      Pentium 200 MHz, 32M RAM, NE2000 netword card, 12 speed CD-ROM
      In case of hardward causing the problem.
      I try to bring the hard drive of new server-host to my old
      development machine. It still show the same error message.
      So It may not relate to the system hardware.

      6.System OS
      The network I have is a Win95 peer-to-peer intranet LAN.
      Without NT server or others (NO DNS server either).
      All the client machine use TCP/IP (with specific IP address)
      and this peer-to-peer intranet LAN to communicate with this
      server-host machine.
      The web server I use is Borland Web Server to serve as the
      HTTP server.

      ------------------- Win95 Network setup -------------------
      Client for Microsoft Networks
      Dial NetWork
      NE 2000 (network card)
      TCP/IP (IP address: 199.10.20.77, subMask 255.255.255.0
      without any DNS server or gate server)
      File and Printer sharing for Microsoft Network
      -------------------------------------------------------------

      7.Question ?

        Are there some tricks about loading multiple servers into the
        machine ? Is there any other ways to load server into memory?
        Except using "start java Server" under DOS.
        Can I use other ways to load the server into memory ?
        Is this causing the problem ?
        Why does this machine can only load six servers only?


      Attached file JavaTest.exe
      (see /net/tygoo.east/opt1/jbenoit/test/2926498)
      contains the 12 subdirectories and the corresponding Company.java
      and batch file Run.bat which is used to compile and execute the server.

        Attachments

          Activity

            People

            Assignee:
            duke J. Duke (Inactive)
            Reporter:
            jbenoit Jonathan Benoit (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: