Closed mbilal100 closed 8 months ago
Microsoft Windows [Version 10.0.22000.1574]
1.1.3.0
5.15.90.1
Debian (bullseye)
No response
Our Linux C application execute simple Windows binary from inside WSL2 and randomly this Windows exe throw following error
2<3>WSL (27216) ERROR: UtilAcceptVsock:248: accept4 failed 110
Windows exe compiled from following code
#include <stdio.h> int main() { printf("Calling from Linux C application inside WSL2 ...\n"); return 0; }
Strace logs:
execve("/home/sokol/app.exe", ["/home/sokol/app.exe"], ["SHELL=/bin/bash", "sharedstatedir=/com", "base_libdir=/lib", "PKG_CONFIG_DIR=/home/sokol/flex_"..., "PKG_CONFIG_PATH=/home/sokol/flex"..., "docdir=${datarootdir}/doc/${PACK"..., "libc_cv_ssp_all=no", "nonarch_base_libdir=/lib", "CPPFLAGS_FOR_BUILD=-I/home/sokol"..., "oldincludedir=/usr/include", "LANGUAGE=C", "prefix=/usr", "LDFLAGS_FOR_BUILD=-L/home/sokol/"..., "PYTHONHASHSEED=0", "BUILD_AS=as ", "BUILD_AR=ar", "BUILD_LDFLAGS=-L/home/sokol/flex"..., "STRINGS=riscv64-oe-linux-strings", "base_prefix=", "CPP=riscv64-oe-linux-gcc -E --sy"..., "LD_FOR_BUILD=ld ", "libc_cv_localedir=/usr/lib/local"..., "libc_cv_include_x86_isa_level=no", "lt_cv_sys_lib_dlsearch_path_spec"..., "BUILD_CXX=g++ ", "libc_cv_rootsbindir=/sbin", "BUILD_NM=nm", "datadir=/usr/share", "nonarch_libdir=/usr/lib", "PWD=/home/sokol/flex_prjs2/build"..., "as_nl=\n", "SOURCE_DATE_EPOCH=1672259150", "LOGNAME=sokol", "CFLAGS_FOR_BUILD=-I/home/sokol/f"..., "CXX=riscv64-oe-linux-g++ --no"..., "CXXFLAGS=-I/home/sokol/flex_prjs"..., "libc_cv_slibdir=/lib", "BUILD_CC=gcc ", "TZ=UTC", "libexecdir=/usr/libexec", "BUILD_FC=gfortran ", "includedir=/usr/include", "LDFLAGS=-Wl,-O1 -Wl,--hash-style"..., "HOME=/home/sokol", "WSL_INTEROP=/run/WSL/9_interop", "systemd_system_unitdir=/lib/syst"..., "libdir=/usr/lib", "CXX_FOR_BUILD=g++ ", "base_sbindir=/sbin", "CCLD=riscv64-oe-linux-gcc --n"..., "CPPFLAGS=", "BUILD_CXXFLAGS=-I/home/sokol/fle"..., "sbindir=/usr/sbin", "LD=riscv64-oe-linux-ld --sysroot"..., "systemd_unitdir=/lib/systemd", "sysconfdir=/etc", "BUILD_RANLIB=ranlib -D", "PERL_HASH_SEED=0", "COLLECT_GCC=/home/sokol/flex_prj"..., "mandir=/usr/share/man", "CPP_FOR_BUILD=gcc -E", "libc_cv_ssp_strong=no", "PKG_CONFIG_LIBDIR=/home/sokol/fl"..., "READELF=riscv64-oe-linux-readelf", "ac_cv_prog_MSGFMT=", "BUILD_CFLAGS=-I/home/sokol/flex_"..., "localstatedir=/var", "exec_prefix=/usr", "CC_FOR_BUILD=gcc ", "USER=sokol", "BUILD_CCLD=gcc ", "servicedir=/srv", "AR=riscv64-oe-linux-gcc-ar", "AS=riscv64-oe-linux-as ", "ac_cv_path_BASH_SHELL=/bin/bash", "CXXFLAGS_FOR_BUILD=-I/home/sokol"..., "SHLVL=2", "NM=riscv64-oe-linux-gcc-nm", "BUILD_CPPFLAGS=-I/home/sokol/fle"..., "GIT_CEILING_DIRECTORIES=/home/so"..., "systemd_user_unitdir=/usr/lib/sy"..., "DUALCASE=1", "libc_cv_ssp=no", "PSEUDO_DISABLED=1", "PKG_CONFIG_DISABLE_UNINSTALLED=y"..., "PKG_CONFIG_SYSROOT_DIR=/home/sok"..., "base_bindir=/bin", "OBJCOPY=riscv64-oe-linux-objcopy", "OMP_NUM_THREADS=16", "FC=riscv64-oe-linux-gfortran "..., "MAKE=make", "PKG_CONFIG_SYSTEM_LIBRARY_PATH=/"..., "LC_ALL=C", "STRIP=riscv64-oe-linux-strip", "BUILD_STRIP=strip", "OBJDUMP=riscv64-oe-linux-objdump", "CONFIG_SITE=/home/sokol/flex_prj"..., "PATH=/home/sokol/flex_prjs2/buil"..., "infodir=/usr/share/info", "CC=riscv64-oe-linux-gcc --no-"..., "CFLAGS=-I/home/sokol/flex_prjs2/"..., "BUILD_CPP=gcc -E", "PSEUDO_UNLOAD=1", "bindir=/usr/bin", "CONFIG_SHELL=/bin/bash", "PKG_CONFIG_SYSTEM_INCLUDE_PATH=/"..., "RANLIB=riscv64-oe-linux-gcc-ranl"..., "OLDPWD=/home/sokol/flex_prjs2/bu"..., "BUILD_LD=ld ", "_=/usr/bin/strace"]) = 0 arch_prctl(ARCH_SET_FS, 0x3e2e90) = 0 set_tid_address(0x3e2e30) = 27216 gettid() = 27216 gettid() = 27216 gettid() = 27216 gettid() = 27216 brk(NULL) = 0x576000 brk(0x578000) = 0x578000 mmap(0x576000, 4096, PROT_NONE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x576000 mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7fb4ba0cf000 mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7fb4ba0ce000 mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7fb4ba0cd000 mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7fb4ba0cc000 mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7fb4ba0cb000 mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7fb4ba0ca000 mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7fb4ba0c9000 mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7fb4ba0c8000 sched_getaffinity(0, 128, [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15]) = 32 mmap(NULL, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7fb4ba0c6000 getpid() = 27216 getpid() = 27216 uname({sysname="Linux", nodename="Windows11-wsl", release="5.15.90.1-microsoft-standard-WSL2", version="#1 SMP Fri Jan 27 02:56:13 UTC 2023", machine="x86_64", domainname=""}) = 0 getcwd("/home/sokol/flex_prjs2/build/tmp/work/riscv64-oe-linux/glibc/2.35-r0/build-riscv64-oe-linux", 4096) = 92 readlink("/home", 0x7fffba8d5f90, 4082) = -1 EINVAL (Invalid argument) readlink("/home/sokol", 0x7fffba8d5f90, 4088) = -1 EINVAL (Invalid argument) readlink("/home/sokol/app.exe", "/mnt/e/siemens/app.exe", 4096) = 22 readlink("/mnt", 0x7fffba8d5f90, 4078) = -1 EINVAL (Invalid argument) readlink("/mnt/e", 0x7fffba8d5f90, 4080) = -1 EINVAL (Invalid argument) readlink("/mnt/e/siemens", 0x7fffba8d5f90, 4088) = -1 EINVAL (Invalid argument) readlink("/mnt/e/siemens/app.exe", 0x7fffba8d5f90, 4096) = -1 EINVAL (Invalid argument) open("/proc/self/mountinfo", O_RDONLY|O_LARGEFILE) = 3 mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7fb4ba0c5000 read(3, "73 80 0:26 / /mnt/wsl rw,relatim"..., 1024) = 1024 read(3, "xmode=000\n105 80 0:52 / /run rw,"..., 1024) = 1024 read(3, "p/memory rw,nosuid,nodev,noexec,"..., 1024) = 1024 read(3, "mnt/wslg/versions.txt rw,relatim"..., 1024) = 891 read(3, "", 1024) = 0 close(3) = 0 munmap(0x7fb4ba0c5000, 4096) = 0 mmap(NULL, 16384, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7fb4ba0c2000 getcwd("/home/sokol/flex_prjs2/build/tmp/work/riscv64-oe-linux/glibc/2.35-r0/build-riscv64-oe-linux", 4096) = 92 munmap(0x7fb4ba0c2000, 16384) = 0 getcwd("/home/sokol/flex_prjs2/build/tmp/work/riscv64-oe-linux/glibc/2.35-r0/build-riscv64-oe-linux", 4096) = 92 open("/proc/self/mountinfo", O_RDONLY|O_LARGEFILE) = 3 mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7fb4ba0c5000 read(3, "73 80 0:26 / /mnt/wsl rw,relatim"..., 1024) = 1024 read(3, "xmode=000\n105 80 0:52 / /run rw,"..., 1024) = 1024 read(3, "p/memory rw,nosuid,nodev,noexec,"..., 1024) = 1024 read(3, "mnt/wslg/versions.txt rw,relatim"..., 1024) = 891 read(3, "", 1024) = 0 close(3) = 0 munmap(0x7fb4ba0c5000, 4096) = 0 access("/run/WSL/9_interop", F_OK) = 0 socket(AF_UNIX, SOCK_STREAM|SOCK_CLOEXEC, 0) = 3 connect(3, {sa_family=AF_UNIX, sun_path="/run/WSL/9_interop"}, 110) = 0 write(3, "\20\0\0\0\10\0\0\0", 8) = 8 poll([{fd=3, events=POLLIN}], 1, 10000) = 1 ([{fd=3, revents=POLLIN|POLLHUP}]) read(3, "codebench-wsl-13.0.0-20230307161"..., 256) = 35 close(3) = 0 ioctl(0, TCGETS, 0x7fffba8d8ef8) = -1 ENOTTY (Inappropriate ioctl for device) socket(AF_VSOCK, SOCK_STREAM|SOCK_CLOEXEC, 0) = 3 bind(3, {sa_family=AF_VSOCK, sa_data="\0\0\377\377\377\377\377\377\377\377\0\0\0\0"}, 16) = 0 getsockname(3, {sa_family=AF_VSOCK, sa_data="\0\0n\326\231?\377\377\377\377\0\0\0\0"}, [16]) = 0 listen(3, 4) = 0 access("/run/WSL/9_interop", F_OK) = 0 socket(AF_UNIX, SOCK_STREAM|SOCK_CLOEXEC, 0) = 4 connect(4, {sa_family=AF_UNIX, sun_path="/run/WSL/9_interop"}, 110) = 0 write(4, "\7\0\0\0\33\1\0\0n\326\231?\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"..., 283) = 283 poll([{fd=3, events=POLLIN}], 1, 10000) = 0 (Timeout) getpid() = 27216 writev(2, [{iov_base="<3>WSL (27216) ERROR: UtilAccept"..., iov_len=62}, {iov_base=NULL, iov_len=0}], 2<3>WSL (27216) ERROR: UtilAcceptVsock:248: accept4 failed 110 ) = 62 close(4) = 0 close(3) = 0 munmap(0x7fb4ba0c9000, 4096) = 0 munmap(0x7fb4ba0ca000, 4096) = 0 munmap(0x7fb4ba0cb000, 4096) = 0 munmap(0x7fb4ba0cc000, 4096) = 0 munmap(0x7fb4ba0cd000, 4096) = 0 munmap(0x7fb4ba0ce000, 4096) = 0 munmap(0x7fb4ba0cf000, 4096) = 0 exit_group(1) = ? +++ exited with 1 +++
Executing Windows exe should print
Calling from Linux C application inside WSL2
Executing Window exe throw following
Please find link for WSL logs WslLogs-2023-03-09_12-23-57.zip
This issue has been automatically closed since it has not had any activity for the past year. If you're still experiencing this issue please re-file this as a new issue or feature request.
Thank you!
Windows Version
Microsoft Windows [Version 10.0.22000.1574]
WSL Version
1.1.3.0
Are you using WSL 1 or WSL 2?
Kernel Version
5.15.90.1
Distro Version
Debian (bullseye)
Other Software
No response
Repro Steps
Our Linux C application execute simple Windows binary from inside WSL2 and randomly this Windows exe throw following error
2<3>WSL (27216) ERROR: UtilAcceptVsock:248: accept4 failed 110
Windows exe compiled from following code
Strace logs:
Expected Behavior
Executing Windows exe should print
Actual Behavior
Executing Window exe throw following
Diagnostic Logs
Please find link for WSL logs WslLogs-2023-03-09_12-23-57.zip