{"action":"created","issue":{"url":"https://api.github.com/repos/IBM-Security/ibmsecurity/issues/56","repository_url":"https://api.github.com/repos/IBM-Security/ibmsecurity","labels_url":"https://api.github.com/repos/IBM-Security/ibmsecurity/issues/56/labels{/name}","comments_url":"https://api.github.com/repos/IBM-Security/ibmsecurity/issues/56/comments","events_url":"https://api.github.com/repos/IBM-Security/ibmsecurity/issues/56/events","html_url":"https://github.com/IBM-Security/ibmsecurity/issues/56","id":292128654,"node_id":"MDU6SXNzdWUyOTIxMjg2NTQ=","number":56,"title":"WGAWA0389E on export_cluster_sign call","user":{"login":"sygilber","id":29456610,"node_id":"MDQ6VXNlcjI5NDU2NjEw","avatar_url":"https://avatars3.githubusercontent.com/u/29456610?v=4","gravatar_id":"","url":"https://api.github.com/users/sygilber","html_url":"https://github.com/sygilber","followers_url":"https://api.github.com/users/sygilber/followers","following_url":"https://api.github.com/users/sygilber/following{/other_user}","gists_url":"https://api.github.com/users/sygilber/gists{/gist_id}","starred_url":"https://api.github.com/users/sygilber/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sygilber/subscriptions","organizations_url":"https://api.github.com/users/sygilber/orgs","repos_url":"https://api.github.com/users/sygilber/repos","events_url":"https://api.github.com/users/sygilber/events{/privacy}","received_events_url":"https://api.github.com/users/sygilber/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":3,"created_at":"2018-01-27T15:24:16Z","updated_at":"2018-06-08T21:21:40Z","closed_at":"2018-06-08T21:21:40Z","author_association":"CONTRIBUTOR","body":"Hi,\r\n\r\nFor now, I am unsure if the issue is to be reported against the role or the ibmsecurity module, we can determine that later.\r\n\r\nWhile testing and re-building from 9.04 factory image this week (using the 'lab' branch) on 2 different set of environments, we obtained a behavior I could not see before.\r\n\r\nThis is our playbook sequence which is pretty classic when initializing the policy server Appliance and promoting it as the primary cluster role:\r\n\r\n    - role: config_policyserver\r\n    - role: set_cluster_config\r\n    - role: set_runtime_replication\r\n    - role: export_cluster_sign\r\n\r\nThis is what happened:\r\n\r\n    - role: config_policyserver (OK)\r\n    - role: set_cluster_config (OK)\r\n    - role: set_runtime_replication (OK)\r\n    - role: export_cluster_sign (ERROR)\r\n    \r\n    *********  WGAWA0389E *********\r\n    \r\n    I then logged-in the LMI, discovered there were pending changes, commited them, waited to LMI to complete restart sequence, and relaunched the playbook and then export_cluster_sign role succeeded.\r\n    \r\n    - role: export_cluster_sign (OK)\r\n\r\nThe detailled trace:\r\n\r\n> TASK [config_policyserver : Snapshot Appliance Before Configuring Policy Server] ***************************************************************************************\r\n> changed: [someserver]\r\n> \r\n> TASK [config_policyserver : Configure Local Policy Server using Embedded LDAP] *****************************************************************************************\r\n> changed: [someserver]\r\n> \r\n> TASK [config_policyserver : Update Connection Inactivity to be less than infinity] *************************************************************************************\r\n> changed: [someserver]\r\n> \r\n> TASK [set_cluster_config : Snapshot Appliance Before Configuring Cluster] **********************************************************************************************\r\n> changed: [someserver]\r\n> \r\n> TASK [set_cluster_config : Set Cluster Configuration] ******************************************************************************************************************\r\n> changed: [someserver]\r\n> \r\n> RUNNING HANDLER [start_config : Commit Changes] ************************************************************************************************************************\r\n> skipping: [someserver]\r\n> \r\n> RUNNING HANDLER [start_config : Restart Web Runtime] *******************************************************************************************************************\r\n> skipping: [someserver]\r\n> \r\n> TASK [set_runtime_replication : Set Web Runtime Replication Status in a cluster] ***************************************************************************************\r\n> changed: [someserver]\r\n> \r\n> TASK [export_cluster_sign : Export cluster signature from Primary appliance] *******************************************************************************************\r\n> fatal: [someserver]: FAILED! => {\"changed\": false, \"failed\": true, \"log\": \"[2018-01-26 17:22:15,391] [PID:56043 TID:139764347021120] [DEBUG] [ibmsecurity.user.applianceuser] [__init__():9] Creating a user\\n[2018-01-26 17:22:15,392] [PID:56043 TID:139764347021120] [DEBUG] [ibmsecurity.user.user] [__init__():8] Creating a user\\n[2018-01-26 17:22:15,392] [PID:56043 TID:139764347021120] [DEBUG] [ibmsecurity.appliance.isamappliance] [__init__():13] Creating an ISAMAppliance\\n[2018-01-26 17:22:15,392] [PID:56043 TID:139764347021120] [DEBUG] [ibmsecurity.appliance.ibmappliance] [__init__():46] Creating an IBMAppliance\\n[2018-01-26 17:22:15,393] [PID:56043 TID:139764347021120] [DEBUG] [ibmsecurity.appliance.ibmappliance] [_log_request():575] Request: GET /core/sys/versions desc=Retrieving version\\n[2018-01-26 17:22:15,393] [PID:56043 TID:139764347021120] [INFO] [ibmsecurity.appliance.ibmappliance] [_log_desc():30] *** Retrieving version ***\\n[2018-01-26 17:22:15,393] [PID:56043 TID:139764347021120] [DEBUG] [ibmsecurity.appliance.ibmappliance] [_process_warnings():92] Checking for minimum version: None.\\n[2018-01-26 17:22:15,393] [PID:56043 TID:139764347021120] [DEBUG] [ibmsecurity.appliance.ibmappliance] [_process_warnings():108] Checking for one of required modules: None.\\n[2018-01-26 17:22:15,393] [PID:56043 TID:139764347021120] [DEBUG] [ibmsecurity.appliance.ibmappliance] [_process_warnings():125] Warnings: []\\n[2018-01-26 17:22:15,393] [PID:56043 TID:139764347021120] [DEBUG] [ibmsecurity.appliance.ibmappliance] [_invoke_request():301] Headers are: {'Content-type': 'application/json', 'Accept': 'application/json'}\\n[2018-01-26 17:22:15,393] [PID:56043 TID:139764347021120] [DEBUG] [ibmsecurity.appliance.ibmappliance] [_invoke_request():306] Input Data: {}\\n[2018-01-26 17:22:15,393] [PID:56043 TID:139764347021120] [DEBUG] [ibmsecurity.appliance.ibmappliance] [_suppress_ssl_warning():35] Suppressing SSL Warnings.\\n[2018-01-26 17:22:15,393] [PID:56043 TID:139764347021120] [DEBUG] [ibmsecurity.appliance.ibmappliance] [_url():24] Issuing request to: https://someserver:443/core/sys/versions\\n[2018-01-26 17:22:15,395] [PID:56043 TID:139764347021120] [DEBUG] [urllib3.connectionpool] [_new_conn():824] Starting new HTTPS connection (1): someserver\\n[2018-01-26 17:22:15,741] [PID:56043 TID:139764347021120] [DEBUG] [urllib3.connectionpool] [_make_request():396] https://someserver:443 \\\"GET /core/sys/versions HTTP/1.1\\\" 200 None\\n[2018-01-26 17:22:15,745] [PID:56043 TID:139764347021120] [DEBUG] [ibmsecurity.appliance.ibmappliance] [_process_response():63] Status Code: 200\\n[2018-01-26 17:22:15,745] [PID:56043 TID:139764347021120] [DEBUG] [ibmsecurity.appliance.ibmappliance] [_process_response():65] Text: {\\\"firmware_label\\\":\\\"isam_9.0.4.0_20171201-2325\\\",\\\"firmware_build\\\":\\\"20171201-2325\\\",\\\"firmware_version\\\":\\\"9.0.4.0\\\",\\\"product_description\\\":\\\"IBM Security Access Manager\\\",\\\"deployment_model\\\":\\\"Appliance\\\",\\\"product_name\\\":\\\"isam\\\"}\\n[2018-01-26 17:22:15,745] [PID:56043 TID:139764347021120] [DEBUG] [ibmsecurity.appliance.ibmappliance] [_log_response():579] Response: 0\\n[2018-01-26 17:22:15,745] [PID:56043 TID:139764347021120] [DEBUG] [ibmsecurity.appliance.ibmappliance] [_log_request():575] Request: GET /setup_complete desc=Get Setup Complete Settings\\n[2018-01-26 17:22:15,746] [PID:56043 TID:139764347021120] [INFO] [ibmsecurity.appliance.ibmappliance] [_log_desc():30] *** Get Setup Complete Settings ***\\n[2018-01-26 17:22:15,746] [PID:56043 TID:139764347021120] [DEBUG] [ibmsecurity.appliance.ibmappliance] [_process_warnings():92] Checking for minimum version: None.\\n[2018-01-26 17:22:15,746] [PID:56043 TID:139764347021120] [DEBUG] [ibmsecurity.appliance.ibmappliance] [_process_warnings():108] Checking for one of required modules: None.\\n[2018-01-26 17:22:15,746] [PID:56043 TID:139764347021120] [DEBUG] [ibmsecurity.appliance.ibmappliance] [_process_warnings():125] Warnings: []\\n[2018-01-26 17:22:15,746] [PID:56043 TID:139764347021120] [DEBUG] [ibmsecurity.appliance.ibmappliance] [_invoke_request():301] Headers are: {'Content-type': 'application/json', 'Accept': 'application/json'}\\n[2018-01-26 17:22:15,746] [PID:56043 TID:139764347021120] [DEBUG] [ibmsecurity.appliance.ibmappliance] [_invoke_request():306] Input Data: {}\\n[2018-01-26 17:22:15,746] [PID:56043 TID:139764347021120] [DEBUG] [ibmsecurity.appliance.ibmappliance] [_suppress_ssl_warning():35] Suppressing SSL Warnings.\\n[2018-01-26 17:22:15,746] [PID:56043 TID:139764347021120] [DEBUG] [ibmsecurity.appliance.ibmappliance] [_url():24] Issuing request to: https://someserver:443/setup_complete\\n[2018-01-26 17:22:15,747] [PID:56043 TID:139764347021120] [DEBUG] [urllib3.connectionpool] [_new_conn():824] Starting new HTTPS connection (1): someserver\\n[2018-01-26 17:22:16,094] [PID:56043 TID:139764347021120] [DEBUG] [urllib3.connectionpool] [_make_request():396] https://someserver:443 \\\"GET /setup_complete HTTP/1.1\\\" 200 21\\n[2018-01-26 17:22:16,097] [PID:56043 TID:139764347021120] [DEBUG] [ibmsecurity.appliance.ibmappliance] [_process_response():63] Status Code: 200\\n[2018-01-26 17:22:16,097] [PID:56043 TID:139764347021120] [DEBUG] [ibmsecurity.appliance.ibmappliance] [_process_response():65] Text: { \\\"configured\\\": true}\\n[2018-01-26 17:22:16,097] [PID:56043 TID:139764347021120] [DEBUG] [ibmsecurity.appliance.ibmappliance] [_log_response():579] Response: 0\\n[2018-01-26 17:22:16,098] [PID:56043 TID:139764347021120] [DEBUG] [ibmsecurity.appliance.ibmappliance] [_log_request():575] Request: GET /isam/capabilities/v1 desc=Retrieving activations\\n[2018-01-26 17:22:16,098] [PID:56043 TID:139764347021120] [INFO] [ibmsecurity.appliance.ibmappliance] [_log_desc():30] *** Retrieving activations ***\\n[2018-01-26 17:22:16,098] [PID:56043 TID:139764347021120] [DEBUG] [ibmsecurity.appliance.ibmappliance] [_process_warnings():92] Checking for minimum version: None.\\n[2018-01-26 17:22:16,098] [PID:56043 TID:139764347021120] [DEBUG] [ibmsecurity.appliance.ibmappliance] [_process_warnings():108] Checking for one of required modules: None.\\n[2018-01-26 17:22:16,098] [PID:56043 TID:139764347021120] [DEBUG] [ibmsecurity.appliance.ibmappliance] [_process_warnings():125] Warnings: []\\n[2018-01-26 17:22:16,098] [PID:56043 TID:139764347021120] [DEBUG] [ibmsecurity.appliance.ibmappliance] [_invoke_request():301] Headers are: {'Content-type': 'application/json', 'Accept': 'application/json'}\\n[2018-01-26 17:22:16,098] [PID:56043 TID:139764347021120] [DEBUG] [ibmsecurity.appliance.ibmappliance] [_invoke_request():306] Input Data: {}\\n[2018-01-26 17:22:16,098] [PID:56043 TID:139764347021120] [DEBUG] [ibmsecurity.appliance.ibmappliance] [_suppress_ssl_warning():35] Suppressing SSL Warnings.\\n[2018-01-26 17:22:16,098] [PID:56043 TID:139764347021120] [DEBUG] [ibmsecurity.appliance.ibmappliance] [_url():24] Issuing request to: https://someserver:443/isam/capabilities/v1\\n[2018-01-26 17:22:16,099] [PID:56043 TID:139764347021120] [DEBUG] [urllib3.connectionpool] [_new_conn():824] Starting new HTTPS connection (1): someserver\\n[2018-01-26 17:22:16,455] [PID:56043 TID:139764347021120] [DEBUG] [urllib3.connectionpool] [_make_request():396] https://someserver:443 \\\"GET /isam/capabilities/v1 HTTP/1.1\\\" 200 None\\n[2018-01-26 17:22:16,459] [PID:56043 TID:139764347021120] [DEBUG] [ibmsecurity.appliance.ibmappliance] [_process_response():63] Status Code: 200\\n[2018-01-26 17:22:16,459] [PID:56043 TID:139764347021120] [DEBUG] [ibmsecurity.appliance.ibmappliance] [_process_response():65] Text: [{\\\"name\\\":\\\"ISAM Base Appliance\\\",\\\"description\\\":\\\"IBM Security Access Manager Base Appliance\\\",\\\"id\\\":\\\"wga\\\",\\\"enabled\\\":\\\"True\\\"}, {\\\"name\\\":\\\"ISAM Advanced Access Control\\\",\\\"description\\\":\\\"IBM Security Access Manager Advanced Access Control\\\",\\\"id\\\":\\\"mga\\\",\\\"enabled\\\":\\\"True\\\"}, {\\\"name\\\":\\\"ISAM Federation\\\",\\\"description\\\":\\\"IBM Security Access Manager Federation\\\",\\\"id\\\":\\\"federation\\\",\\\"enabled\\\":\\\"True\\\"}]\\n[2018-01-26 17:22:16,460] [PID:56043 TID:139764347021120] [DEBUG] [ibmsecurity.appliance.ibmappliance] [_log_response():579] Response: 0\\n[2018-01-26 17:22:16,460] [PID:56043 TID:139764347021120] [INFO] [ibmsecurity.appliance.ibmappliance] [_log_desc():30] *** Retrieve the cluster signature file ***\\n[2018-01-26 17:22:16,460] [PID:56043 TID:139764347021120] [DEBUG] [ibmsecurity.appliance.ibmappliance] [_process_warnings():92] Checking for minimum version: None.\\n[2018-01-26 17:22:16,461] [PID:56043 TID:139764347021120] [DEBUG] [ibmsecurity.appliance.ibmappliance] [_process_warnings():108] Checking for one of required modules: None.\\n[2018-01-26 17:22:16,461] [PID:56043 TID:139764347021120] [DEBUG] [ibmsecurity.appliance.ibmappliance] [_process_warnings():125] Warnings: []\\n[2018-01-26 17:22:16,461] [PID:56043 TID:139764347021120] [DEBUG] [ibmsecurity.appliance.ibmappliance] [invoke_get_file():242] Headers are: {'Accept': 'application/json,application/octet-stream'}\\n[2018-01-26 17:22:16,461] [PID:56043 TID:139764347021120] [DEBUG] [ibmsecurity.appliance.ibmappliance] [_suppress_ssl_warning():35] Suppressing SSL Warnings.\\n[2018-01-26 17:22:16,461] [PID:56043 TID:139764347021120] [DEBUG] [ibmsecurity.appliance.ibmappliance] [_url():24] Issuing request to: https://someserver:443/isam/cluster/signature/v1\\n[2018-01-26 17:22:16,462] [PID:56043 TID:139764347021120] [DEBUG] [urllib3.connectionpool] [_new_conn():824] Starting new HTTPS connection (1): someserver\\n[2018-01-26 17:22:16,933] [PID:56043 TID:139764347021120] [DEBUG] [urllib3.connectionpool] [_make_request():396] https://someserver:443 \\\"GET /isam/cluster/signature/v1 HTTP/1.1\\\" 500 None\\n[2018-01-26 17:22:16,935] [PID:56043 TID:139764347021120] [ERROR] [ibmsecurity.appliance.ibmappliance] [invoke_get_file():251]   Request failed: \\n[2018-01-26 17:22:16,935] [PID:56043 TID:139764347021120] [ERROR] [ibmsecurity.appliance.ibmappliance] [invoke_get_file():252]      status code: 500\\n[2018-01-26 17:22:16,936] [PID:56043 TID:139764347021120] [ERROR] [ibmsecurity.appliance.ibmappliance] [invoke_get_file():254]      text: {\\\"message\\\":\\\"Error: WGAWA0389E   A cluster must be defined before this request can be processed.  To define a cluster the primary master must be set to something other than 127.0.0.1.\\\"}\\n\", \"msg\": \"('HTTP Return code: 500', u'{\\\"message\\\":\\\"Error: WGAWA0389E   A cluster must be defined before this request can be processed.  To define a cluster the primary master must be set to something other than 127.0.0.1.\\\"}')\", \"name\": \"ibmsecurity.isam.base.cluster.signature.export\"}\r\n> \r\n> \r\n> TASK [export_cluster_sign : Export cluster signature from Primary appliance] *******************************************************************************************\r\n> fatal: [someserver]: FAILED! => {\"changed\": false, \"failed\": true, \"log\": \r\n\r\nAs one can know, it is premature to invoke the role 'export_cluster_sign' (or any other role of that sort) if the previous cluster changes are not commited.\r\n\r\nGoing up a bit the stack of message, we can clearly see that roles that executed (config_policyserver, set_cluster_config) did raise the status \"changed\", but the flushing the handlers did not help as their execution was skipped:\r\n\r\n> RUNNING HANDLER [start_config : Commit Changes] ************************************************************************************************************************\r\n> skipping: [someserver]\r\n> \r\n> RUNNING HANDLER [start_config : Restart Web Runtime] *******************************************************************************************************************\r\n> skipping: [someserver]\r\n\r\nSo I think we can narrow our investiguation as to why the handlers (Commit Changes and Restart Web Runtime) are skipped.\r\n\r\nWhat happens after this point is irrelevant as until changes are commited and Web Runtime recycled, other task/play are very likely to fail.\r\n\r\nAs far as I recalled, when we were using the \"master\" branch of ibmsecurity, this behavior did not show up on 9.04 for that particular sequence of roles."},"comment":{"url":"https://api.github.com/repos/IBM-Security/ibmsecurity/issues/comments/395893818","html_url":"https://github.com/IBM-Security/ibmsecurity/issues/56#issuecomment-395893818","issue_url":"https://api.github.com/repos/IBM-Security/ibmsecurity/issues/56","id":395893818,"node_id":"MDEyOklzc3VlQ29tbWVudDM5NTg5MzgxOA==","user":{"login":"sygilber","id":29456610,"node_id":"MDQ6VXNlcjI5NDU2NjEw","avatar_url":"https://avatars3.githubusercontent.com/u/29456610?v=4","gravatar_id":"","url":"https://api.github.com/users/sygilber","html_url":"https://github.com/sygilber","followers_url":"https://api.github.com/users/sygilber/followers","following_url":"https://api.github.com/users/sygilber/following{/other_user}","gists_url":"https://api.github.com/users/sygilber/gists{/gist_id}","starred_url":"https://api.github.com/users/sygilber/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sygilber/subscriptions","organizations_url":"https://api.github.com/users/sygilber/orgs","repos_url":"https://api.github.com/users/sygilber/repos","events_url":"https://api.github.com/users/sygilber/events{/privacy}","received_events_url":"https://api.github.com/users/sygilber/received_events","type":"User","site_admin":false},"created_at":"2018-06-08T21:21:40Z","updated_at":"2018-06-08T21:21:40Z","author_association":"CONTRIBUTOR","body":"Closing this issue for now.\r\n\r\nWill see if in our next build of ISAM this issue will resurface."}}
{"actor":{"display_login":"sygilber"}}