Subject: kern/4448: MS-DOS file system has problems
To: None <gnats-bugs@gnats.netbsd.org>
From: Havard Eidnes <he@vader.runit.sintef.no>
List: netbsd-bugs
Date: 11/07/1997 19:53:49
>Number:         4448
>Category:       kern
>Synopsis:       MS-DOS file system support has problems
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    kern-bug-people (Kernel Bug People)
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Fri Nov  7 11:05:02 1997
>Last-Modified:
>Originator:     Havard Eidnes
>Organization:
	SINTEF RUNIT
>Release:        NetBSD-1.3_ALPHA of Oct 30 sources
>Environment:
System: NetBSD vader.runit.sintef.no 1.3_ALPHA NetBSD 1.3_ALPHA (VADER) #10: Sun Nov 2 01:37:09 MET 1997 he@vader.runit.sintef.no:/usr/src/sys/arch/i386/compile/VADER i386


>Description:
	It appears that NetBSD's msdos file system support has problems,
	at least with my "MS-DOS SMC rescue & boot-manager diskette".

	Several files are mapped to the same information, even though
	they are not the same.  The M-tools appear not to be similarly
	affected, so I tend to think this is caused by a problem in NetBSD
	and not on my diskette.

	The "ls -l" output can be compared with the mdir output, included
	below.  Notice that $RUN.OVL has different sizes, and in the NetBSD
	case has the same size as another file, whereas in the "mdir" output
	this is not the case.

	If someone want to debug this particular floppy in more detail,
	I've left a raw dump of its current state to

	ftp://trane.uninett.no/tmp/rescue-msdos.fs.gz

	I will note that the first error was observed after I had copied
	/tmp/putr.com to /mnt via the msdos file system mount, at that
	time my former ezsetup.exe showed up on the same "inode" as the
	newly copied putr.com.  This was repeated once more where another
	file apparently got junked.

	I will also note that I have let "fsck -t msdos" loose on the
	diskette a couple of times after the first incident.

vader# ls -ltri
total 1052
314 -rwxr-xr-x  1 root  wheel  133401 Aug  5  1991 SYS$MSG.DAT*
315 -rwxr-xr-x  1 root  wheel  117113 Aug  5  1991 NDD.EXE*
314 -rwxr-xr-x  1 root  wheel  133401 Aug  5  1991 DISKEDIT.EXE*
315 -rwxr-xr-x  1 root  wheel  117113 Aug  5  1991 DIAGHLP.HLP*
310 -rwxr-xr-x  1 root  wheel   22916 Sep 30  1993 ezsetupo.exe*
312 -rwxr-xr-x  1 root  wheel     413 Sep 30  1993 SYS$ERR.DAT*
306 -rwxr-xr-x  1 root  wheel   54619 Sep 30  1993 SCSICNTL.EXE*
305 -r-xr-xr-x  1 root  wheel   38138 Sep 30  1993 OSBS20B8.EXE*
305 -r-xr-xr-x  1 root  wheel   38138 Sep 30  1993 MSDOS.SYS*
304 -r-xr-xr-x  1 root  wheel   40566 Sep 30  1993 MBS.SEC*
304 -r-xr-xr-x  1 root  wheel   40566 Sep 30  1993 IO.SYS*
310 -rwxr-xr-x  1 root  wheel   22916 Sep 30  1993 FORMAT.COM*
309 -rwxr-xr-x  1 root  wheel   29334 Sep 30  1993 FDISK.EXE*
312 -rwxr-xr-x  1 root  wheel     413 Sep 30  1993 EDIT.COM*
311 -rwxr-xr-x  1 root  wheel   15718 Sep 30  1993 DIAGNOSE.EXE*
311 -rwxr-xr-x  1 root  wheel   15718 Sep 30  1993 DEBUG.EXE*
306 -rwxr-xr-x  1 root  wheel   54619 Sep 30  1993 COMMAND.COM*
307 -r-xr-xr-x  1 root  wheel   57510 Jun 21  1994 PFDISK.EXE*
307 -r-xr-xr-x  1 root  wheel   57510 Jun 21  1994 DBLSPACE.BIN*
313 -rwxr-xr-x  1 root  wheel     530 Nov  4  1994 SYS$HELP.DAT*
313 -rwxr-xr-x  1 root  wheel     530 Nov  4  1994 NORTON.INI*
316 -r-xr-xr-x  1 root  wheel   31289 Nov  4  1994 OS-BS135.EXE*
316 -r-xr-xr-x  1 root  wheel   31289 Nov  4  1994 $RUN.OVL*
319 -rwxr-xr-x  1 root  wheel   16528 Nov 28  1994 XBOOT.COM*
vader# cd /
vader# umount /mnt
vader# mdir
tracks=80, heads=2, sectors=18, clus_size=1, fat_start=1, fat_len=9, dir_start=19, dir_len=14, num_clus=2847, num_fat=2
 Volume in drive A is UTILITY    
 Directory for A:/

IO       SYS       40566    9-30-93   6:20a
MSDOS    SYS       38138    9-30-93   6:20a
COMMAND  COM       54619    9-30-93   6:20a
DBLSPACE BIN       57510    6-21-94   4:03p
FDISK    EXE       29334    9-30-93   6:20a
FORMAT   COM       22916    9-30-93   6:20a
DEBUG    EXE       15718    9-30-93   6:20a
EDIT     COM         413    9-30-93   6:20a
NORTON   INI         530   11-04-94   7:57p
DISKEDIT EXE      133401    8-04-91  11:01p
NDD      EXE      117113    8-04-91  11:01p
OS-BS135 EXE       31289   11-04-94  10:26p
XBOOT    COM       16528   11-28-94   6:34p
MBS      SEC         512   12-08-94   4:38p
OSBS20B8 EXE       51332   10-20-93   1:55a
SCSICNTL EXE      139116   10-08-94   5:29p
PFDISK   EXE       17542    5-24-96   2:39p
EZSETUPO EXE       40845   11-05-94   1:22a
DIAGNOSE EXE      155565    4-13-92  11:01a
SYS$ERR  DAT        3119   10-25-90   3:29p
SYS$HELP DAT        3728   10-25-90   3:29p
SYS$MSG  DAT       12639   10-25-90   3:29p
DIAGHLP  HLP        9607   10-25-90   3:29p
$RUN     OVL        2460   10-25-90   3:29p
      24 File(s)     431616 bytes free
vader# mcopy /tmp/putr.com a:
tracks=80, heads=2, sectors=18, clus_size=1, fat_start=1, fat_len=9, dir_start=19, dir_len=14, num_clus=2847, num_fat=2
Copying PUTR.COM
vader# mdir 
tracks=80, heads=2, sectors=18, clus_size=1, fat_start=1, fat_len=9, dir_start=19, dir_len=14, num_clus=2847, num_fat=2
 Volume in drive A is UTILITY    
 Directory for A:/

IO       SYS       40566    9-30-93   6:20a
MSDOS    SYS       38138    9-30-93   6:20a
COMMAND  COM       54619    9-30-93   6:20a
DBLSPACE BIN       57510    6-21-94   4:03p
FDISK    EXE       29334    9-30-93   6:20a
FORMAT   COM       22916    9-30-93   6:20a
DEBUG    EXE       15718    9-30-93   6:20a
EDIT     COM         413    9-30-93   6:20a
NORTON   INI         530   11-04-94   7:57p
DISKEDIT EXE      133401    8-04-91  11:01p
NDD      EXE      117113    8-04-91  11:01p
OS-BS135 EXE       31289   11-04-94  10:26p
PUTR     COM       27530   11-07-97   7:41p
XBOOT    COM       16528   11-28-94   6:34p
MBS      SEC         512   12-08-94   4:38p
OSBS20B8 EXE       51332   10-20-93   1:55a
SCSICNTL EXE      139116   10-08-94   5:29p
PFDISK   EXE       17542    5-24-96   2:39p
EZSETUPO EXE       40845   11-05-94   1:22a
DIAGNOSE EXE      155565    4-13-92  11:01a
SYS$ERR  DAT        3119   10-25-90   3:29p
SYS$HELP DAT        3728   10-25-90   3:29p
SYS$MSG  DAT       12639   10-25-90   3:29p
DIAGHLP  HLP        9607   10-25-90   3:29p
$RUN     OVL        2460   10-25-90   3:29p
      25 File(s)     403968 bytes free
vader# 

>How-To-Repeat:
	Copy disk image.

	Watch the msdos file system support fail.

>Fix:
	I've got absolutely no idea, this is way beyond me.
>Audit-Trail:
>Unformatted: