# Generate certificates after expiring

**URL:** https://discuss.elastic.co/t/generate-certificates-after-expiring/369689
**Category:** Elasticsearch
**Created:** [October 28, 2024, 5:24pm UTC](https://discuss.elastic.co/t/generate-certificates-after-expiring/369689 "2024-10-28T17:24:06Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![cyberzlo](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/cyberzlo/32/65490_2.png) [@cyberzlo](https://discuss.elastic.co/u/cyberzlo)
#### Post date: [October 28, 2024, 5:24pm UTC](https://discuss.elastic.co/t/generate-certificates-after-expiring/369689/1 "2024-10-28T17:24:06Z")

</div>

What commands does the Ubuntu deb package installer script execute to **generate HTTPS certificates**? I would like to **regenerate certificates** , but the commands generate completely different file names etc. - I'm lost in this.

Can I somehow ignore only expired dates of certyficates or generate them from advice for more years? Installer generate only for 2y.

---

<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: [October 30, 2024, 10:20am UTC](https://discuss.elastic.co/t/generate-certificates-after-expiring/369689/2 "2024-10-30T10:20:52Z")

</div>

Hi @cyberzlo,

You should be able to generate a new certificate using the `elasticsearch-certutil` tool [by following the steps in the documentation](https://www.elastic.co/guide/en/elasticsearch/reference/current/update-node-certs-different.html#node-certs-different-http):

```auto
./bin/elasticsearch-certutil http

```

Hope that helps!

---

<div class="post-metadata">

### Author: ![cyberzlo](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/cyberzlo/32/65490_2.png) [@cyberzlo](https://discuss.elastic.co/u/cyberzlo)
#### Post date: [October 30, 2024, 12:43pm UTC](https://discuss.elastic.co/t/generate-certificates-after-expiring/369689/3 "2024-10-30T12:43:15Z")

</div>

I know but it will generate other filenames etc. I am not sure which is which and why official installator do it diffrent way? Can I replicate what is done by script to have same reasults with same filenames/paths?
