kata-containers/osbuilder

x86: Kata fails to start with dracut based initrd

nitkon opened this issue · 1 comments

Description of problem

With dracut based initrd on x86

docker run -it --runtime kata-runtime fedora /bin/bash
docker: Error response from daemon: OCI runtime create failed: Failed to check if grpc server is working: rpc error: code = Unavailable desc = transport is closing: unknown.
ERRO[0020] error waiting for container: context canceled

Without dracut:
image = "/usr/share/kata-containers/kata-containers-image_clearlinux_1.9.0-rc0_agent_ba6ab83c16.img"

[root@nitkon osbuilder]# docker run -it --runtime kata-runtime fedora /bin/bash
[root@d846d10969c6 /]# uname -a
Linux d846d10969c6 4.19.75-57.1.container #1 SMP Thu Jan 1 00:00:00 UTC 1970 x86_64 x86_64 x86_64 GNU/Linux

Expected result

Kata container should be launched without any errors

Actual result

Kernel: Used system kernel: kernel = "/root/go/src/github.com/kata-containers/osbuilder/vmlinuz-5.2.7-200.fc30.x86_64"
Initrd: initrd = "/root/go/src/github.com/kata-containers/osbuilder/kata-containers-initrd.img"

docker run -it --runtime kata-runtime fedora /bin/bash
docker: Error response from daemon: OCI runtime create failed: Failed to check if grpc server is working: rpc error: code = Unavailable desc = transport is closing: unknown.
ERRO[0020] error waiting for container: context canceled

Journalctl runtime logs:

Jan 21 13:50:11 nitkon kata-runtime[15283]: time="2020-01-21T13:50:11.58021231+05:30" level=info msg="loaded configuration" arch=amd64 command=create file=/etc/kata-containers/configuration.toml format=TOML name=kata-runtime pid=15283 source=katautils
Jan 21 13:50:11 nitkon kata-runtime[15283]: time="2020-01-21T13:50:11.580409492+05:30" level=info arch=amd64 arguments="\"create --bundle /run/containerd/io.containerd.runtime.v1.linux/moby/68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74 --pid-file /run/containerd/io.containerd.runtime.v1.linux/moby/68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74/init.pid --console-socket /tmp/pty119535711/pty.sock 68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74\"" command=create commit=2e6fccd56956555354cc1eaf59bfd5d674d78f37 name=kata-runtime pid=15283 source=runtime version=1.9.0-rc0
Jan 21 13:50:11 nitkon kata-runtime[15283]: time="2020-01-21T13:50:11.580708096+05:30" level=error msg="Unable to determine if running rootless" arch=amd64 command=create container=68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74 error="Failed to parse uid map file /proc/self/uid_map" name=kata-runtime pid=15283 source=rootless
Jan 21 13:50:11 nitkon kata-runtime[15283]: time="2020-01-21T13:50:11.582270879+05:30" level=info msg="shm-size detected: 67108864" arch=amd64 command=create container=68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74 name=kata-runtime pid=15283 source=virtcontainers subsystem=oci
Jan 21 13:50:11 nitkon kata-runtime[15283]: time="2020-01-21T13:50:11.585848149+05:30" level=info msg="create netns" arch=amd64 command=create container=68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74 name=kata-runtime netns=/var/run/netns/cni-b0853a60-337b-6e15-5729-03e557c88dc7 pid=15283 source=katautils
Jan 21 13:50:11 nitkon kata-runtime[15283]: time="2020-01-21T13:50:11.768219267+05:30" level=warning msg="load sandbox devices failed" arch=amd64 command=create container=68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74 error="open /run/vc/sbs/68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74/devices.json: no such file or directory" name=kata-runtime pid=15283 sandbox=68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74 sandboxid=68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74 source=virtcontainers subsystem=sandbox
Jan 21 13:50:11 nitkon kata-runtime[15283]: time="2020-01-21T13:50:11.768363197+05:30" level=info msg="adding volume" arch=amd64 command=create container=68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74 name=kata-runtime pid=15283 source=virtcontainers subsystem=qemu volume-type=virtio-9p
Jan 21 13:50:11 nitkon kata-runtime[15283]: time="2020-01-21T13:50:11.768969452+05:30" level=info msg="Endpoints found after scan" arch=amd64 command=create container=68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74 endpoints="[0xc0001fe000]" name=kata-runtime pid=15283 source=virtcontainers subsystem=network
Jan 21 13:50:11 nitkon kata-runtime[15283]: time="2020-01-21T13:50:11.769417265+05:30" level=info msg="Attaching endpoint" arch=amd64 command=create container=68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74 endpoint-type=virtual hotplug=false name=kata-runtime pid=15283 source=virtcontainers subsystem=network
Jan 21 13:50:11 nitkon kata-runtime[15283]: time="2020-01-21T13:50:11.770322841+05:30" level=info msg="Starting VM" arch=amd64 command=create container=68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74 name=kata-runtime pid=15283 sandbox=68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74 source=virtcontainers subsystem=sandbox
Jan 21 13:50:11 nitkon kata-runtime[15283]: time="2020-01-21T13:50:11.77052701+05:30" level=info msg="Adding extra file [0xc0000110b8 0xc0000110a8]" arch=amd64 command=create container=68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74 name=kata-runtime pid=15283 source=virtcontainers subsystem=qmp
Jan 21 13:50:11 nitkon kata-runtime[15283]: time="2020-01-21T13:50:11.770606281+05:30" level=info msg="launching /usr/bin/qemu-vanilla-system-x86_64 with: [-name sandbox-68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74 -uuid 4525d8d0-7983-464e-a738-b83ee20ada92 -machine pc,accel=kvm,kernel_irqchip -cpu host -qmp unix:/run/vc/vm/68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74/qmp.sock,server,nowait -m 2048M,slots=10,maxmem=8479M -device pci-bridge,bus=pci.0,id=pci-bridge-0,chassis_nr=1,shpc=on,addr=2,romfile= -device virtio-serial-pci,disable-modern=false,id=serial0,romfile= -device virtconsole,chardev=charconsole0,id=console0 -chardev socket,id=charconsole0,path=/run/vc/vm/68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74/console.sock,server,nowait -device virtio-scsi-pci,id=scsi0,disable-modern=false,romfile= -object rng-random,id=rng0,filename=/dev/urandom -device virtio-rng,rng=rng0,romfile= -device virtserialport,chardev=charch0,id=channel0,name=agent.channel.0 -chardev socket,id=charch0,path=/run/vc/vm/68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74/kata.sock,server,nowait -device virtio-9p-pci,disable-modern=false,fsdev=extra-9p-kataShared,mount_tag=kataShared,romfile= -fsdev local,id=extra-9p-kataShared,path=/run/kata-containers/shared/sandboxes/68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74,security_model=none -netdev tap,id=network-0,vhost=on,vhostfds=3,fds=4 -device driver=virtio-net-pci,netdev=network-0,mac=02:42:ac:11:00:02,disable-modern=false,mq=on,vectors=4,romfile= -global kvm-pit.lost_tick_policy=discard -vga none -no-user-config -nodefaults -nographic -daemonize -object memory-backend-ram,id=dimm1,size=2048M -numa node,memdev=dimm1 -kernel /usr/share/kata-containers/vmlinuz-4.19.75.54-57.1.container -initrd /root/go/src/github.com/kata-containers/osbuilder/kata-containers-initrd.img -append tsc=reliable no_timer_check rcupdate.rcu_expedited=1 i8042.direct=1 i8042.dumbkbd=1 i8042.nopnp=1 i8042.noaux=1 noreplace-smp reboot=k console=hvc0 console=hvc1 iommu=off cryptomgr.notests net.ifnames=0 pci=lastbus=0 quiet panic=1 nr_cpus=4 agent.use_vsock=false agent.log=debug initcall_debug -pidfile /run/vc/vm/68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74/pid -smp 1,cores=1,threads=1,sockets=4,maxcpus=4]" arch=amd64 command=create container=68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74 name=kata-runtime pid=15283 source=virtcontainers subsystem=qmp
Jan 21 13:50:11 nitkon kata-runtime[15283]: time="2020-01-21T13:50:11.879056026+05:30" level=info msg="{\"QMP\": {\"version\": {\"qemu\": {\"micro\": 0, \"minor\": 1, \"major\": 4}, \"package\": \"\"}, \"capabilities\": [\"oob\"]}}" arch=amd64 command=create container=68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74 name=kata-runtime pid=15283 source=virtcontainers subsystem=qmp
Jan 21 13:50:11 nitkon kata-runtime[15283]: time="2020-01-21T13:50:11.879417785+05:30" level=info msg="QMP details" arch=amd64 command=create container=68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74 name=kata-runtime pid=15283 qmp-capabilities=oob qmp-major-version=4 qmp-micro-version=0 qmp-minor-version=1 source=virtcontainers subsystem=qemu
Jan 21 13:50:11 nitkon kata-runtime[15283]: time="2020-01-21T13:50:11.879599659+05:30" level=info msg="{\"execute\":\"qmp_capabilities\"}" arch=amd64 command=create container=68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74 name=kata-runtime pid=15283 source=virtcontainers subsystem=qmp
Jan 21 13:50:11 nitkon kata-runtime[15283]: time="2020-01-21T13:50:11.896257443+05:30" level=info msg="{\"return\": {}}" arch=amd64 command=create container=68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74 name=kata-runtime pid=15283 source=virtcontainers subsystem=qmp
Jan 21 13:50:11 nitkon kata-runtime[15283]: time="2020-01-21T13:50:11.896470775+05:30" level=info msg="sanner return error: read unix @->/run/vc/vm/68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74/qmp.sock: use of closed network connection" arch=amd64 command=create container=68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74 name=kata-runtime pid=15283 source=virtcontainers subsystem=qmp
Jan 21 13:50:11 nitkon kata-runtime[15283]: time="2020-01-21T13:50:11.896551011+05:30" level=info msg="VM started" arch=amd64 command=create container=68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74 name=kata-runtime pid=15283 sandbox=68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74 source=virtcontainers subsystem=sandbox
Jan 21 13:50:11 nitkon kata-runtime[15283]: time="2020-01-21T13:50:11.89700462+05:30" level=info msg="proxy started" arch=amd64 command=create container=68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74 name=kata-runtime pid=15283 proxy-pid=15605 proxy-url="unix:///run/vc/sbs/68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74/proxy.sock" sandbox=68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74 source=virtcontainers subsystem=kata_agent
Jan 21 13:50:11 nitkon kata-runtime[15283]: time="2020-01-21T13:50:11.897139031+05:30" level=info msg="New client" arch=amd64 command=create container=68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74 name=kata-runtime pid=15283 proxy=15605 source=virtcontainers subsystem=kata_agent url="unix:///run/vc/sbs/68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74/proxy.sock"
Jan 21 13:50:31 nitkon kata-runtime[15283]: time="2020-01-21T13:50:31.898484493+05:30" level=info msg="Stopping Sandbox" arch=amd64 command=create container=68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74 name=kata-runtime pid=15283 source=virtcontainers subsystem=qemu
Jan 21 13:50:31 nitkon kata-runtime[15283]: time="2020-01-21T13:50:31.901234131+05:30" level=info msg="{\"QMP\": {\"version\": {\"qemu\": {\"micro\": 0, \"minor\": 1, \"major\": 4}, \"package\": \"\"}, \"capabilities\": [\"oob\"]}}" arch=amd64 command=create container=68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74 name=kata-runtime pid=15283 source=virtcontainers subsystem=qmp
Jan 21 13:50:31 nitkon kata-runtime[15283]: time="2020-01-21T13:50:31.901848962+05:30" level=info msg="{\"execute\":\"qmp_capabilities\"}" arch=amd64 command=create container=68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74 name=kata-runtime pid=15283 source=virtcontainers subsystem=qmp
Jan 21 13:50:31 nitkon kata-runtime[15283]: time="2020-01-21T13:50:31.902601919+05:30" level=info msg="{\"return\": {}}" arch=amd64 command=create container=68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74 name=kata-runtime pid=15283 source=virtcontainers subsystem=qmp
Jan 21 13:50:31 nitkon kata-runtime[15283]: time="2020-01-21T13:50:31.907879884+05:30" level=info msg="{\"execute\":\"quit\"}" arch=amd64 command=create container=68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74 name=kata-runtime pid=15283 source=virtcontainers subsystem=qmp
Jan 21 13:50:31 nitkon kata-runtime[15283]: time="2020-01-21T13:50:31.908458554+05:30" level=info msg="{\"return\": {}}" arch=amd64 command=create container=68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74 name=kata-runtime pid=15283 source=virtcontainers subsystem=qmp
Jan 21 13:50:31 nitkon kata-runtime[15283]: time="2020-01-21T13:50:31.908527717+05:30" level=info msg="{\"timestamp\": {\"seconds\": 1579594831, \"microseconds\": 908457}, \"event\": \"SHUTDOWN\", \"data\": {\"guest\": false, \"reason\": \"host-qmp-quit\"}}" arch=amd64 command=create container=68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74 name=kata-runtime pid=15283 source=virtcontainers subsystem=qmp
Jan 21 13:50:31 nitkon kata-runtime[15283]: time="2020-01-21T13:50:31.908666255+05:30" level=info msg="cleanup vm path" arch=amd64 command=create container=68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74 dir=/run/vc/vm/68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74 link=/run/vc/vm/68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74 name=kata-runtime pid=15283 source=virtcontainers subsystem=qemu
Jan 21 13:50:31 nitkon kata-runtime[15283]: time="2020-01-21T13:50:31.908774686+05:30" level=info msg="Detaching endpoint" arch=amd64 command=create container=68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74 endpoint-type=virtual name=kata-runtime pid=15283 source=virtcontainers subsystem=network
Jan 21 13:50:31 nitkon kata-runtime[15283]: time="2020-01-21T13:50:31.909060793+05:30" level=info msg="sanner return error: <nil>" arch=amd64 command=create container=68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74 name=kata-runtime pid=15283 source=virtcontainers subsystem=qmp
Jan 21 13:50:31 nitkon kata-runtime[15283]: time="2020-01-21T13:50:31.91727538+05:30" level=info msg="Network namespace \"/var/run/netns/cni-b0853a60-337b-6e15-5729-03e557c88dc7\" deleted" arch=amd64 command=create container=68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74 name=kata-runtime pid=15283 source=virtcontainers subsystem=network
Jan 21 13:50:31 nitkon kata-runtime[15283]: time="2020-01-21T13:50:31.919075311+05:30" level=warning msg="sandox cgroups path is empty" arch=amd64 command=create container=68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74 name=kata-runtime pid=15283 sandbox=68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74 source=virtcontainers subsystem=sandbox
Jan 21 13:50:31 nitkon kata-runtime[15283]: time="2020-01-21T13:50:31.919183223+05:30" level=info msg="cleanup agent" arch=amd64 command=create container=68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74 name=kata-runtime path=/run/kata-containers/shared/sandboxes/68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74 pid=15283 source=virtcontainers subsystem=kata_agent
Jan 21 13:50:31 nitkon kata-runtime[15283]: time="2020-01-21T13:50:31.919575442+05:30" level=warning msg="failed to cleanup netns" arch=amd64 command=create container=68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74 error="failed to get netns /var/run/netns/cni-b0853a60-337b-6e15-5729-03e557c88dc7: failed to Statfs \"/var/run/netns/cni-b0853a60-337b-6e15-5729-03e557c88dc7\": no such file or directory" name=kata-runtime path=/var/run/netns/cni-b0853a60-337b-6e15-5729-03e557c88dc7 pid=15283 source=katautils
Jan 21 13:50:31 nitkon kata-runtime[15283]: time="2020-01-21T13:50:31.919642739+05:30" level=error msg="Failed to check if grpc server is working: rpc error: code = Unavailable desc = transport is closing" arch=amd64 command=create container=68633126dfab0b2195016e29a8b65ede6f840b274ea8e487e4e1f2bc55d33b74 name=kata-runtime pid=15283 source=runtime

Agent logs:

Jan 21 13:54:27 nitkon kata-proxy[32040]: time="2020-01-21T13:54:27.478122112+05:30" level=fatal msg="channel error" error="accept unix /run/vc/sbs/02e63b23d63cc9d961559dc51b211b31ad64bcb8ecc831897c943c437c2c7d93/proxy.sock: use of closed network connection" name=kata-proxy pid=32040 sandbox=02e63b23d63cc9d961559dc51b211b31ad64bcb8ecc831897c943c437c2c7d93 source=proxy
[root@nitkon runtime]# kata-runtime version
kata-runtime  : 1.10.0-rc0
   commit   : 73a63baab58480d1546c0fb8e9e762055cd2c8a7
   OCI specs: 1.0.1-de

Dracut Creation Steps:

[root@nitkon osbuilder]# make BUILD_METHOD=dracut DRACUT_KVERSION=5.2.7-200.fc30.x86_64 AGENT_INIT=yes initrd
mkdir -p /root/go/src/github.com/kata-containers/osbuilder/dracut_overlay
# Modules preload
/root/go/src/github.com/kata-containers/osbuilder/rootfs-builder/rootfs.sh -o 1.10.0-rc0-7526f4957dbd6893d1b36d6170c34ff7342b9f97-dirty -r /root/go/src/github.com/kata-containers/osbuilder/dracut_overlay
INFO: Create symlink to /tmp in /var to create private temporal directories with systemd
INFO: Create /root/go/src/github.com/kata-containers/osbuilder/dracut_overlay/etc
INFO: Configure chrony file /root/go/src/github.com/kata-containers/osbuilder/dracut_overlay/etc/chrony.conf
INFO: Pull Agent source code
[OK] Pull Agent source code
INFO: Build agent
~/go/src/github.com/kata-containers/agent ~/go/src/github.com/kata-containers/osbuilder
make[1]: Entering directory '/root/go/src/github.com/kata-containers/agent'
rm -f kata-agent kata-agent.service
make[1]: Leaving directory '/root/go/src/github.com/kata-containers/agent'
make[1]: Entering directory '/root/go/src/github.com/kata-containers/agent'
go build -buildmode=pie -tags "" -o kata-agent \
	-ldflags "-X main.version=1.10.0-rc0-7c2d8ab303085d0c59dcba784c22bdf168ff8961 -X main.seccompSupport=no "
make[1]: Leaving directory '/root/go/src/github.com/kata-containers/agent'
make[1]: Entering directory '/root/go/src/github.com/kata-containers/agent'
install -D kata-agent /root/go/src/github.com/kata-containers/osbuilder/dracut_overlay/usr/bin/kata-agent
make[1]: Leaving directory '/root/go/src/github.com/kata-containers/agent'
~/go/src/github.com/kata-containers/osbuilder
[OK] Agent installed
INFO: Install /root/go/src/github.com/kata-containers/osbuilder/dracut_overlay/usr/bin/kata-agent as init process
[OK] Agent is installed as init process
INFO: Check init is installed
[OK] init is installed
INFO: Create /etc/resolv.conf file in rootfs if not exist
INFO: Creating summary file
INFO: Created summary file '/var/lib/osbuilder/osbuilder.yaml' inside rootfs
mkdir -p /root/go/src/github.com/kata-containers/osbuilder/dracut_overlay/etc/modules-load.d
echo 9p 9pnet 9pnet_virtio | tr " " "\n" > /root/go/src/github.com/kata-containers/osbuilder/dracut_overlay/etc/modules-load.d/kata-modules.conf
Creating initrd image based on the host OS using dracut
dracut --no-compress --conf /dev/null --confdir /root/go/src/github.com/kata-containers/osbuilder/dracut/dracut.conf.d --include /root/go/src/github.com/kata-containers/osbuilder/dracut_overlay / /root/go/src/github.com/kata-containers/osbuilder/kata-containers-initrd.img 5.2.7-200.fc30.x86_64
cp: not writing through dangling symlink '/var/tmp/dracut.Akllbo/initramfs///sbin/init'  <-----------------
cp: cannot overwrite directory '/var/tmp/dracut.Akllbo/initramfs///var/tmp' with non-directory <-------------
[root@nitkon osbuilder]# cat dracut/dracut.conf.d/10-drivers.conf 
#
# Copyright (c) 2019 SUSE LLC
#
# SPDX-License-Identifier: Apache-2.0

# Specify a space-separated set of kernel modules to copy from the host to 
# the initramfs image. For example:
drivers="9p 9pnet 9pnet_virtio"
#drivers=""

root@nitkon dracut.conf.d]# cat 05-base.conf 
#
# Copyright (c) 2019 SUSE LLC
#
# SPDX-License-Identifier: Apache-2.0

# Main dracut config for Kata Containers

# do NOT combine early microcode with ramdisk
early_microcode="no"
# do NOT install only what's needed to boot the local host 
hostonly="no"
# do NOT store the kernel command line arguments in the initramfs
hostonly_cmdline="no"
# create reproducible images
reproducible="yes"
# dracut modules to include (NOTE: these are NOT kernel modules)
dracutmodules="kernel-modules udev-rules syslog systemd"
[root@nitkon dracut_overlay]# ls
etc  init  lib  sbin  usr  var
[root@nitkon dracut_overlay]# tree
.
├── etc
│   ├── chrony.conf
│   ├── modules-load.d
│   │   └── kata-modules.conf
│   ├── resolv.conf
│   └── systemd
│       └── system
│           └── basic.target.wants
│               └── kata-containers.target -> /usr/lib/systemd/system/kata-containers.target
├── init -> ./usr/lib/systemd/systemd
├── lib
│   └── systemd
│       └── systemd -> ../../init
├── sbin
│   └── init
├── usr
│   └── bin
└── var
    ├── lib
    │   └── osbuilder
    │       └── osbuilder.yaml
    └── tmp -> ../tmp

13 directories, 9 files

The dracut plumbing doesn't work out of the box for fedora kernels (or most distro kernels I suspect). You can check the fedora packaging changes we have to get an idea of what's required: https://src.fedoraproject.org/rpms/kata-osbuilder/tree/master

The changes are: