Menu

#70 ftpfs: operation ftpfs_flush failed because Input/output error

v1.0 (example)
open
nobody
5
2022-05-14
2015-12-11
No

Version 0.9.2 (lastest version downloaded and compiled)

./curlftpfs -d ftp://user:pass@site.com /mnt/ftp

A copy of a file always fails:

........
unique: 5032, opcode: WRITE (16), nodeid: 2, insize: 4176, pid: 41040
write[140467039637376] 4096 bytes to 20582400 flags: 0x8001
write[140467039637376] 4096 bytes to 20582400
unique: 5032, success, outsize: 24
unique: 5033, opcode: WRITE (16), nodeid: 2, insize: 4176, pid: 41040
write[140467039637376] 4096 bytes to 20586496 flags: 0x8001
write[140467039637376] 4096 bytes to 20586496
unique: 5033, success, outsize: 24
unique: 5034, opcode: WRITE (16), nodeid: 2, insize: 4031, pid: 41040
write[140467039637376] 3951 bytes to 20590592 flags: 0x8001
write[140467039637376] 3951 bytes to 20590592
unique: 5034, success, outsize: 24
unique: 5035, opcode: FLUSH (25), nodeid: 2, insize: 64, pid: 41040
flush[140467039637376]
ftpfs: operation ftpfs_flush failed because Input/output error
unique: 5035, error: -5 (Input/output error), outsize: 16

unique: 5036, opcode: RELEASE (18), nodeid: 2, insize: 64, pid: 0
release[140467039637376] flags: 0x8001
unique: 5036, success, outsize: 16

Tryed with proftpd server and microsoft ftp server. Any ideas please?

Discussion

  • Robson Braga Araujo

    Please also use the -v command line flag to get debug output from libcurl.

     
    • Alejandro Vargas

      This is a full session from mount up to transferring an exactly 1Kb file and error:

      curlftpfs -d -v ftp://user:pass@80.xx.xx.xxs /mnt/1

      • Couldn't find host 80.xx.xx.xx in the .netrc file; using defaults
      • Hostname was NOT found in DNS cache
      • Trying 80.xx.xx.xx...
      • Adding handle: conn: 0xe08140
      • Adding handle: send: 0
      • Adding handle: recv: 0
      • Curl_addHandleToPipeline: length: 1
        • Conn 0 (0xe08140) send_pipe: 1, recv_pipe: 0
      • Connected to 80.xx.xx.xx (80.xx.xx.xx) port 21 (#0)
        < 220 Microsoft FTP Service

        USER user
        < 331 Password required
        PASS pass
        < 230 User logged in.
        PWD
        < 257 "/" is current directory.

      • Entry path is '/'
      • ftp_perform ends with SECONDARY: 0
      • Remembering we are in dir ""
      • Connection #0 to host 80.xx.xx.xx left intact
        FUSE library version: 2.9.3
        nullpath_ok: 0
        nopath: 0
        utime_omit_ok: 0
        unique: 1, opcode: INIT (26), nodeid: 0, insize: 56, pid: 0
        INIT: 7.22
        flags=0x0000f7fb
        max_readahead=0x00020000
        INIT: 7.19
        flags=0x00000011
        max_readahead=0x00020000
        max_write=0x00020000
        max_background=0
        congestion_threshold=0
        unique: 1, success, outsize: 40
        unique: 2, opcode: GETATTR (3), nodeid: 1, insize: 56, pid: 40268
        getattr /
      • Couldn't find host 80.xx.xx.xx in the .netrc file; using defaults
      • Found bundle for host 80.xx.xx.xx: 0xe08ae0
      • Re-using existing connection! (#0) with host 80.xx.xx.xx
      • Connected to 80.xx.xx.xx (80.xx.xx.xx) port 21 (#0)
      • Adding handle: conn: 0xe08140
      • Adding handle: send: 0
      • Adding handle: recv: 0
      • Curl_addHandleToPipeline: length: 1
        • Conn 0 (0xe08140) send_pipe: 1, recv_pipe: 0
      • Request has same path as previous transfer

        PASV

      • Connect data stream passively
      • ftp_perform ends with SECONDARY: 0
        < 227 Entering Passive Mode (80,xx,xx,xx,220,90).
      • Hostname was NOT found in DNS cache
      • Trying 80.xx.xx.xx...
      • Connecting to 80.xx.xx.xx (80.xx.xx.xx) port 56410
      • Connected to 80.xx.xx.xx (80.xx.xx.xx) port 21 (#0)

        TYPE A
        < 200 Type set to A.
        LIST -a
        < 125 Data connection already open; Transfer starting.

      • Maxdownload = -1
      • Remembering we are in dir ""
        < 226 Transfer complete.
      • Connection #0 to host 80.xx.xx.xx left intact
        unique: 2, success, outsize: 120
        unique: 3, opcode: LOOKUP (1), nodeid: 1, insize: 45, pid: 40268
        LOOKUP /test
        getattr /test
      • Couldn't find host 80.xx.xx.xx in the .netrc file; using defaults
      • Found bundle for host 80.xx.xx.xx: 0xe08ae0
      • Re-using existing connection! (#0) with host 80.xx.xx.xx
      • Connected to 80.xx.xx.xx (80.xx.xx.xx) port 21 (#0)
      • Adding handle: conn: 0xe08140
      • Adding handle: send: 0
      • Adding handle: recv: 0
      • Curl_addHandleToPipeline: length: 1
        • Conn 0 (0xe08140) send_pipe: 1, recv_pipe: 0
      • Request has same path as previous transfer

        PASV

      • Connect data stream passively
      • ftp_perform ends with SECONDARY: 0
        < 227 Entering Passive Mode (80,xx,xx,xx,220,91).
      • Hostname was NOT found in DNS cache
      • Trying 80.xx.xx.xx...
      • Connecting to 80.xx.xx.xx (80.xx.xx.xx) port 56411
      • Connected to 80.xx.xx.xx (80.xx.xx.xx) port 21 (#0)

        LIST -a
        < 125 Data connection already open; Transfer starting.

      • Maxdownload = -1
      • Remembering we are in dir ""
        < 226 Transfer complete.
      • Connection #0 to host 80.xx.xx.xx left intact
        ftpfs: operation ftpfs_getattr failed because No such file or directory
        unique: 3, error: -2 (No such file or directory), outsize: 16
        unique: 4, opcode: LOOKUP (1), nodeid: 1, insize: 45, pid: 40268
        LOOKUP /test
        getattr /test
        unique: 4, error: -2 (No such file or directory), outsize: 16
        unique: 5, opcode: CREATE (35), nodeid: 1, insize: 61, pid: 40268
        create flags: 0x80c1 /test 0100644 umask=0022
      • Couldn't find host 80.xx.xx.xx in the .netrc file; using defaults
      • Found bundle for host 80.xx.xx.xx: 0xe08ae0
      • Re-using existing connection! (#0) with host 80.xx.xx.xx
      • Connected to 80.xx.xx.xx (80.xx.xx.xx) port 21 (#0)
      • Adding handle: conn: 0xe08140
      • Adding handle: send: 0
      • Adding handle: recv: 0
      • Curl_addHandleToPipeline: length: 1
        • Conn 0 (0xe08140) send_pipe: 1, recv_pipe: 0
      • Request has same path as previous transfer

        PASV

      • Connect data stream passively
      • ftp_perform ends with SECONDARY: 0
        < 227 Entering Passive Mode (80,xx,xx,xx,220,92).
      • Hostname was NOT found in DNS cache
      • Trying 80.xx.xx.xx...
      • Connecting to 80.xx.xx.xx (80.xx.xx.xx) port 56412
      • Connected to 80.xx.xx.xx (80.xx.xx.xx) port 21 (#0)

        LIST -a
        < 125 Data connection already open; Transfer starting.

      • Maxdownload = -1
      • Remembering we are in dir ""
        < 226 Transfer complete.
      • Connection #0 to host 80.xx.xx.xx left intact
        ftpfs: operation ftpfs_getattr failed because No such file or directory
      • Couldn't find host 80.xx.xx.xx in the .netrc file; using defaults
      • Hostname was NOT found in DNS cache
      • Trying 80.xx.xx.xx...
      • Adding handle: conn: 0x7f04fc009f40
      • Adding handle: send: 0
      • Adding handle: recv: 0
      • Curl_addHandleToPipeline: length: 1
        • Conn 1 (0x7f04fc009f40) send_pipe: 1, recv_pipe: 0
      • Connected to 80.xx.xx.xx (80.xx.xx.xx) port 21 (#1)
        < 220 Microsoft FTP Service

        USER user
        < 331 Password required
        PASS pass
        < 230 User logged in.
        PWD
        < 257 "/" is current directory.

      • Entry path is '/'

        PASV

      • Connect data stream passively
      • ftp_perform ends with SECONDARY: 0
        < 227 Entering Passive Mode (80,xx,xx,xx,220,93).
      • Hostname was NOT found in DNS cache
      • Trying 80.xx.xx.xx...
      • Connecting to 80.xx.xx.xx (80.xx.xx.xx) port 56413
      • Connected to 80.xx.xx.xx (80.xx.xx.xx) port 21 (#1)

        TYPE I
        < 200 Type set to I.
        STOR test
        < 125 Data connection already open; Transfer starting.

      • Couldn't find host 80.xx.xx.xx in the .netrc file; using defaults
      • Found bundle for host 80.xx.xx.xx: 0xe08ae0
      • Re-using existing connection! (#0) with host 80.xx.xx.xx
      • Connected to 80.xx.xx.xx (80.xx.xx.xx) port 21 (#0)
      • Adding handle: conn: 0xe08140
      • Adding handle: send: 0
      • Adding handle: recv: 0
      • Curl_addHandleToPipeline: length: 1
        • Conn 0 (0xe08140) send_pipe: 1, recv_pipe: 0
      • Request has same path as previous transfer
      • ftp_perform ends with SECONDARY: 0
      • Remembering we are in dir ""

        SITE CHMOD 644 test
        < 500 'SITE': command not understood

      • QUOT string not accepted: SITE CHMOD 644 test
      • Connection #0 to host 80.xx.xx.xx left intact
        ftpfs: operation ftpfs_chmod failed because Operation not permitted
        create[139659451570112] flags: 0x80c1 /test
        getattr /test
      • Couldn't find host 80.xx.xx.xx in the .netrc file; using defaults
      • Found bundle for host 80.xx.xx.xx: 0xe08ae0
      • Re-using existing connection! (#0) with host 80.xx.xx.xx
      • Connected to 80.xx.xx.xx (80.xx.xx.xx) port 21 (#0)
      • Adding handle: conn: 0xe08140
      • Adding handle: send: 0
      • Adding handle: recv: 0
      • Curl_addHandleToPipeline: length: 1
        • Conn 0 (0xe08140) send_pipe: 1, recv_pipe: 0
      • Request has same path as previous transfer

        PASV

      • Connect data stream passively
      • ftp_perform ends with SECONDARY: 0
        < 227 Entering Passive Mode (80,xx,xx,xx,xx,94).
      • Hostname was NOT found in DNS cache
      • Trying 80.xx.xx.xx...
      • Connecting to 80.xx.xx.xx (80.xx.xx.xx) port 56414
      • Connected to 80.xx.xx.xx (80.xx.xx.xx) port 21 (#0)

        LIST -a
        < 125 Dat0a connection already open; Transfer starting.

      • Maxdownload = -1
      • Remembering we are in dir ""
        < 226 Transfer complete.
      • Connection #0 to host 80.xx.xx.xx left intact
        NODEID: 2
        unique: 5, success, outsize: 160
        unique: 6, opcode: GETXATTR (22), nodeid: 2, insize: 68, pid: 40268
        unique: 6, error: -38 (Function not implemented), outsize: 16
        unique: 7, opcode: WRITE (16), nodeid: 2, insize: 1104, pid: 40268
        write[139659451570112] 1024 bytes to 0 flags: 0x8001
        write[139659451570112] 1024 bytes to 0
        unique: 7, success, outsize: 24
        unique: 8, opcode: FLUSH (25), nodeid: 2, insize: 64, pid: 40268
        flush[139659451570112]
      • Remembering we are in dir ""
        < 226 Transfer complete.
      • Uploaded unaligned file size (1024 out of 4294967295 bytes)
      • Connection #1 to host 80.xx.xx.xx left intact
        ftpfs: operation ftpfs_flush failed because Input/output error
        unique: 8, error: -5 (Input/output errorr, outsize: 16
        unique: 9, opcode: RELEASE (18), nodeid: 2, insize: 64, pid: 0
        release[139659451570112] flags: 0x8001
        unique: 9, success, outsize: 16

      I see it says "Uploaded unaligned file size (1024 out of 4294967295 bytes)"... There may be a problem here. The file is exactly 1024 bytes, not "4294967295").

       

      Last edit: Alejandro Vargas 2015-12-23

Log in to post a comment.

MongoDB Logo MongoDB