---
title: "Proxmox — LXC Container Autostart After PVE Reboot"
aliases: [proxmox-autostart, lxc-autostart, pve-reboot-containers, proxmox-start-at-boot]
tags: [proxmox, lxc, homelab, reboot, autostart, containers]
sources:
  - "daily/2026-04-24.md"
created: 2026-04-24
updated: 2026-04-24
---

# Proxmox — LXC Container Autostart After PVE Reboot

After rebooting the Proxmox VE host, LXC containers do not start automatically unless the "Start at boot" option is explicitly enabled per container. This is a per-container setting — not a global default. Containers created via community scripts (like the tteck/ProxmoxVE scripts) may or may not have this enabled depending on the script. After a kernel update and reboot, any container without "Start at boot" will remain stopped and all services inside it (Docker, Vaultwarden, Nextcloud, etc.) will be unavailable.

## Key Points

- **"Start at boot" is off by default** for LXC containers in Proxmox — must be manually enabled per container
- **After any PVE host reboot** (kernel update, maintenance), containers with the flag disabled stay stopped until manually started
- **Docker containers inside an LXC** inherit the stopped state — if the LXC doesn't start, no Docker services start either
- **Enabling via UI:** Proxmox web UI → Container → Options → Start at boot → Edit → check the box
- **Enabling via CLI:** `pct set <VMID> --onboot 1`
- After enabling, verify with `pct config <VMID> | grep onboot` — should show `onboot: 1`

## Details

### The Incident Pattern (2026-04-24)

Proxmox kernel was updated from `6.17.13-2 → 6.17.13-3` and PVE rebooted. After the reboot, CT 104 (Vaultwarden in Docker) did not come back up automatically. The Proxmox host was healthy, but CT 104 remained in stopped state because its "Start at boot" option was not enabled.

This is a common oversight: when first setting up a container, the autostart flag is not set because the service is being configured interactively. Once configuration is complete, the flag is often forgotten.

### Enabling Autostart

**Via Proxmox Web UI:**
1. Select the container in the left sidebar
2. Click **Options** tab
3. Double-click **Start at boot**
4. Check **Start at boot** → OK

**Via CLI on the Proxmox host:**
```bash
# Enable autostart for container 104
pct set 104 --onboot 1

# Verify
pct config 104 | grep onboot
# onboot: 1

# Apply to multiple containers at once
for VMID in 100 101 102 103 104 105 106 107 108 109 110; do
    pct set $VMID --onboot 1
done
```

**View all containers and their autostart status:**
```bash
# List all LXCs with their autostart flag
pct list | while read VMID STATUS LOCK NAME; do
    [[ "$VMID" =~ ^[0-9]+$ ]] && \
    echo "$VMID $NAME $(pct config $VMID | grep -o 'onboot: [01]' || echo 'onboot: 0')"
done
```

### Startup Order and Delay

For containers with dependencies (e.g., a database LXC must start before an app LXC), set startup order and delay:

```bash
# Start container 101 first (order=1), then wait 30 seconds before the next
pct set 101 --startup order=1,up=30,down=10

# Start container 102 second (order=2)
pct set 102 --startup order=2,up=30,down=10
```

- `order=N` — lower numbers start first
- `up=N` — seconds to wait after this container starts before starting the next
- `down=N` — seconds to wait during shutdown before stopping this container

### VMs vs LXC

The same "Start at boot" setting applies to Proxmox VMs (QEMU/KVM). For VMs, the CLI is:
```bash
qm set <VMID> --onboot 1
```

For Home Assistant OS or other VMs that should always run, enable this immediately after installation.

### Post-Reboot Verification Checklist

After any Proxmox host reboot (kernel update, hardware change):

```bash
# 1. Check which containers are running
pct list

# 2. For any stopped container that should be running — start manually and investigate
pct start 104

# 3. Check services inside the container
pct exec 104 -- systemctl status vaultwarden
pct exec 104 -- docker ps  # if Docker-based

# 4. Immediately enable autostart to prevent recurrence
pct set 104 --onboot 1
```

### Why PVE Reboots Happen

Beyond planned maintenance, PVE reboots may be triggered by:
- **Kernel updates:** applied automatically by Proxmox's update mechanism; require reboot to take effect
- **Firmware updates:** motherboard, BIOS, NIC firmware
- **Hardware maintenance:** RAM swap, drive replacement
- **Power events:** UPS transfer, power cycle

With all critical containers set to `--onboot 1`, a PVE reboot becomes a routine maintenance event rather than a service outage.

## Related Concepts

- [[wiki/concepts/immich-lxc-ram-oom]] — Immich in LXC, where the container host (CT 105) was rebooted to apply RAM changes and required CT start verification
- [[wiki/concepts/home-assistant-proxmox-install]] — HAOS VM installed via community scripts; autostart should be enabled post-install
- [[wiki/concepts/proxmox-vm-management-methods]] — broader Proxmox management approaches including CLI and API
- [[wiki/homelab/_index]] — homelab infrastructure context

## Sources

- [[daily/2026-04-24.md]] — After Proxmox kernel update 6.17.13-2 → 6.17.13-3 and PVE reboot, CT 104 (Vaultwarden in Docker) did not start automatically; required manual `pct start 104`; autostart was not enabled on this container
