<?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 socket.gaierror: [Errno 11001] getaddrinfo failed in ArcGIS API for Python Questions</title>
    <link>https://community.esri.com/t5/arcgis-api-for-python-questions/socket-gaierror-errno-11001-getaddrinfo-failed/m-p/1322927#M8959</link>
    <description>&lt;P&gt;&lt;SPAN&gt;Greetings,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;i want to overwrite feature service in portal. i followed this guide &lt;A href="https://developers.arcgis.com/python/samples/overwriting-feature-layers/" target="_blank"&gt;https://developers.arcgis.com/python/samples/overwriting-feature-layers/&lt;/A&gt;&amp;nbsp;but im getting an error at overwriting part.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="python"&gt;from arcgis.gis import GIS
from arcgis import features
import pandas as pd
import os
from arcgis.features import FeatureLayerCollection

portal_url = "https://myportalurl"
username = "login"
password = "pass"

gis = GIS(portal_url, username, password)

fileid = '9bfb22d38bee49af93ad56952f5a4cc3'

item = gis.content.get(fileid)

# item_props = {
#     "title": "Updated title",
#     "description": "Updated description"
# }
# item.update(
#     item_properties=item_props,
# )
# updating is not causing any problems

new_file_path = os.path.join( os.getcwd(), "uz_thermal_points.zip")

thermal_flayer_collection = FeatureLayerCollection.fromitem(item)

thermal_flayer_collection.manager.overwrite(new_file_path)&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;filename is the same as original published file. in the website, there is no error while overwriting features.&lt;BR /&gt;i got this error:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="python"&gt;Exception has occurred: ConnectionError
A connection error has occurred: HTTPSConnectionPool(host='esrisrv.uzspace.org', port=6443): Max retries exceeded with url: /arcgis/rest/services/Hosted/uz_thermal_points/FeatureServer/layers?f=json (Caused by NewConnectionError('&amp;lt;urllib3.connection.HTTPSConnection object at 0x0000022A5D6EDC10&amp;gt;: Failed to establish a new connection: [Errno 11001] getaddrinfo failed'))
socket.gaierror: [Errno 11001] getaddrinfo failed

During handling of the above exception, another exception occurred:

urllib3.exceptions.NewConnectionError: &amp;lt;urllib3.connection.HTTPSConnection object at 0x0000022A5D6EDC10&amp;gt;: Failed to establish a new connection: [Errno 11001] getaddrinfo failed

During handling of the above exception, another exception occurred:

urllib3.exceptions.MaxRetryError: HTTPSConnectionPool(host='esrisrv.uzspace.org', port=6443): Max retries exceeded with url: /arcgis/rest/services/Hosted/uz_thermal_points/FeatureServer/layers?f=json (Caused by NewConnectionError('&amp;lt;urllib3.connection.HTTPSConnection object at 0x0000022A5D6EDC10&amp;gt;: Failed to establish a new connection: [Errno 11001] getaddrinfo failed'))

During handling of the above exception, another exception occurred:

requests.exceptions.ConnectionError: HTTPSConnectionPool(host='esrisrv.uzspace.org', port=6443): Max retries exceeded with url: /arcgis/rest/services/Hosted/uz_thermal_points/FeatureServer/layers?f=json (Caused by NewConnectionError('&amp;lt;urllib3.connection.HTTPSConnection object at 0x0000022A5D6EDC10&amp;gt;: Failed to establish a new connection: [Errno 11001] getaddrinfo failed'))

During handling of the above exception, another exception occurred:

  File "D:\scripts\thermal_active\from arcgis.py", line 33, in &amp;lt;module&amp;gt;
    thermal_flayer_collection.manager.overwrite(new_file_path)
requests.exceptions.ConnectionError: A connection error has occurred: HTTPSConnectionPool(host='esrisrv.uzspace.org', port=6443): Max retries exceeded with url: /arcgis/rest/services/Hosted/uz_thermal_points/FeatureServer/layers?f=json (Caused by NewConnectionError('&amp;lt;urllib3.connection.HTTPSConnection object at 0x0000022A5D6EDC10&amp;gt;: Failed to establish a new connection: [Errno 11001] getaddrinfo failed'))&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;i found&amp;nbsp;&lt;A href="https://community.esri.com/t5/arcgis-enterprise-portal-questions/list-services-in-portal-for-arcgis/m-p/1106631/highlight/true#M11593" target="_blank" rel="noopener"&gt;post&lt;/A&gt;&amp;nbsp;which had similar problem, but solution required using&amp;nbsp;&lt;STRONG&gt;request&lt;/STRONG&gt;&lt;SPAN&gt;&amp;nbsp;module instead of using the&amp;nbsp;&lt;/SPAN&gt;&lt;STRONG&gt;httplib&lt;/STRONG&gt;. However, i cant control it in my case.&lt;/P&gt;</description>
    <pubDate>Mon, 28 Aug 2023 12:02:20 GMT</pubDate>
    <dc:creator>AbdujabborMakhmudov</dc:creator>
    <dc:date>2023-08-28T12:02:20Z</dc:date>
    <item>
      <title>socket.gaierror: [Errno 11001] getaddrinfo failed</title>
      <link>https://community.esri.com/t5/arcgis-api-for-python-questions/socket-gaierror-errno-11001-getaddrinfo-failed/m-p/1322927#M8959</link>
      <description>&lt;P&gt;&lt;SPAN&gt;Greetings,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;i want to overwrite feature service in portal. i followed this guide &lt;A href="https://developers.arcgis.com/python/samples/overwriting-feature-layers/" target="_blank"&gt;https://developers.arcgis.com/python/samples/overwriting-feature-layers/&lt;/A&gt;&amp;nbsp;but im getting an error at overwriting part.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="python"&gt;from arcgis.gis import GIS
from arcgis import features
import pandas as pd
import os
from arcgis.features import FeatureLayerCollection

portal_url = "https://myportalurl"
username = "login"
password = "pass"

gis = GIS(portal_url, username, password)

fileid = '9bfb22d38bee49af93ad56952f5a4cc3'

item = gis.content.get(fileid)

# item_props = {
#     "title": "Updated title",
#     "description": "Updated description"
# }
# item.update(
#     item_properties=item_props,
# )
# updating is not causing any problems

new_file_path = os.path.join( os.getcwd(), "uz_thermal_points.zip")

thermal_flayer_collection = FeatureLayerCollection.fromitem(item)

thermal_flayer_collection.manager.overwrite(new_file_path)&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;filename is the same as original published file. in the website, there is no error while overwriting features.&lt;BR /&gt;i got this error:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="python"&gt;Exception has occurred: ConnectionError
A connection error has occurred: HTTPSConnectionPool(host='esrisrv.uzspace.org', port=6443): Max retries exceeded with url: /arcgis/rest/services/Hosted/uz_thermal_points/FeatureServer/layers?f=json (Caused by NewConnectionError('&amp;lt;urllib3.connection.HTTPSConnection object at 0x0000022A5D6EDC10&amp;gt;: Failed to establish a new connection: [Errno 11001] getaddrinfo failed'))
socket.gaierror: [Errno 11001] getaddrinfo failed

During handling of the above exception, another exception occurred:

urllib3.exceptions.NewConnectionError: &amp;lt;urllib3.connection.HTTPSConnection object at 0x0000022A5D6EDC10&amp;gt;: Failed to establish a new connection: [Errno 11001] getaddrinfo failed

During handling of the above exception, another exception occurred:

urllib3.exceptions.MaxRetryError: HTTPSConnectionPool(host='esrisrv.uzspace.org', port=6443): Max retries exceeded with url: /arcgis/rest/services/Hosted/uz_thermal_points/FeatureServer/layers?f=json (Caused by NewConnectionError('&amp;lt;urllib3.connection.HTTPSConnection object at 0x0000022A5D6EDC10&amp;gt;: Failed to establish a new connection: [Errno 11001] getaddrinfo failed'))

During handling of the above exception, another exception occurred:

requests.exceptions.ConnectionError: HTTPSConnectionPool(host='esrisrv.uzspace.org', port=6443): Max retries exceeded with url: /arcgis/rest/services/Hosted/uz_thermal_points/FeatureServer/layers?f=json (Caused by NewConnectionError('&amp;lt;urllib3.connection.HTTPSConnection object at 0x0000022A5D6EDC10&amp;gt;: Failed to establish a new connection: [Errno 11001] getaddrinfo failed'))

During handling of the above exception, another exception occurred:

  File "D:\scripts\thermal_active\from arcgis.py", line 33, in &amp;lt;module&amp;gt;
    thermal_flayer_collection.manager.overwrite(new_file_path)
requests.exceptions.ConnectionError: A connection error has occurred: HTTPSConnectionPool(host='esrisrv.uzspace.org', port=6443): Max retries exceeded with url: /arcgis/rest/services/Hosted/uz_thermal_points/FeatureServer/layers?f=json (Caused by NewConnectionError('&amp;lt;urllib3.connection.HTTPSConnection object at 0x0000022A5D6EDC10&amp;gt;: Failed to establish a new connection: [Errno 11001] getaddrinfo failed'))&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;i found&amp;nbsp;&lt;A href="https://community.esri.com/t5/arcgis-enterprise-portal-questions/list-services-in-portal-for-arcgis/m-p/1106631/highlight/true#M11593" target="_blank" rel="noopener"&gt;post&lt;/A&gt;&amp;nbsp;which had similar problem, but solution required using&amp;nbsp;&lt;STRONG&gt;request&lt;/STRONG&gt;&lt;SPAN&gt;&amp;nbsp;module instead of using the&amp;nbsp;&lt;/SPAN&gt;&lt;STRONG&gt;httplib&lt;/STRONG&gt;. However, i cant control it in my case.&lt;/P&gt;</description>
      <pubDate>Mon, 28 Aug 2023 12:02:20 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-python-questions/socket-gaierror-errno-11001-getaddrinfo-failed/m-p/1322927#M8959</guid>
      <dc:creator>AbdujabborMakhmudov</dc:creator>
      <dc:date>2023-08-28T12:02:20Z</dc:date>
    </item>
  </channel>
</rss>

