# Deploy ELK on AlmaLinux 9.2 elasticsearch-create-enrollment-token Command not found

**URL:** <https://discuss.elastic.co/t/deploy-elk-on-almalinux-9-2-elasticsearch-create-enrollment-token-command-not-found/380664>\
**Category:** Elasticsearch\
**Created:** [August 1, 2025, 12:56pm UTC](https://discuss.elastic.co/t/deploy-elk-on-almalinux-9-2-elasticsearch-create-enrollment-token-command-not-found/380664 "2025-08-01T12:56:34Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Elasticisti](https://avatars.discourse-cdn.com/v4/letter/e/51bf81/32.png) [@Elasticisti](https://discuss.elastic.co/u/Elasticisti)\
**Post date:** [August 1, 2025, 12:56pm UTC](https://discuss.elastic.co/t/deploy-elk-on-almalinux-9-2-elasticsearch-create-enrollment-token-command-not-found/380664/1 "2025-08-01T12:56:34Z")

</div>

Hi,

I have an AlmaLinux Vm mit 4CPU und 4GB RAM where ELK should be deployed.

I have used this tutorial to achieve this:  
"www.hostmycode.in/tutorials/install-and-configure-elk-stack-on-almalinux"

I got to the point, where enrollment token has to be added ...

Problem:  
If I use `bin\elasticsearch-create-enrollment-token.bat --scope kibana` in the directory, it seems not to be found:

 ![image](https://us1.discourse-cdn.com/elastic/original/3X/9/a/9a60e555e21f43503bd7f950f8666b0f639494bf.png)

Has anybody an idea, what the problem van be?

Thank you

Best regards

E

---

<div class="post-metadata">

**Author:** ![carly.richmond](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/carly.richmond/32/104935_2.png) [@carly.richmond](https://discuss.elastic.co/u/carly.richmond)\
**Post date:** [August 1, 2025, 2:26pm UTC](https://discuss.elastic.co/t/deploy-elk-on-almalinux-9-2-elasticsearch-create-enrollment-token-command-not-found/380664/2 "2025-08-01T14:26:02Z")

</div>

Hi @Elasticisti,

This isn't a tutorial of ours, but can you try the below as per [our install docs](https://www.elastic.co/docs/deploy-manage/deploy/self-managed/install-elasticsearch-from-archive-on-linux-macos#existing-cluster):

```auto
./bin/elasticsearch-create-enrollment-token -s kibana

```

I do see the [elasticsearch-create-enrollment-token](https://www.elastic.co/docs/reference/elasticsearch/command-line-tools/create-enrollment-token) in your screenshot, so it has been created.

Hope that helps!

---

<div class="post-metadata">

**Author:** ![Elasticisti](https://avatars.discourse-cdn.com/v4/letter/e/51bf81/32.png) [@Elasticisti](https://discuss.elastic.co/u/Elasticisti)\
**Post date:** [August 1, 2025, 2:36pm UTC](https://discuss.elastic.co/t/deploy-elk-on-almalinux-9-2-elasticsearch-create-enrollment-token-command-not-found/380664/3 "2025-08-01T14:36:49Z")

</div>

Thank you Carly,

it has helped, I have had to use also this:

"Are you running elasticsearch on a single node? If so, check if you have the line cluster.initial\_master\_nodes: ["localhost"] uncommented on the elasticsearch.yml file. Comment the line and add discovery.type: single-node on the next line. Restart elasticsearch and check. Check on this link too [Error] Setup-passwords: Failed to determine the health of the Cluster"

After these changes, it works now.

regards

E.
