Ubuntu and Docker - How to Check Used and Available Ports With Netstat
Docker containers which are using the network of the host (the machine Docker runs on) will also need to share the ports of the host with each other.
So when creating a new container you will first have to make a choice whether:
- You want to use a macvlan network with its own IP address
- Or you want to use the ports of the host
Netstat
I run the following on the CLI of my Ubuntu VM. After running, check in the list whether a port is in use or not:
sudo netstat -tulpen
Net Tools may still need to be installed:
sudo apt-get update
sudo apt install net-tools
Read other notes
Tags
Notes mentioning this note
- Docker - Portainer Container Setup
Here I describe my setup of the Portainer container.
- Docker - WebDAV Container Setup
Here I describe my setup of the WebDAV container.
- Docker - Jekyll Container Setup
Here I describe my setup of the Jekyll container.
- Docker - Visual Studio Code Server Setup
Here I describe my setup of the Visual Studio Code Server container.
- Docker - Node-RED Container Setup with Authentication and Home Assistant Nodes
Here I describe my setup of the Node-RED docker container.
- Docker - Unbound Container Setup with Pi-hole
Here I describe my setup of the Unbound docker container.
- Docker - Syncthing Container Setup
Syncthing is a great piece of software that lets you safely sychronize your files between different devices and operating systems....
- Docker - Grafana Container Setup
Here I describe my setup of the Docker Grafana container. With Grafana you can create beautiful dashboards.
- Docker - Telegraf Container Setup with InfluxDB to Monitor Docker
Here I describe my setup of the Docker Telegraf container. Telegraf from InfluxData is a server agent for collecting metrics...
- Docker - Hop Server Container Setup
Here I describe my setup of the Docker Apache Hop Server container. Apache Hop is an open source data integration...
- Docker - Telegraf Container with Syslog Receiver Input Plugin
I found out that an IoT device (smart power strip) had the setting to communicatie with a syslog server and...
- Docker - Budibase Low-code Platform Container Setup
When I heard that my employer was using the no-code platform Betty Blocks my interest was piqued. Although I like...
- Docker - InfluxDB 2.x Container Setup
InfluxDB is a time series database.
- Docker - QuestDB Container Setup
QuestDB is a high-performance, open-source SQL database. QuestDB’s stack is engineered from scratch, zero-GC Java and dependency-free. It includes endpoints...
- Docker - Smartmeter2mqtt Container Setup with Webserver and Webrequest Output
Smartmeter2mqtt is an application that parses smartmeter data over the network or a P1 cable, I use it in combination...
- Docker - n8n Workflow Automation Container Setup
As a big fan of Node-RED and Apache Hop, it took me a long time to give n8n a try....
- Docker - Pi-hole Container Setup with Unbound
Here I describe my setup of the Pi-hole docker container.
Comments
No comments found for this note.
Join the discussion for this note on this ticket. Comments appear on this page instantly.