Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 01 Aug 2018 21:20:23 +0000
From:      bugzilla-noreply@freebsd.org
To:        bugs@FreeBSD.org
Subject:   [Bug 230273] linux_select CALL is very slow (100 ms)
Message-ID:  <bug-230273-227@https.bugs.freebsd.org/bugzilla/>

next in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D230273

            Bug ID: 230273
           Summary: linux_select CALL is very slow (100 ms)
           Product: Base System
           Version: 11.2-RELEASE
          Hardware: amd64
                OS: Any
            Status: New
          Severity: Affects Only Me
          Priority: ---
         Component: kern
          Assignee: bugs@FreeBSD.org
          Reporter: jasonmader@gmail.com

Linux compatibility layer is taking a long time with either a read() or
select() in a jail. I noticed this because the select() is called about 20
times during a network exchange, so the network communication takes about 2
seconds. I always see this take 100 ms, so it makes me think it's a timeout=
 of
some kind.

0.000007856 linux_time(0x0)                      =3D 1533157182 (0x5b621f3e)
0.000017328 linux_newstat("/etc/localtime",0x7fffffffc500) =3D 0 (0x0)
0.000009030 linux_select(0x1,0x7fffffffd310,0x0,0x0,0x7fffffffd390) =3D 1 (=
0x1)
0.000009219 read(0,"f\0\0\0",4)                  =3D 4 (0x4)
0.104589092 linux_select(0x1,0x7fffffffd290,0x0,0x0,0x7fffffffd310) =3D 1 (=
0x1)

Here's a ktrace of a similar call sequence,

 70145 lstc_server CALL  linux_time(0)
 70145 lstc_server RET   linux_time 1533157805/0x5b6221ad
 70145 lstc_server CALL  linux_newstat(0x800b56e6b,0x7fffffffc500)
 70145 lstc_server NAMI  "/compat/linux/etc/localtime"
 70145 lstc_server NAMI  "/etc/localtime"
 70145 lstc_server STRU  struct stat {dev=3D2853443365, ino=3D53, mode=3D01=
00444,
nlink=3D1, uid=3D0, gid=3D0, rdev=3D4294967295, atime=3D1504808312.22183000=
0,
mtime=3D1504808312.221900000, ctime=3D1532210790.994694000,
birthtime=3D1504808312.221900000, size=3D118, blksize=3D4096, blocks=3D1, f=
lags=3D0x800 }
 70145 lstc_server RET   linux_newstat 0
 70145 lstc_server CALL  linux_select(0x1,0x7fffffffd310,0,0,0x7fffffffd390)
 70145 lstc_server RET   linux_select 1
 70145 lstc_server CALL  read(0,0x7fffffffd3a0,0x4)
 70145 lstc_server GIO   fd 0 read 4 bytes
       "f\0\0\0"
 70145 lstc_server RET   read 4
 70145 lstc_server CALL  linux_select(0x1,0x7fffffffd290,0,0,0x7fffffffd310)
 70145 lstc_server RET   linux_select 1


And maybe related, or not, even with

jail {
  sysvsem;
}

linux_semop() always returns an error.

0.000006559 linux_time(0x0)                      =3D 1533157182 (0x5b621f3e)
0.000007433 linux_semop(0x20000,0x7fffffffd3d0,0x1) ERR#-11 'Resource
temporarily unavailable'
0.000380425 linux_select(0x6,0x7fffffffd310,0x0,0x0,0x7fffffffd390) =3D 1 (=
0x1)
0.000010566 linux_accept(0x4,0x0,0x7fffffffd3ac) =3D 0 (0x0)
0.000007921 linux_getpeername(0x0,0x7fffffffd1b0,0x7fffffffd1cc) =3D 0 (0x0)
0.000007532 linux_getpeername(0x0,0x7fffffffd1b0,0x7fffffffd1cc) =3D 0 (0x0)
0.000009828 linux_semop(0x20000,0x7fffffffd3d0,0x1) ERR#-11 'Resource
temporarily unavailable'
0.000009462 linux_getpeername(0x0,0x7fffffffd3c0,0x7fffffffd3dc) =3D 0 (0x0)
0.000009209 linux_getpeername(0x0,0x7fffffffd3c0,0x7fffffffd3dc) =3D 0 (0x0)

--=20
You are receiving this mail because:
You are the assignee for the bug.=



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-230273-227>