werc on openbsd-current

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

werc on openbsd-current

Patrick Marchand
Hi, I'm trying to run werc (http://werc.cat-v.org/) on my local openbsd-current (13th july snapshot)

I cant seem to get slowcgi to execute the main script properly. I'm not sure what the problem is but I've included the output of a few commands and a ktrace of slowcgi in an attachment.

chiron$ cat /etc/httpd.conf
server "default" {
  listen on * port 80
  location "*" {
    root "/werc/bin"
    fastcgi
  }
}
chiron$ ls -la /var/www/{,werc,werc/bin,usr/local/plan9/bin}
/var/www/:
total 1648
drwxr-xr-x  12 root     daemon     512 Jul 13 02:29 .
drwxr-xr-x  27 root     wheel      512 Jul 13 03:09 ..
drwxr-xr-x   2 root     daemon     512 Jul 13 02:29 acme
drwxr-xr-x   2 root     daemon     512 Jul 13 02:29 bin
drwx-----T   2 www      daemon     512 Jul 13 02:29 cache
drwxr-xr-x   2 root     daemon     512 Jul 13 02:29 cgi-bin
drwxr-xr-x   2 root     daemon     512 Jul 13 02:29 conf
drwxr-xr-x   3 root     daemon     512 Jul 13 02:29 htdocs
-rw-------   1 root     daemon  802588 Jul 16 19:41 ktrace.out
drwxr-xr-x   2 root     daemon     512 Jul 13 02:29 logs
drwxr-xr-x   2 root     daemon     512 Jul 17 13:01 run
drwxr-xr-x   6 root     daemon     512 Jul 16 21:10 usr
drwxr-xr-x  10 patrick  daemon     512 Jul 16 23:50 werc

/var/www/usr/local/plan9/bin:
total 73036
drwxr-xr-x  2 root  daemon     1024 Jul 17 13:00 .
drwxr-xr-x  7 root  daemon      512 Jul 17 13:00 ..
-rwxr-xr-x  1 root  daemon   486140 Jul 17 13:00 ascii
-rwxr-xr-x  1 root  daemon   818231 Jul 17 13:00 awk
-rwxr-xr-x  1 root  daemon   457311 Jul 17 13:00 basename
-rwxr-xr-x  1 root  daemon   518430 Jul 17 13:00 bc
-rwxr-xr-x  1 root  daemon  1104193 Jul 17 13:00 cal
-rwxr-xr-x  1 root  daemon   466569 Jul 17 13:00 cat
-rwxr-xr-x  1 root  daemon   461423 Jul 17 13:00 cleanname
-rwxr-xr-x  1 root  daemon   470422 Jul 17 13:00 cmp
-rwxr-xr-x  1 root  daemon  1090116 Jul 17 13:00 date
-rwxr-xr-x  1 root  daemon  1151900 Jul 17 13:00 dc
-rwxr-xr-x  1 root  daemon   480646 Jul 17 13:00 dd
-rwxr-xr-x  1 root  daemon  1160227 Jul 17 13:00 diff
-rwxr-xr-x  1 root  daemon  1078554 Jul 17 13:00 du
-rwxr-xr-x  1 root  daemon   457552 Jul 17 13:00 echo
-rwxr-xr-x  1 root  daemon  1150034 Jul 17 13:00 ed
-rwxr-xr-x  1 root  daemon   554206 Jul 17 13:00 factor
-rwxr-xr-x  1 root  daemon   486355 Jul 17 13:00 fmt
-rwxr-xr-x  1 root  daemon  1092056 Jul 17 13:00 fortune
-rwxr-xr-x  1 root  daemon   472869 Jul 17 13:00 freq
-rwxr-xr-x  1 root  daemon   472789 Jul 17 13:00 getflags
-rwxr-xr-x  1 root  daemon   530612 Jul 17 13:00 grep
-rwxr-xr-x  1 root  daemon   555017 Jul 17 13:00 hoc
-rwxr-xr-x  1 root  daemon   460497 Jul 17 13:00 join
-rwxr-xr-x  1 root  daemon   723848 Jul 17 13:00 listen1
-rwxr-xr-x  1 root  daemon   489547 Jul 17 13:00 look
-rwxr-xr-x  1 root  daemon  1148449 Jul 17 13:00 ls
-rwxr-xr-x  1 root  daemon   471447 Jul 17 13:00 md5sum
-rwxr-xr-x  1 root  daemon   594875 Jul 17 13:00 mk
-rwxr-xr-x  1 root  daemon   470553 Jul 17 13:00 mkdir
-rwxr-xr-x  1 root  daemon  1070302 Jul 17 13:00 mtime
-rwxr-xr-x  1 root  daemon   411386 Jul 17 13:00 pbd
-rwxr-xr-x  1 root  daemon   543081 Jul 17 13:00 primes
-rwxr-xr-x  1 root  daemon  1285061 Jul 17 13:00 rc
-rwxr-xr-x  1 root  daemon   472896 Jul 17 13:00 read
-rwxr-xr-x  1 root  daemon  1077905 Jul 17 13:00 rm
-rwxr-xr-x  1 root  daemon   393072 Jul 17 13:00 sam
-rwxr-xr-x  1 root  daemon   509331 Jul 17 13:00 sed
-rwxr-xr-x  1 root  daemon   543025 Jul 17 13:00 seq
-rwxr-xr-x  1 root  daemon   471452 Jul 17 13:00 sha1sum
-rwxr-xr-x  1 root  daemon   416733 Jul 17 13:00 sleep
-rwxr-xr-x  1 root  daemon   523284 Jul 17 13:00 sort
-rwxr-xr-x  1 root  daemon   494286 Jul 17 13:00 split
-rwxr-xr-x  1 root  daemon      551 Jul 17 13:00 ssam
-rwxr-xr-x  1 root  daemon   474094 Jul 17 13:00 strings
-rwxr-xr-x  1 root  daemon  1086387 Jul 17 13:00 tail
-rwxr-xr-x  1 root  daemon   488256 Jul 17 13:00 tee
-rwxr-xr-x  1 root  daemon  1081422 Jul 17 13:00 test
-rwxr-xr-x  1 root  daemon   476576 Jul 17 13:00 touch
-rwxr-xr-x  1 root  daemon   466402 Jul 17 13:00 tr
-rwxr-xr-x  1 root  daemon   995553 Jul 17 13:00 troff
-rwxr-xr-x  1 root  daemon   476150 Jul 17 13:00 unicode
-rwxr-xr-x  1 root  daemon   475937 Jul 17 13:00 uniq
-rwxr-xr-x  1 root  daemon   468219 Jul 17 13:00 unutf
-rwxr-xr-x  1 root  daemon   474386 Jul 17 13:00 urlencode
-rwxr-xr-x  1 root  daemon   470468 Jul 17 13:00 wc
-rwxr-xr-x  1 root  daemon   543282 Jul 17 13:00 yacc

/var/www/werc:
total 344
drwxr-xr-x  10 patrick  daemon     512 Jul 16 23:50 .
drwxr-xr-x  12 root     daemon     512 Jul 13 02:29 ..
drwxr-xr-x   8 patrick  daemon     512 Jul 16 16:17 .git
-rw-r--r--   1 patrick  daemon    2970 Jul 28  2017 README
drwxr-xr-x   8 patrick  daemon     512 Jul 28  2017 apps
drwxr-xr-x   4 patrick  daemon     512 Jul 16 22:26 bin
drwxr-xr-x   3 patrick  daemon     512 Jul 16 15:40 etc
-rw-------   1 root     daemon  149816 Jul 16 23:13 ktrace.out
drwxr-xr-x   2 patrick  daemon     512 Jul 28  2017 lib
drwxr-xr-x   3 patrick  daemon     512 Jul 28  2017 pub
drwxrwxr-x   3 patrick  daemon     512 Jul 16 16:09 sites
drwxr-xr-x   3 patrick  daemon     512 Jul 28  2017 tpl

/var/www/werc/bin:
total 2268
drwxr-xr-x   4 patrick  daemon      512 Jul 16 22:26 .
drwxr-xr-x  10 patrick  daemon      512 Jul 16 23:50 ..
drwxr-xr-x   2 patrick  daemon      512 Jul 28  2017 aux
-rwxr-xr-x   1 patrick  daemon     5891 Jul 28  2017 cgilib.rc
drwxr-xr-x   3 patrick  daemon      512 Jul 28  2017 contrib
-rwxr-xr-x   1 patrick  daemon     5155 Jul 28  2017 corehandlers.rc
-rwxr-xr-x   1 patrick  daemon      818 Jul 28  2017 fltr_cache.rc
-rwxr-xr-x   1 patrick  daemon  1087197 Jul 16 22:21 fortune
-rwxr-xr--   1 patrick  www         212 Jul 16 22:26 hello.cgi
-rwxr-xr-x   1 patrick  daemon      767 Jul 28  2017 template.awk
-rwxr-xr-x   1 patrick  daemon     4195 Jul 28  2017 werc.rc
-rwxr-xr-x   1 patrick  daemon      153 Jul 28  2017 werc_errlog_wrap.rc
-rwxr-xr-x   1 patrick  daemon      467 Jul 28  2017 wercconf.rc
-rwxr-xr-x   1 patrick  daemon     8648 Jul 28  2017 werclib.rc
chiron$
chiron$ doas ktrace -i slowcgi -dd
doas ([hidden email]) password:
slowcgi: socket: /var/www/run/slowcgi.sock
slowcgi: slowcgi_user: www
slowcgi: chroot: /var/www
slowcgi: inflight incremented, now 1
slowcgi: version:         1
slowcgi: type:            1
slowcgi: requestId:       1
slowcgi: contentLength:   8
slowcgi: paddingLength:   0
slowcgi: reserved:        0
slowcgi: role             1
slowcgi: flags            0
slowcgi: version:         1
slowcgi: type:            4
slowcgi: requestId:       1
slowcgi: contentLength:   686
slowcgi: paddingLength:   0
slowcgi: reserved:        0
slowcgi: env[0], PATH_INFO=
slowcgi: env[1], SCRIPT_NAME=/werc.rc
slowcgi: env[2], SCRIPT_FILENAME=/werc/bin/werc.rc
slowcgi: env[3], QUERY_STRING=
slowcgi: env[4], DOCUMENT_ROOT=/werc/bin
slowcgi: env[5], DOCUMENT_URI=/werc.rc
slowcgi: env[6], GATEWAY_INTERFACE=CGI/1.1
slowcgi: env[7], HTTP_ACCEPT=text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8
slowcgi: env[8], HTTP_ACCEPT_ENCODING=gzip, deflate
slowcgi: env[9], HTTP_ACCEPT_LANGUAGE=en-US,en;q=0.5
slowcgi: env[10], HTTP_CACHE_CONTROL=max-age=0
slowcgi: env[11], HTTP_CONNECTION=keep-alive
slowcgi: env[12], HTTP_HOST=localhost
slowcgi: env[13], HTTP_UPGRADE_INSECURE_REQUESTS=1
slowcgi: env[14], HTTP_USER_AGENT=Mozilla/5.0 (X11; OpenBSD amd64; rv:61.0) Gecko/20100101 Firefox/61.0
slowcgi: env[15], REMOTE_ADDR=127.0.0.1
slowcgi: env[16], REMOTE_PORT=23332
slowcgi: env[17], REQUEST_METHOD=GET
slowcgi: env[18], REQUEST_URI=/werc.rc
slowcgi: env[19], SERVER_ADDR=127.0.0.1
slowcgi: env[20], SERVER_PORT=80
slowcgi: env[21], SERVER_NAME=default
slowcgi: env[22], SERVER_PROTOCOL=HTTP/1.1
slowcgi: env[23], SERVER_SOFTWARE=OpenBSD httpd
slowcgi: version:         1
slowcgi: type:            4
slowcgi: requestId:       1
slowcgi: contentLength:   0
slowcgi: paddingLength:   0
slowcgi: reserved:        0
slowcgi: fork: /werc/bin/werc.rc
slowcgi: version:         1
slowcgi: type:            5
slowcgi: requestId:       1
slowcgi: contentLength:   0
slowcgi: paddingLength:   0
slowcgi: reserved:        0
slowcgi: wait: /werc/bin/werc.rc
slowcgi: resp version:         1
slowcgi: resp type:            7
slowcgi: resp requestId:       1
slowcgi: resp contentLength:   61
slowcgi: resp paddingLength:   3
slowcgi: resp reserved:        0
slowcgi: resp version:         1
slowcgi: resp type:            7
slowcgi: resp requestId:       1
slowcgi: resp contentLength:   0
slowcgi: resp paddingLength:   0
slowcgi: resp reserved:        0
slowcgi: resp version:         1
slowcgi: resp type:            6
slowcgi: resp requestId:       1
slowcgi: resp contentLength:   0
slowcgi: resp paddingLength:   0
slowcgi: resp reserved:        0
slowcgi: resp version:         1
slowcgi: resp type:            3
slowcgi: resp requestId:       1
slowcgi: resp contentLength:   8
slowcgi: resp paddingLength:   0
slowcgi: resp reserved:        0
slowcgi: resp appStatus:       1
slowcgi: resp protocolStatus:  0
^?

kdump.txt (163K) Download Attachment