diff --git a/install.sh b/install.sh index 2e70f66..2bab1d5 100755 --- a/install.sh +++ b/install.sh @@ -119,8 +119,7 @@ if [ $ctid -gt 99 ]; then LXC_CHK=$ctid else # Get next free LXC-number - LXC_LST=$( lxc-ls -1 | tail -1 ) - LXC_CHK=$((LXC_LST+1)); + LXC_CHK=$(($(pct list | cut -d' ' -f1 | tail -1) + 1)) fi if [ $LXC_CHK -lt 100 ] || [ -f /etc/pve/qemu-server/$LXC_CHK.conf ]; then