AlmaLinux 9 LXC Container startet nach Upgrade auf 9.1 nicht mehr

AnK

Member
Dec 28, 2021
13
1
8
40
Hi,

ich habe bei mir AlmaLinux 9 LXC Container laufen.
Testweise habe ich jetzt einen davon auf 9.1 aktualisiert.

Leider startet der jetzt aber nicht mehr... :(
Nein, es hat nix mit dem pve-container Update Bug zu tun.
Code:
# pct start 106
run_buffer: 321 Script exited with status 25
lxc_init: 847 Failed to run lxc.hook.pre-start for container "106"
__lxc_start: 2008 Failed to initialize container "106"
startup for container '106' failed
Im Debug Log steht folgendes:
Code:
xc-start 106 20221119124515.722 INFO     lsm - ../src/lxc/lsm/lsm.c:lsm_init_static:38 - Initialized LSM security driver AppArmor
lxc-start 106 20221119124515.722 INFO     conf - ../src/lxc/conf.c:run_script_argv:337 - Executing script "/usr/share/lxc/hooks/lxc-pve-prestart-hook" for container "106", config section "lxc"
lxc-start 106 20221119124516.175 DEBUG    conf - ../src/lxc/conf.c:run_buffer:310 - Script exec /usr/share/lxc/hooks/lxc-pve-prestart-hook 106 lxc pre-start produced output: unknown ID 'almalinux' in /etc/os-release file, trying fallback detection

lxc-start 106 20221119124516.177 DEBUG    conf - ../src/lxc/conf.c:run_buffer:310 - Script exec /usr/share/lxc/hooks/lxc-pve-prestart-hook 106 lxc pre-start produced output: unsupported centos release 'AlmaLinux release 9.1 (Lime Lynx)'

lxc-start 106 20221119124516.189 ERROR    conf - ../src/lxc/conf.c:run_buffer:321 - Script exited with status 25
lxc-start 106 20221119124516.189 ERROR    start - ../src/lxc/start.c:lxc_init:847 - Failed to run lxc.hook.pre-start for container "106"
lxc-start 106 20221119124516.189 ERROR    start - ../src/lxc/start.c:__lxc_start:2008 - Failed to initialize container "106"
lxc-start 106 20221119124516.189 INFO     conf - ../src/lxc/conf.c:run_script_argv:337 - Executing script "/usr/share/lxcfs/lxc.reboot.hook" for container "106", config section "lxc"
lxc-start 106 20221119124516.691 INFO     conf - ../src/lxc/conf.c:run_script_argv:337 - Executing script "/usr/share/lxc/hooks/lxc-pve-poststop-hook" for container "106", config section "lxc"
lxc-start 106 20221119124517.141 ERROR    lxc_start - ../src/lxc/tools/lxc_start.c:main:306 - The container failed to start
lxc-start 106 20221119124517.141 ERROR    lxc_start - ../src/lxc/tools/lxc_start.c:main:311 - Additional information can be obtained by setting the --logfile and --logpriority options

Jemand ne Idee?

Danke & Gruß
Frank

UPDATE:

Ich hab nen Workaround gefunden. :)
Code:
# diff /usr/share/perl5/PVE/LXC/Setup/CentOS.pm /usr/share/perl5/PVE/LXC/Setup/CentOS.pm.org
25c25
<     if ($1 >= 5 && $1 <= 9.1) {
---
>     if ($1 >= 5 && $1 <= 9) {
 
Last edited:
I have same error

pct start 107 --debug
Code:
run_buffer: 321 Script exited with status 25
lxc_init: 847 Failed to run lxc.hook.pre-start for container "107"
__lxc_start: 2008 Failed to initialize container "107"
pve-prestart-hook" for container "107", config section "lxc"
DEBUG    conf - conf.c:run_buffer:310 - Script exec /usr/share/lxc/hooks/lxc-pve-prestart-hook 107 lxc pre-start produced output: unknown ID 'almalinux' i>

DEBUG    conf - conf.c:run_buffer:310 - Script exec /usr/share/lxc/hooks/lxc-pve-prestart-hook 107 lxc pre-start produced output: unsupported centos relea>

ERROR    conf - conf.c:run_buffer:321 - Script exited with status 25
ERROR    start - start.c:lxc_init:847 - Failed to run lxc.hook.pre-start for container "107"
ERROR    start - start.c:__lxc_start:2008 - Failed to initialize container "107"
INFO     conf - conf.c:run_script_argv:337 - Executing script "/usr/share/lxcfs/lxc.reboot.hook" for container "107", config section "lxc"


nano /etc/pve/lxc/107.conf
Code:
arch: amd64
cores: 4
hostname: backup-satu.plasawebhost.com
memory: 4096
net0: name=eth0,bridge=vmbr0,firewall=1,gw=103.151.140.49,hwaddr=9A:7E:8C:70:E8:72,ip=103.151.140.60/28,type=veth
ostype: centos
rootfs: local-lvm:vm-107-disk-0,size=2500G
swap: 4096
lxc.apparmor.profile: unconfined
 
You can get it running again, when you do the following change:

Edit /usr/share/perl5/PVE/LXC/Setup/CentOS.pm
Search for if ($1 >= 5 && $1 <= 9) {
And change it to if ($1 >= 5 && $1 <= 9.1) {
(you have only to append the .1)
 
You can get it running again, when you do the following change:

Edit /usr/share/perl5/PVE/LXC/Setup/CentOS.pm
Search for if ($1 >= 5 && $1 <= 9) {
And change it to if ($1 >= 5 && $1 <= 9.1) {
(you have only to append the .1)
work fine
thank you
 
Testweise habe ich jetzt einen davon auf 9.1 aktualisiert.
mit 7.3 sollte das schon gehen;

> pveversion -v
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!