Learn how easy it is to sync an existing GitHub or Google Code repo to a SourceForge project! See Demo

Close

Getting HTTP error 414

Help
dom547
2009-04-15
2013-04-16
  • dom547
    dom547
    2009-04-15

    Hi,
    I have just started to use davfs2.
    (Version davfs2-1.3.3-bin-i386-neon-0.26)

    I am trying to connect to a sharepoint server.
    It works fine with this URL:
    https://projektplats.peab.se/projekt/LTEStockholm/

    but it fails with this URL:
    https://projektplats.peab.se/projekt/LTEStockholm/Delade Dokument/

    When I do a mapping from windows (via My Network Places) it works...

    I did a debug

    Here is when it fails.

    Apr 15 16:00:41 ubuntu mount.davfs: Header Name: [server], Value: [Microsoft-IIS/6.0]
    Apr 15 16:00:41 ubuntu mount.davfs: [hdr] MicrosoftSharePointTeamServices: 6.0.2.6361^M
    Apr 15 16:00:41 ubuntu mount.davfs: Header Name: [microsoftsharepointteamservices], Value: [6.0.2.6361]
    Apr 15 16:00:41 ubuntu mount.davfs: [hdr] X-Powered-By: ASP.NET^M
    Apr 15 16:00:41 ubuntu mount.davfs: Header Name: [x-powered-by], Value: [ASP.NET]
    Apr 15 16:00:41 ubuntu mount.davfs: [hdr] MS-Author-Via: MS-FP/4.0,DAV^M
    Apr 15 16:00:41 ubuntu mount.davfs: Header Name: [ms-author-via], Value: [MS-FP/4.0,DAV]
    Apr 15 16:00:41 ubuntu mount.davfs: [hdr] DAV: 1,2^M
    Apr 15 16:00:41 ubuntu mount.davfs: Header Name: [dav], Value: [1,2]
    Apr 15 16:00:41 ubuntu mount.davfs: [hdr] Accept-Ranges: none^M
    Apr 15 16:00:41 ubuntu mount.davfs: Header Name: [accept-ranges], Value: [none]
    Apr 15 16:00:41 ubuntu mount.davfs: [hdr] Allow: GET, POST, OPTIONS, HEAD, MKCOL, PUT, PROPFIND, PROPPATCH, DELETE, MOVE, COPY, GETLIB, LOCK, UNLOCK^M
    Apr 15 16:00:41 ubuntu mount.davfs: Header Name: [allow], Value: [GET, POST, OPTIONS, HEAD, MKCOL, PUT, PROPFIND, PROPPATCH, DELETE, MOVE, COPY, GETLIB, LOCK, UNLOCK]
    Apr 15 16:00:41 ubuntu mount.davfs: [hdr] Cache-Control: private^M
    Apr 15 16:00:41 ubuntu mount.davfs: Header Name: [cache-control], Value: [private]
    Apr 15 16:00:41 ubuntu mount.davfs: [hdr] Public-Extension: http://schemas.microsoft.com/repl-2^M
    Apr 15 16:00:41 ubuntu mount.davfs: Header Name: [public-extension], Value: [http://schemas.microsoft.com/repl-2]
    Apr 15 16:00:41 ubuntu mount.davfs: [hdr] ^M
    Apr 15 16:00:41 ubuntu mount.davfs: End of headers.
    Apr 15 16:00:41 ubuntu mount.davfs: Running post_send hooks
    Apr 15 16:00:41 ubuntu mount.davfs: Request ends, status 200 class 2xx, error line: 200 OK
    Apr 15 16:00:41 ubuntu mount.davfs: Running destroy hooks.
    Apr 15 16:00:41 ubuntu mount.davfs: Request ends.
    Apr 15 16:00:41 ubuntu mount.davfs: Running pre_send hooks
    Apr 15 16:00:41 ubuntu mount.davfs: Sending request headers: PROPFIND /projekt/LTEStockholm/Delade%2520Dokument/ HTTP/1.1^M Host: projektplats.peab.se^M User-Agent: davfs2/1.3.3 neon/0.26.4^M Connection: TE^M TE: trailers^M Depth: 1^M Content-Length: 314^M Content-Type: application/xml^M Authorization: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx^M ^M
    Apr 15 16:00:41 ubuntu mount.davfs: Sending request-line and headers:
    Apr 15 16:00:41 ubuntu mount.davfs: Sending request body:
    Apr 15 16:00:41 ubuntu mount.davfs: Request sent; retry is 1.
    Apr 15 16:00:41 ubuntu mount.davfs: [status-line] < HTTP/1.1 414 REQUEST URI TOO LONG^M

    And here is when it is working.
    Apr 15 16:24:11 ubuntu mount.davfs: Header Name: [accept-ranges], Value: [none]
    Apr 15 16:24:11 ubuntu mount.davfs: [hdr] Allow: GET, POST, OPTIONS, HEAD, MKCOL, PUT, PROPFIND, PROPPATCH, DELETE, MOVE, COPY, GETLIB, LOCK, UNLOCK^M
    Apr 15 16:24:11 ubuntu mount.davfs: Header Name: [allow], Value: [GET, POST, OPTIONS, HEAD, MKCOL, PUT, PROPFIND, PROPPATCH, DELETE, MOVE, COPY, GETLIB, LOCK, UNLOCK]
    Apr 15 16:24:11 ubuntu mount.davfs: [hdr] Cache-Control: private^M
    Apr 15 16:24:11 ubuntu mount.davfs: Header Name: [cache-control], Value: [private]
    Apr 15 16:24:11 ubuntu mount.davfs: [hdr] Public-Extension: http://schemas.microsoft.com/repl-2^M
    Apr 15 16:24:11 ubuntu mount.davfs: Header Name: [public-extension], Value: [http://schemas.microsoft.com/repl-2]
    Apr 15 16:24:11 ubuntu mount.davfs: [hdr] ^M
    Apr 15 16:24:11 ubuntu mount.davfs: End of headers.
    Apr 15 16:24:11 ubuntu mount.davfs: Running post_send hooks
    Apr 15 16:24:11 ubuntu mount.davfs: Request ends, status 200 class 2xx, error line: 200 OK
    Apr 15 16:24:11 ubuntu mount.davfs: Running destroy hooks.
    Apr 15 16:24:11 ubuntu mount.davfs: Request ends.
    Apr 15 16:24:11 ubuntu mount.davfs: Running pre_send hooks
    Apr 15 16:24:11 ubuntu mount.davfs: Sending request headers: PROPFIND /projekt/LTEStockholm/ HTTP/1.1^M Host: projektplats.peab.se^M User-Agent: davfs2/1.3.3 neon/0.26.4^M Connection: TE^M TE: trailers^M Depth: 1^M Content-Length: 314^M Content-Type: application/xml^M Authorization: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx^M ^M
    Apr 15 16:24:11 ubuntu mount.davfs: Sending request-line and headers:
    Apr 15 16:24:11 ubuntu mount.davfs: Sending request body:
    Apr 15 16:24:11 ubuntu mount.davfs: Request sent; retry is 1.
    Apr 15 16:24:11 ubuntu mount.davfs: [status-line] < HTTP/1.1 207 MULTI-STATUS^M
    Apr 15 16:24:11 ubuntu mount.davfs: [hdr] Connection: Keep-Alive^M
    Apr 15 16:24:11 ubuntu mount.davfs: Header Name: [connection], Value: [Keep-Alive]
    Apr 15 16:24:12 ubuntu mount.davfs: [hdr] Content-Length: 7296^M
    Apr 15 16:24:12 ubuntu mount.davfs: Header Name: [content-length], Value: [7296]
    Apr 15 16:24:12 ubuntu mount.davfs: [hdr] Date: Wed, 15 Apr 2009 14:24:17 GMT^M
    Apr 15 16:24:12 ubuntu mount.davfs: Header Name: [date], Value: [Wed, 15 Apr 2009 14:24:17 GMT]
    Apr 15 16:24:12 ubuntu mount.davfs: [hdr] Content-Type: text/xml^M
    Apr 15 16:24:12 ubuntu mount.davfs: Header Name: [content-type], Value: [text/xml]
    Apr 15 16:24:12 ubuntu mount.davfs: [hdr] Server: Microsoft-IIS/6.0^M
    Apr 15 16:24:12 ubuntu mount.davfs: Header Name: [server], Value: [Microsoft-IIS/6.0]
    Apr 15 16:24:12 ubuntu mount.davfs: [hdr] MicrosoftSharePointTeamServices: 6.0.2.6361^M
    Apr 15 16:24:12 ubuntu mount.davfs: Header Name: [microsoftsharepointteamservices], Value: [6.0.2.6361]
    Apr 15 16:24:12 ubuntu mount.davfs: [hdr] X-Powered-By: ASP.NET^M
    Apr 15 16:24:12 ubuntu mount.davfs: Header Name: [x-powered-by], Value: [ASP.NET]
    Apr 15 16:24:12 ubuntu mount.davfs: [hdr] Cache-Control: no-cache^M
    Apr 15 16:24:12 ubuntu mount.davfs: Header Name: [cache-control], Value: [no-cache]
    Apr 15 16:24:12 ubuntu mount.davfs: [hdr] Public-Extension: http://schemas.microsoft.com/repl-2^M
    Apr 15 16:24:12 ubuntu mount.davfs: Header Name: [public-extension], Value: [http://schemas.microsoft.com/repl-2]
    Apr 15 16:24:12 ubuntu mount.davfs: [hdr] ^M
    Apr 15 16:24:12 ubuntu mount.davfs: End of headers.
    Apr 15 16:24:12 ubuntu mount.davfs: Reading 7296 bytes of response body.
    Apr 15 16:24:12 ubuntu mount.davfs: Got 6353 bytes.
    Apr 15 16:24:12 ubuntu mount.davfs: Reading 943 bytes of response body.
    Apr 15 16:24:12 ubuntu mount.davfs: Got 943 bytes.
    Apr 15 16:24:12 ubuntu mount.davfs: Running post_send hooks
    Apr 15 16:24:12 ubuntu mount.davfs: Request ends, status 207 class 2xx, error line: 207 MULTI-STATUS
    Apr 15 16:24:12 ubuntu mount.davfs: Running destroy hooks.
    Apr 15 16:24:12 ubuntu mount.davfs: Request ends.

    Please help!
    Regards,
    Manne

     
    • Werner Baumann
      Werner Baumann
      2009-04-15

      "/projekt/LTEStockholm/Delade%2520Dokument/" looks like you tried to do %-escaping by yourself. You must not. This is a matter of the HTTP-protocol and is done by davfs2 and neon.
      You must enter the URL as it is, and it is
      "https://projektplats.peab.se/projekt/LTEStockholm/Delade Dokument/".
      Depending on how you enter it you must obey the escapint rules that apply:
      - on command line follow the escaping rules of the shell
      - in fstab follow the escaping rules of fstab.
      Did you read about URLs with spaces in the mount.davfs man-page?

      The beginning of the debug log will show the command line as received by mount.davfs and also how mount.davfs2 splitted the URL into components (scheme, host, path, ..). The command line must show "https://projektplats.peab.se/projekt/LTEStockholm/Delade Dokument/".

      If you are sure you entered the URL correctly, but the debug log shows it the wrong way, please tell me where you entered the URL and send the exact text.

      Cheers
      Werner

       
      • dom547
        dom547
        2009-04-16

        I have read the section about SPACES in URL:s (but maybe not understood it)
        When I try to use the /etc/fstab I get errors in every way I have tried to escape the SPACE CHAR.
        Which includes:

        https://projektplats.peab.se/projekt/LTEStockholm/Delade\040Dokument  /mnt2     davfs  rw,noauto  0  0

        "https://projektplats.peab.se/projekt/LTEStockholm/Delade\040Dokument"  /mnt2     davfs  rw,noauto  0  0

        "https://projektplats.peab.se/projekt/LTEStockholm/Delade\ Dokument"  /mnt2     davfs  rw,noauto  0  0

        https://projektplats.peab.se/projekt/LTEStockholm/Delade\ Dokument  /mnt2     davfs  rw,noauto  0  0

        This is the error I get

        root@ubuntu:/var/log# mount /mnt2
        /sbin/mount.davfs: invalid URL

        and the debug log just writes one line:
        Apr 16 12:09:52 ubuntu mount.davfs: davfs2 1.3.3

        I am using ubuntu 8.04.2
        Could you please help me with the escape of the space characters in eighter fstab or on the commandline?

        Kind Regards,
        Manne

         
    • Werner Baumann
      Werner Baumann
      2009-04-16

      https://projektplats.peab.se/projekt/LTEStockholm/Delade\040Dokument is correct for use in fstab.
      "https://projektplats.peab.se/projekt/LTEStockholm/Delade\ Dokument" and https://projektplats.peab.se/projekt/LTEStockholm/Delade\ Dokument are correct on the command line (sh).
      The bug is in davfs2. Some years ago there was a change in the neon library which I did not notice until now. There will be a new release within the next weeks with this bug (and others) fixed. Meanwhile davfs2 is not able to handle URLs with spaces (unless you build it yourself, linking against Neon 0.25. But this is not recommended).
      I will send a notice when the new release is ready.

      Cheers
      Werner

      P.S.: This bug does not affect file names in the mounted davfs2 file system. It can handle file names with spaces (escaping rules of the shell or whatever you use apply).

       
    • Werner Baumann
      Werner Baumann
      2009-05-03

      I just released davfs2 1.4.0 which fixes this bug.
      Please note:
      davfs2 is now hosted at http://savannah.nongnu.org/projects/davfs2

      Cheers
      Werner