- 08 Dec, 2015 8 commits
-
-
Pavel Emelyanov authored
So here's the new test class that handles the test from groups set. The class is inherited from zdtm_test one as what it does is -- starts the pseudo-init in ns/uns flavors and asks one to spawn() the sub-tests from the list. All groups tests can only be run inside ns flavor, so if the host flavor is asked, just the pseudo-init is spawned. This is because using ns flavor is the easiest way to spawn all the sub tests under this init (however, h flavor can be supported by marking the pseudo-init as sub-reaper). On stop this pseudo-init is signalled to stop, it in turn stops all the sub-tests and then exits. When the pid namespace destruction is complete, the sub-tests .out-s are checked. Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Pavel Emelyanov authored
Introduce yet another tests set called 'groups'. Each test in this set is a list of existing zdtm tests that can be started side-by-side in an ns flavor. To 'create' such a test the zdtm.py group action is used, which lists tests and semi-randomly groups them together. The grouping possibility is checked by comparing the .desc files of those -- desc-s should coincide. One exception is test dependencies, these are just merged together. After running the group action there appears groups/ dir with tests each containing just the list of zdtm tests that are in a group. The respective .desc file is also generated and this one matches the .desc for tests inside. Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Pavel Emelyanov authored
This is -- add ability to pull more than one binary into mntns root and ability to start zdtm test with more stuff in the environment than generated in start method itself. Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Pavel Emelyanov authored
When starting inside ns flavor the test_init() routine prepares the binary to be run inside namespaces. In particular this routine fork()-s an init, execve()-s one to pick up mappings and exe from the new mntns and then fork()-s the test itself. In order to go back to test_init() for test initialization the execve() is done again, but it's actually not required and confuses the reader. Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Pavel Emelyanov authored
Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Pavel Emelyanov authored
This one is to set up uids for userns, do ip l s lo up for netns and do the prepare_mntns(). BTW, the latter's code is shifted one tab left as this is where it should be. Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Kirill Tkhai authored
This patch implements checkpoint/restore functionality for binfmt_misc mounts. Both magic and extension types and "disabled" state are supported. Signed-off-by:
Kirill Tkhai <ktkhai@virtuozzo.com> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Kirill Tkhai authored
This test is for unix sockets open in DGRAM mode. Server opens a socket, binds it and waits for a signal. Client connects to the socket and sends a message. After the signal server checks that data is readable, and that it's still possible to connect to the bound socket. Signed-off-by:
Kirill Tkhai <ktkhai@virtuozzo.com> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
- 07 Dec, 2015 2 commits
-
-
Pavel Emelyanov authored
So, first of all we've fixed (I hope) the security issues spotted by RedHat people. Another big thing of this release is the huge amount of bug fixes found while testing live migration. And enhancements for live migration itself is Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Pavel Emelyanov authored
Due to security reasons the systemd-spawn mode is no longer supported in service. Also fix the default binding address to be in local cwd not to start global service by chance. Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
- 04 Dec, 2015 6 commits
-
-
Pavel Emelyanov authored
Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Andrew Vagin authored
Currently we see that a cgroup yard are not umounted with the ENOENT error, because cwd was changed. v2: construct a path to remove a roots yard Signed-off-by:
Andrew Vagin <avagin@virtuozzo.com> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Cyrill Gorcunov authored
Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org> Acked-by:
Tycho Andersen <tycho.andersen@canonical.com> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Cyrill Gorcunov authored
Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org> Acked-by:
Tycho Andersen <tycho.andersen@canonical.com> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Cyrill Gorcunov authored
This conflicts with predefined constants in our own syscalls lib. Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org> Acked-by:
Tycho Andersen <tycho.andersen@canonical.com> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Cyrill Gorcunov authored
We will need it for cr-check. Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org> iAcked-by:
Tycho Andersen <tycho.andersen@canonical.com> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
- 03 Dec, 2015 12 commits
-
-
Pavel Emelyanov authored
When using non-run command the 'sat' option is not in opts dict, so it should be checked with softer method. Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Pavel Emelyanov authored
This test does nasty things with the root it runs in, in particular is kills and creates /dev/null which may result in /dev/null become 'deleted' for the tests running in paralles with this. The lattest is critical for uns flavor as ghost /dev/null will not be re-created (mknod fails). Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Pavel Emelyanov authored
Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Pavel Emelyanov authored
Also remove now unused skip_pid label. Signed-off-by:
Pavel Emelyanov <xemul@parallels.com> Acked-by:
Andrew Vagin <avagin@virtuozzo.com>
-
Pavel Emelyanov authored
The ns and uns flavors are MUCH better ways of launching tests in namespaces. Signed-off-by:
Pavel Emelyanov <xemul@parallels.com> Acked-by:
Andrew Vagin <avagin@virtuozzo.com>
-
Pavel Emelyanov authored
Signed-off-by:
Pavel Emelyanov <xemul@parallels.com> Acked-by:
Andrew Vagin <avagin@virtuozzo.com>
-
Pavel Emelyanov authored
Signed-off-by:
Pavel Emelyanov <xemul@parallels.com> Acked-by:
Andrew Vagin <avagin@virtuozzo.com>
-
Pavel Emelyanov authored
Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Pavel Emelyanov authored
Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Pavel Emelyanov authored
Instead of doing some dirs/files/links in launcher and some in libzdtm, make everything in the launcher. The library is then just to set up the namespaces. Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Tycho Andersen authored
If we get EBUSY here, it means that we didn't umount in the test (i.e. we didn't call fini() on some path). We should just do that instead. Signed-off-by:
Tycho Andersen <tycho.andersen@canonical.com> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Tycho Andersen authored
The kernel only requires that we supply a scope id to bind() when the source address is of certain types, so lets only save/supply the scope id in these cases. Signed-off-by:
Tycho Andersen <tycho.andersen@canonical.com> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
- 02 Dec, 2015 1 commit
-
-
Tycho Andersen authored
This change does two things to be more defensive: 1. add a checkskip script which fails if __NR_seccomp isn't defined, and 2. allows seccomp_filter_tsync to compile even if it isn't defined (and then fails "gracefully" with a skip message if it does). The checkskip bits are necessary because zdtm.sh gets confused if the test exits 0 without actually invoking criu. Signed-off-by:
Tycho Andersen <tycho.andersen@canonical.com> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
- 30 Nov, 2015 8 commits
-
-
Andrew Vagin authored
It's possiable, if a parent task lives in a sub-mntns and its child lives in the root mntns. A mount namespace is restored before forking children, so all children are created in parent's mount namespace. If a child lives in another mount namespace, we need to move it into the required mntns. Reported-by: Mr Jenkins Signed-off-by:
Andrew Vagin <avagin@virtuozzo.com> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Andrew Vagin authored
Signed-off-by:
Andrew Vagin <avagin@virtuozzo.com> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Tycho Andersen authored
This tests c/r of the link-local scope-id argument to bind(). v2: sort the interfaces so diff works Signed-off-by:
Tycho Andersen <tycho.andersen@canonical.com> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Tycho Andersen authored
For some ipv6 scope types (link local, amongo others), we need to tell the kernel the ifindex of the interface whose address we want to bind to as well as the address itself. v2: use SO_BINDTODEVICE to get the ifname, and pass that through instead of using netlink to grab all the ipv6 sockets via rtnetlink. Signed-off-by:
Tycho Andersen <tycho.andersen@canonical.com> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Pavel Emelyanov authored
Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Andrew Vagin authored
CID 154853 (#1 of 1): Uninitialized scalar variable (UNINIT) 7. uninit_use_in_call: Using uninitialized value c when calling write. Reported-by: coverity Signed-off-by:
Andrew Vagin <avagin@virtuozzo.com> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Andrew Vagin authored
CID 154850 (#1 of 1): Resource leak (RESOURCE_LEAK) 9. leaked_handle: Handle variable cwd_fd going out of scope leaks the handle. Reported-by: coverity Signed-off-by:
Andrew Vagin <avagin@virtuozzo.com> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Andrew Vagin authored
CID 154852 (#1 of 3): Resource leak (RESOURCE_LEAK) 32. leaked_storage: Variable info going out of scope leaks the storage it points to. Reported-by: coverity Signed-off-by:
Andrew Vagin <avagin@virtuozzo.com> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
- 27 Nov, 2015 3 commits
-
-
Tycho Andersen authored
This header is unused, and not present on kernels w/o CONFIG_BPF_SYSCALL, so let's not require it. Signed-off-by:
Tycho Andersen <tycho.andersen@canonical.com> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Andrew Vagin authored
nsid->mnt.ns_fd is initialized into 0, so currently fini_restore_mntns() closes the 0 descriptor if processes lives in a current mount namespace (NS_CRIU). Without this patch I get the following error: (00.166444) 4109: Inherit fd tty:[8800:d] -> 0 has been closed v2: typo fix v3: do nothing when processes are restored in the local mntns Signed-off-by:
Andrew Vagin <avagin@virtuozzo.com> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Andrew Vagin authored
stopped03 is an old name of stopped12 Signed-off-by:
Andrew Vagin <avagin@virtuozzo.com> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-