# Problem Enable TLS encryption

**URL:** <https://community.influxdata.com/t/problem-enable-tls-encryption/21875>\
**Category:** Welcome & Getting Started\
**Created:** [September 28, 2021, 11:37am UTC](https://community.influxdata.com/t/problem-enable-tls-encryption/21875 "2021-09-28T11:37:06Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![juanrodrigues](https://avatars.discourse-cdn.com/v4/letter/j/df788c/32.png) [@juanrodrigues](https://community.influxdata.com/u/juanrodrigues)\
**Post date:** [September 28, 2021, 11:37am UTC](https://community.influxdata.com/t/problem-enable-tls-encryption/21875/1 "2021-09-28T11:37:06Z")

</div>

I had use the following command with indicates your web page and it does not work  
to see who can help me.  
/home/server# sudo openssl req -x509 -nodes -newkey rsa:2048 \

> -keyout /etc/ssl/influxdb-selfsigned.key   
> -out /etc/ssl/influxdb-selfsigned.crt   
> -days 365  
> /home/server# cd /etc/ssl/  
> root@ubuntuoasis:/etc/ssl# ls  
> certs influxdb-selfsigned.crt influxdb-selfsigned.key openssl.cnf private  
> root@ubuntuoasis:/etc/ssl# sudo chmod 644 /etc/ssl/influxdb-selfsigned.crt  
> root@ubuntuoasis:/etc/ssl# sudo chmod 600 /etc/ssl/influxdb-selfsigned.key  
> root@ubuntuoasis:/etc/ssl# influxd --tls-cert=/etc/ssl/influxdb-selfsigned.crt  
> ^[[D^[[D^[[D2021-09-28T11:16:49.187216Z info Welcome to InfluxDB {“log\_id”: “0Ws1n1dG000”, “version”: “2.0.8”, “commit”: “e91d41810f”, “build\_date”: “2021-08-13T18:22:30Z”}  
> 2021-09-28T11:16:49.313723Z info Resources opened {“log\_id”: “0Ws1n1dG000”, “service”: “bolt”, “path”: “/root/.influxdbv2/influxd.bolt”}  
> 2021-09-28T11:16:49.318021Z info Bringing up metadata migrations {“log\_id”: “0Ws1n1dG000”, “service”: “migrations”, “migration\_count”: 15}  
> 2021-09-28T11:16:49.561838Z info Using data dir {“log\_id”: “0Ws1n1dG000”, “service”: “storage-engine”, “service”: “store”, “path”: “/root/.influxdbv2/engine/data”}  
> 2021-09-28T11:16:49.561978Z info Compaction settings {“log\_id”: “0Ws1n1dG000”, “service”: “storage-engine”, “service”: “store”, “max\_concurrent\_compactions”: 1, “throughput\_bytes\_per\_second”: 50331648, “throughput\_bytes\_per\_second\_burst”: 50331648}  
> 2021-09-28T11:16:49.562004Z info Open store (start) {“log\_id”: “0Ws1n1dG000”, “service”: “storage-engine”, “service”: “store”, “op\_name”: “tsdb\_open”, “op\_event”: “start”}  
> 2021-09-28T11:16:49.562080Z info Open store (end) {“log\_id”: “0Ws1n1dG000”, “service”: “storage-engine”, “service”: “store”, “op\_name”: “tsdb\_open”, “op\_event”: “end”, “op\_elapsed”: “0.075ms”}  
> 2021-09-28T11:16:49.562112Z info Starting retention policy enforcement service {“log\_id”: “0Ws1n1dG000”, “service”: “retention”, “check\_interval”: “30m”}  
> 2021-09-28T11:16:49.562139Z info Starting precreation service {“log\_id”: “0Ws1n1dG000”, “service”: “shard-precreation”, “check\_interval”: “10m”, “advance\_period”: “30m”}  
> 2021-09-28T11:16:49.562186Z info Starting query controller {“log\_id”: “0Ws1n1dG000”, “service”: “storage-reads”, “concurrency\_quota”: 1024, “initial\_memory\_bytes\_quota\_per\_query”: 9223372036854775807, “memory\_bytes\_quota\_per\_query”: 9223372036854775807, “max\_memory\_bytes”: 0, “queue\_size”: 1024}  
> 2021-09-28T11:16:49.584443Z info Configuring InfluxQL statement executor (zeros indicate unlimited). {“log\_id”: “0Ws1n1dG000”, “max\_select\_point”: 0, “max\_select\_series”: 0, “max\_select\_buckets”: 0}  
> 2021-09-28T11:16:49.939998Z info Starting {“log\_id”: “0Ws1n1dG000”, “service”: “telemetry”, “interval”: “8h”}  
> 2021-09-28T11:16:49.941074Z error Failed to set up TCP listener {“log\_id”: “0Ws1n1dG000”, “service”: “tcp-listener”, “addr”: “:8086”, “error”: “listen tcp :8086: bind: address already in use”}  
> Error: listen tcp :8086: bind: address already in use  
> See ‘influxd -h’ for help  
> root@ubuntuoasis:/etc/ssl# influxd --tls-cert=/etc/ssl/influxdb-selfsigned.crt --tls-key=/etc/ssl/influxdb-selfsigned.key  
> 2021-09-28T11:17:50.019288Z info Welcome to InfluxDB {“log\_id”: “0Ws1qkGl000”, “version”: “2.0.8”, “commit”: “e91d41810f”, “build\_date”: “2021-08-13T18:22:30Z”}  
> 2021-09-28T11:17:50.083342Z info Resources opened {“log\_id”: “0Ws1qkGl000”, “service”: “bolt”, “path”: “/root/.influxdbv2/influxd.bolt”}  
> 2021-09-28T11:17:50.121040Z info Using data dir {“log\_id”: “0Ws1qkGl000”, “service”: “storage-engine”, “service”: “store”, “path”: “/root/.influxdbv2/engine/data”}  
> 2021-09-28T11:17:50.121125Z info Compaction settings {“log\_id”: “0Ws1qkGl000”, “service”: “storage-engine”, “service”: “store”, “max\_concurrent\_compactions”: 1, “throughput\_bytes\_per\_second”: 50331648, “throughput\_bytes\_per\_second\_burst”: 50331648}  
> 2021-09-28T11:17:50.121372Z info Open store (start) {“log\_id”: “0Ws1qkGl000”, “service”: “storage-engine”, “service”: “store”, “op\_name”: “tsdb\_open”, “op\_event”: “start”}  
> 2021-09-28T11:17:50.121481Z info Open store (end) {“log\_id”: “0Ws1qkGl000”, “service”: “storage-engine”, “service”: “store”, “op\_name”: “tsdb\_open”, “op\_event”: “end”, “op\_elapsed”: “0.167ms”}  
> 2021-09-28T11:17:50.121524Z info Starting retention policy enforcement service {“log\_id”: “0Ws1qkGl000”, “service”: “retention”, “check\_interval”: “30m”}  
> 2021-09-28T11:17:50.121544Z info Starting precreation service {“log\_id”: “0Ws1qkGl000”, “service”: “shard-precreation”, “check\_interval”: “10m”, “advance\_period”: “30m”}  
> 2021-09-28T11:17:50.121662Z info Starting query controller {“log\_id”: “0Ws1qkGl000”, “service”: “storage-reads”, “concurrency\_quota”: 1024, “initial\_memory\_bytes\_quota\_per\_query”: 9223372036854775807, “memory\_bytes\_quota\_per\_query”: 9223372036854775807, “max\_memory\_bytes”: 0, “queue\_size”: 1024}  
> 2021-09-28T11:17:50.127801Z info Configuring InfluxQL statement executor (zeros indicate unlimited). {“log\_id”: “0Ws1qkGl000”, “max\_select\_point”: 0, “max\_select\_series”: 0, “max\_select\_buckets”: 0}  
> 2021-09-28T11:17:50.446747Z info Starting {“log\_id”: “0Ws1qkGl000”, “service”: “telemetry”, “interval”: “8h”}  
> 2021-09-28T11:17:50.446880Z error Failed to set up TCP listener {“log\_id”: “0Ws1qkGl000”, “service”: “tcp-listener”, “addr”: “:8086”, “error”: “listen tcp :8086: bind: address already in use”}  
> Error: listen tcp :8086: bind: address already in use  
> See ‘influxd -h’ for help  
> root@ubuntuoasis:/etc/ssl#

---

<div class="post-metadata">

**Author:** ![Anaisdg](https://sea1.discourse-cdn.com/flex023/user_avatar/community.influxdata.com/anaisdg/32/6401_2.png) [@Anaisdg](https://community.influxdata.com/u/Anaisdg)\
**Post date:** [September 28, 2021, 3:44pm UTC](https://community.influxdata.com/t/problem-enable-tls-encryption/21875/2 "2021-09-28T15:44:49Z")

</div>

Hello @juanrodrigues,  
It looks like you already are using port 8086.  
I’d run `sudo lsof -i:8086` to see what’s running on that port.

---

<div class="post-metadata">

**Author:** ![juanrodrigues](https://avatars.discourse-cdn.com/v4/letter/j/df788c/32.png) [@juanrodrigues](https://community.influxdata.com/u/juanrodrigues)\
**Post date:** [September 28, 2021, 4:09pm UTC](https://community.influxdata.com/t/problem-enable-tls-encryption/21875/4 "2021-09-28T16:09:54Z")

</div>

hello Anaisdg  
sudo lsof -i:8086  
[sudo] password for server:  
COMMAND PID USER FD TYPE DEVICE SIZE/OFF NODE NAME  
influxd 998 influxdb 37u IPv6 32431 0t0 TCP \*:8086 (LISTEN)

I thank you for helping me

---

<div class="post-metadata">

**Author:** ![juanrodrigues](https://avatars.discourse-cdn.com/v4/letter/j/df788c/32.png) [@juanrodrigues](https://community.influxdata.com/u/juanrodrigues)\
**Post date:** [September 30, 2021, 2:41pm UTC](https://community.influxdata.com/t/problem-enable-tls-encryption/21875/5 "2021-09-30T14:41:58Z")

</div>

sudo service influxdb stop  
server@ubuntuoasis:/var/lib/influxdb$ sudo service influxdb status  
● influxdb.service - InfluxDB is an open-source, distributed, time series database  
Loaded: loaded (/lib/systemd/system/influxdb.service; enabled; vendor preset: enabled)  
Active: inactive (dead) since Thu 2021-09-30 14:36:13 UTC; 3min 48s ago  
Docs: [InfluxDB OSS 2.6 Documentation](https://docs.influxdata.com/influxdb/)  
Process: 40856 ExecStart=/usr/lib/influxdb/scripts/influxd-systemd-start.sh (code=exited, status=0/SUCCESS)  
Main PID: 40857 (code=killed, signal=TERM)

sep 30 14:35:50 ubuntuoasis systemd[1]: Starting InfluxDB is an open-source, distributed, time series database…  
sep 30 14:35:51 ubuntuoasis influxd-systemd-start.sh[40856]: InfluxDB started  
sep 30 14:35:51 ubuntuoasis systemd[1]: Started InfluxDB is an open-source, distributed, time series database.  
sep 30 14:36:13 ubuntuoasis systemd[1]: Stopping InfluxDB is an open-source, distributed, time series database…  
sep 30 14:36:13 ubuntuoasis systemd[1]: influxdb.service: Succeeded.  
sep 30 14:36:13 ubuntuoasis systemd[1]: Stopped InfluxDB is an open-source, distributed, time series database.  
server@ubuntuoasis:/var/lib/influxdb$ influxd --tls-cert /etc/ssl/influxdb-selfsigned1.crt  
2021-09-30T14:40:50.166105Z info Welcome to InfluxDB {“log\_id”: “0WunG1y0000”, “version”: “2.0.8”, “commit”: “e91d41810f”, “build\_date”: “2021-08-13T18:22:30Z”}  
2021-09-30T14:40:51.138308Z error Failed opening bolt {“log\_id”: “0WunG1y0000”, “error”: “unable to open boltdb: timeout”}  
Error: unable to open boltdb: timeout  
See ‘influxd -h’ for help
