Connection refused

If the Adaptive Server max network packet size configuration parameter is set to 512 (the default), clients connections to OpenSwitch fail and the client receives this error message:

The packet size (2048) specified at login time is illegal. Legal values are between 512 and 512.

To correct this problem you can set the Adaptive Server max network packet size to 2048, or you can set the OpenSwitch MAX_PACKETSIZE to 512.

StepsSetting Adaptive Server max network packet size to 2048

  1. Set the SYBASE environment variable at a command prompt:

    • UNIX – in $SYBASE enter:

      SYBASE.csh
      
    • Windows – in %SYBASE% enter:

      SYBASE.bat
      
  2. Use isql to log in to the Adaptive Server as an administrator:

    isql -Usa -P -S Adaptive_Server_server_name
    
  3. Execute:

    sp_configure 'max network packet size', 2048
    go
    
  4. Restart the Adaptive Server.

  5. Restart OpenSwitch to establish the client connection.

StepsSetting OpenSwitch MAX_PACKETSIZE to 512

MAX_PACKETSIZE refers to the maximum size of the TDS packet. This option is used to tune the data throughput across the network and can significantly improve performance when larger packet sizes are used.

  1. Shut down the OpenSwitch server:

    1. Set the SYBASE environment variable at a command prompt:

      • On UNIX – in $SYBASE enter:

        SYBASE.csh
        
      • On Windows – in %SYBASE% enter:

        SYBASE.bat
        
    2. Use isql to log in to OpenSwitch as an administrator:

      isql -UAdministrator_UserName 
           -PAdministrator_Password 
           -SOpenSwitch_ServerName
      
      
    3. Execute:

      rp_shutdown
      go
      
  2. Use a text editor to modify the OpenSwitch configuration file OpenSwitch_ServerName.cfg, which is located in %OPENSWITCH%\config on Windows and in $OPENSWITCH/config on UNIX.

    Change the MAX_PACKETSIZE value from 2048 (the default) to 512. For example:

    MAX_PACKETSIZE=512
    
  3. Restart the OpenSwitch server.