Fw: ZFS + sendfile = data corruption

From: Andrey V. Elsukov <bu7cher_at_yandex.ru>
Date: Thu, 19 Apr 2007 09:55:29 +0400
Sorry, I've misspelled email address, so i forward this 
email to the list. May be someone else can confirm this 
bug.

----- Message -----
Hi, All and Pawel.

I found a new bug related to ZFS.
My system is not a fresh CURRENT, and may be this bug 
is already fixed. Then excuse me.

I use vsftpd for sharing some files for a windows users.
By the default vsftpd use sendfile(2) for file transfers.
And my files is on the ZFS. When i tried download theses 
files (of course i use binary mode data connection) i got 
a corrupted files. 
A downloaded files have the same file size, but not content.
In first file i've found following strings:

> strings dsc01150.jpg
<skipped>
d dump header
cannot allocate vm
_kvm_vatop: pte not valid
invalid address (0x%lx)
cannot read %d bytes for page bitmap
wrong minidump version. expected %d got %d
cannot read %d bytes for ptemap
cannot allocate %d bytes for bitmap
cannot allocate %d bytes for ptemap
not a minidump for this platform
kvm_kvatop called in live kernel!
_kvm_vatop: virtual address 0x%lx not minidumped
_kvm_vatop: physical address 0x%llx not in minidump
_kvm_vatop: physical address 0x%lx not in minidump
cannot mmap corefile
kernbase
minidump
Cannot read PDPT
cannot read PDPT
cannot read IdlePDPT
cannot read IdlePTD
bad namelist
cannot read PTD
vatop called in live kernel!
_kvm_vatop: pdpe_pa not found
_kvm_vatop: pde_pa not found
_kvm_vatop: pde not valid
_kvm_vatop: lseek
_kvm_vatop_pae: lseek
_kvm_vatop_pae: read
_kvm_vatop: read
_kvm_kvatop: pte not valid
_kvm_vatop_pae: pte not valid
_kvm_vatop_pae: pdpe_pa not found
_kvm_vatop_pae: pde_pa not found
_kvm_vatop: address not in dump
_kvm_kvatop_pae: pde not valid
_kvm_vatop: bootstrap data not in dump
_kvm_vatop_pae: bootstrap data not in dump
_kvm_vatop_pae: address not in dump
%s: 
can't allocate %u bytes: %s
/dev/null
/dev/mem
/dev/kmem
empty file
exec file name too long
bad flags arg
%s: %s
kvm_nlist
invalid address (%x)
short read
kvm_read
short write
kvm_write
kvm_write not implemented for dead kernels
$FreeBSD: src/lib/csu/i386-elf/crtn.S,v 1.6 2005/05/19 07:31:06 dfr Exp $
<skipped>

Other data seems that memory from other processes:
data from HTML-forms from firefox, dhclient configuration,...

When i have disabled "use_sendfile=NO" for the vsftpd - 
all files was downloaded ok. With UFS all works good.

--
WBR, Andrey V. Elsukov
Received on Thu Apr 19 2007 - 04:07:52 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:39:08 UTC