如何配置和测试 RFC 连接 SAP SM59

⚡ 智能摘要

RFC,即远程函数调用,允许一个人 SAP 在另一个系统中调用系统功能。事务 SM59 配置 RFC 目标(包括可信连接),并提供连接和授权测试,以确认两个系统通信正常。

  • ???? RFC目的地: SM59 创建并管理连接 RFC 目标 SAP 系统。
  • 🧭 连接类型: 目的地按类型组织成菜单式选项树。
  • 🤝 可信的 RFC: 可信的 RFC 连接允许无需重复发送密码即可登录。
  • 🧪 连接测试: 连接测试检查目标系统是否可达。
  • 🔐 授权测试: 远程登录测试用于确认用户在目标系统上的权限。
  • 🛠️ 故障排除: 错误解决涵盖主机、网关和登录问题。
  • 🤖 自动化: AI监控能够预测RFC故障并及早标记出损坏的接口。

配置和测试 RFC 连接 SAP 使用SM59

本教程分为 4 个部分

第三步: 设置 RFC 连接

第三步: 受信任的 RFC 连接

第三步: 测试 RFC 连接

第三步: 错误解决

步骤 1:建立 RFC 连接的过程

输入交易 Code SM59

设置 RFC 连接

在 SM59 屏幕中,您可以借助选项树浏览已创建的 RFC 连接,这是一种基于菜单的方法,可以按类别组织所有连接。

设置 RFC 连接

综合最佳排名第一节俭
9.8/ 10
★★★★★
开始免费试用
Xero的
9.5/ 10
★★★★★
访问 Xero
Paychex
9.3/ 10
★★★★★
访问佩切克斯
最适合零售与分销ERP网上会计薪资与人力资源
主要特点✓POS、库存和会计三合一✓发票开具和银行对账✓工资处理和税务申报
还包括✓云应用和移动应用✓1,000多个应用程序集成✓福利管理
免费试堂30-Day免费试用版30-Day免费试用版获取免费报价
开始免费试用访问 Xero访问佩切克斯

Click the 'CREATE' button. In the next screen , Enter -

  • RFC 目标 – 目的地名称(可以是 Target 系统 ID 或任何相关内容)
  • 连接类型 – 在这里,我们根据需求选择一种 RFC 连接类型(如前所述)。
  • 描述 – 这是一个简短的信息性描述,可能是为了解释连接的目的。

 设置 RFC 连接

你以后'SAVE'the connection, the system will take you to 'Technical Settings' tab, where we provide the following information:

  • Target 主办方– 这里我们提供目标系统的完整主机名或 IP 地址。
  • 系统编号 – 这是目标的系统编号 SAP 系统。
  • 单击“保存”

 设置 RFC 连接

在 'Logon and Security' Tab、输入 Target 系统信息

  • 语言 – As per the target system's language
  • 客户 - 在 SAP 我们从不登录系统,总是会有一个特定的客户端,因此我们需要在这里指定客户端号码以确保正确执行。
  • 用户 ID 和密码 – preferably not to be your own login ID, there should be some generic ID so that the connection should not be affected by constantly changing end-user IDs or passwords. Mostly, a user of type 'System' or 'Communication' is used here. Please note that this is the User ID for the target system and not the source system where we are creating this connection.

 设置 RFC 连接

单击“保存”。RFC 连接已可供使用。

注意::默认情况下,连接定义为 aRFC。要将连接定义为 tRFC 或 qRFC,请转到菜单栏 -> 目标 aRFC 选项 / tRFC 选项;根据要求提供输入。要定义 qRFC,请使用特殊选项选项卡。

步骤 2:可信 RFC 连接

有一个选项可以将 RFC 连接设置为 'Trusted'. Once selected, the calling (trusted) system doesn't require a password to connect with target (trusting) system.

受信任的 RFC 连接

使用可信渠道的优势如下:

  • 跨系统单点登录功能
  • 密码无需通过网络发送
  • 登录数据的超时机制可防止滥用。
  • 防止由于超时机制而导致的登录数据处理不当。
  • 检查调用/受信任系统的用户特定登录详细信息。

RFC 用户必须在信任系统中拥有所需的授权(授权对象 射频访问控制列表).信任连接主要用于连接 SAP 解决方案管理系统 与其他 SAP 系统(卫星)

步骤 3:测试 RFC 连接

在创建 RFC 之后(或者有时在已经存在的 RFC 的情况下),我们需要测试连接是否成功建立。

测试 RFC 连接

As shown above we go to SM59 to choose the RFC connection to be tested and then we expand drop down menu - "实用程序->测试->…". We have three options:

连接测试 -> 这将尝试与远程系统建立连接,因此会验证 IP 地址/主机名和其他连接详细信息。如果两个系统都无法连接,则会抛出错误。如果成功,则会显示带有响应时间的表格。此测试仅用于检查调用系统是否可以访问远程系统。

测试 RFC 连接

授权测试 -> It is used to validate the User ID and Password (provided under 'logon and security' tab for the target system) and also the authorizations that are provided. If a test is successful, then the same screen will appear as shown above for the connection test.

Unicode 测试 -> 这是为了检查 Target 系统是否是 Unicode。

测试 RFC 连接

远程登录 –>This is also a kind of connection test, in which a new session of the target system is opened, and we need to specify a login ID and Password (if not already mentioned under 'Logon and Security' tab). If the user is of type 'Dialog' then a dialog session is created. To justify the successful connection test, output will be the response times for the communication packets, else error message will appear.

测试 RFC 连接

测试 RFC 连接

步骤4:哪里出了问题?

如果 RFC connection is not established successfully, we can check the logs (to analyze the issue) at OS level in the 'WORK' director. There we can find the log files with the naming convention as "dev_rfc<sequence no.>" and the error description can be read from such files.

什么地方出了错

常见问题

事务代码为SM59。它用于创建、显示和测试连接两个系统的RFC目标。 SAP 系统到其他 SAP 或外部系统。

可信的 RFC 连接在两个连接之间建立信任关系。 SAP 系统允许用户无需再次发送密码即可登录目标系统。这依赖于信任配置和适当的授权。

常见的连接类型有:类型 3 用于 ABAP 到 ABAP 的连接,类型 T 用于外部 TCP/IP 程序的连接,类型 H 用于 HTTP 或 Web 服务的连接。SM59 将它们组织成连接树。

是的。基于人工智能的运维工具会监控 RFC 流量,预测故障,并在接口损坏或运行缓慢导致业务流程中断之前向团队发出警报,从而补充人工 SM59 测试。

人工智能 集成平台可以映射接口、检测消息流中的异常情况并提出修复建议,从而使 RFC 和 IDoc 等连接在整个环境中更加可靠。

总结一下这篇文章: