Package: dosfstools
Version: 2.11-2.1
Severity: critical
File: /sbin/fsck.vfat
Justification: causes serious data loss

/sbin/fsck.vfat truncates files of 4294966784 bytes length.

The file system on /dev/hda8 was checked immediately before reboot using the 
GUI tool 
in Windows 2000.  As the output /var/log/fsck/checkfs shows /sbin/fsck.vfat 
decided 
during boot that the filesystem was inconsistent and automatically truncated 
the file.  
Note that it hasn't actually released the clusters yet.  The clusters seem to 
be freed 
during when fsck is run at the next boot.

Also shown below is the result of manually copying an equivalant file, and 
manually 
running fsck.vfat is sufficent to reproduce the problem.

A quick test shows that Sarge does not truncate the file during boot.
 
Thanks for your work in Debian

Andrew V.

========================================================================

$ cat /var/log/fsck/checkfs
Log of fsck -C -V -R -A -a
Wed Apr  4 17:23:06 2007

fsck 1.40-WIP (14-Nov-2006)
Checking all file systems.
[/sbin/fsck.ext3 (1) -- /mnt/p4-backup-root] fsck.ext3 -a -C0 /dev/hda6
/dev/hda6: Superblock last mount time is in the future.  FIXED.
/dev/hda6: clean, 19738/128520 files, 313092/514048 blocks
[/sbin/fsck.vfat (1) -- /mnt/p4-shared] fsck.vfat -a /dev/hda8
dosfsck 2.11, 12 Mar 2005, FAT32, LFN
/Sarge Hard Disk.vhd
  File size is 4294966784 bytes, cluster chain length is 0 bytes.
  Truncating file to 0 bytes.
Performing changes.
/dev/hda8: 63 files, 950195/2076388 clusters
fsck died with exit status 1

Wed Apr  4 17:23:07 2007
----------------

$ cp /mnt/p4-games/tmp/MS-Virtual-PC/sarge1/Sarge\ Hard\ Disk.vhd 
/mnt/p4-shared/sarge_test

$ ll /mnt/p4-shared/
total 4194368
[...]
-rwxr-xr-x 1 andrew andrew          0 2007-03-29 18:32 Sarge Hard Disk.vhd
-rwxr-xr-x 1 andrew andrew 4294966784 2007-04-04 17:34 sarge_test

$ sudo umount /dev/hda8

$ sudo fsck.vfat -a /dev/hda8
dosfsck 2.11, 12 Mar 2005, FAT32, LFN
/sarge_test
  File size is 4294966784 bytes, cluster chain length is 0 bytes.
  Truncating file to 0 bytes.
/Sarge Hard Disk.vhd
  File size is 0 bytes, cluster chain length is > 0 bytes.
  Truncating file to 0 bytes.
Free cluster summary wrong (864049 vs. really 1126193)
  Auto-correcting.
Performing changes.
/dev/hda8: 64 files, 950195/2076388 clusters

$ sudo fsck.vfat -a /dev/hda8
dosfsck 2.11, 12 Mar 2005, FAT32, LFN
/sarge_test
  File size is 0 bytes, cluster chain length is > 0 bytes.
  Truncating file to 0 bytes.
Free cluster summary wrong (1126193 vs. really 1388337)
  Auto-correcting.
Performing changes.
/dev/hda8: 64 files, 688051/2076388 clusters


-- System Information:
Debian Release: 4.0
  APT prefers testing
  APT policy: (500, 'testing')
Architecture: i386 (i686)
Shell:  /bin/sh linked to /bin/bash
Kernel: Linux 2.6.18-4-686
Locale: LANG=en_AU.UTF-8, LC_CTYPE=en_AU.UTF-8 (charmap=UTF-8)

Versions of packages dosfstools depends on:
ii  libc6                       2.3.6.ds1-13 GNU C Library: Shared libraries

dosfstools recommends no packages.

-- no debconf information


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to