FREE license expired and now I can't do anything

curl -v -XPUT -u adam 'http://0.0.0.0:9200/_license' -d /home/deploy/adam-medeiros-c6e3e22c-18c0-4b72-8023-5810ee4bed5a-v5.json

  • Trying 0.0.0.0...
  • Connected to 0.0.0.0 (127.0.0.1) port 9200 (#0)
  • Server auth using Basic with user 'adam'

PUT /_license HTTP/1.1
Host: 0.0.0.0:9200
Authorization: Basic YWRhbTpjYW52YXMxMA==
User-Agent: curl/7.47.0
Accept: /
Content-Length: 1200
Content-Type: application/x-www-form-urlencoded

  • upload completely sent off: 1200 out of 1200 bytes
  • Empty reply from server
  • Connection #0 to host 0.0.0.0 left intact

Ehm.......what now? adam user is a superuser. I also tried the elastic user but same outcome. I'm completely blocked right now and I'm unable to look at my logstashes to find a problem on one of my production servers. Documentation is terribly disorganized and I have to use google search to look up solutions - which is no good since I can't tell of the proposed solutions are outdated or I have some system problem.

Why a complete lockout on a FREE license? Why not just nag me to update my license and let me get on with my life?

Kibana is not allowing me to get in and I can't install a new license to satisfy it either. If someone can get back to me quickly, I'd appreciate it. I can't search through Kibana dashboard at the moment.

Hey! That sucks.

What version of elastic stack are you running?

Although this page doesn't mention any degradation of authentication/authorisation that has already been established, I will wait for someone from elastic.co to officially comment on it.

Hey there,

:~$ elasticsearch -V
Version: 5.6.3, Build: 1a2f265/2017-10-06T20:33:39.012Z, JVM: 1.8.0_151

OH - and thank you for reaching out to help me. I appreciate it.

For the record, I also tried a few times to install the license before it expired, but had the same outcome and didn't have time to troubleshoot the issue then. Now it's too late and I'm forced to confront this. I wish there wasn't so much friction to install a free license. Just reading https://www.elastic.co/guide/en/x-pack/current/license-expiration.html frustrates me because following those steps didn't actually work.

It looks like you're missing the @ at the beginning on the filename.

The -d flag to curl expect a raw input string, you need to have a leading @ to tell it to read from a file (sorry, it's a curl thing)

 curl -v -XPUT -u adam 'http://0.0.0.0:9200/_license' -d @/home/deploy/adam-medeiros-c6e3e22c-18c0-4b72-8023-5810ee4bed5a-v5.json

Yeah...I tried that too Tim - that had the same outcome:

:~$ curl -v -XPUT -u adam 'http://0.0.0.0:9200/_license' -d @/home/deploy/adam-medeiros-c6e3e22c-18c0-4b72-8023-5810ee4bed5a-v5.json
Enter host password for user 'adam':

  • Trying 0.0.0.0...
  • Connected to 0.0.0.0 (127.0.0.1) port 9200 (#0)
  • Server auth using Basic with user 'adam'

PUT /_license HTTP/1.1
Host: 0.0.0.0:9200
Authorization: Basic YWRhbTpjYW52YXMxMA==
User-Agent: curl/7.47.0
Accept: /
Content-Length: 1200
Content-Type: application/x-www-form-urlencoded
Expect: 100-continue

  • Empty reply from server
  • Connection #0 to host 0.0.0.0 left intact
    curl: (52) Empty reply from server

Also, just so everyone can see this user should theoretically have the power to do this:

:/usr/share/elasticsearch/bin/x-pack# ./users list
adam : superuser

Sorry, I just noticed that you also have the wrong URL.

From the documentation

curl -XPUT -u elastic 'http://<host>:<port>/_xpack/license' -H "Content-Type: application/json" -d @license.json

So in your case this should work:

curl -XPUT -u adam 'http://127.0.0.1:9200/_xpack/license' -H "Content-Type: application/json" -d @/home/deploy/adam-medeiros-c6e3e22c-18c0-4b72-8023-5810ee4bed5a-v5.json
1 Like

Actually 0.0.0.0 worked - but with https in front. What a dork I am.

1 Like

My deepest thanks for trying to help me guys! @TimV @mujtabahussain

All good mate. Best of luck.

Thanks for stepping in to help so quickly @TimV and @mujtabahussain!

1 Like

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