ClusterLabs / ClusterLabs/resource-agents
ERROR: LXC container name not set!
- Dominant language
- Shell
- Stars
- 519
- Forks
- 608
- Avg merge
- 6d 1h
- Merged PRs (30d)
- 7
Description
OS: Debian 10/11/12
Kernel: 5.10.0-15-amd64 - 6.1.0-18-amd64
Env (depens on deb ver):
- resource-agents 1:4.7.0-1~bpo10+1, pacemaker 2.0.5-2, corosync 3.1.2-2, lxc 1:4.0.6-2
- resource-agents 1:4.12.0-2, pacemaker 2.1.5-1+deb12u1, corosync 3.1.7-1, lxc 1:5.0.2-1+deb12u2
Just trying to add new resource
```
lxc-start -n front-2.fr
pcs resource create front-2.fr ocf:heartbeat:lxc config=/mnt/cluster_volumes/lxc2/front-2.fr/config container=front-2.fr
```
After ~5min want to remove it
`pcs resource remove front-2.fr --force`
got an error and cluster starts to migrate
`Mar 29 23:28:51 cse2.fr lxc(front-2.fr)[2103391]: ERROR: LXC container name not set!`
as i can see in `/usr/lib/ocf/resource.d/heartbeat/lxc` the error spawns when agent can't get `OCF_RESKEY_container` variable.
This bug is only on clusters who work without reboot a long time. For example after fencing i can add/remove lxc resources and everything will be fine for a while.
The question is: why? And how to debug it?
Contributor guide
No contributing guide indexed for this repository
Research direction
Start with /usr/lib/ocf/resource.d/heartbeat/lxc and reproduce the reported pcs resource create and remove sequence using the Debian, Pacemaker, Corosync, and LXC versions listed. Trace when OCF_RESKEY_container is unavailable and compare behavior before and after fencing; done means the cause is established and the resource removal path no longer produces the reported error.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- debian, linux, shell
- Domain
- devops, infrastructure, operating-systems
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100