Would you like to learn how to install TimescaleDB using Docker on Ubuntu Linux? In this tutorial, we are going to show you all the steps required to perform the TimescaleDB installation using Docker on a computer running Ubuntu Linux in 5 minutes or less.
• Ubuntu 20.04
• Ubuntu 18.04
• Ubuntu 19.04
• TimescaleDB 12.4
Tutorial TimescaleDB – Docker Installation on Ubuntu Linux
Install the Docker service.
Download the TimescaleDB docker image from the online repository.
List the Docker images installed on your system.
Here is the command output:
Start a new TimescaleDB container using this Docker image.
Here is the command output:
In our example, the Docker image was used to start a new container.
The new container is using the local port 5432.
The container ID is db51dbe186b1d63c72d1cfc38464467279bf99df456435528e8a2462e6d02578.
The TimescaleDB password configured was kamisama123.
Congratulations! You have finished the TimescaleDB Docker installation on Ubuntu Linux.
Docker TimescaleDB – Persistent data
Create a docker volume for persistent data.
Verify the persistent data directory.
Here is the command output:
Start a TimescaleDB container with persistent data storage.
In our example, the TimescaleDB password configured was kamisama123.
Verify the content of the persistent data directory.
Here is the command output:
Congratulations! You successfully configured the use of Docker persistent data storage.
Tutorial TimescaleDB – Testing the Docker installation
Install the PostgreSQL client package on the localhost.
Access the TimescaleDB service running on the Docker container.
Here is the command output:
Congratulations! Your TimescaleDB Docker installation was tested successfully.
Tutorial TimescaleDB – Docker container management
Verify the status of all Docker conteiners using the following command:
Here is the command output:
Verify the status of the TimescaleDB container using the ID or its name.
Here is the command output:
To stop the TimescaleDB container service, use the following command:
To start the TimescaleDB container service, use the following command:
To restart the TimescaleDB container service, use the following command:
In case of error, use the following command to verify the TimescaleDB container logs.
In our examples, we demonstrated how to manage the TimescaleDB container using its ID or the name previously defined.