From: Eva Kurchatova <eva.kurchatova@virtuozzo.com>
To: khorenko@virtuozzo.com
Cc: devel@openvz.org
Subject: [Devel] [PATCH hci-8.1 v8 0/2] selftests: ve: fix ve_perms, introduce vtty_stress
Date: Thu, 8 Oct 2026 06:52:17 +0300 [thread overview]
Message-ID: <20261008035335.2823931-1-eva.kurchatova@virtuozzo.com> (raw)
Patchset for tasks:
https://virtuozzo.atlassian.net/browse/VSTOR-144955
https://virtuozzo.atlassian.net/browse/VSTOR-144771
Should be merged in this order, since without the ve fix, the testsuite
will not pass at all.
Changes in v8:
2/2:
- Take a high random veid instead of asking the kernel if one is in use.
- A master that cannot be opened fails the test unless the device is
absent or denied.
- Scan the kernel log one last time after the cleanup, the last report
could land after the scan.
- A signal that lands while the master waits for the slave's count no
longer leaves the slave running to its own deadline.
- Correct feature trailer to follow other ve selftests.
Link to v7: http://lore.virtuozzo.com/kernel/20261006221704.2507107-1-eva.kurchatova@virtuozzo.com/T/#t
Changes in v7:
2/2:
- Read the kernel log every second, match more warning patterns, count
a ring overrun or kmsg read error as a complaint.
- Try the next cgroup id when a running container holds the veid.
- Skip when mknod()/mkdtemp() is refused or /dev/kmsg cannot be opened.
instead of skipping on the first one for good.
- The slave side exits when its parent is already gone.
- Clarify that the veid check is best-effort and subject to TOCTOU.
- Correct the referenced vtty fix commit hash.
- Minor cleanup / skip fixes.
1/2:
- Mention the set_entry() change in the message.
Link to v6: http://lore.virtuozzo.com/kernel/20261002044431.1632888-1-eva.kurchatova@virtuozzo.com/T/#t
Changes in v6:
2/2:
- Ask the kernel whether the veid is taken before writing ve.veid, and
skip when it is, instead of assuming the 108..200 range is free.
- Skip when the slave node lands on a nodev mount, where mknod()
succeeds and every open fails with EACCES.
- kmsg_check() still fails on any WARNING, BUG or Oops record, as the
v2 review asked: the node runs nothing else during the test.
Link to v5: http://lore.virtuozzo.com/kernel/20261001032531.1307025-1-eva.kurchatova@virtuozzo.com/T/#t
Changes in v5:
2/2:
- Rebased.
- Drop the vendored uapi structure definition.
- Use newly introduced VE test helpers instead of hand-rolled ones.
- Check subtree_control write, skip if needed.
- Report child exit status alongside "The VE side never came up".
Link to v4: http://lore.virtuozzo.com/kernel/5fc7cab9-c486-4568-8034-693d756b1050@virtuozzo.com/T/#t
Changes in v4:
1/2:
- Check the snprintf() in set_entry() against sizeof() and give the
buffer PATH_MAX, similar to how ve_open_rel() already operates.
- Correct comments.
- Fix the Feature tag.
2/2:
- Move the double release_tty() history out of the file header into
the message. The header keeps what the test does, how it reaches
both ends, and the usage line.
- Match "general protection fault" records as well, they carry no
"Oops:" prefix.
- Reason about the test reproduction time in the commit message.
- Document that the test assumes its veid is not in use by a
running container in the commit message.
- Default to 30 seconds and drop the settings file, the run now fits
the timeout the suite already has.
Link to v3: https://lists.openvz.org/pipermail/devel/2026-September/085277.html
Changes in v3:
1/2:
- Code unchanged from v2. Only the test count and the sentence about
the proc variant were dropped from the message; the rest of the v2
review is addressed in v4.
2/2:
- Corrections in commit message and comments.
- Bail out on the first open errno that is not EBUSY, EIO or ENXIO,
on both ends, and report it, instead of spinning erroneously.
- Match /dev/kmsg one record at a time.
- Keep reading /dev/kmsg after EPIPE instead of stopping on it.
- Put the slave node under a private mkdtemp() directory instead of a
fixed name in /tmp.
- Kill the slave side when the master side gives up, with
PR_SET_PDEATHSIG as the backstop, so it does not hold the cgroup
open against destroy_ve().
- Call destroy_ve() on the one exit path that skipped it.
- Default to 60 seconds, from 600.
Link to v2: https://lists.openvz.org/pipermail/devel/2026-September/085125.html
Changes in v2:
1/2:
- Add the Fixes: tag, the code is unchanged.
2/2:
- Add the binary to .gitignore.
- Formatting: single spaces, one initialiser per line.
Link to v1: https://lists.openvz.org/pipermail/devel/2026-September/085081.html
Eva Kurchatova (2):
selftests: ve: grant the directories the files sit in
selftests: ve: introduce vtty pair teardown stress test
tools/testing/selftests/ve/.gitignore | 1 +
tools/testing/selftests/ve/Makefile | 3 +-
tools/testing/selftests/ve/ve_perms_test.c | 34 +-
tools/testing/selftests/ve/ve_vtty_stress.c | 415 ++++++++++++++++++++
4 files changed, 450 insertions(+), 3 deletions(-)
create mode 100644 tools/testing/selftests/ve/ve_vtty_stress.c
--
2.56.0
_______________________________________________
Devel mailing list
Devel@openvz.org
https://lists.openvz.org/mailman/listinfo/devel
next reply other threads:[~2026-10-08 3:55 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-10-08 3:52 Eva Kurchatova [this message]
2026-10-08 3:52 ` [Devel] [PATCH hci-8.1 v8 1/2] selftests: ve: grant the directories the files sit in Eva Kurchatova
2026-10-08 3:56 ` no-reply
2026-10-08 3:52 ` [Devel] [PATCH hci-8.1 v8 2/2] selftests: ve: introduce vtty pair teardown stress test Eva Kurchatova
2026-10-08 4:03 ` no-reply
2026-10-09 2:43 ` Eva Kurchatova (Virtuozzo)
2026-10-08 16:24 ` [Devel] [PATCH hci-8.1 v8 0/2] selftests: ve: fix ve_perms, introduce vtty_stress Konstantin Khorenko
2026-10-08 16:32 ` Konstantin Khorenko
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20261008035335.2823931-1-eva.kurchatova@virtuozzo.com \
--to=eva.kurchatova@virtuozzo.com \
--cc=devel@openvz.org \
--cc=khorenko@virtuozzo.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.