error Content-Type header application x-www-form-urlencoded is not supported status 406

0 votes

Hi Guys,

I am trying to upload a log file in the ElasticSearch engine using the PUT command. But it is showing me the below-given error.

$ curl -X PUT http://ElasticEngineIP:9200/mylogdb --data-binary @log.json 
{"error":"Content-Type header [application/x-www-form-urlencoded] is not supported","status":406}

Can anyone help me to resolve this error?

Jun 16, 2020 in DevOps Tools by akhtar
• 38,260 points
5,772 views

1 answer to this question.

0 votes

Hi@akhtar,

In your command, you have to mention the Content-Type of your log file. You can use the below-given command.

$ curl -X PUT -H 'Content-Type: application/json' http://ElasticEngineIP:9200/mylogdb --data-binary @log.json

I hope this will help you. 

answered Jun 16, 2020 by MD
• 95,460 points

Related Questions In DevOps Tools

0 votes
1 answer

Gunicorn stuck on docker when run is executed with flask application

Here's something that you could try: Check your ...READ MORE

answered Jun 14, 2018 in DevOps Tools by ajs3033
• 7,300 points
6,758 views
0 votes
1 answer

login popup not working in tomcat9 when I click the server status

Try and install tomcat 8.0.41. It is ...READ MORE

answered Jul 12, 2018 in DevOps Tools by DareDev
• 6,890 points
1,646 views
+2 votes
3 answers

mvn not recognized as an internal or external command error

Setting the environment variables JAVA_HOME, MAVEN_HOME and  ...READ MORE

answered Jun 3, 2019 in DevOps Tools by Sirajul
• 59,230 points
95,436 views
0 votes
1 answer
+1 vote
1 answer
+15 votes
2 answers

Git management technique when there are multiple customers and need multiple customization?

Consider this - In 'extended' Git-Flow, (Git-Multi-Flow, ...READ MORE

answered Mar 27, 2018 in DevOps & Agile by DragonLord999
• 8,450 points
4,059 views
0 votes
1 answer
webinar REGISTER FOR FREE WEBINAR X
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP