Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 15 Mar 2007 15:40:01 +0200
From:      "Emile Coetzee" <freebsd-stable@clarotech.co.za>
To:        <freebsd-stable@freebsd.org>
Subject:   Re: Openvpn tap uses 99% cpu time
Message-ID:  <001101c76707$6e796530$7efaa8c0@clarotech.co.za>

next in thread | raw e-mail | index | archive | help
>
> I then ran 
>
> ktrace -p 1083 -f openvpn2.dump 
>
> This produced no data at all.
>   

>Shouldn't. :-) You need to run ktrace then kdump to dump the trace.<

I figured that part out on my own thanks ;) The second file is 0kb in size
running a kdump on it produces no output.

>Correlate the cpu spin with the wallclock time in the kdump output, and 
paste an excerpt of what you get -- it sounds like it is spinning on a 
syscall.<
I have no idea what exactly you want me to do here. Point me at some reading
material if you like or show me some examples.

>I can't seem to get the stuff from pastebin, it just times out, so ok to 
post an excerpt here.<

No worries below is the last part of the first ktrace. I have dropped a full
copy on our webserver: http://www.clarotech.co.za/dump/openvpn.txt

  1082 sh       RET   read 4096/0x1000
  1082 sh       CALL  mmap(0,0xea000,0x5,0x20002,0x3,0,0,0)
  1082 sh       RET   mmap 672038912/0x280e8000
  1082 sh       CALL  mprotect(0x281b5000,0x1000,0x7)
  1082 sh       RET   mprotect 0
  1082 sh       CALL  mprotect(0x281b5000,0x1000,0x5)
  1082 sh       RET   mprotect 0
  1082 sh       CALL  mmap(0x281b6000,0x6000,0x3,0x12,0x3,0,0xcd000,0)
  1082 sh       RET   mmap 672882688/0x281b6000
  1082 sh       CALL  mmap(0x281bc000,0x16000,0x3,0x1012,0xffffffff,0,0,0)
  1082 sh       RET   mmap 672907264/0x281bc000
  1082 sh       CALL  close(0x3)
  1082 sh       RET   close 0
  1082 sh       CALL  access(0x28092000,0)
  1082 sh       NAMI  "/lib/libncurses.so.6"
  1082 sh       RET   access 0
  1082 sh       CALL  sysarch(0xa,0xbfbfec60)
  1082 sh       RET   sysarch 0
  1082 sh       CALL  mmap(0,0x440,0x3,0x1000,0xffffffff,0,0,0)
  1082 sh       RET   mmap 672997376/0x281d2000
  1082 sh       CALL  munmap(0x281d2000,0x440)
  1082 sh       RET   munmap 0
  1082 sh       CALL  mmap(0,0x3f8,0x3,0x1000,0xffffffff,0,0,0)
  1082 sh       RET   mmap 672997376/0x281d2000
  1082 sh       CALL  munmap(0x281d2000,0x3f8)
  1082 sh       RET   munmap 0
  1082 sh       CALL  mmap(0,0x1208,0x3,0x1000,0xffffffff,0,0,0)
  1082 sh       RET   mmap 672997376/0x281d2000
  1082 sh       CALL  munmap(0x281d2000,0x1208)
  1082 sh       RET   munmap 0
  1082 sh       CALL  mmap(0,0x58d8,0x3,0x1000,0xffffffff,0,0,0)
  1082 sh       RET   mmap 672997376/0x281d2000
  1082 sh       CALL  munmap(0x281d2000,0x58d8)
  1082 sh       RET   munmap 0
  1082 sh       CALL  sigprocmask(0x1,0x28087980,0xbfbfec30)
  1082 sh       RET   sigprocmask 0
  1082 sh       CALL  sigprocmask(0x3,0x28087990,0)
  1082 sh       RET   sigprocmask 0
  1082 sh       CALL  getpid
  1082 sh       RET   getpid 1082/0x43a
  1082 sh       CALL  geteuid
  1082 sh       RET   geteuid 0
  1082 sh       CALL  getppid
  1082 sh       RET   getppid 1006/0x3ee
  1082 sh       CALL  readlink(0x281ade4b,0xbfbfe810,0x3f)
  1082 sh       NAMI  "/etc/malloc.conf"
  1082 sh       RET   readlink -1 errno 2 No such file or directory
  1082 sh       CALL  issetugid
  1082 sh       RET   issetugid 0
  1082 sh       CALL  mmap(0,0x1000,0x3,0x1002,0xffffffff,0,0,0)
  1082 sh       RET   mmap 672997376/0x281d2000
  1082 sh       CALL  break(0x8066000)
  1082 sh       RET   break 0
  1082 sh       CALL  break(0x8067000)
  1082 sh       RET   break 0
  1082 sh       CALL  break(0x8068000)
  1082 sh       RET   break 0
  1082 sh       CALL  stat(0x8067004,0xbfbfebb0)
  1082 sh       NAMI  "/var/mail/support"
  1082 sh       RET   stat 0
  1082 sh       CALL  getuid
  1082 sh       RET   getuid 0
  1082 sh       CALL  geteuid
  1082 sh       RET   geteuid 0
  1082 sh       CALL  getgid
  1082 sh       RET   getgid 0
  1082 sh       CALL  getegid
  1082 sh       RET   getegid 0
  1082 sh       CALL  open(0xbfbfee07,0,0x28066b71)
  1082 sh       NAMI  "./tapserver.sh"
  1082 sh       RET   open 3
  1082 sh       CALL  fcntl(0x3,0,0xa)
  1082 sh       RET   fcntl 10/0xa
  1082 sh       CALL  close(0x3)
  1082 sh       RET   close 0
  1082 sh       CALL  fcntl(0xa,0x2,0x1)
  1082 sh       RET   fcntl 0
  1082 sh       CALL  sigaction(0x2,0,0xbfbfebb0)
  1082 sh       RET   sigaction 0
  1082 sh       CALL  sigaction(0x2,0xbfbfebb0,0xbfbfeb90)
  1082 sh       RET   sigaction 0
  1082 sh       CALL  sigaction(0x2,0,0xbfbfebb0)
  1082 sh       RET   sigaction 0
  1082 sh       CALL  sigaction(0x2,0xbfbfebb0,0)
  1082 sh       RET   sigaction 0
  1082 sh       CALL  sigaction(0x3,0,0xbfbfebb0)
  1082 sh       RET   sigaction 0
  1082 sh       CALL  sigaction(0x3,0xbfbfebb0,0xbfbfeb90)
  1082 sh       RET   sigaction 0
  1082 sh       CALL  sigaction(0x3,0,0xbfbfebb0)
  1082 sh       RET   sigaction 0
  1082 sh       CALL  sigaction(0x3,0xbfbfebb0,0)
  1082 sh       RET   sigaction 0
  1082 sh       CALL  sigaction(0xf,0,0xbfbfebb0)
  1082 sh       RET   sigaction 0
  1082 sh       CALL  sigaction(0xf,0xbfbfebb0,0xbfbfeb90)
  1082 sh       RET   sigaction 0
  1082 sh       CALL  sigaction(0x1c,0,0xbfbfebb0)
  1082 sh       RET   sigaction 0
  1082 sh       CALL  sigaction(0x1c,0xbfbfebb0,0xbfbfeb90)
  1082 sh       RET   sigaction 0
  1082 sh       CALL  __getcwd(0xbfbfe860,0x400)
  1082 sh       RET   __getcwd 0
  1082 sh       CALL  read(0xa,0x8063d60,0x3ff)
  1082 sh       GIO   fd 10 read 80 bytes
       "/usr/local/sbin/openvpn --daemon --config
/usr/local/etc/openvpn/tapserver.conf
       "
  1082 sh       RET   read 80/0x50
  1082 sh       CALL  break(0x8069000)
  1082 sh       RET   break 0
  1082 sh       CALL  fork
  1082 sh       RET   fork 1083/0x43b
  1082 sh       CALL  getpgrp
  1082 sh       RET   getpgrp 1082/0x43a
  1082 sh       CALL  wait4(0xffffffff,0xbfbfeac8,0x2,0)







Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?001101c76707$6e796530$7efaa8c0>