261 lines
9.5 KiB
HTML
261 lines
9.5 KiB
HTML
<!--startcut ======================================================= -->
|
|
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
|
|
<html>
|
|
<head>
|
|
<META NAME="generator" CONTENT="lgazmail v1.2M.b">
|
|
<TITLE>The Answer Guy 43: Floppy Failure: mdir Works; mount Fails</TITLE>
|
|
</HEAD><BODY BGCOLOR="#FFFFFF" TEXT="#000000"
|
|
LINK="#3366FF" VLINK="#A000A0">
|
|
<!-- ::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: -->
|
|
<H4>"The Linux Gazette...<I>making Linux just a little more fun!</I>"</H4>
|
|
<P> <hr> <P>
|
|
<!-- ::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: -->
|
|
<center>
|
|
<H1><A NAME="answer">
|
|
<img src="../../gx/dennis/qbubble.gif" alt="(?)"
|
|
border="0" align="middle">
|
|
<font color="#B03060">The Answer Guy</font>
|
|
<img src="../../gx/dennis/bbubble.gif" alt="(!)"
|
|
border="0" align="middle">
|
|
</A></H1>
|
|
<BR>
|
|
<H4>By James T. Dennis,
|
|
<a href="mailto:linux-questions-only@ssc.com">linux-questions-only@ssc.com</a><BR>
|
|
LinuxCare,
|
|
<A HREF="http://www.linuxcare.com/">http://www.linuxcare.com/</A>
|
|
</H4>
|
|
</center>
|
|
|
|
<p><hr><p>
|
|
<!-- endcut ======================================================= -->
|
|
<!-- begin 5 -->
|
|
<H3 align="left"><img src="../../gx/dennis/qbubble.gif"
|
|
height="50" width="60" alt="(?) " border="0"
|
|
>Floppy Failure: mdir Works; mount Fails</H3>
|
|
|
|
|
|
<p><strong>From Tim Baverstock on Fri, 25 Jun 1999
|
|
</strong></p>
|
|
<!-- ::
|
|
Floppy Failure: mdir Works; mount Fails
|
|
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
|
:: -->
|
|
<P><STRONG>
|
|
Hi.
|
|
</STRONG></P>
|
|
<P><STRONG>
|
|
I came across this page where someone'd asked you a question,
|
|
apparently identical to something a (non-techie) friend of mine is
|
|
now experiencing, except that his Linux is a vanilla RedHat 5.1
|
|
install (although with Star Office, and RedHat 5.2 Ghostscript and
|
|
ppp).
|
|
</STRONG></P>
|
|
<P><STRONG>
|
|
He has a PCI PnP soundcard in his machine, which he's not managed
|
|
to get working with W95 or with Linux, but the rest of the machine
|
|
worked fine for both OSs, including the floppy.
|
|
</STRONG></P>
|
|
<P><STRONG>
|
|
All of a sudden, about a month ago, the floppy stopped mounting on
|
|
Linux (works fine on W95).
|
|
</STRONG></P>
|
|
<BLOCKQUOTE><IMG SRC="../../gx/dennis/bbub.gif" ALT="(!)"
|
|
HEIGHT="28" WIDTH="50" BORDER="0"
|
|
>
|
|
Does writing to the floppy work under MS Windows?
|
|
</BLOCKQUOTE>
|
|
<P><STRONG><IMG SRC="../../gx/dennis/qbub.gif" ALT="(?)"
|
|
HEIGHT="28" WIDTH="50" BORDER="0"
|
|
>
|
|
I can `<TT>less -f /dev/fd0</TT>', to see the data on the floppy, and
|
|
<tt>mdir</tt>/<tt>mcopy</tt> work fine.
|
|
</STRONG></P>
|
|
<BLOCKQUOTE><IMG SRC="../../gx/dennis/bbub.gif" ALT="(!)"
|
|
HEIGHT="28" WIDTH="50" BORDER="0"
|
|
>
|
|
Does '<tt>mcopy</tt>' work in both directions (copying to
|
|
the floppy as well as from it)?
|
|
</BLOCKQUOTE>
|
|
<P><STRONG><IMG SRC="../../gx/dennis/qbub.gif" ALT="(?)"
|
|
HEIGHT="28" WIDTH="50" BORDER="0"
|
|
>
|
|
The machine mounts his W95 <tt>C:</tt> drive as <TT>/mnt/dosC</TT>, and
|
|
that works perfectly as well.
|
|
</STRONG></P>
|
|
<BLOCKQUOTE><IMG SRC="../../gx/dennis/bbub.gif" ALT="(!)"
|
|
HEIGHT="28" WIDTH="50" BORDER="0"
|
|
>
|
|
So we know that this kernel is compiled with
|
|
FAT fs support (linked in directly or the
|
|
loadable module support is working).
|
|
</BLOCKQUOTE>
|
|
<P><STRONG><IMG SRC="../../gx/dennis/qbub.gif" ALT="(?)"
|
|
HEIGHT="28" WIDTH="50" BORDER="0"
|
|
>
|
|
When I try `<TT>mount -t msdos /dev/fd0 /tmp/floppy</TT>', the mount
|
|
command goes into `<tt>D</tt>' wait in the `<tt>ps axf</tt>' output, as
|
|
does the update demon. The floppy lights, spins, then stops, but no
|
|
failure messages appear, and I can't kill the mount. Subsequent
|
|
attepts to mount also block, and if I recall correctly, <tt>mcopy</tt> says
|
|
it can't write to the device.
|
|
</STRONG></P>
|
|
<P><STRONG>
|
|
Nothing appears in <TT>/var/log/messages</TT>.
|
|
</STRONG></P>
|
|
<P><STRONG>
|
|
During shutdown, the <tt>umount -a</tt> line in
|
|
<TT>/etc/rc.d/init.d/halt</TT> hangs too.
|
|
</STRONG></P>
|
|
<P><STRONG>
|
|
If you're interested in whether fiddling with the soundcard fixes
|
|
the problem, I'll be happy to let you know, but since mcopy and
|
|
mdir work, this seems unlikely.
|
|
</STRONG></P>
|
|
<P><STRONG>
|
|
Nothing's been added or removed within the machine's case, so I
|
|
think the only thing that could have changed, which persists over
|
|
powerdowns, is the CMOS, and hence (presumably) some aspect of PnP
|
|
that W95 was fiddling around with.
|
|
</STRONG></P>
|
|
<P><STRONG>
|
|
I've only ever had <tt>isapnp</tt> work under RedHat 6.0, when Redhat did
|
|
it all for me!
|
|
<IMG SRC="../../gx/dennis/smily.gif" ALT=":)"
|
|
height="24" width="20" align="middle">
|
|
For my earlier kernels, I used the <tt>cmgr</tt> patch.
|
|
</STRONG></P>
|
|
<P><STRONG>
|
|
Cheers,
|
|
<br>Tim Baverstock.
|
|
</STRONG></P>
|
|
<BLOCKQUOTE><IMG SRC="../../gx/dennis/bbub.gif" ALT="(!)"
|
|
HEIGHT="28" WIDTH="50" BORDER="0"
|
|
>
|
|
What happens if you try mounting it in read-only mode?
|
|
</BLOCKQUOTE>
|
|
<BLOCKQUOTE>
|
|
It sure sounds like a hardware failure. I'd buy an
|
|
extra floppy drive (about $20 US in most computer parts
|
|
stores). I've asked questions to see if the problem
|
|
is limited to the write functionality (since a careful
|
|
reading of your messages seems to correlate to read-only
|
|
vs. read/write access). When you mount a filesystem
|
|
in rw mode under Linux --- I think the atime on the
|
|
root of that filesystem will be updated (involving
|
|
a write to the media). If it works when you try the
|
|
'<tt>mount -o ro</tt>' variation on the command --- that
|
|
suggests that it is related to the write functions.
|
|
</BLOCKQUOTE>
|
|
<!-- sig -->
|
|
|
|
<!-- end 5 -->
|
|
<hr width="40%" align="center">
|
|
|
|
<!-- begin 4 -->
|
|
<H3 align="left"><img src="../../gx/dennis/qbubble.gif"
|
|
height="50" width="60" alt="(?) " border="0"
|
|
>Found The Culprit!</H3>
|
|
|
|
<p><strong>From Tim Baverstock on Sun, 27 Jun 1999
|
|
</strong></p>
|
|
<p><strong>
|
|
Hi Jim.
|
|
</strong></p>
|
|
<p><strong>
|
|
Ach! Rats!
|
|
</strong></p>
|
|
<p><strong>
|
|
I forgot to email you the solution I discovered!
|
|
</strong></p>
|
|
<p><strong>
|
|
The drive wrote perfectly well under Windows, and worked without difficulty in
|
|
both directions with <tt>mcopy</tt>. I should have made this clearer in my
|
|
first email; my apologies for this.
|
|
</strong></p>
|
|
<p><strong>
|
|
The functionality of the drive, and the evident integrity of the msdos filing
|
|
system module eliminated those subsystems from the problem, which was why I was
|
|
so perplexed, and why I wrote to you.
|
|
<IMG SRC="../../gx/dennis/smily.gif" ALT=":)"
|
|
height="24" width="20" align="middle">
|
|
</strong></p>
|
|
<p><strong>
|
|
The next day, I used <tt>strace</tt> on `<tt>mount</tt>' to try and find out
|
|
where it hung. It hung on the actual <tt>mount()</tt> system call itself.
|
|
</strong></p>
|
|
<p><strong>
|
|
I noticed that the automounter was in `<tt>D</tt>' discwait on the process
|
|
list during its own mount attempt, so I disabled it in the boot sequence
|
|
while trying to find out what was going on (I wanted to strace the very
|
|
first attempt to mount the floppydrive) but that cured the problem!
|
|
</strong></p>
|
|
<p><strong>
|
|
Further investigation (with <tt>strace</tt>) revealed that I'd earlier changed
|
|
<TT>/etc/resolv.conf</TT> to include a domain search path while trying to set
|
|
my friend up with an ISP account, and the DNS hang was causing automount to
|
|
hang while trying to finagle those strange pseudo-NFS mounts of the local
|
|
host it does (by the host's internet name, not as `localhost') for the floppy
|
|
drive!
|
|
</strong></p>
|
|
<p><strong>
|
|
I fixed <tt>resolv.conf</tt>, and the problem went away, although I've left
|
|
AMD disabled, because autofs does the same job, and was installed alongside
|
|
it on RedHat; and because one day I'll get my friend's ISP working on Linux
|
|
as well as Windows. I don't want this to repeat.
|
|
<IMG SRC="../../gx/dennis/smily.gif" ALT=":)"
|
|
height="24" width="20" align="middle">
|
|
</strong></p>
|
|
<p><strong>
|
|
Many thanks for your response, and my apologies once more for not writing
|
|
sooner,
|
|
</strong></p>
|
|
<p><strong>
|
|
Tim Baverstock.
|
|
</strong></p>
|
|
|
|
<!-- end 4 -->
|
|
<!--startcut ======================================================= -->
|
|
<P> <hr> <P>
|
|
<H5 align="center"><a href="http://www.linuxgazette.com/copying.html"
|
|
>Copyright ©</a> 1999, James T. Dennis
|
|
<BR>Published in <I>The Linux Gazette</I> Issue 43 July 1999</H5>
|
|
<H6 ALIGN="center">HTML transformation by
|
|
<A HREF="mailto:star@starshine.org">Heather Stern</a> of
|
|
Starshine Techinical Services,
|
|
<A HREF="http://www.starshine.org/">http://www.starshine.org/</A>
|
|
</H6>
|
|
<P> <hr> <P>
|
|
<!-- begin tagnav ::::::::::::::::::::::::::::::::::::::::::::::::::-->
|
|
<TABLE WIDTH="97%"><TR VALIGN="center" ALIGN="center">
|
|
<TD ROWSPAN="3" COLSPAN="1" WIDTH="40%"><A
|
|
HREF="../lg_answer43.html"
|
|
><IMG SRC="../../gx/dennis/answernew.gif"
|
|
ALT="[ Answer Guy Index ]"></A></td>
|
|
<TD WIDTH="19%"><A HREF="1.html">1</A></TD>
|
|
<TD WIDTH="19%"><A HREF="2.html">2</A></TD>
|
|
<TD WIDTH="19%"><A HREF="3.html">3</A></TD>
|
|
</TR><TR VALIGN="center" ALIGN="center">
|
|
<TD><A HREF="4.html">4</A></TD>
|
|
<TD><A HREF="5.html">5</A></TD>
|
|
<TD><A HREF="6.html">6</A></TD>
|
|
</TR><TR VALIGN="center" ALIGN="center">
|
|
<TD><A HREF="7.html">7</A></TD>
|
|
<TD><A HREF="8.html">8</A></TD>
|
|
<TD><A HREF="9.html">9</A></TD>
|
|
</TR></TABLE>
|
|
<!-- end tagnav ::::::::::::::::::::::::::::::::::::::::::::::::::::-->
|
|
<P> <hr> <P>
|
|
<!-- begin lgnav ::::::::::::::::::::::::::::::::::::::::::::::::::: -->
|
|
<A HREF="../index.html"
|
|
><IMG SRC="../../gx/indexnew.gif" ALT="[ Table Of Contents ]"></A>
|
|
<A HREF="/index.html"
|
|
><IMG SRC="../../gx/homenew.gif" ALT="[ Front Page ]"></A>
|
|
<A HREF="../lg_bytes43.html"
|
|
><IMG SRC="../../gx/back2.gif" ALT="[ Previous Section ]"></A>
|
|
<A HREF="../lg_tips43.html"
|
|
><IMG SRC="../../gx/fwd.gif" ALT="[ Next Section ]"></A>
|
|
<!-- end lgnav ::::::::::::::::::::::::::::::::::::::::::::::::::::: -->
|
|
<!-- ::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: -->
|
|
</BODY></HTML>
|
|
<!--endcut ========================================================= -->
|