Monday, September 19, 2016

Gateway


Gateway system communicates with other SAP and Non SAP system e.g. SAP:BW,CRM,SCM: Non SAP


Architecture of the SAP Gateway: 

Each instance of an SAP System has a gateway. The gateway enables communication between work processes and external programs, as well as communication between work processes from different instances or SAP Systems.

Gateway Processes:

The SAP Gateway is made up of various processes:

·        Gateway read process

·        Gateway monitor

These processes are described in the following topics.

Note :Earlier gateway releases that support DCAM and SNA have additional gateway work processes (gwwp, gwwp.exe).

Gateway Read Process:

Gateway read (gwrd, gwrd.exe) is the main process in the gateway system.

It is started by the application server (dispatcher) and checked by it periodically.

The gateway reader receives and processes all CPI-C requests.

Note:

If the executable gwrd program is called without parameters or with the switch -help, the program outputs a description of the possible command parameters, as well as all the patches

Gateway Monitor:

The gateway monitor (gwmon, gwmon.exe) is used to analyze and administer the SAP Gateway.

When you start it, you initially get a list of active CPI-C connections. You can call up all the other monitor functions via a menu.

You can monitor the gateway from the SAP System (transaction SMGW) or from the operating system. 


What would happen if your Gateway is not working?

1-     No RFC is working

2-     No connection with other sap system and non sap systems

3-     In dual stack case : No connection between ABAP instance and JAVA instance. Java instance will go down. But as per new scenarios Netweaver 7.10 Onwards JAVA instance and ABAP instance would be working independently and communicate through JCO rfc connection only. So there is no master slave concept between java instance and ABAP instance (My concept) .Why I have  called ABAP as master instance and Java as slave .Because ABAP start java instance and Java instance can be stopped independently. Without affect ABAP instance .But You can to run java instance without ABAP instance.


SMGW:

Displaying Clients Currently Logged On 

You can display a list of currently logged on systems via Goto ® Logged on systems .

The following values are displayed for each system that is logged on:

·        LU Name: With CPIC connections via TCP/IP, this field describes the host on which the partner program is running or supposed to run.


If we check in SM21 system log, we can find out that this particular connection was terminated by the administrator at that particular time stamp.

How to monitor SAP Gateway from the OS  level ?

Gateway can also be monitored at the os level (in particular if the gateway is running in a system without AS ABAP) using program gwmon (.exe) 

Note:

The term "logical unit" is a term borrowed from SNA and describes a logical node in an SNA network. The remote partner program is intended to run on this node.

·        TP Name: Name of the transaction program or the name of the program that was started by the gateway.

·        System Type The following values are possible:

·         ¡        NORMAL_CLIENT : Normal client (external program)

·         ¡        LOCAL_R3: Local SAP System

·         ¡        REMOTE_GATEWAY: connection to remote gateway

·         ¡        FROM_REMOTE_GATEWAY: connection from a remote gateway

·         ¡        REGISTER_TP: Registered transaction program

·        Host Name: Name of host client is running on

·        Host Address: All TCP/IP names on the host. If there are several network cards then there may be several entries here. Usually 5 alternative host names are supported.

·        Last Req: Time of last activity

·        Status: Connection status to a client or another gateway at TCP/IP level. The default value is CONNECTED.

In the following cases connections are highlighted in color in the gateway monitor.

·         ¡        Connections with status PENDING (handshake while opening the connection) are colored orange

·         ¡        If the data packets could not be fully written in the network connections, the connection is colored green. 
If this status lasts for a while, it indicates network problems, or the partner program cannot read any data from the network, because it is busy with other tasks that take time (for example, BRBACKUP).



ParameterDescriptionDefault Value
gw/accept_remote_trace_level
Specifies whether the trace level of a CPIC or RFC connection should be transferred.
(configuration parameter)
1
gw/accept_timeout
Maximum allowed time period for the login process of a server program.
(timeout parameter)
60 seconds
gw/acl_file
Specifies the name of an access control list (ACL) file.
(security parameter)
No ACL file is used
gw/acl_mode
The parameter defines the behavior of the gateway, if no ACL file (gw/sec_info oder gw/reg_info) exists.
(security parameter)
1
gw/alternative_hostnames
List of alternative host names for local host.
Network Parameters
No alternative host names
gw/close_routes
Specifies the period (in seconds) after which a route to a remote gateway through which a CPIC connection is open is closed.
(timeout parameter)
120 seconds
gw/conn_disconnect
Specifies the maximum number of seconds for which an active connection can remain in the status DISCONNECT or DISCONNECTED.
(timeout parameter)
900 seconds
gw/conn_pending
Specifies the maximum number of seconds for which a connection can remain in the status CONN_PENDING.
(timeout parameter)
60 seconds
gw/cpic_timeout
Specifies the maximum wait time for a connection setup.
(timeout parameter)
20 seconds
gw/deallocate_timeout
Time period in which the network connection for a DEALLOCATE must be closed.
(timeout parameter)
600 seconds
gw/frag_timeout
Determines the timeout for incomplete network write operations.
(timeout parameter)
120 seconds
gw/gw_disconnect
Specifies the maximum number of seconds for which a GW-GW connection can remain inactive.
(timeout parameter)
1800 seconds
gw/internal_timeout
Specifies the timeout value for NiReadand NiWrite calls.
(timeout parameter)
0 milliseconds
gw/keepalive
Specifies the maximum time period (in seconds) before the system checks, using a ping, whether the partner is still alive when there is no data transfer across a CPIC connection.
(timeout parameter)
300 seconds
gw/listen_queue_len
The operating system must keep requests in a queue while the connection is being set up.
(parameter for resource management)
512
gw/local_addr
Network Parameters
gw/logging
With this parameter you can configure gateway logging.
(configuration parameter)
see detailed parameter documentation.
gw/max_conn
Specifies the maximum number of connections that can be active at a time.
(parameter for resource management)
500
gw/max_conn_per_dest
Configures how many TCP/IP connections to a remote gateway or ABAP Application Server can be opened in parallel.
(parameter for resource management)
10
gw/max_overflow_size
This parameter specifies the size of the overflow area in bytes.
(parameter for resource management)
10000000 Bytes (10 MB)
gw/max_overflow_usage
Specifies the usage of the overflow area as a percentage from which the gateway slows down its clients, that is it sends SYNC requests.
(parameter for resource management)
20 %
gw/max_sleep
Specifies the maximum time in seconds for which the gateway read process sleeps on the select.
(timeout parameter)
20 seconds
gw/max_sys
Specifies the maximum number of clients connected at a time.
(parameter for resource management)
300
gw/monitor
This parameter determines whether the gateway should communicate with the monitor locally or remotely.
(configuration parameter)
1
gw/netstat_once
There are high availability solutions in which the IP addresses can move from one host to another. This means that the entries read when the gateway was started up may no longer be valid. In such cases, the current configuration must always be read using the command when making the test for a local IP address.
Network Parameters
1
gw/nibuf_max
Number of entries in the host name buffer.
Network Parameters
Used by NI interface
gw/nibuf_retry
Time period after which the invalid entries are deleted in the host name buffer.
(timeout parameter)
Used by NI interface.
gw/nifragtest
Tests fragmentation on the network layer.
Network Parameters
0
gw/nitrace
Activates or deactivates the trace for NI connections.
Network Parameters
0
gw/prxy_info
This parameter is used to specify the proxy settings of the gateway.
(configuration parameter)
/usr/sap/<SID>/<instance>/data/prxyinfo
gw/reg_info
File with the security information for registered programs.
(security parameter)
<Data directory>/reg info
gw/reg_keepalive
Specifies the maximum time period in seconds before the system checks, using a ping, whether the partners are still alive in a registered server program with the status WAITING.
(timeout parameter)
300 seconds
gw/reg_lb_default
Default value for the load of a server if its IP address cannot be found in the list.
(Load balancing parameter)
20
gw/reg_lb_ip
Specifies the load value for an IP address or for a range of IP addresses.
(Load balancing parameter)
see detailed parameter documentation.
gw/reg_lb_level
Defines the type of load balancing for registered programs.
(Load balancing parameter)
1
gw/reg_timeout
Specifies the maximum wait time for setting up the connection with a registered program.
(timeout parameter)
60 seconds
gw/remsh
Specifies the call path of the remote shell to start programs on other hosts.
(configuration parameter)
see detailed parameter documentation.
gw/rem_start
Determines how remote CPIC programs are to be started.
(configuration parameter)
REMOTE_SHELL
gw/req_stack_size
Specifies the number of CICP requests that can be stacked for each CPIC connection.
(parameter for resource management)
30
gw/resolve_phys_addrThis parameter specifies whether theGateway will resolve names of IP addresses.
Perform name resolution
gw/resolve_timeout
This parameter is used to activate a time measurement for the network lookup calls (host name - IP address, service name - port number).
(timeout parameter)
0 milliseconds
gw/sec_info
File with the security information.
(security parameter)
<Data Directory>/secinfo
gw/so_keepalive
Parameter to activate the socket option KEEPALIVE for the network connections.
Network Parameters
0
gw/ssh
Specifies the call path of the secure shell to start programs on other hosts.
(configuration parameter)
see detailed parameter documentation.
gw/start_in_homedir
Determines the directory in which the gateway starts programs.
(configuration parameter)
1
gw/start_threshold
If programs are started using rexec, blockages may occur in the gateway. To make it easier to analyze any blockages, a warning is written to the trace file once the time has exceeded by the defined time.
(configuration parameter)
5 seconds
gw/startup
File containing statements to start programs when the gateway starts.
(configuration parameter)
-
gw/stat
Determines the status of the gateway statistics after starting the gateway.
(configuration parameter)
0
gw/tcp_security
(security parameter)
gw/timeout
Specifies the timeout value for the establishing connections to other gateways.
(timeout parameter)
0 milliseconds
snc/enable
Specifies whether the gateway accepts connections that protect the data via SNC.
(security parameter)
0
snc/gssapi_lib
Path for the shared library of the security system in use.
(security parameter)
-
snc/identity/as
Identity of the gateway application server
(security parameter)
-
snc/permit_common_name
Specifies whether the gateway can use a default SNC name specified by the parameter snc/identity/as, if an SNC name for the connection cannot be read from the secinfo.
(security parameter)
0
snc/permit_insecure_comm
Specifies whether the gateway accepts connections without SNC.
(security parameter)
0
snc/permit_insecure_start
Specifies whether the gateway may establish connections with programs that communicate without SNC.
(security parameter)
0

1 comment: