# "Access Denied" when I try to execute "curl -XGET localhost:9200"

**URL:** <https://discuss.elastic.co/t/access-denied-when-i-try-to-execute-curl-xget-localhost-9200/38565>\
**Category:** Elasticsearch\
**Created:** [January 7, 2016, 2:56am UTC](https://discuss.elastic.co/t/access-denied-when-i-try-to-execute-curl-xget-localhost-9200/38565 "2016-01-07T02:56:03Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Young\_Heon\_Kim](https://avatars.discourse-cdn.com/v4/letter/y/e19b73/32.png) [@Young\_Heon\_Kim](https://discuss.elastic.co/u/Young_Heon_Kim)\
**Post date:** [January 7, 2016, 2:56am UTC](https://discuss.elastic.co/t/access-denied-when-i-try-to-execute-curl-xget-localhost-9200/38565/1 "2016-01-07T02:56:03Z")

</div>

Hi All.  
I try to use elasticsearch for my job.  
But I found some error when I use it.

I can connect http://my\_id\_address:9200 using my browser.

{  
status: 200,  
name: "Dreadnought",  
cluster\_name: "elasticsearch",  
version: {  
number: "1.7.3",  
build\_hash: "05d4530971ef0ea46d0f4fa6ee64dbc8df659682",  
build\_timestamp: "2015-10-15T09:14:17Z",  
build\_snapshot: false,  
lucene\_version: "4.10.4"  
},  
tagline: "You Know, for Search"  
}

But I can get some date using command line.

# curl -XGET my\_id\_address:9200

......  
.....  
....

# ERROR

## The requested URL could not be retrieved

* * *

The following error was encountered while trying to retrieve the URL: [http://my\_id\_address:9200/](http://my_id_address:9200/)

> **Access Denied.**

....... ....... .....

Do you know why this error occurred?

---

<div class="post-metadata">

**Author:** ![Stephane\_Steph](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/stephane_steph/32/8426_2.png) [@Stephane\_Steph](https://discuss.elastic.co/u/Stephane_Steph)\
**Post date:** [March 2, 2016, 1:41pm UTC](https://discuss.elastic.co/t/access-denied-when-i-try-to-execute-curl-xget-localhost-9200/38565/2 "2016-03-02T13:41:20Z")

</div>

Hi,  
Looks like a proxy issue. Check your ~/.curlrc.

---

<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:** [July 5, 2017, 11:12pm UTC](https://discuss.elastic.co/t/access-denied-when-i-try-to-execute-curl-xget-localhost-9200/38565/3 "2017-07-05T23:12:02Z")

</div>


