From owner-freebsd-current Wed Apr 3 2:44: 7 2002 Delivered-To: freebsd-current@freebsd.org Received: from mailman.zeta.org.au (mailman.zeta.org.au [203.26.10.16]) by hub.freebsd.org (Postfix) with ESMTP id 269A037B41C; Wed, 3 Apr 2002 02:43:49 -0800 (PST) Received: from bde.zeta.org.au (bde.zeta.org.au [203.2.228.102]) by mailman.zeta.org.au (8.9.3/8.8.7) with ESMTP id UAA28955; Wed, 3 Apr 2002 20:43:38 +1000 Date: Wed, 3 Apr 2002 20:44:35 +1000 (EST) From: Bruce Evans X-X-Sender: bde@gamplex.bde.org To: Joerg Wunsch Cc: freebsd-current@freebsd.org, Subject: Re: disklabel(8) floppy panic In-Reply-To: <20020402203559.A25802@uriah.heep.sax.de> Message-ID: <20020403202932.T9816-100000@gamplex.bde.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Tue, 2 Apr 2002, Joerg Wunsch wrote: > As Bruce Evans wrote: > > > BTW, device cloning seems to work wrong for fd: > > > > %%% > > Script started on Wed Apr 3 02:16:43 2002 > > ttyp1:bde@besplex:/tmp> ls /dev/fd0c > > ls: /dev/fd0c: No such file or directory > > ttyp1:bde@besplex:/tmp> ls /dev/fd0c > > /dev/fd0c@ > > ttyp1:bde@besplex:/tmp> exit > > I can also see this. IMHO, that's an artifact of how device on-demand > alias creation is working. Cc to Poul-Henning, maybe he can shed some > light on this. > > Ah, hmm, i think that's a problem of "ls -F", actually. Look here. > > j@uriah 90% ls -l /dev/fd1* > crw-r----- 1 root operator 9, 64 Apr 1 22:37 /dev/fd1 > j@uriah 91% /bin/ls /dev/fd1c > /dev/fd1c > j@uriah 92% ls -l /dev/fd1* > crw-r----- 1 root operator 9, 64 Apr 1 22:37 /dev/fd1 > lrwxr-xr-x 1 root wheel 4 Apr 2 20:34 /dev/fd1c@ -> fd0 > > Plain /bin/ls (without any options) works as expected. You are right that I forgot to use plain ls. I have ls aliased to "ls -Fg" (the "g" tells how long it is since I changed this :-). I also tried a stat utility. It failed like ls. I just tried cat. It failed in the same way. Plain ls works accidentally by first doing a stat() which fails except for creating a directory entry; ls then does a successful lstat(). This seems to be a bug in the fd driver. ls -F "works" the first time on nonexistent partitions. But it should only work on devices that exist. fd0a and fd0c may need to exist for compatibility, but shouldn't. fd0b and fd0[d-h] just shouldn't exist. Bruce To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message