sap-linuxlab / community.sap_install

Automation for SAP - Collection of Ansible Roles for various SAP software installation
Apache License 2.0
53 stars 55 forks source link

S4HANA playbook (role: sap_swpm) installation is failing. ERROR: Start SAPinst in interactive mode to solve this problem #301

Closed arubasu closed 1 year ago

arubasu commented 1 year ago

Scenario: We have deployed 2 VMs in Azure to install HANA and S4HANA respectively. We have successfully installed HANADB on one VM hostname: vm-techmsapdb with sap_hana_install role. sap_hana_install role variables:

# HANA DB Playbook Params
sap_hana_install_software_directory: /hana/hanadb
sap_hana_install_common_master_password: 'NewPass$321'
sap_hana_install_sid: 'H01'
sap_hana_install_instance_number: '00'

However, we are getting the following error while installing S4HANA on the other VM hostname: vm-techmsapapp. Error:

ERROR 2023-01-05 08:49:08.319 (root/sapinst) id=modlib.jslib.caughtException errno=MUT-03025
Caught ESAPinstException in module call: Validator of step '
|NW_ABAP_OneHost|ind|ind|ind|ind|0|0
|NW_Onehost_System|ind|ind|ind|ind|onehost|0
|NW_GetSidNoProfiles|ind|ind|ind|ind|getSid|0
|NW_getDBInfo|ind|ind|ind|ind|db|0
|NW_HDB_getDBInfo|ind|ind|ind|ind|hdb_dbinfo|0|getDBInfo' reported an error:
Start SAPinst in interactive mode to solve this problem.

ERROR 2023-01-05 08:49:08.366 (root/sapinst) id=controller.stepExecuted errno=FCO-00011
The step getDBInfo with step key 
|NW_ABAP_OneHost|ind|ind|ind|ind|0|0
|NW_Onehost_System|ind|ind|ind|ind|onehost|0
|NW_GetSidNoProfiles|ind|ind|ind|ind|getSid|0
|NW_getDBInfo|ind|ind|ind|ind|db|0
|NW_HDB_getDBInfo|ind|ind|ind|ind|hdb_dbinfo|0|getDBInfo
was executed with status ERROR
(Last error reported by the step: Caught ESAPinstException in module call: Validator of step '|NW_ABAP_OneHost|ind|ind|ind|ind|0|0|NW_Onehost_System|ind|ind|ind|ind|onehost|0|NW_GetSidNoProfiles|ind|ind|ind|ind|getSid|0|NW_getDBInfo|ind|ind|ind|ind|db|0|NW_HDB_getDBInfo|ind|ind|ind|ind|hdb_dbinfo|0|getDBInfo' reported an error:
Start SAPinst in interactive mode to solve this problem).

sap_swpm role variables:

# S4 App Playbook Params
# Product ID for New Installation
sap_swpm_product_catalog_id: NW_ABAP_OneHost:S4HANA1909.CORE.HDB.ABAP

# Software
sap_swpm_software_path: /hana/s4app
sap_swpm_sapcar_path: /hana/s4app
sap_swpm_swpm_path: /hana/s4app

# NW Passwords
sap_swpm_master_password: "NewPass$321"
sap_swpm_ddic_000_password: "NewPass$321"

# HDB Passwords
sap_swpm_db_system_password: "NewPass$321"
sap_swpm_db_systemdb_password: "NewPass$321"
sap_swpm_db_schema_abap: "SAPHANADB"
sap_swpm_db_schema_abap_password: "NewPass$321"
sap_swpm_db_sidadm_password: "NewPass$321"

# NW Instance Parameters
sap_swpm_sid: S4H
sap_swpm_pas_instance_nr: "01"
sap_swpm_ascs_instance_nr: "02"
sap_swpm_ascs_instance_hostname: "{{ ansible_hostname }}"
sap_swpm_fqdn: "poc.cloud"

# HDB Instance Parameters
# For dual host installation, change the db_host to appropriate value
sap_swpm_db_host: "vm-techmsapdb"
sap_swpm_db_sid: 'H01'
sap_swpm_db_instance_nr: "00"

# https://github.com/sap-linuxlab/community.sap_install/issues/298
sap_swpm_update_etchosts: "false"

I have also tried with vm-techmsapdb.internal.cloudapp.net as sap_swpm_db_host name as internal.cloudapp.net is Azure managed DNS.

For your reference, I have provided the /etc/hosts details of both the VMs. HANA VM /etc/hosts details:

$ cat /etc/hosts
127.0.0.1   localhost localhost.localdomain localhost4 localhost4.localdomain4
::1         localhost localhost.localdomain localhost6 localhost6.localdomain6
#vm-techmsapdb.internal.cloudapp.net 10.0.1.6
10.0.1.6 vm-techmsapdb.internal.cloudapp.net vm-techmsapdb
127.0.0.1       SLANALYTICSFTP.wdf.sap.corp

S4HANA VM /etc/hosts details:

$   cat /etc/hosts
127.0.0.1   localhost localhost.localdomain localhost4 localhost4.localdomain4
::1         localhost localhost.localdomain localhost6 localhost6.localdomain6
10.0.1.7        vm-techmsapapp.poc.cloud        vm-techmsapapp
10.0.1.6        vm-techmsapdb.poc.cloud vm-techmsapdb 

Please let me know if you need any additional information.

sean-freeman commented 1 year ago

When SAP SWPM displays |getDBInfo' reported an error, it is usually is a connectivity or credentials error when initialising the database connection with database user SYSTEM.

Have you verified connectivity between the hosts and ensured no OS Firewall or Network Firewall (e.g. in Cloud, this could be Security Group applied to the network interface of the host, or the Network Access Control List applied to the entire subnet) is blocking the connection? Should be port 5xx13 and 5xx14, but would need to check the SAP.com documentation; it's either in the 30000-31000 or 50000-51000 ranges. Use something like...

$ [vm-techmsapapp]  nmap -p 5xx13 10.0.1.6
$ [vm-techmsapapp]  nmap -p 3xx13 10.0.1.6

If network connection is ruled out, and SAP HANA Studio can login without issue with the password given - then additional investigation is required.

arubasu commented 1 year ago

@sean-freeman Since both VMs are in same subnet, there is no firewall in between. I can access the DB port i.e. 3001X from the App VM.

[root@vm-techmsapapp ~]# nc -zv 10.0.1.6 30013
Ncat: Version 7.70 ( https://nmap.org/ncat )
Ncat: Connected to 10.0.1.6:30013.
Ncat: 0 bytes sent, 0 bytes received in 0.01 seconds.
[root@vm-techmsapapp ~]# nc -zv 10.0.1.6 30015
Ncat: Version 7.70 ( https://nmap.org/ncat )
Ncat: Connected to 10.0.1.6:30015.
Ncat: 0 bytes sent, 0 bytes received in 0.01 seconds.
[root@vm-techmsapapp ~]# 

From DB VM, I can access the DB locally with SYSTEM user

vm-techmsapdb:h01adm> hdbsql -u SYSTEM -p NewPass$321

Welcome to the SAP HANA Database interactive terminal.

Type:  \h for help with commands          
       \q to quit                         

hdbsql H01=> 

I can also access HANA DB with SYSTEM user from SAP HANA Studio. Screenshot:

image

Still got the same error. Error:

ERROR 2023-01-06 09:06:55.228 (root/sapinst) id=modlib.jslib.caughtException errno=MUT-03025
Caught ESAPinstException in module call: Validator of step '|NW_ABAP_OneHost|ind|ind|ind|ind|0|0|NW_Onehost_System|ind|ind|ind|ind|onehost|0|NW_GetSidNoProfiles|ind|ind|ind|ind|getSid|0|NW_getDBInfo|ind|ind|ind|ind|db|0|NW_HDB_getDBInfo|ind|ind|ind|ind|hdb_dbinfo|0|getDBInfo' reported an error:
Start SAPinst in interactive mode to solve this problem.

ERROR 2023-01-06 09:06:55.294 (root/sapinst) id=controller.stepExecuted errno=FCO-00011
The step getDBInfo with step key |NW_ABAP_OneHost|ind|ind|ind|ind|0|0|NW_Onehost_System|ind|ind|ind|ind|onehost|0|NW_GetSidNoProfiles|ind|ind|ind|ind|getSid|0|NW_getDBInfo|ind|ind|ind|ind|db|0|NW_HDB_getDBInfo|ind|ind|ind|ind|hdb_dbinfo|0|getDBInfo was executed with status ERROR (Last error reported by the step: Caught ESAPinstException in module call: Validator of step '|NW_ABAP_OneHost|ind|ind|ind|ind|0|0|NW_Onehost_System|ind|ind|ind|ind|onehost|0|NW_GetSidNoProfiles|ind|ind|ind|ind|getSid|0|NW_getDBInfo|ind|ind|ind|ind|db|0|NW_HDB_getDBInfo|ind|ind|ind|ind|hdb_dbinfo|0|getDBInfo' reported an error:
Start SAPinst in interactive mode to solve this problem).

I am sharing the binary details of both S4HANA and HANADB below. S4 binary details:

[root@vm-techmsapapp hana]# ls s4app-1909/
igsexe_9-80003187.sar              S4CORE104_INST_EXPORT_13.zip  S4CORE104_INST_EXPORT_19.zip  S4CORE104_INST_EXPORT_24.zip  S4CORE104_INST_EXPORT_6.zip  SAPEXEDB_27-80004392.SAR
igshelper_17-10010245.sar          S4CORE104_INST_EXPORT_14.zip  S4CORE104_INST_EXPORT_1.zip   S4CORE104_INST_EXPORT_25.zip  S4CORE104_INST_EXPORT_7.zip  SAPHOSTAGENT58_58-80004822.SAR
IMDB_CLIENT20_015_17-80002082.SAR  S4CORE104_INST_EXPORT_15.zip  S4CORE104_INST_EXPORT_20.zip  S4CORE104_INST_EXPORT_2.zip   S4CORE104_INST_EXPORT_8.zip  SWPM20SP13_2-80003424.SAR
S4CORE104_INST_EXPORT_10.zip       S4CORE104_INST_EXPORT_16.zip  S4CORE104_INST_EXPORT_21.zip  S4CORE104_INST_EXPORT_3.zip   S4CORE104_INST_EXPORT_9.zip
S4CORE104_INST_EXPORT_11.zip       S4CORE104_INST_EXPORT_17.zip  S4CORE104_INST_EXPORT_22.zip  S4CORE104_INST_EXPORT_4.zip   SAPCAR_1115-70006178.EXE
S4CORE104_INST_EXPORT_12.zip       S4CORE104_INST_EXPORT_18.zip  S4CORE104_INST_EXPORT_23.zip  S4CORE104_INST_EXPORT_5.zip   SAPEXE_27-80004393.SAR
[root@vm-techmsapapp hana]# 

HANA binary details:

[root@vm-techmsapdb hana]# ls hanadb-orig/
IMDB_CLIENT20_006_64-80002082.SAR  IMDB_SERVER20_024_10-80002031.SAR  SAPCAR_1115-70006178.EXE  SAPHOSTAGENT58_58-80004822.SAR
[root@vm-techmsapdb hana]# 

DB_SL_Logfile.log output from APP VM.

[root@vm-techmsapapp tmp]# cat HDB_SL_Logfile.log 
Fri Jan 06 09:06:54 UTC 2023 | com.sap.hdb.core.main.cmd.HdbCmdMain | Start new command section
Fri Jan 06 09:06:54 UTC 2023 | com.sap.hdb.core.main.cmd.HdbCmdMain | Version of com.sap.hdb.core.jar | Changelist: 206558 | Release: lmts_026_REL | API-Version: 00
Fri Jan 06 09:06:54 UTC 2023 | com.sap.hdb.core.main.cmd.HdbCmdMain | Version of com.sap.hdb.sl.lib.jar | Changelist: 208889 | Release: lmts_026_REL | API-Version: 35
Fri Jan 06 09:06:54 UTC 2023 | com.sap.hdb.sl.lib.connection.sql.JdbcDriver | URI: file:/tmp/sapinst_instdir/S4HANA1909/CORE/HDB/INSTALL/STD/ABAP/ngdbc.jar
Fri Jan 06 09:06:54 UTC 2023 | com.sap.hdb.sl.lib.connection.sql.JdbcConnection | Instance is a multiple-container system.
Fri Jan 06 09:06:54 UTC 2023 | com.sap.hdb.sl.lib.connection.sql.JdbcConnection | Start new connection with connect URL: jdbc:sap://techmsapdb-dns.eastus.cloudapp.azure.com:30013?databaseName=H01 connect user: SYSTEM
Fri Jan 06 09:06:54 UTC 2023 | com.sap.hdb.sl.lib.user.password.HdbPassword | Configured password_layout is: A1a, minimum password length: 8
Fri Jan 06 09:06:54 UTC 2023 | com.sap.hdb.core.main.cmd.HdbCmdMain | Name of HdbCmdClazz: class com.sap.hdb.sl.lib.utils.cmd.clazz.IsMultiDB
Fri Jan 06 09:06:54 UTC 2023 | com.sap.hdb.core.main.cmd.HdbCmdMain | End of HdbCmdClazz section: class com.sap.hdb.sl.lib.utils.cmd.clazz.IsMultiDB
Fri Jan 06 09:06:54 UTC 2023 | com.sap.hdb.sl.lib.connection.sql.JdbcConnection | Closing connection: jdbc:sap://techmsapdb-dns.eastus.cloudapp.azure.com:30013?databaseName=H01 Connect user: SYSTEM
Fri Jan 06 09:06:54 UTC 2023 | com.sap.hdb.core.main.cmd.HdbCmdMain | *************************************************************
[root@vm-techmsapapp tmp]# 

/etc/hosts details: HANA DB:

[root@vm-techmsapdb hana]# cat /etc/hosts
127.0.0.1   localhost localhost.localdomain localhost4 localhost4.localdomain4
::1         localhost localhost.localdomain localhost6 localhost6.localdomain6
#vm-techmsapdb.internal.cloudapp.net 10.0.1.6
10.0.1.6 vm-techmsapdb.internal.cloudapp.net    vm-techmsapdb.poc.cloud vm-techmsapdb   techmsapdb-dns.eastus.cloudapp.azure.com
127.0.0.1       SLANALYTICSFTP.wdf.sap.corp
10.0.1.7        vm-techmsapapp.poc.cloud        vm-techmsapapp techmsapapp-dns.eastus.cloudapp.azure.com
[root@vm-techmsapdb hana]# 

S4HANA APP:

[root@vm-techmsapapp hana]# cat /etc/hosts
127.0.0.1   localhost localhost.localdomain localhost4 localhost4.localdomain4
::1         localhost localhost.localdomain localhost6 localhost6.localdomain6
10.0.1.7        vm-techmsapapp.poc.cloud        vm-techmsapapp techmsapapp-dns.eastus.cloudapp.azure.com
10.0.1.6        vm-techmsapdb.poc.cloud vm-techmsapdb   techmsapdb-dns.eastus.cloudapp.azure.com
[root@vm-techmsapapp hana]# 

Please let me know what further investigation I should perform.

arubasu commented 1 year ago

Issue was with the HANA DB version.

Screenshot 2023-01-06 at 15 23 00

This issue is fixed. Thanks :)

sean-freeman commented 1 year ago

@arubasu Glad to see it is fixed, although a little annoyed that I will have to update my own notes about getDBInfo errors in SAP SWPM may be caused by the response of the DB Info and not just a refused connection

Unfortunately SAP SWPM Unattended error messages are frequently misleading, and as you have done - require running with the GUI to see the message. Although it is possible this error text might be visible in sapinst_dev.log instead.