MinIO is a high-performance, self-hosted object storage server that speaks the Amazon S3 API. If your backups, application uploads, or media files currently live on S3, MinIO lets you run the same API on your own Ubuntu server — with no per-gigabyte bill and full control over your data. In this guide you will install MinIO on Ubuntu 24.04, run it as a systemd service, open it through the firewall, and verify it with the web console and the mc command-line client.

Prerequisites

  • An Ubuntu 24.04 (or 22.04) server with sudo access — 2 GB RAM and at least 10 GB free disk is a sensible minimum for testing.
  • A dedicated disk or partition for data is ideal in production; this guide uses /data.
  • Ports 9000 (S3 API) and 9001 (web console) reachable from your machine.

Step 1: Update the system and install prerequisites

Start with a full package refresh so the tools you need are current.

sudo apt update && sudo apt upgrade -y
sudo apt install -y wget curl ufw

The first line updates the package index and upgrades installed packages. The second installs wget (to download the MinIO binary), curl (for health checks), and ufw (the firewall you will configure later).

Step 2: Download the MinIO server binary

MinIO ships as a single static binary. Download the official Linux amd64 build into /usr/local/bin and make it executable.

sudo wget https://dl.min.io/server/minio/release/linux-amd64/minio -O /usr/local/bin/minio
sudo chmod +x /usr/local/bin/minio

The -O flag writes the download to the given path, and chmod +x marks it executable so you can run it as a command. Confirm the version:

minio --version

You should see output similar to minio version RELEASE.2025-... — any recent release is fine.

Step 3: Create a dedicated user and data directory

MinIO should never run as root. Create a system user with no login shell, plus the directories for data and configuration.

sudo useradd -r -s /sbin/nologin minio-user
sudo mkdir -p /data /etc/minio
sudo chown minio-user:minio-user /data /etc/minio
sudo chmod 750 /data /etc/minio

useradd -r creates a system account, and -s /sbin/nologin prevents anyone logging in as it. The chown gives that user ownership of the data directory so MinIO can write objects there.

Step 4: Set the root credentials

MinIO needs a root access key and secret key. Store them in /etc/default/minio, which the systemd service will read. The secret key must be at least 8 characters long.

sudo tee /etc/default/minio > /dev/null <<'EOF'
MINIO_ROOT_USER=minioadmin
MINIO_ROOT_PASSWORD=ChangeMeToAStrongSecret123
MINIO_VOLUMES="/data"
MINIO_OPTS="--console-address :9001"
EOF
sudo chown root:minio-user /etc/default/minio
sudo chmod 640 /etc/default/minio

Replace the password with a long random value of your own — for example, generate one with openssl rand -hex 16. The file is restricted to root and the MinIO group so the credentials are not world-readable. MINIO_VOLUMES points at your data directory, and --console-address :9001 puts the web console on port 9001 while the S3 API listens on the default port 9000.

Step 5: Create a systemd service

A systemd unit makes MinIO start at boot and restart automatically if it crashes. Create the unit file:

sudo tee /etc/systemd/system/minio.service > /dev/null <<'EOF'
[Unit]
Description=MinIO Object Storage
Documentation=https://min.io/docs/minio/linux/index.html
Wants=network-online.target
After=network-online.target

[Service]
User=minio-user
Group=minio-user
EnvironmentFile=/etc/default/minio
ExecStart=/usr/local/bin/minio server $MINIO_OPTS $MINIO_VOLUMES
Restart=always
RestartSec=5
LimitNOFILE=65536

[Install]
WantedBy=multi-user.target
EOF

Wants=network-online.target ensures MinIO starts after networking is up. Restart=always brings it back after a crash, and LimitNOFILE=65536 raises the open-file limit, which matters once you store many objects. Now reload systemd and enable the service:

sudo systemctl daemon-reload
sudo systemctl enable --now minio
sudo systemctl status minio

enable --now both enables the service at boot and starts it immediately. The status output should show Active: active (running).

Step 6: Open the firewall

If UFW is active, allow the two MinIO ports. Skip this step if your server has no firewall or uses a cloud security group instead — in that case, open the same ports there.

sudo ufw allow 9000/tcp
sudo ufw allow 9001/tcp
sudo ufw reload
sudo ufw status

Port 9000 serves the S3-compatible API your apps talk to; port 9001 serves the browser console. Only open 9001 to the networks that need admin access.

Step 7: Verify it worked

First, check the built-in health endpoints:

curl -s http://localhost:9000/minio/health/live
curl -s http://localhost:9000/minio/health/ready

Both should return an empty body with HTTP 200 — a quick way to confirm the server is alive and ready. Next, open the web console in your browser at http://YOUR_SERVER_IP:9001 and log in with the root user and password from Step 4. You should see the MinIO dashboard with zero buckets. Finally, confirm the process is listening where you expect:

sudo ss -tlnp | grep minio

You should see listeners on ports 9000 and 9001.

Step 8: Create your first bucket with the mc client (optional but recommended)

The MinIO client (mc) is the fastest way to manage buckets from the terminal. Install it and point it at your server:

sudo wget https://dl.min.io/client/mc/release/linux-amd64/mc -O /usr/local/bin/mc
sudo chmod +x /usr/local/bin/mc
mc alias set local http://localhost:9000 minioadmin ChangeMeToAStrongSecret123

Use the same credentials from Step 4. Then create a bucket and upload a test file:

mc mb local/backups
echo "hello minio" > /tmp/test.txt
mc cp /tmp/test.txt local/backups/
mc ls local/backups

mc mb makes the bucket, mc cp uploads the file, and mc ls lists it. The file should also appear in the web console under the backups bucket. Your S3-compatible endpoint is now ready: any S3 client can use http://YOUR_SERVER_IP:9000 with these credentials.

Step 9: Enable versioning and plan TLS

Two quick hardening steps turn this test setup into something you can trust with real data. First, turn on bucket versioning so an accidental overwrite or delete never destroys the only copy of a file:

mc version enable local/backups
mc version info local/backups

Versioning keeps every previous version of an object, so you can restore an older copy with mc cp using its version ID. Second, do not expose the console over plain HTTP on the public internet. Put MinIO behind Nginx with a Let's Encrypt certificate and proxy port 9000 and 9001 through HTTPS, or restrict both ports to your VPN or office IP range in the firewall. TLS also matters for your applications: most S3 SDKs will refuse or warn about unsigned endpoints, so a valid certificate avoids a whole class of client errors later.

Common issues & fixes

MinIO fails to start: "password must be at least 8 characters"

The MINIO_ROOT_PASSWORD in /etc/default/minio is too short. Set a longer value, then run sudo systemctl restart minio.

Permission denied on /data

The data directory must belong to minio-user. Fix ownership with sudo chown -R minio-user:minio-user /data and restart the service. Check the logs with sudo journalctl -u minio -n 50 to confirm.

Console loads but the API returns "connection refused"

Something else may already occupy port 9000, or the service only bound to localhost. Check with sudo ss -tlnp | grep 9000 and look for a conflicting process. If you run MinIO behind Nginx, make sure the proxy passes the Host header and forwards to 127.0.0.1:9000.

Uploads fail with "Access Denied"

This usually means the access key is wrong or the bucket policy blocks the operation. Re-check the credentials in /etc/default/minio match what your client uses, and verify the bucket exists with mc ls local.

MinIO stops after a reboot

The service was not enabled. Run sudo systemctl enable minio and confirm with sudo systemctl is-enabled minio, which should print enabled.


That is a complete single-node MinIO setup on Ubuntu 24.04: a systemd-managed server, firewall rules, health checks, and your first bucket created with mc. From here you can point application uploads at the S3 endpoint, configure bucket lifecycle rules, or add TLS with a reverse proxy. If you need help designing storage, backups, or a multi-node MinIO cluster for production, XpertBees can set it up for you.