<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: cme service stops due to api error in API / CLI Discussion</title>
    <link>https://community.checkpoint.com/t5/API-CLI-Discussion/cme-service-stops-due-to-api-error/m-p/117650#M5823</link>
    <description>&lt;P&gt;Hi Richard,&lt;/P&gt;&lt;P&gt;I had a very similar issue and I found out it was because the SSL Web Port for the management server was different to what the script was trying to connect to the Mgmt CLI on (It was trying on 443 but the port was set to 4434).&lt;/P&gt;&lt;P&gt;To work around this I changed the Web Port to 443, but I am sure there must be a way to modify the CME script to tell it to connect on the custom port. I am going to look into this and I will let you know if I figure it out.&lt;/P&gt;&lt;P&gt;Hopefully this helps you.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Aiden&lt;/P&gt;</description>
    <pubDate>Tue, 04 May 2021 15:28:40 GMT</pubDate>
    <dc:creator>Aiden_Dale</dc:creator>
    <dc:date>2021-05-04T15:28:40Z</dc:date>
    <item>
      <title>cme service stops due to api error</title>
      <link>https://community.checkpoint.com/t5/API-CLI-Discussion/cme-service-stops-due-to-api-error/m-p/117004#M5815</link>
      <description>&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;We are having problems with cme for managing Azure Scale Sets on R80.40 . The cme service keeps stopping. We only noticed then one of the Scale-Sets gateways crashed. It was deleted, a new one came up but it never deployed in the Check Point manager. If I start the cme service and run service cme test, cme appears to run through and read the Azure components, including the new gateway that we can't bring into management. But the test fails on an api error:&lt;/P&gt;&lt;P&gt;Testing management configuration...&lt;BR /&gt;Testing management connectivity...&lt;BR /&gt;Traceback (most recent call last):&lt;BR /&gt;File "/opt/CPcme/cp_handlers/mgmt_api_handler.py", line 85, in __call__&lt;BR /&gt;payload=body)&lt;BR /&gt;File "/opt/CPcme/cp_handlers/cpapi/mgmt_api.py", line 459, in api_query&lt;BR /&gt;[container_key], payload=payload):&lt;BR /&gt;File "/opt/CPcme/cp_handlers/cpapi/mgmt_api.py", line 537, in gen_api_query&lt;BR /&gt;"to"] # number of objects we got so far&lt;BR /&gt;KeyError: 'to'&lt;/P&gt;&lt;P&gt;During handling of the above exception, another exception occurred:&lt;/P&gt;&lt;P&gt;Traceback (most recent call last):&lt;BR /&gt;File "/opt/CPcme/cp_handlers/mgmt_api_handler.py", line 186, in login&lt;BR /&gt;self.take_over_old_sessions(session_uid)&lt;BR /&gt;File "/opt/CPcme/cp_handlers/mgmt_api_handler.py", line 263, in take_over_old_sessions&lt;BR /&gt;aggregate='objects'):&lt;BR /&gt;File "/opt/CPcme/cp_handlers/mgmt_api_handler.py", line 92, in __call__&lt;BR /&gt;CMEExceptionCodes.MGMT_API)&lt;BR /&gt;cme_exceptions.cme_exceptions.ManagementApiException: Error Code: Management API error&lt;/P&gt;&lt;P&gt;API call: show-sessions failed with an exception: 'to'.&lt;/P&gt;&lt;P&gt;During handling of the above exception, another exception occurred:&lt;/P&gt;&lt;P&gt;Traceback (most recent call last):&lt;BR /&gt;File "/opt/CPcme/service/cme_service.py", line 700, in test&lt;BR /&gt;management('discard', {})&lt;BR /&gt;File "/opt/CPcme/cp_handlers/mgmt_handler.py", line 160, in __call__&lt;BR /&gt;silent=silent, version=version)&lt;BR /&gt;File "/opt/CPcme/cp_handlers/mgmt_api_handler.py", line 73, in __call__&lt;BR /&gt;self.re_login_if_needed()&lt;BR /&gt;File "/opt/CPcme/cp_handlers/mgmt_api_handler.py", line 216, in re_login_if_needed&lt;BR /&gt;self.login()&lt;BR /&gt;File "/opt/CPcme/cp_handlers/mgmt_api_handler.py", line 194, in login&lt;BR /&gt;CMEExceptionCodes.MGMT_API)&lt;BR /&gt;cme_exceptions.cme_exceptions.ManagementApiException: Error Code: Management API error&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Failed discard old sessions (1/5):&lt;BR /&gt;Error Code: Management API error&lt;/P&gt;&lt;P&gt;API call: show-sessions failed with an exception: 'to'.&lt;BR /&gt;called __exit__ with no sid&lt;BR /&gt;Failed&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;We are running latest build of AutoUpdater and CME build 141.&lt;/P&gt;</description>
      <pubDate>Tue, 27 Apr 2021 09:40:16 GMT</pubDate>
      <guid>https://community.checkpoint.com/t5/API-CLI-Discussion/cme-service-stops-due-to-api-error/m-p/117004#M5815</guid>
      <dc:creator>Richard_Cullum</dc:creator>
      <dc:date>2021-04-27T09:40:16Z</dc:date>
    </item>
    <item>
      <title>Re: cme service stops due to api error</title>
      <link>https://community.checkpoint.com/t5/API-CLI-Discussion/cme-service-stops-due-to-api-error/m-p/117650#M5823</link>
      <description>&lt;P&gt;Hi Richard,&lt;/P&gt;&lt;P&gt;I had a very similar issue and I found out it was because the SSL Web Port for the management server was different to what the script was trying to connect to the Mgmt CLI on (It was trying on 443 but the port was set to 4434).&lt;/P&gt;&lt;P&gt;To work around this I changed the Web Port to 443, but I am sure there must be a way to modify the CME script to tell it to connect on the custom port. I am going to look into this and I will let you know if I figure it out.&lt;/P&gt;&lt;P&gt;Hopefully this helps you.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Aiden&lt;/P&gt;</description>
      <pubDate>Tue, 04 May 2021 15:28:40 GMT</pubDate>
      <guid>https://community.checkpoint.com/t5/API-CLI-Discussion/cme-service-stops-due-to-api-error/m-p/117650#M5823</guid>
      <dc:creator>Aiden_Dale</dc:creator>
      <dc:date>2021-05-04T15:28:40Z</dc:date>
    </item>
  </channel>
</rss>

