Академический Документы
Профессиональный Документы
Культура Документы
Características:
El orden en que se asigna el tipo de memoria al work process,
depende del tipo de work process (ya sea diálogo o no diálogo),
y el sistema operativo subyacente.
Por defecto, los work process de diálogo asignan memoria extendida primero, mientras que
los que no son de diálogo se apilan.
Extended memory is the core of the memory management system. em/initial_size_MB at instance startup. El tamaño de este recurso está definido por el parámetro
There can be some exceptions depending on the underlying em / initial_size_MB en el inicio de la instancia.
Each work process hasa part reserved in its virtual address space for operating system that we will describe in the next unit.
extended memory. Every work process can allocate a limited part of it. Puede haber algunas excepciones dependiendo del sistema
The screenshot visualizes the relationship between extended operativo subyacente que describiremos en la siguiente unidad.
You can adjust the size of extended memory using the profile parameter memory pool and the work processes.
em/initial_size_MB, Cada Work Process puede asignar una parte limitada de él.
La captura de pantalla visualiza la relación entre la agrupación de
on AIX platform using EM/TOTAL_SIZE_MB. memoria extendida y los WP.
Memoria Extendida
Hablemos sobre la memoria extendida, que es un recurso compartido para todos los work process.
La memoria extendida es el núcleo del sistema de administración de memoria.
Cada work process tiene una parte reservada en su espacio de direcciones virtuales para memoria extendida.
El tamaño de este recurso se define mediante el parámetro em / initial_size_MB al inicio de la instancia.
Puede ajustar el tamaño de la memoria extendida usando el parámetro de perfil em / initial_size_MB,
en la plataforma AIX utilizando EM / TOTAL_SIZE_MB.
La captura de pantalla visualiza la relación entre el grupo de memoria extendida y los work process.
Let us continue with the heap memory. Continuemos con la Heap Memory
When a dialog work process uses its quota of extended memory or there is
not more extended memory available,
Cuando un WP de diálogo usa su cuota de memoria extendida o no hay más memoria extendida disponible,
and it still requires more memory,it will start to allocate work process local
memory, the so-called heap memory. y aún requiere más memoria, comenzará a asignar memoria local del WP, la llamada Heap Memory.
Los WP sin diálogo asignan primero la memoria de almacenamiento dinámico (Heap Memory), ya que no se produce un cambio de contexto.
Non-dialog work processes allocate heap memory first, since no context
switch occurs.
Después de usar la cuota de memoria de almacenamiento dinámico del proceso, o si no hay más memoria de almacenamiento dinámico
After using the process’ quota of heap memory or if there is no more heap disponible, los WP comenzarán a asignar memoria extendida.
memory available, the work processes will start allocating extended
memory. Si profundizamos en la tecnología, la Heap Memory se puede dividir en memoria PRIV y memoria PROC.
If we go deeper into the technology, heap memory can be divided into
© 2017 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 9
PRIV memory and PROC memory.
Fundamentals of Memory Management In some cases, when you go to transaction En algunos casos, cuando pasa a la transacción SM50 o SM66, ve los work process del
SM50 or SM66, you see dialog work processes diálogo en el modo PRIV.
Private memory (2) in PRIV mode. This means that heap memory
Esto significa que la heap memory se les ha asignado.
has been assigned to them.
PRIV-memory La heap memory no puede ser compartida por otros WP, e incluso cuando el work process
Heap memory cannot be shared by other ha finalizado su tarea, la memoria permanece ocupada a nivel del sistema operativo.
The work process is run in PRIV mode when work processes, and even when the work
private memory is assigned. process has finished its task, the memory Para liberar la memoria, es necesario reiniciar el work process.
remains occupied at the operating system Para ello, se establece un límite con el parámetro abap / heaplimit.
Private memory cannot be used by other work level.
processes. Cuando el work process utiliza la cantidad de heap memory definida por este parámetro,
To release the memory, the work process se reinicia automáticamente, solo después de terminar la tarea que ha estado
After releasing the assigned memory, the operating needs to be restarted. procesando.
To do so, a limit is set by the parameter
system still considers the virtual memory as being abap/heaplimit.
occupied by the allocating work process. Recomendamos que no cambie el valor predeterminado del parámetro abap / heaplimit,
When the work process uses the amount of ya que puede dar lugar a problemas inesperados.
When the amount of heap memory defined by heap memory defined by this parameter, it is
abap/heaplimit is exceeded, a work process is restarted automatically restarted, only after finishing El objetivo es reiniciar los work process lo menos posible, evitando cuellos de botella en el
after completing a transaction step and releases the the task that it has been processing. espacio de intercambio al mismo tiempo .
resources on operating system level. We recommend that you do not change the
default value of the abap/heaplimit
It is strongly recommended not to change the default parameter, because it may result in
value of abap/heaplimit. unexpected issues.
The SAP system offers a mechanism that lets you terminate non-active dialog
work processes in PRIV mode.
The mechanism works as follows:
In PRIV mode, a maximum number (n) of dialog work processes can run without
any time restrictions.
To determine this number (n), set the value of the profile parameter
rdisp/wppriv_max_no.
If more than (n) dialog work processes are active and the time span set in
parameter rdisp/max_priv_time has elapsed, the transaction for the PRIV process
that has spent the longest possible time in PRIV mode is reset.
Memoria Privada (3)
El sistema SAP ofrece un mecanismo que le permite finalizar WP de diálogo no activos en modo PRIV.
El mecanismo funciona de la siguiente manera:
En modo PRIV, se puede ejecutar un número máximo (n) de WP de diálogo sin restricciones de tiempo.
Para determinar este número (n), establezca el valor del parámetro de perfil
rdisp / wppriv_max_no.
Si hay más de (n) WP de diálogo activos y ha transcurrido el período de tiempo establecido en el
parámetro rdisp / max_priv_time, se restablece la transacción para el proceso PRIV que ha pasado el
mayor tiempo posible en modo PRIV.
When this maximum number, defined by parameter Cuando se alcanza este número máximo, definido por el parámetro
rdisp/wppriv_max_no is reached, the longest running rdisp / wppriv_max_no, el Work Process de diálogo de ejecución más
dialog work process in PRIV larga en el modo PRIV terminará primero.
mode will be terminated first.
© 2017 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 11
Fundamentals of Memory Management As already mentioned earlier,
heap memory can be divided into
Private memory (4) PRIV memory and PROC memory.
Memoria PROC
Como ya se mencionó anteriormente, la memoria de almacenamiento dinámico
Esto se usa para datos que no están vinculados a un contexto de usuario específico, se puede dividir en memoria PRIV y memoria PROC.
por ejemplo,
temporary, heap buffer areas. La memoria PROC se usa para datos que no están vinculados a un contexto de usuario específico, por ejemplo, áreas
temporales de almacenamiento intermedio de almacenamiento dinámico.
En contraste con la memoria PRIV,
la asignación de memoria PROC no conduce a una reserva exclusiva del WP para un contexto Los parámetros que influyen en este tipo de memoria se mencionan en esta diapositiva.
de usuario específico. Es importante que el parámetro em / proc_max_size_MB esté establecido en ilimitado, para evitar una parada del
sistema.
El Parametro: em / proc_max_size_MB Si este parámetro se establece en un valor específico, un WP probablemente no pueda obtener su cuota de
especifica el tamaño máximo de la Heap Memory PROC que todos los WP pueden asignar
memoria PROC en algunos casos.
en total,
y el Parametro: em / proc_max_wpsize_MB la asignación máxima por Work
Process.
La memoria de paginación puede residir en la memoria principal o compartirse entre la memoria principal y
It is divided into two parts: el sistema de archivos. (main memory and the file system.)
Paging buffer (in memory) is set by rdisp/PG_SHM
Por defecto, toda la memoria de paginación está disponible en la memoria principal para evitar problemas
Paging file (on file system) is set by rdisp/PG_MAXFS de rendimiento.
By default, the paging buffer is set by a formula depending on physical
La fórmula para calcular la memoria de paginación es óptima para el uso normal.
memory, and the paging file is set to the size of the paging buffer.
The formulais optimal for normal usage. Cuando una aplicación usa mucho la memoria de la página, puede ser necesario aumentarla manualmente.
The third type of SAP memory, that I want to mention, is the paging memory.
This is specific to ABAP extract and export statements, therefore it should not be
mixed up with the paging method at the operating system level.
The paging memory can reside in the main memory or be shared between main
memory and the file system.
The formula for calculating paging memory is optimal for the normal usage.
Parámetros
Una instancia está controlada por sus parámetros de perfil.
Los parámetros de perfil le permiten (entre otras cosas)
configurar su sistema de administración de memoria para
obtener el máximo beneficio de él.
Ciertos parámetros pueden restringir los WP individuales, y
las cuotas pueden limitar los recursos utilizados por todos
los WP.
Muchos de los parámetros del perfil de administración de
memoria de SAP se calculan mediante fórmulas para
simplificar la administración y garantizar que los parámetros
sean consistentes.
Ver también:
Nota SAP 2085980 - Nuevas características en la gestión de
© 2017 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 14
memoria a partir de la versión 7.40 de Kernel
Fundamentals of Memory Management
Parameters
The parameters in the instance profile allow system
administrators to customize the SAP system
according to the requirements.
Among others, the memory management
parameters can be adjusted to get the maximum
benefit from it.
These are parameters which are calculated with
formulas by default.
Some parameters are valid for individual work
processes; others influence the whole system.
EM / TOTAL_SIZE_MB
Define el tamaño de la agrupación de memoria extendida en AIX
Linux
es/implementation = std | map
With the default std variant, the memory management of an
SAP system on Linux is the same as on standard UNIX
systems.
This means that all user contexts are displayed in the
address space at the same time.
LINUX
es / implementación = std | mapa
Con la variante estándar estándar, la gestión de memoria de un sistema SAP en Linux
es la misma que en los sistemas UNIX estándar.
Esto significa que todos los contextos de usuario se muestran en el espacio de
direcciones al mismo tiempo.
The operating system offers resources like El sistema operativo ofrece recursos como CPU, memoria, disco, red, para todas las
Resources
CPU, memory, disk, network,
aplicaciones que se ejecutan en él.
Various operating systems: for all the applications running on it.
– Windows The resources are used by the operating Los recursos son utilizados por el propio sistema operativo,
system itself, by the SAP application, por la aplicación SAP,
– UNIX: Linux, AIX, Oracle Solaris, HP-UX and by a third-party application as well, for y también por una aplicación de terceros,
example a non-SAP database or application. por ejemplo, una base de datos o aplicación que no sea de SAP.
Recursos
*Varios sistemas operativos:
₋ Windows
₋ UNIX: Linux, AIX, Oracle Solaris, HP-UX
*Usado por:
₋ Sistema Operativo
₋ SAP
₋ Aplicaciones de terceros (por ejemplo, base de datos)
*RAM + Swap
© 2017 = anmemoria
SAP SE or SAP affiliate virtual
company. All rights reserved. ǀ PUBLIC 23
Memory Management Configuration The operating system has certain settings which limit the El sistema operativo tiene ciertas configuraciones que limitan el uso de memoria
memory usage per user. por usuario.
User-specific memory
Since the SAP system and all its processes are run by adm
Operating system memory for <sid>adm Dado que el sistema SAP y todos sus procesos son ejecutados por un usuario adm
user at the operating system level,
limits for the adm will be valid for the whole SAP system en el nivel del sistema operativo,
as well. Los límites para adm también serán válidos para todo el sistema SAP.
Determine it by:
– sh -c 'ulimit -a’ or csh -c limit On Windows, usually there aren’t any issues connected to En Windows,
such limits, normalmente no hay problemas relacionados con dichos límites,
– SAP tool: memlimits -v off but on Unix operating systems, they need to be set
pero en los sistemas operativos Unix, deben configurarse correctamente.
correctly.
The requirements are different per operating system. Los requisitos son diferentes según el sistema operativo.
In command output refer to:
There are several ways to check these limits.
– data size, stack size (requirements vary per operating system) One of them is to run “ulimit -a” or “limit” commands.
Hay varias formas de verificar estos límites.
Uno de ellos es ejecutar los comandos "ulimit -a" o "limit".
– Maximum heap size per process
In the command output, data and stack size point to
En la salida del comando, los datos y el tamaño del stack apuntan a las limitaciones
memory limitations.
See also: Another way is to use SAP’s “memlimits” executable. de la memoria.
SAP Note 1704753 – Inst.Systems Based on NetWeaver on UNIX In its output, “Maximum heap size per process” refers to Otra forma es usar el ejecutable "memlimits" de SAP.
SAP Note 1827960 – Adjusting operating system limits for SAP instances this user’s limitations.
En su salida, "Tamaño máximo de heap size" se refiere a las limitaciones de este
usuario.
Memoria del sistema operativo para <sid> adm
*Determinarlo por:
sh -c 'ulimit -a’ o csh -c limit
Herramienta SAP: memlimits -v off
Ver también:
SAP Note 1704753 - Inst.Systems basados en NetWeaver en
UNIX
Nota de SAP 1827960 - Ajuste de los límites del sistema
operativo para las instancias de SAP
Memory requirement of SAP instance If you run the command tool sappfpar using the instance profile
and the check option, the output provides the following
Determine it by: information:
*First, the “Total, minimum requirement”
– sappfpar check pf=<instance profile> is the memory which is allocated when starting the SAP system.
*Later, the “Total, worst case requirement” is the maximum
At the bottom of command output: usage made of the various shared memory segments
at the operating system level.
– Total, minimum requirement *The “Total, worst case requirement” value must fit into the
available virtual memory.
– Total, worst case requirement
If more SAP instances are running on the same host, you need to
Shared Memory (SHM) + Extended Memory (EM) total + summarize their worst-case requirement.
Heap total The tool sappfpar with the check option also verifies the
parameter configuration,
– Errors detected (e.g. segment size) and reports if there are any errors to be corrected.
What to consider:
– Total, worst case requirement must fit in RAM+Swap
Cada instancia de SAP tiene un requisito de memoria inicial y máximo
– Errors detected must be 0 ---> change posible
configuration if there are any Si ejecuta la herramienta de comando sappfpar utilizando el perfil de
instancia y la opción de verificación.
Requisito de memoria de la instancia de SAP La salida proporciona la siguiente información:
*Determinarlo por: * Primero, el "Total, requisito mínimo"
sappfpar check pf = <perfil de instancia> es la memoria que se asigna al iniciar el sistema SAP.
* Más tarde, el "Total, de requisitos en el peor de los de casos" es el uso
*En la parte inferior de la salida de comando: máximo que se hace de los diversos segmentos de memoria compartida, a
• Total, requisito mínimo nivel del sistema operativo.
• Total, requisito de peor caso El valor de "Total, de los requisitos en el peor de los casos" debe encajar en
• Memoria compartida (SHM) + Total de memoria extendida (EM) + la memoria virtual disponible.
Heap Total
• Errores detectados (por ejemplo, tamaño de segmento) Si se ejecutan más instancias de SAP en el mismo host, debe sumarizar el
requisito del peor de los casos.
*Qué considerar:
• Total, el requisito de peor caso debe caber en RAM + Swap La herramienta sappfpar con la opción de verificación
• Los errores detectados deben ser 0 ---> cambiar la configuración si hay también verifica la configuración del parámetro, e informa si hay errores por
alguno corregir.
© 2017 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 25
Memory Management Configuration
ZAMM (1)
Zero Administration Memory Management
One parameter:
– PHYS_MEMSIZE
– % of RAM or absolute value in MB, default 100% RAM
– other memory parameters are automatically derived from
it, platform dependently, by best practices formulas
Change if:
– further SAP instances are planned on same host
– you want to adjust the resource requirement of an SAP
instance
Administración de memoria de administración cero
*Un parámetro:
• PHYS_MEMSIZE
• % de RAM o valor absoluto en MB, predeterminado 100% RAM
• Otros parámetros de memoria se derivan automáticamente de ella,
dependiendo de la plataforma, mediante fórmulas de mejores
prácticas.
*Cambiar si
• Se planean más instancias de SAP en el mismo host
• quieres ajustar el requerimiento de recursos de una instancia de SAP
*Para verificar los valores antiguos que todavía están configurados con los nuevos
calculados, use sappfpar check_formula pf = <perfil>
y decida cuál es más adecuado para la instancia de SAP.
Typical issues:
Work process-specific memory limits reached (dump)
Instance-specific memory limits reached (dump)
Operating system memory fully utilized or user- specific
operating system limits reached (crash, dump)
Problemas típicos:
• Límites de memoria específicos del WP alcanzados (volcado)
• Límites de memoria específicos de la instancia alcanzados (volcado)
• Memoria del sistema operativo totalmente utilizada o límites del sistema
operativo específicos del usuario alcanzados (bloqueo, volcado)
Monitoring tools
ABAP:
– ST02
– ST06
– RZ20
– SM50 / SM66 (PRIV)
– RSMEMORY ------------------
Operating system:
– top
– ps aux
– Windows task manager
– ...
Memory Management Configuration
Tools
Hay varias herramientas de monitoreo disponibles en el sistema SAP y en el nivel del sistema
Several monitoring tools are available in the SAP
system and on the operating system level
operativo para Determinar el uso de los recursos y encontrar los posibles factores a
to determine the usage of resources and find optimizar.
the potential factors to optimize.
Tales herramientas son:
Such tools are: Transacción ST02
Transaction ST02 que muestra el uso actual de la memoria en porcentaje.
that displays the current usage of memory in
percentage.
Además, puede comparar el valor en memoria con el uso máximo para ver si ya se ha
In addition, you can compare the in-memory alcanzado.
value to the maximum usage to see if it has
already been reached. Transacción ST06
ofrece una visión general de los recursos del sistema operativo:
Transaction ST06 los valores actuales, las 24 horas anteriores y el historial también si desea mirar hacia atrás
offers an overview of the operating system
resources:
los últimos días.
current values, previous 24 hours ones, and
history as well if you want to look back to Transacción RZ20
the last days. También tiene elementos de árbol de monitoreo para generar alertas cuando se alcanzan
algunos umbrales de memoria.
Transaction RZ20
also has monitoring tree elements to generate
alerts when some memory thresholds are
Transacciones SM50 y SM66
reached. son útiles para verificar si los WP han entrado en el modo PRIV y cuánto tiempo han estado
en ese modo.
Transactions SM50 and SM66
are helpful to check whether work processes Transacción RSMEMORY
have entered the PRIV mode and how long they le permite visualizar la memoria global extendida y la descripción general de la memoria
have been in that mode.
PROC por proceso y en el nivel de instancia de SAP.
Transaction RSMEMORY
enables you to display extended global memory Cada sistema operativo también ofrece herramientas para monitorear los recursos de
and PROC memory overview per process and at memoria.
the SAP instance level. Como:
Top
Each operating system also offers tools to
monitor memory resources.
ps aux
-Administrador de tareas de Windows
SYSTEM_NO_MEMORY
SYSTEM_NO_ROLL
SYSTEM_NO_SHM_MEMORY
SYSTEM_NO_TASK_STORAGE
SYSTEM_SHM_NO_ROLL
...
TSV_TNEW_BLOCKS_NO_ROLL_MEMORY
TSV_TNEW_OCCURS_NO_ROLL_MEMORY
TSV_TNEW_PAGE_ALLOC_FAILED
...
LOAD_NO_ROLL
When resources are exhausted, SAP system Cuando se agotan los recursos,
raises a short dump and collects the most el sistema SAP genera un volcado corto y recopila la
important information in it. información más importante que contiene.
You can view a list of the short dumps in
transaction ST22.
Puede ver una lista de los volcados cortos en la
Short dumps are either the result of a transacción ST22.
shortage at the operating system level or at
ABAP level. Los volcados cortos son el resultado de una escasez a
nivel del sistema operativo o a nivel ABAP.
© 2017 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 32
Memory Management Configuration
Dumps (2)
Typical memory dumps (ST22)
Special case:
*NO_ROLL* dumps
They point to EM shortage.
Background:
Starting with SAP NetWeaver 7.4, all data that was stored in the classic ROLL
area in earlier releases will be stored in the extended memory together with
the other data contained in the ABAP user context, to simplify configuration.
Fondo:
A partir de SAP NetWeaver 7.4, todos los datos que se almacenaron en el área ROLL clásica,
en versiones anteriores se almacenarán en la memoria extendida
junto con los demás datos contenidos en el contexto del usuario ABAP,
para simplificar la configuración.
Therefore the dumps which include the ROLL Por lo tanto, los volcados que incluyen el patrón ROLL
pattern point to a shortage in extended apuntan a una escasez en la memoria extendida.
memory.
Mejores Practicas:
Consumo de memoria - EM, Heap:
1.Corresponde a (o muy cerca de) los límites específicos del proceso
EM: ztta / roll_extension
EM: abap / heap_area_ (dia | nondia)
2.Diferente de los límites específicos del proceso
Como reaccionar:
*Involucre a los especialistas de la aplicación
1. (consulte "Transacción",
2. "Información sobre dónde terminó",
3. "Extracto de código fuente" en el volcado)
para que verifiquen por qué se utiliza tanta memoria; restringir los criterios de selección del informe si es posible
*Revise el WP Trace(consulte "Número de WP" en el volcado) para obtener más detalles, ya sea la instancia o los
2017 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 36
límites©del sistema operativo alcanzados
Week 2: Memory Management and Gateway Service
Unit 3: Fundamentals of SAP Gateway
In this unit, we will talk about the SAP Gateway.
Before we begin, let us clarify what we mean by SAP Gateway.
In this openSAP course, we mean the SAP kernel process called gateway,
not the SAP NetWeaver Gateway 2.0, which is an ABAP-based product that handles OData requests
and is used with the SAP Fiori.
Uso de la Gateway 2
La siguiente figura muestra tres sistemas SAP diferentes.
Aquí puede ver las diferencias entre los tipos de instalación
solo 1.ABAP, 2.solo Java y 3. Dual stack.
Para los sistemas ABAP,
Cada instancia contiene una gateway iniciada y supervisada por el
despachador ABAP.
Para sistemas con una instancia de ASCS,
Es posible configurar una gateway en la instancia de ASCS.
Por defecto, no está configurado.
Para los sistemas Java,
Una gateway es suficiente para todo el sistema,
porque las instancias se comunican entre sí y no utilizan el RFC.
La gateway se utiliza para las conexiones RFC / JCo a otros
sistemas.
– Gateway read process (usual name: gateway) Si detecta que la gateway no se está ejecutando más,
intentará iniciar una nueva gateway.
– Gateway monitor
Si no se puede iniciar la gateway,
el despachador activará un apagado de emergencia y
Gateway Read Process detendrá la instancia.
Gateway read is started by the dispatcher and Esto se debe a que la gateway es un proceso clave para el
checked by it periodically. funcionamiento normal de una instancia ABAP.
The gateway reader receives all RFC requests and hands El procesamiento real de las solicitudes RFC
them over to a DIA WP; the processing takes place there. tiene lugar en los WP de diálogo.
Procesos de Gateway El gateway entrega una solicitud RFC entrante a un WP de
El Gateway SAP se compone de: diálogo libre,
1. Proceso de lectura de la gateway (nombre habitual: gateway) y se encarga de enviar la respuesta a la persona que llama,
2. Monitor de gateway una vez que el WP de diálogo finalizó el procesamiento.
This is because the gateway is a key process for the normal operation of an ABAP
instance.
The actual processing of RFC requests takes place at the dialog work processes.
The gateway hands over an incoming RFC request to a free dialog work process and takes
care of sending the response back to
the caller, once
© 2017 SAPthe processing
SE or was
an SAP affiliate finished
company. by the
All rights dialog
reserved. work process.
ǀ PUBLIC 40
Fundamentals of SAP Gateway At an ABAP instance, we can monitor the local En una instancia ABAP, podemos monitorear la gateway local a través de la
gateway through the transaction SMGW. transacción SMGW.
Architecture of the gateway (2)
When we open this transaction, we are
Gateway Monitor presented with a list of the currently active Cuando abrimos esta transacción, se nos presenta una lista de las conexiones
connections. activas actualmente.
The gateway monitor (transaction SMGW) is used to analyze and
administer the gateway. When you start it, you initially get a list of active We also see some information about the status También vemos información sobre el estado de la gateway, en el encabezado en
connections. of the gateway, at the header on the top of the la parte superior de la pantalla.
screen.
You can call up all the other monitor functions via a menu.
At this transaction, we can also see a list of En esta transacción, también podemos ver
These are among others:
external systems that are connected to this • una lista de sistemas externos que están conectados a esta gateway,
– Display Logged-On Clients gateway, • muestra el valor actual de los parámetros de la gateway,
display the current value of gateway parameters, • cambia el valor de los parámetros que se pueden cambiar dinámicamente,
– Display and Control Existing Connections change the value of parameters that are • y mantener las diferentes características de seguridad de la gateway.
dynamically switchable,
– Display Gateway Release Information and maintain the different security features of
– Display Parameters and Attributes of the Gateway the gateway.
Monitor de Gateway
• El monitor de gateway (transacción SMGW) se utiliza para analizar y
administrar la gateway.
• Cuando lo arranca, inicialmente obtiene una lista de conexiones activas.
Puede acceder a todas las demás funciones del monitor a través de un menú.
Estos son entre otros:
Mostrar clientes conectados
Visualización y control de conexiones existentes
Mostrar información de la versión de Gateway
Mostrar parámetros y atributos de la gateway
Cambiar los parámetros de la gateway
Activar rastreos o traces
Funciones de experto
Los servidores de aplicaciones y los hosts de bases de datos están en el mismo segmento de red.
Esta red está protegida del acceso externo a través de una zona desmilitarizada (DMZ).
You can protect the SAP servers through your network Ahora, hablemos sobre las características de seguridad de la gateway.
infrastructure.
However, this usually does not provide application level
security, Puede proteger los servidores SAP a través de su infraestructura de red.
for example, which program name a third-party system can Sin embargo, esto generalmente no proporciona seguridad a nivel de aplicación, por ejemplo,
use when registering itself at the gateway. qué nombre de programa puede usar un sistema de terceros al registrarse en la gateway.
Therefore, the gateway provides security features from its Por lo tanto, la gateway proporciona características de seguridad desde su nivel de aplicación.
application level.
In addition, the data exchanged through RFC communication Además, los datos intercambiados a través de la comunicación RFC no están encriptados de
is not encrypted by default. manera predeterminada.
Please note: Establishing an SNC-protected connection is time- The number of the non-SNC port is 33 and
consuming, and it will therefore have an impact on performance. then the instance number, and this port is
always opened.
See also: Recommendations regarding SNC configuration
Tenga en cuenta que el establecimiento de una conexión protegida con SNC lleva
mucho tiempo y, por lo tanto, tendrá un impacto en el rendimiento.
SAProuter
Es un programa que actúa, como una ubicación intermedia en la red entre
sistemas SAP, donde el acceso se controla antes de enviar los datos más
adelante en el camino de la comunicación.
También se pueden establecer conexiones entre sistemas SAP a través de varios
SAProuters.
Luego puede asegurar y proteger las conexiones entre los SAProuter adyacentes
utilizando SNC.
Los SAProuters se autentican entre sí, y encriptan los mensajes intercambiados.
De esta manera, puede establecer un túnel seguro para las comunicaciones
entre componentes que no puedan utilizar SNC.
Un único SAProuter puede ser tanto el iniciador como el aceptador de una
conexión protegida con SNC.
De esta manera, obtiene una visión general de los programas que se permitirán,
y luego puede editar los archivos de configuración
secinfo y reginfo
en consecuencia.
See also:
SAP Note 1850230 - GW: "Registration of tp <program ID> not allowed"
SAP Note 2145145 - User is not authorized to start an external
program
The keyword “local” means “the local server”; the keyword Discutiremos los argumentos disponibles en las siguientes diapositivas.
We will discuss the arguments available in the next
“internal” means “all servers that are part of this SAP • Cada instancia debe tener sus propios archivos de seguridad, con sus slides.
system” propias reglas, ya que las reglas son aplicadas por el proceso de
gateway de la instancia local. Each instance should have its own security files, with
See also: SAP Note 1408081 - Basic settings for reg_info and sec_info their own rules, as the rules are applied by the
En su lugar, puede usar un archivo central, si las mismas reglas se aplican gateway process of the local instance.
Consejos generales para reginfo y secinfo a todas las instancias del sistema.
You can use a central file instead, if the same rules
• La primera línea del archivo reginfo / secinfo debe ser "# VERSION = 2" • La palabra clave "local" significa "el servidor local".
apply to all instances of the system.
• La primera letra de la regla puede ser P (para Permiso) o D (para Denegar) • Y la palabra clave "interno" significa "todos los servidores que forman
• Cada línea debe ser una regla completa, es decir, no puede dividir la regla en dos parte de este sistema SAP". The keyword “local” means "the local server”.
o más líneas And the keyword “internal” means “all servers that
• La gateway aplicará las reglas en el mismo orden en que aparecen en el archivo, y Si no hay una regla que permita el registro o el inicio del programa, la are part of this SAP system”.
gateway negará la acción. If there is no rule allowing the registration or start of
solo se usará la primera regla coincidente excepto para programas registrados: the program, the gateway will deny the action.
Toda la información de ACCESO de todas las líneas se utilizará si el TP Names en otras palabras, la gateway agrega una regla implícita de "negar todo"
coincide al final durante el tiempo de ejecución. in other words, the gateway adds an implicit “deny
• Cada instancia debe tener sus propios archivos de seguridad, con sus propias all” rule at the end during runtime.
reglas, como las reglas son aplicadas por el proceso de gateway de la instancia
local; sin embargo, también se puede usar un archivo central
• La palabra clave "local" significa "el servidor local";
• la palabra clave "interno" significa "todos los servidores que forman parte de este
© 2017 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 52
sistema SAP"
The reginfo file has rules related to the registration of
SAP Gateway Security Configuration external programs or systems to the local SAP instance.
For example, when you configure the SLD, the System
Landscape Directory, it will perform the registration of
El archivo reginfo
tiene reglas relacionadas con el registro de programas o sistemas
ACLs the program SLD_UC at the gateway. externos en la instancia local de SAP.
The secinfo file has rules related to the start of programs
Por ejemplo,
reginfo and secinfo by the local SAP instance.
For example, when you import a transport request Cuando configura el SLD, the System Landscape Directory,
The reginfo file has rules related to the registration of external through the transaction STMS, it will start an SAP tool
called tp at the operating system level. realizará el registro del programa SLD_UC en la gateway.
programs (systems) to the local SAP instance
The default location of both files is the data folder of the
El archivo secinfo
The secinfo file has rules related to the start of programs by the local SAP local instance.
The gateway reads both security files when it is started. tiene reglas relacionadas con el inicio de programas por parte de la
instance
It is possible to reload these files without having to instancia local de SAP.
restart the instance, which allows dynamic changes to
Default location/name: be made to these security rules. Por ejemplo,
gw/sec_info = $(DIR_DATA)/secinfo cuando importa una solicitud de transporte a través de la transacción
STMS, iniciará una herramienta SAP llamada tp en el nivel del sistema
gw/reg_info = $(DIR_DATA)/reginfo operativo.
When the gateway is started, it reads both securityfiles. La ubicación predeterminada de ambos archivos es la carpeta de datos
You can make dynamic changes by changing, adding, or deleting entries in the de la instancia local.
reginfo / secinfo file.
La gateway lee ambos archivos de seguridad cuando se inicia.
Then the file can be immediately activated by reloading the security files.
Es posible volver a cargar estos archivos sin tener que reiniciar la
reginfo y secinfo instancia, lo que permite realizar cambios dinámicos en estas reglas de
seguridad.
El archivo reginfo tiene reglas relacionadas con el registro de programas externos
(sistemas)
en la instancia local de SAP
El archivo secinfo tiene reglas relacionadas con el inicio de programas por parte de
la instancia local de SAP
Ubicación / nombre predeterminado:
gw / sec_info = $ (DIR_DATA) / secinfo
gw / reg_info = $ (DIR_DATA) / reginfo
Cuando se inicia la gateway, lee ambos archivos de seguridad.
El argumento TP se utiliza para definir el nombre del programa que se registrará en la The TP argument is used to define the name of the
General reginfo rule definition program that will be registered at the gateway.
gateway.
P (permit) / D (denied) Notice that this program name is just an alias.
Tenga en cuenta que este nombre de programa es solo un alias. It does not necessarily need to be the name of the
TP=<program name> No necesariamente tiene que ser el nombre del sistema, producto o ejecutable que system, product or executable that will perform
realizará el registro. the registration.
HOST=<comma separated list of hosts that can register the El argumento TP es obligatorio. The TP argument is mandatory.
program> The next arguments that we will discuss are
optional, and if they are not set, the gateway will
ACCESS=<comma separated list of hosts that can Los siguientes argumentos que discutiremos son opcionales, assume their value to be a star or an asterisk.
communicate with the program> y si no están configurados, la gateway asumirá que su valor es una estrella o un asterisco. This would mean “all servers”, which might not be
Esto significaría "todos los servidores", lo que podría no ser bueno desde una perspectiva good from a security perspective.
CANCEL=<comma separated list of hosts that can cancel this Therefore, it is recommended to maintain all
registration> de seguridad.
arguments on every rule, even if you set them to
Por lo tanto, se recomienda mantener todos los argumentos en cada regla, incluso si los “star”, just for clarity purposes.
Usually: establece en "estrella", solo por razones de claridad.
ACCESS is a list with at least all SAP servers from this SAP *HOST es el argumento utilizado para definir la lista de servidores que pueden realizar el HOST is the argument used to define the list of
system; this can be replaced by the keyword “internal” servers that are allowed to perform the
registro del programa. registration of the program.
CANCEL is a list with all SAP servers from this system, or the Puede enumerar más de un servidor, separándolos mediante comas. You can list more than one server, separating them
keyword “internal”, and also the same servers as in HOST using commas.
*En el argumento ACCESS, definimos una lista de servidores que pueden comunicarse con ‘
este programa. At the ACCESS argument, we define a list of
Definición de Regla reginfo En la mayoría de los escenarios, ACCESS tendría una lista de todos los servidores SAP del servers that can communicate with this program.
• P (permiso) / D (denegado) sistema donde está registrado el programa. On most scenarios, ACCESS would have a list of all
Puede reemplazar esta lista por la palabra clave "interna". SAP servers of the system where the program is
• TP = <nombre del programa> registered.
• HOST = <lista de hosts separados por comas que pueden registrar el *También es posible definir qué servidores pueden cancelar el registro.
programa> Esto se define en el argumento CANCELAR. You can replace this list by the keyword “internal”.
• ACCESS = <lista de hosts separados por comas que pueden Por lo general, CANCELAR incluye todos los servidores enumerados en el argumento HOST It is also possible to define which servers are
• comunicarse con el programa> allowed to cancel the registration.
y la palabra clave "interna", o la lista de servidores SAP.
This is defined at the CANCEL argument.
• CANCELAR = <lista de hosts separados por comas que pueden Esto se debe a que debemos permitir que el sistema externo o el sistema SAP finalicen el Usually, CANCEL includes all servers listed at the
cancelar este registro> registro de manera agradable. HOST argument and the keyword “internal”, or the
list of SAP servers.
Generalmente: Por ejemplo, si uno de los sistemas se detendrá por mantenimiento, puede desencadenar This is because we need to allow the external
ACCESS es una lista con al menos todos los servidores SAP de este SAP la cancelación del registro del programa. system or the SAP system to terminate the
sistema; esto puede ser reemplazado por la palabra clave "interno“ registration nicely.
For example, if one of the systems will be stopped
for maintenance, it can then trigger the de-
CANCELAR es una lista con todos los servidores SAP de este sistema, o la registration of the program.
palabra clave "interna", y también los mismos servidores que en HOST
© 2017 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 54
Los cambios realizados directamente en el archivo reginfo Changes made directly to the reginfo file will not take effect immediately.
SAP Gateway Security Configuration no tendrán efecto de inmediato. First you need to reload the file through the transaction SMGW,
->menu Goto,
Primero debe volver a cargar el archivo a través de la
reginfo (2) transacción SMGW,
--> Expert functions
--->External security
Changes to the reginfo rules -> menú Ir a, ---->Maintain ACL Files,
Changes are not immediately effective, even after having -> Funciones expertas ----->then Goto
------>Reread)
---> Seguridad externa
reloaded the file (transaction SMGW, menu Goto → Expert This will reload both the reginfo and secinfo files.
----> Mantener archivos ACL, Then, if the changes made to the rules are related to a program that is already registered,
functions → External security → Maintain ACL Files, then Goto
-----> luego Goto for example, you have modified the ACCESS argument,
→ Reread); after reloading, de-register all existing registrations all registrations of the program need to be de-registered,
------> Releer
of the affected program, and re-register it again and the program needs to be re-registered.
Esto recargará los archivos reginfo y secinfo. This is because the gateway copies the rule used at the time of the registration to a memory
For a standalone gateway installation, you can reload the Luego, si los cambios realizados en las reglas están
area of the specific registration.
This means that if the program is registered 10 times and only 5 registrations are restarted, the
security files (reginfo and secinfo) without having to restart the relacionados con un programa que ya está registrado, por 5 new registrations will use the updated rule, and the 5 old registrations will continue to use the
gateway or the ASCS instance: gwmon pf=<path to instance ejemplo, ha modificado el argumento ACCESS, old rule.
profile> This could cause random issues, as it will depend on which registration will be used to process
todos los registros del programa deben ser dados de baja, y the request.
there access “m” Menu → “9” security information → “4” refresh sec. el programa debe volver a registrarse. How to restart the registration depends on the external system, so the support team of the
Esto se debe a que la gateway copia la regla utilizada en el remote system might have to be involved.
To reload the rules at a standalone gateway, execute the gwmon tool and access
See also (videos included): momento del registro en un área de memoria del registro the menu “m”,
– SAP KBA 1850230 - GW: "Registration of tp <program ID> not allowed” específico. then the option 9,
and then the option 4.
– SAP KBA 2075799 - ERROR: Error (Msg EGW 748 not found) Esto significa que si el programa se registra 10 veces y solo There is a video that illustrates how the reginfo rules work attached to both SAP KBAs linked at
Cambios a las reglas de reginfo se reinician 5 registros, this slide.
Los cambios no son efectivos de inmediato, los 5 registros nuevos usarán la regla actualizada
incluso después de haber vuelto a cargar el archivo (transacción SMGW, y los 5 registros antiguos continuarán usando la regla
menú Pasar a anterior.
→ Funciones expertas Esto podría causar problemas aleatorios, ya que dependerá
→ Seguridad externa de qué registro se utilizará para procesar la solicitud.
→ Mantener archivos ACL, La forma de reiniciar el registro depende del sistema
luego Pasar a externo, por lo que el equipo de soporte del sistema
→ Volver a leer); remoto podría tener que participar.
después de volver a cargar,
anule el registro de todos los registros existentes del programa afectado y Para volver a cargar las reglas en una gateway
vuelva a registrarlo nuevamente independiente, ejecute via sistema operativo la
herramienta gwmon y acceda
Para una instalación de Gateway standalone, el menú "m",
puede volver a cargar los archivos de seguridad (reginfo y secinfo) sin tener entonces la opción 9,
que reiniciar la gateway o la instancia de ASCS: y luego la opción 4.
gwmon pf = <ruta al perfil de instancia>
allí acceda al menú "m" Hay un video que ilustra cómo funcionan las reglas de
→ información de seguridad "9" reginfo adjuntas a ambos KBA de SAP vinculados en esta
2017 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 55
→ sec.©de actualización "4". diapositiva.
SAP Gateway Security Configuration Ahora veremos la sintaxis de las reglas secinfo.
Now we will see the syntax for the secinfo
rules.
Consider that we are creating a rule that will
secinfo allow the start of the program, that is, a rule
Considere que estamos creando una regla que permitirá el inicio del programa, es decir, una regla that starts with the letter P for permit.
que comience con la letra P para permiso.
General secinfo rule definition The TP argument is used to define the name
of the program that is to be started by SAP.
El argumento TP se utiliza para definir el nombre del programa que debe iniciar SAP.
P (permit) / D (denied)
The username that is allowed to start the
El nombre de usuario que tiene permitido iniciar el programa se define en el argumento USER.
TP=<program name> program is defined at the USER argument.
Este argumento solo acepta un nombre de usuario único. This argument only accepts a single
username.
USER=<username that is allowed to start the program>
El argumento HOST define el host de destino donde se iniciará el programa. The HOST argument defines the target host
HOST=<comma separated list of hosts the program can El sistema SAP puede iniciar programas en el servidor local y también en servidores remotos.
where the program will be started.
definition: The proxy info rules also start with either P for permit or D
P (permit) / D (denied) for deny.
SOURCE = <list of host names and port separated by comma where The SOURCE argument defines the source server and the
TCP/IP connection is allowed from> client that is using this gateway as the intermediary.
DEST = <list of host names and port separated by comma The DEST argument defines the final target server.
where TCP/IP connection is allowed to>
You can define a list of servers at both arguments,
La siguiente característica de seguridad que cubriremos en esta unidad se llama separating each server with a comma.
Default location/file:
información de proxy.
$(DIR_DATA)/prxyinfo As usual, there will be the implicit “deny all” rule at the
La gateway se puede utilizar como intermediario entre dos sistemas o servidores. Por end.
Listas de control de acceso adicionales ejemplo, If this file does not exist, then the gateway allows all proxy
Definición general de gw / prxy_info: connections.
el sistema SAP "A" se conectará al sistema SAP "C" a través de la gateway del sistema
• P (permiso) / D (denegado) SAP "B".
• FUENTE = <lista de nombres de host y puerto separados por
comas desde donde se permite la conexión TCP / IP> Puede usar la información del proxy del sistema "B" para controlar dicho acceso.
• DEST = <lista de nombres de host y puertos separados por Las reglas de información de proxy también comienzan con P para permiso o D para
comas denegar.
• donde se permite la conexión TCP / IP a>
Ubicación / archivo predeterminado: El argumento SOURCE define el servidor de origen y el cliente que utiliza esta gateway
$ (DIR_DATA) / prxyinfo como intermediario.
Modo de simulación
gw / sim_mode = 0 | 1
Implementing the reginfo, secinfo and proxy info files at a production environment may
cause disruptions if these rules are not well defined, or if there are missing rules.
The gateway provides a simulation mode that can be used to avoid that.
When this mode is active, the gateway does not add that final “deny all” rule. Instead, it
will allow the action.
However, if a rule that exists in the relevant security file matches the request, the rule will
be applied.
Furthermore, the ACCESS and CANCEL arguments of the reginfo file will be applied as
defined in the rule. In other words, the simulation mode applies only to the action of
registering the program, for the reginfo file.
gw/sim_mode = 0 | 1 Activates/Deactivates the simulation El diagrama que vemos en la diapositiva muestra el comportamiento de la gateway considerando el valor de estos
mode dos parámetros.
Como podemos ver, ambos parámetros no se consideran si existe el archivo reginfo o secinfo y si hay una regla
Comportamiento de gateway frente a Parámetros de Gateway que coincida con la solicitud.
• gw / acl_mode = 0 | 1
El parámetro define el comportamiento de la gateway si no existe un archivo
ACL (gw / sec_info, gw / reg_info).
Si se mantienen los archivos ACL anteriores, el valor de este parámetro es
irrelevante.
If the reginfo or secinfo files do not exist, the gateway will use internal default rules.
If it is set to 1, which is the default value, the gateway will allow everything from the local
server and from the same SAP system only.
For example, if a user tries to start a program at a remote server that does not belong to the
same SAP system where the user is logged on, the gateway would deny this action.
But starting the same program at the local SAP server would be allowed.
The diagram we see at the slide shows the gateway behavior considering the value of these
two parameters.
As we can see, both parameters are not considered if the reginfo or secinfo file exists and if
there is a rule that matches the request.
© 2017 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 60
SAP Gateway Security Configuration
Logging (1)
Gateway logging
For standalone gateway (ASCS)
Activate it by
gw/logging=LOGFILE=<name>ACTION=[TERSMPXVCO][MAXSIZEKB=n][SWITCHTF=t][FILEWRAP=on]
For ABAP:
Start it from SMGW → Goto → Expert Functions
→ Logging
Define File Name, Log Events, Toggle Criteria, Simulation Mode (switch on/off
simulation mode)
Activate logging by “magic wand”
See also:
SAP Note 910919 - Setting up Gateway logging
Setting Up Gateway Logging (Help portal)
Registro de Gateway
Para gateway independiente (ASCS)
Actívelo mediante gw / logging = LOGFILE = <name> ACTION = [TERSMPXVCO] [MAXSIZEKB = n] [SWITCHTF = t] [FILEWRAP = on]
Para ABAP:
Comience desde SMGW
→ Ir a
→ Funciones expertas
→ Registro
Definir nombre de archivo, eventos de registro, criterios de alternancia, modo de simulación (activar / desactivar el modo de
simulación)
Activar el registro mediante "varita mágica"
Tenga en cuenta que los cambios que hacemos en esta pantalla se perderán si SAP se What you can do is perform the configuration
reinicia. at this screen, activate it, and then go to the
transaction RZ11 to get the current value of
Lo que puede hacer es realizar la configuración en esta pantalla, activarla y luego ir a the parameter gw/logging.
la transacción RZ11 para obtener el valor actual del parámetro gw / logging.
This way you can easily add the parameter to
the instance profile, with the appropriate
De esta manera, puede agregar fácilmente el parámetro al perfil de instancia, con el value.
valor apropiado.
accepted / denied records Then we have the date and time of the
event, followed by the corresponding text
for reginfo / secinfo explaining the event.
Luego tenemos la fecha y hora del evento, seguido del texto correspondiente que explica el evento.
Value 64 activates the security feature of SAP Note 1697971 La primera nota de SAP que hemos vinculado en esta diapositiva tiene una lista de posibles For example, to activate the
valores de máscara de bits y el número de la nota de SAP correspondiente que proporciona más features 1 and 64 that we see on
Value 65 (=64+1) will activate both of the above features información sobre la función de seguridad que está activando o cambiando. the slide, we would have to set this
parameter to the value 65.
and so on...
Value 193 (=128+64+1) activates all the three features available as of kernel 7.4 The first SAP Note that we have
linked on this slide has a list of
See also: possible bitmask values and the
number of the corresponding SAP
SAP Note 1444282 - gw/reg_no_conn_info settings Note that provides more
SAP Note 2269642 - GW: Validity of parameter gw/reg_no_conn_info information about the security
feature it is activating or changing.
Bienvenido a la Semana 2, Unidad 5. Aprenderemos sobre los diferentes escenarios de RFC en esta unidad.
Let us begin by explaining some
RFC Interface Scenarios Comencemos explicando alguna terminología sobre los RFC. terminology about RFCs.
RFC fundamentals El cliente RFC es el sistema que inicia la conexión RFC.
The RFC client is the system that starts
El sistema que recibe la conexión y procesa la solicitud es el servidor RFC.
the RFC connection.
Tenga en cuenta que un sistema, o incluso una instancia, puede ser tanto el cliente como el servidor al
RFC connection fundamentals mismo tiempo. The system that receives the
client: where the RFC call is initiated from connection and processes the request
La Gateway "líder“ (The “leading" Gateway) es la Gateway que tiene control sobre el flujo de datos. is the RFC server.
server: where the RFC call is processed Por defecto, es la Gateway desde el extremo del cliente. Notice that a system, or even an
Esto se puede cambiar configurando las opciones de Gateway ”del destino RFC, en la transacción SM59. instance, can be both, the client and
“leading” gateway: the local gateway of the client by
Si esas opciones están configuradas, esa será la Gateway "líder". the server at the same time.
default, unless specified otherwise in SM59 at
“Gateway Options” Un bloque CA (A CA block ) The “leading" gateway is the gateway
Es un bloque de comunicación que Contiene los datos asociados a la solicitud. that has control over the data flow.
CA block: communication block, required for all By default, it is the gateway from the
requests with associated data Streaming client end.
Es una nueva característica que se introdujo en la versión SAP NetWeaver 7.40.
streaming: CPIC streaming is used for the RFC data Es una optimización del rendimiento, y se utilizará si ambos extremos de la comunicación lo admiten. This can be changed by setting the
transfer; this is a performance optimization Esta característica está controlada por el parámetro de perfil rdisp / cpicStreaming. gateway options”of the RFC
rdisp/cpicStreaming (on), available only for kernel >= destination, at the transaction SM59.
7.4
If those options are set, that will be the
“leading" gateway.
Fundamentos de conexión RFC
A CA block is a communication block. It
• Cliente: desde donde se inicia la llamada RFC holds the data associated to the
• Servidor: donde se procesa la llamada RFC request.
• Gateway “principal”: la gateway local del cliente de manera
predeterminada, a menos que se especifique lo contrario en SM59 Streaming is a new feature that was
en “Opciones de gateway” introduced on the SAP NetWeaver 7.40
• Bloque CA: bloque de comunicación, requerido para todos release.
It is a performance optimization and it
• solicitudes con datos asociados will be used if both ends of the
• Transmisión: la transmisión CPIC se utiliza para la transferencia de communication support it.
datos RFC;
Esta es una optimización de rendimiento rdisp / cpicStreaming This feature is controlled by the profile
(activado), disponible solo para kernel > = 7.4 parameter rdisp/cpicStreaming.
RFC síncrono (sRFC) en el nivel ABAP When an RFC client makes a synchronous request, it
Synchronous RFC (sRFC) on ABAPlevel • Espera la respuesta del servidor en el lado del cliente will become blocked and it will wait for the response
from the RFC server.
wait for the answer of server at client side • Paquete de sincronización cuando el Taskhandler de destino recibió el bloque CA
(= un viaje de ida y vuelta por bloque CA) In this scenario, a synchronization packet is sent by the
synchronizing package when target taskhandler taskhandler of the target system every time it receives
received the CA block ( = one round trip per CA block) RFC asíncrono (aRFC) en el nivel ABAP a CA block, or data package.
No espere la respuesta del servidor en el lado del cliente
Asynchronous RFC (aRFC) on ABAPlevel When the RFC client makes an asynchronous request,
don’t wait for the answer of server at client side it will not be blocked and it can execute other tasks
Posibles escenarios
while it waits for the RFC server to send a response.
• gateway "líder" en aRFC en el lado del cliente
Possible scenarios • gateway "líder" en aRFC en el lado del servidor
"leading" gateway in aRFC on the client side
"leading" gateway in aRFC on the server side
sessions in SM04 with last request a long time ago Las posibles explicaciones para esta situación son: Possible explanations for this situation are:
A) El cliente RFC todavía está esperando la respuesta del servidor RFC. A) The RFC client is still waiting for the response from
What does it point to? the RFC server.
B) Este comportamiento se observa en un Work Process sin diálogo, como un WP en segundo B) This behavior is being observed at a non-dialog
a) the client has been waiting for a server response for a long time plano. work process, like a background work process.
The session on a non-dialog work process cannot be
b) a non-dialog process cannot be rolled out during the RFC La sesión en un Work Process sin diálogo no se puede deshacer. rolled out.
communication and always displays the status “On Hold” Por lo tanto, los WP sin diálogo siempre muestran este estado cuando realizan llamadas RFC. So, non-dialog work processes always show this status
when they are making RFC calls.
“RFC response” Y C) El cliente RFC está haciendo varias llamadas RFC en secuencia, y aunque siempre ve el WP And C) The RFC client is making several RFC calls in
en este estado "En espera", el ID de la conversación cambia constantemente. sequence, and although you always see the process in
c) the communication changes so fast that other conversation IDs this status "On Hold", he conversation ID is constantly
Esta ID de conversación es un identificador único de 8 dígitos creado para cada llamada RFC. changing.
are connected to it This conversation ID is an 8-digit unique identifier
Entonces, ¿estos posibles escenarios representan un problema? No necesariamente. created for every RFC call.
Is this really a problem situation? Los escenarios B y C serían comportamientos normales y esperados. So, do these possible scenarios represent an issue?
a) the server needs further analysis El escenario A tendría que analizarse más desde la perspectiva del servidor RFC.
Not necessarily.
The scenarios B and C would be normal and expected
b) and c) does not constitute an error Por ejemplo, si la función que se llamó todavía se está ejecutando, entonces podría estar behaviors.
The scenario A would have to be further analyzed
enfrentando un problema de rendimiento y el estado del cliente RFC es el correcto. from the RFC server perspective.
For example, if the function that was called is still
RFC “En Espera” / ON HOLD Observe que el escenario A también puede encajar en el escenario B, ya que un Work Process running, then it might be facing a performance issue
and the status of the RFC client is the correct one.
sin diálogo también puede ser el cliente RFC. En las siguientes diapositivas, discutiremos las
Observaciones en el sistema SAP:
transacciones de monitoreo que pueden usarse para analizar el escenario A. Notice that the scenario A can also fit in the scenario
• sesiones en SM50 con estado "En espera" "Respuesta RFC" B, as a non-dialog work process can also be the RFC
• sesiones en SM04 con la última solicitud hace mucho tiempo client.
At the next slides, we will discuss monitoring
transactions that can be used to analyze the scenario
¿A qué apunta? A.
At the transaction SM51, you En la transacción SM51, puede seleccionar la instancia que
can select the instance that has tiene el WP en espera y acceder a la ruta del menú
the process on hold and access
Ir,
the menu path
Goto, → Información,
Information, → Comunicación,
Communication, → Conexión RFC.
RFC connection. Luego puede ubicar la sesión deseada.
You can then locate the desired
session.
Por lo general,
We would usually use the usamos la ID de conversación o la ID de sesión que puede
conversation ID or the session obtener de los detalles del proceso, haciendo doble clic en el
ID that you can get from the Work Process en la transacción SM50.
process details, by double-
clicking at the work process at
the transaction SM50.
© 2017 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 72
RFC Interface Scenarios
Information (2)
How to find relevant information?
SM04
– Select the user session
– Menu User → Technical information
– modeinfo[n].cpic_no
is the number of RFCs spawned by this context
At the transaction
SM04, select the
En la transacción SM04, seleccione la sesión deseada,
desired session, y acceda al menú Usuario,
and access the menu Información técnica.
User,
Technical Information. Para cada sesión interna de esta sesión de usuario,
que se denomina modo,
For each internal
session of this user
puede buscar la propiedad llamada cpic_no.
session, that is called a
mode, you can look for Esta propiedad muestra el número de llamadas RFC
the property called creadas por este modo.
cpic_no.
You can also verify También puede verificar la propiedad de modo llamada appl_info (stack).
the mode property
called Mostrará el servidor RFC en la propiedad "S" - esto es "S" para el servidor;
appl_info(stack).
It will show the RFC
y el módulo de función que fue llamado en la propiedad "F" - esto es "F" para la
server at the “S” función.
property – this is “S”
for server;
and the function
module that was
called at the “F”
property – this is “F”
for function.
One scenario that is also common is an RFC chain. Un escenario que también es común es una cadena RFC.
This is when we have RFC sessions that open other RFC
sessions.
Esto es cuando tenemos sesiones de RFC que abren otras sesiones de RFC.
For example, an RFC server also acts as an RFC client Por ejemplo, un servidor RFC también actúa como un cliente RFC al hacer una llamada RFC.
by making an RFC call.
El segundo servidor RFC también puede actuar como un cliente y hacer otra llamada RFC para la cual
The second RFC server can also act as a client and tendremos el tercer servidor RFC en esta cadena, y esto podría continuar.
make another RFC call for which we will have the third La transacción SM5A se puede usar para analizar fácilmente tales cadenas de RFC y obtener la lista de
RFC server on this chain, and this could continue going
sesiones de usuario para todos los contextos de cliente y servidor de RFC, así como los ID de
on.
conversación asociados a cada sesión.
The transaction SM5A can be used to easily analyze De hecho, incluso si no estamos lidiando con un escenario de cadena RFC, la transacción SM5A puede
such RFC chains and get the list of user sessions for all
the RFC client and server contexts, as well as the
ser muy útil.
conversation IDs associated to each session.
SAP KBA y SAP Note que hemos vinculado en esta diapositiva tienen más información sobre el análisis
In fact, even if we are not dealing with an RFC chain de la situación de RFC "En espera".
scenario, the transaction SM5A can be very helpful.
The SAP KBA and SAP Note that we have linked on this
slide have further information about the analysis of
© 2017 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 76
the “On Hold" RFC situation.
Thank you.
Contact information:
open@sap.com