Help please, I dont know whats going on. Qbittorrent container w/ Gluetun can't be stopped.
I am trying to connect gluetun to qbittorrent. First I got them both running in the same docker compose file but the qbittorrent container would not reset. Then I tried separating the .yml files, both times everything worked like it should torrents downloaded and it was connected to the VPN, but I cant restart the container. Gluetun is working without issue. Below is my docker compose files and the error.
$ sudo docker restart qbitt
Error response from daemon: Cannot restart container qbitt: tried to kill container, but did not receive an exit event
Here is the command I found that helped me stop the container (no idea what this does):
$ ps aux | grep (Docker ID) | awk '(print $1 $2}'
root112502
user1440452
$ sudo kill -9 112502
Docker-compose without gluetun:
services:
qbittorrent:
image: lscr.io/linuxserver/qbittorrent:latest
container_name: qbitt
network_mode: "container:gluetun"
environment:
- TZ=America/New_York
- WEBUI_PORT=8080
- PUID=1000
- PGID=1000
volumes:
- /home/mxh/Documents/gluetun/qbitt/config:/config
- /media/mxh/External1:/downloads
- /home/mxh/in:/internal
restart: always
Docker compose with gluetun:
- NET_ADMIN
devices:
- /dev/net/tun:/dev/net/tun
ports:
- 8888:8888/tcp # HTTP proxy
- 8388:8388/tcp # Shadowsocks
- 8388:8388/udp # Shadowsocks
- 8080:8080 # Qbittorrent
volumes:
- /home/mxh/Documents/gluetun:/gluetun
environment:
- VPN_SERVICE_PROVIDER=surfshark
- VPN_TYPE=openvpn
# OpenVPN:
- OPENVPN_USER=user
- OPENVPN_PASSWORD=pass
# Timezone for accurate log times
- TZ=America/New_York
- SERVER_COUNTRIES=United States
# qbittorrent:
# image: lscr.io/linuxserver/qbittorrent:latest
# container_name: qbitt
# network_mode: "service:gluetun"
# environment:
# - TZ=America/New_York
# - WEBUI_PORT=8080
# - PUID=1000
# - PGID=1000
# volumes:
# - /home/mxh/Documents/gluetun/qbitt/config:/config
# - /media/mxh/External1:/downloads
# - /home/mxh/in:/internal
# depends_on:
# gluetun:
# condition: service_healthy
# restart: always
Posted Nov 5, 2025, 11:39 PM UTC