Closed rgentyala closed 2 years ago
Edited original issue text for readability of the issue, and to address best practice of raising GH Issues.
Terraform Template identified from text: sap_s4hana_single_node_install/ibmcloud_vs
Error identified from text:
The database connection with database user SYSTEM cannot be set up. Check that the database is online and the password of user SYSTEM is correct
This error usually appears on SWPM Unattended Mode when the wrong Database Schema name for SAP (inside the SAP HANA MDC Tenant) has been provided, so a connection cannot be established to perform the DB Restore during System Copy. To see this error with an installation from SAP Maintenance Planner is unusual.
I will re-run with the same Terraform Input Variables provided above, to see if I have the same result.
Hello Sean - Thank you for helping me on my issue. I will wait for your confirmation, try to destroy my deployment and recreate the instances once again. If I can preserve Bastion host while destroying and perform only remaining part of the deployment which is S/4 deployment that really saves my time. I will wait for your confirmation.
list
type, was given as string
stype (resource_tags)number
type, was given as string
type (bastion_ssh_port, disk_volume_capacity_software)Sample data entry in Terraform Templates:
resource_tags = ["sap", "saps4hana"]
bastion_ssh_port = 50222
disk_volume_capacity_software = 304
sap_software_download_directory = "/software"
Values given in this GH Issue:
resource_tags = "mytag2"
bastion_ssh_port = "65500"
disk_volume_capacity_software = "200"
sap_software_download_directory = "mysoftware"
/root/mysoftware
) incorrectly, but volume mounted OKmysoftware
onlyi.e. Terraform variable sap_software_download_directory = "mysoftware"
module.run_ansible_sap_s4hana_install_maintplan["s4h01"].null_resource.ansible_exec[0] (local-exec):
TASK [community.sap_install.sap_install_media_detect : SAP Media Organize - SAP HANA - Extracting IMDB_CLIENT20_013_13-80002082.SAR] ***
fatal: [10.241.0.4]: FAILED! =>
{
"changed": false,
"cmd": "mysoftware/sap_hana/SAPCAR_1115-70006178.EXE -R mysoftware/sap_hana/tmp -xvf mysoftware/sap_hana/IMDB_CLIENT20_013_13-80002082.SAR -manifest SIGNATURE.SMF",
"msg": "[Errno 2] No such file or directory: b'mysoftware/sap_hana/SAPCAR_1115-70006178.EXE': b'mysoftware/sap_hana/SAPCAR_1115-70006178.EXE'",
"rc": 2,
"stderr_lines": [],
"stdout_lines": []
}
/root/mysoftware
i.e. Terraform variable sap_software_download_directory = "/root/mysoftware"
module.run_ansible_sap_s4hana_install_maintplan["s4h01"].null_resource.ansible_exec[0] (local-exec):
TASK [community.sap_install.sap_hana_install : Install SAP HANA - SA1 00] ******
fatal: [10.241.0.4]: FAILED! =>
{
"changed": true,
"cmd": [
"./hdblcm",
"--configfile=/tmp/ansible.kdz652z5hanaconfig/configfile.cfg",
"-b"
],
"delta": "0:00:02.245110",
"end": "2022-06-22 09:19:12.958743",
"msg": "non-zero return code",
"rc": 1,
"start": "2022-06-22 09:19:10.713633",
"stderr_lines": [
"Running in batch mode",
" The following software installation files are missing execute permissions:",
" /root",
" Ensure that no permissions are changed by the umask when extracting or copying the folders."
],
"stdout_lines": [
"",
"",
"SAP HANA Lifecycle Management - SAP HANA Database 2.00.062.00.1650891137",
"************************************************************************",
"",
"",
"Scanning software locations...",
"Detected components:",
" SAP HANA Database (2.00.062.00.1650891137) in /root/mysoftware/sap_hana/extracted/SAP_HANA_DATABASE/server",
" SAP HANA Database Client (2.13.13.1650313242) in /root/mysoftware/sap_hana/extracted/SAP_HANA_CLIENT/client",
"Log file written to '/var/tmp/hdb_SA1_hdblcm_install_2022-06-22_09.19.10/hdblcm.log' on host 's4h01'."
]
}
I performed another deployment to correct for the software download directory being an incomplete path; as above comment describes.
Unfortunately after re-deployment, I was unable to replicate the issue. The Ansible execution triggered by Terraform, took 1h17m47s to deploy SAP S/4HANA from SAP Maintenance Planner.
Approximate breakdown:
module.run_ansible_sap_s4hana_install_maintplan["rjs4h01"].null_resource.ansible_exec[0] (local-exec):
FAILED - RETRYING: [10.241.0.4]: SAP SWPM - Wait for sapinst process to exit, poll every 60 seconds (981 retries left).
module.run_ansible_sap_s4hana_install_maintplan["rjs4h01"].null_resource.ansible_exec[0]:
Still creating... [1h17m20s elapsed]
module.run_ansible_sap_s4hana_install_maintplan["rjs4h01"].null_resource.ansible_exec[0] (local-exec):
ok: [10.241.0.4]
TASK [community.sap_install.sap_swpm : SAP SWPM - Verify if sapinst process finished successfully] ***
changed: [10.241.0.4]
TASK [community.sap_install.sap_swpm : SAP SWPM - Find last installation location] ***
changed: [10.241.0.4]
TASK [community.sap_install.sap_swpm : SAP SWPM - Verify if SWPM success file exists] ***
ok: [10.241.0.4]
TASK [community.sap_install.sap_swpm : SAP SWPM - Get success file] ************
changed: [10.241.0.4]
TASK [community.sap_install.sap_swpm : SAP SWPM - Display installation finished from success file] ***
ok: [10.241.0.4] => {
"msg": [
"NW_ABAP_OneHost|ind|ind|ind|ind finished 22_06_2022_17_47_43"
]
}
TASK [community.sap_install.sap_swpm : SAP SWPM Post Install - Set s4dadm to no expire] ***
changed: [10.241.0.4]
TASK [community.sap_install.sap_swpm : SAP SWPM Post Install - Firewall Setup] ***
skipping: [10.241.0.4]
TASK [community.sap_install.sap_swpm : SAP SWPM Deployment - Finished] *********
ok: [10.241.0.4] => {
"msg": [
" SAP SWPM deployment successfully completed ",
" ",
" SAP Product - NW_ABAP_OneHost:S4HANA2020.CORE.HDB.ABAP ",
" SID - S4D ",
" Primary Instance - 01 ",
" Host - s4h01 ",
" FQDN - s4h01.mydomainlocal.com ",
" IP - 10.241.0.4 ",
" Master Password - abcd@Abcde123 ",
" DDIC 000 Password - abcd@Abcde123 "
]
}
As stated originally, error The database connection with database user SYSTEM cannot be set up. Check that the database is online and the password of user SYSTEM is correct
is usually witnessed on SWPM Unattended Mode when the wrong Database Schema name for SAP (inside the SAP HANA MDC Tenant) has been provided, so a connection cannot be established to perform the DB Restore during System Copy.
To see this error with an installation from SAP Maintenance Planner is unusual. Given I cannot replicate this issue, I have to conclude this as an uncharacteristic error with SAP SWPM in this instance. Closing the issue.
I will correct variable definitions properly to reflect declaration standards, however it helps if we give default value and comments that can help improve the standard and these Hints either can be in readme.md or input.auto.tfvars.tf file to help.
I have a question regarding keeping mysoftware under /root that is not recommended. Can we have a way of keeping mysoftware in its own mount point?
I will try to work on your recommendations and come back to you with more comments.
This error was seen during SAP S/4HANA OneHost install with SAP Maintenance Planner.
I used the following Terraform variables:
==========================================================================================
Below is the error:
=========================================================================================
Maintainer: do not raise issues within an issue. Ignoring these for reasons below
I have few other observations that needs a closer look at though it is not related to my present issue that I am reporting as these limitations cause restrictions.Maintainer: no data provided, cannot debug
Maintainer: Terraform Templates are free to amend, for click-run a design principle is to always leverage a created Bastion even when re-using an existing network, to ensure security and reduce unpredictable results
Maintainer: please see existing Terraform documentation and blogs on Google, this can be achieved in two ways primarily (1) comment/remove from Terraform Template and terraform apply which will remove those resources or (2) use -target combined with terraform destroy see doc https://learn.hashicorp.com/tutorials/terraform/resource-targeting.