# Error while importing metricbeat dashboard

**URL:** <https://discuss.elastic.co/t/error-while-importing-metricbeat-dashboard/65469>\
**Category:** Beats\
**Tags:** metricbeat\
**Created:** [November 9, 2016, 10:58am UTC](https://discuss.elastic.co/t/error-while-importing-metricbeat-dashboard/65469 "2016-11-09T10:58:36Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![elasticheart](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/elasticheart/32/65189_2.png) [@elasticheart](https://discuss.elastic.co/u/elasticheart)\
**Post date:** [November 9, 2016, 10:58am UTC](https://discuss.elastic.co/t/error-while-importing-metricbeat-dashboard/65469/1 "2016-11-09T10:58:36Z")

</div>

Hi,

I am trying to import dashboard for metricbeat offline using the command

```
./scripts/import_dashboards -dir /files/beats-dashboards-5.0.0/metricbeat

```

and I am getting the error;

```
-bash-4.1$ ./import_dashboards -dir /files/beats-dashboards-5.0.0/metricbeat
fail to set the mapping. Error: Put http://127.0.0.1:9200/.kibana/_mapping/search: dial tcp 127.0.0.1:9200: getsockopt: connection refused
Import directory /files/beats-dashboards-5.0.0/metricbeat/index-pattern
Import index to /.kibana/index-pattern/metricbeat-* from /files/beats-dashboards-5.0.0/metricbeat/index-pattern/metricbeat.json
ERROR: couldn't load json. Error: Put http://127.0.0.1:9200/.kibana/index-pattern/metricbeat-*: dial tcp 127.0.0.1:9200: getsockopt: connection refused
fail to import index-pattern: fail to load directory /files/beats-dashboards-5.0.0/metricbeat/index-pattern: error loading /files/beats-dashboards-5.0.0/metricbeat/index-pattern/metricbeat.json: couldn't load json. Error: Put http://127.0.0.1:9200/.kibana/index-pattern/metricbeat-*: dial tcp 127.0.0.1:9200: getsockopt: connection refused

```

What is the problem and how can I fix this? Thanks.

---

<div class="post-metadata">

**Author:** ![elasticheart](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/elasticheart/32/65189_2.png) [@elasticheart](https://discuss.elastic.co/u/elasticheart)\
**Post date:** [November 9, 2016, 11:00am UTC](https://discuss.elastic.co/t/error-while-importing-metricbeat-dashboard/65469/2 "2016-11-09T11:00:36Z")

</div>

Solved it. I forgot to gave `--es` ip, port, username and password.

---

<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:** [December 7, 2016, 11:00am UTC](https://discuss.elastic.co/t/error-while-importing-metricbeat-dashboard/65469/3 "2016-12-07T11:00:41Z")

</div>

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