Re: Why can't I access my floppy disk?

2005-02-21 Thread Dan Nelson
In the last episode (Feb 22), Anthony Atkielski said:
> I put a diskette (MS-DOS) into my floppy drive and try
> 
> mount -t msdosfs /dev/fd0 /floppy
> mount -o ro -t msdosfs /dev/fd0 /floppy
> 
> and various other variations, but all I get is "Operation not permitted"
> 
> fsck works okay.  I'm logged in as root.  What am I overlooking?

Is it write-protected?  Securelevel too high?  Check your console or
dmesg output; the kernel may be printing more info there.

-- 
Dan Nelson
[EMAIL PROTECTED]
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Why can't I access my floppy disk?

2005-02-21 Thread Anthony Atkielski
Dan Nelson writes:

> Is it write-protected?  Securelevel too high?  Check your console or
> dmesg output; the kernel may be printing more info there.

No console messages that I've seen, but securelevel=3.  Does
securelevel=3 prevent me from mounting floppies??

-- 
Anthony


___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Why can't I access my floppy disk?

2005-02-21 Thread Dan Nelson
In the last episode (Feb 22), Anthony Atkielski said:
> Dan Nelson writes:
> > Is it write-protected?  Securelevel too high?  Check your console
> > or dmesg output; the kernel may be printing more info there.
> 
> No console messages that I've seen, but securelevel=3.  Does
> securelevel=3 prevent me from mounting floppies??

A quick look at the source says it shouldn't stop you, but there are a
lot of calls within vfs_domount that may return EPERM.  You may need to
add printfs to figure out which one is failing.

-- 
Dan Nelson
[EMAIL PROTECTED]
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Why can't I access my floppy disk?

2005-02-22 Thread Lowell Gilbert
Anthony Atkielski <[EMAIL PROTECTED]> writes:

> Dan Nelson writes:
> 
> > Is it write-protected?  Securelevel too high?  Check your console or
> > dmesg output; the kernel may be printing more info there.
> 
> No console messages that I've seen, but securelevel=3.  Does
> securelevel=3 prevent me from mounting floppies??

Yes.  This is, in fact, one of the main ways in which securelevel
makes the system more secure.

If you are going to run at a raised securelevel, please read 
"man securelevel".
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Why can't I access my floppy disk?

2005-02-22 Thread Chad Leigh -- Shire . Net LLC
On Feb 22, 2005, at 8:27 AM, Lowell Gilbert wrote:
Anthony Atkielski <[EMAIL PROTECTED]> writes:
Dan Nelson writes:
Is it write-protected?  Securelevel too high?  Check your console or
dmesg output; the kernel may be printing more info there.
No console messages that I've seen, but securelevel=3.  Does
securelevel=3 prevent me from mounting floppies??
Why would you want to mount an MSDOS floppy on a server?  That reduces 
the security and stability of your server

Chad
(before any of you reply, go research Anthony's missives on servers)
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Why can't I access my floppy disk?

2005-02-22 Thread Anthony Atkielski
Lowell Gilbert writes:

> Yes.  This is, in fact, one of the main ways in which securelevel
> makes the system more secure.

OK

> If you are going to run at a raised securelevel, please read 
> "man securelevel".

I did.  It doesn't say anything about not being able to mount a floppy.
Since I can mount CD-ROMs, I figured I could mount a floppy, but perhaps
not.

I'll have to try it with securelevel set lower when I get a chance.  As
it is, I managed to create the floppy I needed on Windows, so the
problem is no longer pressing.

-- 
Anthony


___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Why can't I access my floppy disk?

2005-02-22 Thread Anthony Atkielski
Chad Leigh -- Shire.Net LLC writes:

> Why would you want to mount an MSDOS floppy on a server?

In order to copy a raw file image to the floppy.

> That reduces the security and stability of your server

Not really. See above. The intent is not to leave the floppy permanently
mounted; I only needed to copy a raw diskette image to the floppy (a
boot floppy for FreeBSD, as it happens). As it happens, I found a way to
do it under Windows, so the problem is solved.

-- 
Anthony


___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Why can't I access my floppy disk?

2005-02-23 Thread Loren M. Lang
On Tue, Feb 22, 2005 at 08:39:24PM +0100, Anthony Atkielski wrote:
> Chad Leigh -- Shire.Net LLC writes:
> 
> > Why would you want to mount an MSDOS floppy on a server?
> 
> In order to copy a raw file image to the floppy.

Do you mean install a 1440k floppy image onto a disk or just copy a file
smaller than 1440k onto the msdos fs of an already formatted floppy.
The latter should be ok even at securelevel 3, but the former can't
because that would mean open /dev/fd0 for writing other than a mount.

> 
> > That reduces the security and stability of your server
> 
> Not really. See above. The intent is not to leave the floppy permanently
> mounted; I only needed to copy a raw diskette image to the floppy (a
> boot floppy for FreeBSD, as it happens). As it happens, I found a way to
> do it under Windows, so the problem is solved.
> 
> -- 
> Anthony
> 
> 
> ___
> freebsd-questions@freebsd.org mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-questions
> To unsubscribe, send any mail to "[EMAIL PROTECTED]"

-- 
I sense much NT in you.
NT leads to Bluescreen.
Bluescreen leads to downtime.
Downtime leads to suffering.
NT is the path to the darkside.
Powerful Unix is.

Public Key: ftp://ftp.tallye.com/pub/lorenl_pubkey.asc
Fingerprint: B3B9 D669 69C9 09EC 1BCD  835A FAF3 7A46 E4A3 280C
 
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Why can't I access my floppy disk?

2005-02-23 Thread Anthony Atkielski
Loren M. Lang writes:

> Do you mean install a 1440k floppy image onto a disk or just copy a file
> smaller than 1440k onto the msdos fs of an already formatted floppy.

Specifically, I was trying to generate an installation boot floppy for
FreeBSD, in order to install it on my other machine (which is too old to
boot from CD).

> The latter should be ok even at securelevel 3, but the former can't
> because that would mean open /dev/fd0 for writing other than a mount.

I got the error just trying to mount the diskette.  I tried all
different formats of the mount and mount_msdosfs commands and they all
either generated a syntax error or told me that the operation was not
permitted.

-- 
Anthony


___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Why can't I access my floppy disk?

2005-02-25 Thread Loren M. Lang
On Wed, Feb 23, 2005 at 05:11:37PM +0100, Anthony Atkielski wrote:
> Loren M. Lang writes:
> 
> > Do you mean install a 1440k floppy image onto a disk or just copy a file
> > smaller than 1440k onto the msdos fs of an already formatted floppy.
> 
> Specifically, I was trying to generate an installation boot floppy for
> FreeBSD, in order to install it on my other machine (which is too old to
> boot from CD).

If you were using one of the pre-fabbed floppy images provided by
freebsd like kern.flp then you would want to write it raw to disk, not
mount it, and this is forbidden at securelevel 3.

> 
> > The latter should be ok even at securelevel 3, but the former can't
> > because that would mean open /dev/fd0 for writing other than a mount.
> 
> I got the error just trying to mount the diskette.  I tried all
> different formats of the mount and mount_msdosfs commands and they all
> either generated a syntax error or told me that the operation was not
> permitted.

I don't know why this is, it should still be possible, especially since
you can mount cdroms.  /dev/fd0 is read/write by root right?  And the
disk already had a formatted filesystem on it before you tried mounting
it?

> 
> -- 
> Anthony
> 
> 
> ___
> freebsd-questions@freebsd.org mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-questions
> To unsubscribe, send any mail to "[EMAIL PROTECTED]"

-- 
I sense much NT in you.
NT leads to Bluescreen.
Bluescreen leads to downtime.
Downtime leads to suffering.
NT is the path to the darkside.
Powerful Unix is.

Public Key: ftp://ftp.tallye.com/pub/lorenl_pubkey.asc
Fingerprint: B3B9 D669 69C9 09EC 1BCD  835A FAF3 7A46 E4A3 280C
 
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Why can't I access my floppy disk?

2005-02-25 Thread Anthony Atkielski
Loren M. Lang writes:

> If you were using one of the pre-fabbed floppy images provided by
> freebsd like kern.flp then you would want to write it raw to disk, not
> mount it, and this is forbidden at securelevel 3.

I was trying to do it with dd.  I tried the same on my other system (the
one on which I'm trying to install FreeBSD for experimentation), and it
worked, but that system is at the default level of securelevel=-1.

That's fine, though, since it gives me a machine that can do the job,
which is all I need.  I trust a UNIX command a bit more than I trust a
Windows command (especially since the one supplied on the FreeBSD CD is
a bit weird).

> I don't know why this is, it should still be possible, especially since
> you can mount cdroms.  /dev/fd0 is read/write by root right?  And the
> disk already had a formatted filesystem on it before you tried mounting
> it?

Yes to both questions.  But it must be securelevel, because it works on
the test machine.  The man page doesn't say anything about this
restriction, though, nor is it obvious from what the page does say.

-- 
Anthony


___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Why can't I access my floppy disk?

2005-02-28 Thread Ruben de Groot
On Fri, Feb 25, 2005 at 06:41:10PM +0100, Anthony Atkielski typed:
> Loren M. Lang writes:

> > I don't know why this is, it should still be possible, especially since
> > you can mount cdroms.  /dev/fd0 is read/write by root right?  And the
> > disk already had a formatted filesystem on it before you tried mounting
> > it?
> 
> Yes to both questions.  But it must be securelevel, because it works on
> the test machine.  The man page doesn't say anything about this
> restriction, though, nor is it obvious from what the page does say.

>From the securelevel manpage (which is symlinked to init(8) ):

 1 Secure mode - the system immutable and system append-only flags may
   not be turned off; disks for mounted file systems, /dev/mem,
   /dev/kmem and /dev/io (if your platform has it) may not be opened
   for writing; kernel modules (see kld(4)) may not be loaded or
   unloaded.

 2 Highly secure mode - same as secure mode, plus disks may not be
   opened for writing (except by mount(2)) whether mounted or not.
   This level precludes tampering with file systems by unmounting
   them, but also inhibits running newfs(8) while the system is multi-
   user.
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Why can't I access my floppy disk?

2005-02-28 Thread Anthony Atkielski
Ruben de Groot writes:

>  1 Secure mode - the system immutable and system append-only flags may
>not be turned off; disks for mounted file systems, /dev/mem,
>/dev/kmem and /dev/io (if your platform has it) may not be opened
>for writing; kernel modules (see kld(4)) may not be loaded or
>unloaded.

Disks for mounted file systems ... but the floppy disk was not mounted.
Indeed, the problem was just that:  I couldn't mount it.

>  2 Highly secure mode - same as secure mode, plus disks may not be
>opened for writing (except by mount(2)) whether mounted or not.
>This level precludes tampering with file systems by unmounting
>them, but also inhibits running newfs(8) while the system is multi-
>user.

I wasn't trying to open the diskette for writing.  Even a read-only attempt
to mount the diskette failed.

If securelevel=3 prohibits mounting floppy disks, then the documentation
should say something like "floppy disks cannot be mounted at this
level."

-- 
Anthony


___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"