# When I try to import a model using eland, I get an error!

**URL:** <https://discuss.elastic.co/t/when-i-try-to-import-a-model-using-eland-i-get-an-error/334531>\
**Category:** Elasticsearch\
**Tags:** language-clients\
**Created:** [May 28, 2023, 3:50pm UTC](https://discuss.elastic.co/t/when-i-try-to-import-a-model-using-eland-i-get-an-error/334531 "2023-05-28T15:50:29Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![laoyang360](https://avatars.discourse-cdn.com/v4/letter/l/a9a28c/32.png) [@laoyang360](https://discuss.elastic.co/u/laoyang360)\
**Post date:** [May 28, 2023, 3:50pm UTC](https://discuss.elastic.co/t/when-i-try-to-import-a-model-using-eland-i-get-an-error/334531/1 "2023-05-28T15:50:29Z")

</div>

```auto
[root@-centos www]# eland_import_hub_model 
Traceback (most recent call last):
  File "/usr/local/bin/eland_import_hub_model", line 34, in <module>
    from elastic_transport.client_utils import DEFAULT
  File "/usr/local/lib/python3.10/site-packages/elastic_transport/ __init__.py", line 22, in <module>
    from ._async_transport import AsyncTransport as AsyncTransport
  File "/usr/local/lib/python3.10/site-packages/elastic_transport/_async_transport.py", line 34, in <module>
    from ._exceptions import (
  File "/usr/local/lib/python3.10/site-packages/elastic_transport/_exceptions.py", line 20, in <module>
    from ._models import ApiResponseMeta
  File "/usr/local/lib/python3.10/site-packages/elastic_transport/_models.py", line 21, in <module>
    import ssl
  File "/usr/local/lib/python3.10/ssl.py", line 99, in <module>
    import _ssl # if we can't import it, let the error propagate
ModuleNotFoundError: No module named '_ssl'

```

---

<div class="post-metadata">

**Author:** ![Priscilla\_Parodi](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/priscilla_parodi/32/43047_2.png) [@Priscilla\_Parodi](https://discuss.elastic.co/u/Priscilla_Parodi)\
**Post date:** [May 28, 2023, 5:02pm UTC](https://discuss.elastic.co/t/when-i-try-to-import-a-model-using-eland-i-get-an-error/334531/2 "2023-05-28T17:02:22Z")

</div>

Hello @laoyang360,

Apparently, the \_ssl module is missing in your Python environment.

Are you connecting to a self-managed cluster?

- [Connecting to a self-managed cluster](https://www.elastic.co/guide/en/elasticsearch/client/python-api/current/connecting.html#connect-self-managed-new)

I would check if the OpenSSL library is installed and then I would try to import the model again.

---

<div class="post-metadata">

**Author:** ![laoyang360](https://avatars.discourse-cdn.com/v4/letter/l/a9a28c/32.png) [@laoyang360](https://discuss.elastic.co/u/laoyang360)\
**Post date:** [May 30, 2023, 10:07am UTC](https://discuss.elastic.co/t/when-i-try-to-import-a-model-using-eland-i-get-an-error/334531/3 "2023-05-30T10:07:36Z")

</div>

Thanks for your reply！ But when I reinstall python 10.3.6 using “./configure --with-openssl=/www/openssl-1.1.1l“， The above error is still exist！ I want to know if there has another way for import a self model ？？

---

<div class="post-metadata">

**Author:** ![Priscilla\_Parodi](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/priscilla_parodi/32/43047_2.png) [@Priscilla\_Parodi](https://discuss.elastic.co/u/Priscilla_Parodi)\
**Post date:** [May 30, 2023, 4:44pm UTC](https://discuss.elastic.co/t/when-i-try-to-import-a-model-using-eland-i-get-an-error/334531/4 "2023-05-30T16:44:18Z")

</div>

Thanks for the additional context.

I have some questions,

Which model are you trying to import?

Which Elastic version are you using?

Can you show me how you're trying to import the model?

Another way, you mean, using Eland without installing it? You can build the Docker container to run the available scripts:

`docker build -t elastic/eland`

You can read more about it [here](https://www.elastic.co/guide/en/elasticsearch/client/eland/current/machine-learning.html#ml-nlp-pytorch-docker).

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [June 27, 2023, 4:44pm UTC](https://discuss.elastic.co/t/when-i-try-to-import-a-model-using-eland-i-get-an-error/334531/5 "2023-06-27T16:44:28Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
