Seafdav does not work (seafdav.pid problem)

Hey,

I want to use the Webdav component of the Seafile server…
My seafile is located at seafile.quenzer.one
seafile.quenzer.one/seafdav causes Bad Gateway
Looks like there is a problem with the seafdav.pid file…
I already restarted the whole VServer some times and upgraded seafile server to latest version (6.2.3)

seafdav config:
[WEBDAV]
enabled = true
port = 8080
fastcgi = true
share_name = /seafdav

nginx config (only seafdav location):
location /seafdav {
fastcgi_pass 127.0.0.1:8080;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
fastcgi_param PATH_INFO $fastcgi_script_name;

     fastcgi_param   SERVER_PROTOCOL     $server_protocol;
     fastcgi_param   QUERY_STRING        $query_string;
     fastcgi_param   REQUEST_METHOD      $request_method;
     fastcgi_param   CONTENT_TYPE        $content_type;
     fastcgi_param   CONTENT_LENGTH      $content_length;
     fastcgi_param   SERVER_ADDR         $server_addr;
     fastcgi_param   SERVER_PORT         $server_port;
     fastcgi_param   SERVER_NAME         $server_name;
     fastcgi_param   HTTPS               on;
     fastcgi_param   HTTP_SCHEME         https;

     client_max_body_size 0;
     proxy_connect_timeout  36000s;
     proxy_read_timeout  36000s;
     proxy_send_timeout  36000s;
     send_timeout  36000s;

     # This option is only available for Nginx >= 1.8.0. See more details below.
     proxy_request_buffering off;

     access_log      /var/log/nginx/seafdav.access.log;
     error_log       /var/log/nginx/seafdav.error.log;
  }

seafdav.error log:
2017/12/23 12:29:56 [error] 4751#4751: 7 connect() failed (111: Connection refused) while connecting to upstream, client: 89.245.254.203, server: seafile., request: $
2017/12/23 12:34:33 [error] 4751#4751: *156 upstream sent unsupported FastCGI protocol version: 72 while reading response header from upstream, client: 89.245.254.203,$
2017/12/23 12:34:34 [error] 4751#4751: *156 upstream sent unsupported FastCGI protocol version: 72 while reading response header from upstream, client: 89.245.254.203,$
2017/12/23 12:41:21 [error] 4750#4750: *459 upstream sent unsupported FastCGI protocol version: 72 while reading response header from upstream, client: 89.245.254.203,$
2017/12/23 12:47:43 [error] 4750#4750: *621 upstream sent unsupported FastCGI protocol version: 72 while reading response header from upstream, client: 89.245.254.203,$
2017/12/23 12:56:47 [error] 4750#4750: *828 upstream sent unsupported FastCGI protocol version: 72 while reading response header from upstream, client: 89.245.254.203,$
2017/12/23 12:58:21 [error] 4750#4750: *869 upstream sent unsupported FastCGI protocol version: 72 while reading response header from upstream, client: 89.245.254.203,$

controller log:
[12/23/17 13:00:37] seafile-controller.c(396): pid file /root/haiwen/pids/seafdav.pid does not exist
[12/23/17 13:00:37] seafile-controller.c(422): seafdav need restart…
[12/23/17 13:00:37] seafile-controller.c(73): spawn_process: /usr/bin/python2.7 -m wsgidav.server.run_server runfcgi --log-file /root/haiwen/logs/seafdav.log --pid /ro$
[12/23/17 13:00:37] seafile-controller.c(88): spawned /usr/bin/python2.7, pid 21433
[12/23/17 13:00:47] seafile-controller.c(396): pid file /root/haiwen/pids/seafdav.pid does not exist
[12/23/17 13:00:47] seafile-controller.c(422): seafdav need restart…
[12/23/17 13:00:47] seafile-controller.c(73): spawn_process: /usr/bin/python2.7 -m wsgidav.server.run_server runfcgi --log-file /root/haiwen/logs/seafdav.log --pid /ro$
[12/23/17 13:00:47] seafile-controller.c(88): spawned /usr/bin/python2.7, pid 21528
[12/23/17 13:00:57] seafile-controller.c(396): pid file /root/haiwen/pids/seafdav.pid does not exist
[12/23/17 13:00:57] seafile-controller.c(422): seafdav need restart…
[12/23/17 13:00:57] seafile-controller.c(73): spawn_process: /usr/bin/python2.7 -m wsgidav.server.run_server runfcgi --log-file /root/haiwen/logs/seafdav.log --pid /ro$
[12/23/17 13:00:57] seafile-controller.c(88): spawned /usr/bin/python2.7, pid 21626
[12/23/17 13:01:07] seafile-controller.c(396): pid file /root/haiwen/pids/seafdav.pid does not exist
[12/23/17 13:01:07] seafile-controller.c(422): seafdav need restart…
[12/23/17 13:01:07] seafile-controller.c(73): spawn_process: /usr/bin/python2.7 -m wsgidav.server.run_server runfcgi --log-file /root/haiwen/logs/seafdav.log --pid /ro$
[12/23/17 13:01:07] seafile-controller.c(88): spawned /usr/bin/python2.7, pid 21729
[12/23/17 13:01:17] seafile-controller.c(396): pid file /root/haiwen/pids/seafdav.pid does not exist
[12/23/17 13:01:17] seafile-controller.c(422): seafdav need restart…
[12/23/17 13:01:17] seafile-controller.c(73): spawn_process: /usr/bin/python2.7 -m wsgidav.server.run_server runfcgi --log-file /root/haiwen/logs/seafdav.log --pid /ro$
[12/23/17 13:01:17] seafile-controller.c(88): spawned /usr/bin/python2.7, pid 21802
[12/23/17 13:01:27] seafile-controller.c(396): pid file /root/haiwen/pids/seafdav.pid does not exist
[12/23/17 13:01:27] seafile-controller.c(422): seafdav need restart…
[12/23/17 13:01:27] seafile-controller.c(73): spawn_process: /usr/bin/python2.7 -m wsgidav.server.run_server runfcgi --log-file /root/haiwen/logs/seafdav.log --pid /ro$
[12/23/17 13:01:27] seafile-controller.c(88): spawned /usr/bin/python2.7, pid 21913
[12/23/17 13:01:37] seafile-controller.c(396): pid file /root/haiwen/pids/seafdav.pid does not exist
[12/23/17 13:01:37] seafile-controller.c(422): seafdav need restart…
[12/23/17 13:01:37] seafile-controller.c(73): spawn_process: /usr/bin/python2.7 -m wsgidav.server.run_server runfcgi --log-file /root/haiwen/logs/seafdav.log --pid /ro$
[12/23/17 13:01:37] seafile-controller.c(88): spawned /usr/bin/python2.7, pid 21987

Greetings

I´ve the same issue. It´s also not clear wether to use SeafDav with FastCGI or WSGI.

Seems that this problem is unsolvable…

@CertifiedG and @das_apfel check out this forum link and if you need further help I can post my nginx configuration. On my side seafdav with wsgi working fine with 6.2.3. Froehes neues :wink:

1 Like

Danke, dir auchn frohes Neues.

The issue is actually not related to Nginx but Seafile itself and sadly I´m not aware of any config file variables in order to be able to raise the logging verbosity.
Current log files don´t tell anything … other than it´s restarting the service.

WSGI works just fine. CE manual contains the config.

I have the same problem after upgrading to seafile-server_7.0.5_x86-64.tar.gz coming from seafile-server-6.3.4 (where I hadn’t any webdav problems) - is this problem maybe version specific?

I suppose your WebDAV server does not run. Can you check with
netstat -tulpn
if therer is a service listening on the port you configured in your seafdav.conf?
If there isn’t, post your seafdav.conf here as well as the seafdav.log.
Please also check this: Shutdown your Seafile Server and check the pids folder at ~/pids. If there is still a pids file for seafdav, then delete it, startup your Seafile Server and test WebDAV access.

My fault, following your advice I notied SeafDav is working just fine. I somehow mixed the problem with fuse problems I have and during my investigation for "Unknown erorr" and "Server error" status syncing libraries since Seafile Server CE 7.0.5? I found this topic.

However: I still have the log error Failed to init seahub db: No module named seahub_settings. but maybe this is more related to Seafile 7.0.2, seafdav bug "No module named seahub_settings.".