dd if=/dev/zero of=/dev/hdXY bs=512 count=1where
hdXY
is the relevant partition, eg, hda1
for the first partition of the first (IDE) disk.
Linux can read and write the files on your DOS and OS/2 FAT partitions
and floppies using either the DOS filesystem type built into the
kernel or mtools. There is an alpha version of kernel support for the
VFAT filesystem used by Windows 95 and Windows NT; it is available
from mm-ftp.cs.berkeley.edu
in /pub/multimedia/linux/vfat/vfat-0.3.0.tgz
. This was integrated into the standard kernel in version 1.3.60.
See Q1.2 `What software does it support ?' for details and status of the emulators for DOS, MS Windows and System V programs.
See also Q3.5 `Can I access BSD FFS, SysV UFS, Mac, Amiga, etc filesystems
?'.
Question 3.2. How do I access files on my DOS partition or floppy
?
Use the DOS filesystem, i.e. type, for example:
mkdir /dos mount -t msdos -o conv=text,umask=022,uid=100,gid=100 /dev/hda3 /dosIf it's a floppy, don't forget to
umount
it before ejecting it !
You can use the conv=text/binary/auto
, umask=nnn
, uid=nnn
and gid=nnn
options to control the automatic line-ending
conversion, permissions and ownerships of the files in the DOS
filesystem as they appear under Linux. If you mount your DOS
filesystem by putting it in your /etc/fstab
you can record the options (comma-separated) there, instead of
defaults
.
Alternatively you can use `mtools', available in both binary and source form on the FTP sites -- see Q2.5 `Where can I get Linux material by FTP ?'.
A kernel patch (known as the fd-patches) is available which allows
floppies with nonstandard numbers of tracks and/or sectors to be used;
this patch is included in the 1.1 alpha testing kernel series.
Question 3.3. Can I use my Stacked/DBLSPC/etc. DOS drive
?
Not very easily. You can access them from within the DOS emulator
[Q1.2 `What software does it support ?'], but it's harder to do as a normal filesystem under Linux or using mtools. There is a module available
for the Linux kernel which can do read-only access of the compressed
volume. Look on sunsite.unc.edu
in /pub/Linux/system/Filesystems
, for the ths
package.
Question 3.4. Can I access OS/2 HPFS partitions from Linux
?
Yes, but it's only read-only at the moment. To use it you must
compile a kernel with support for it enabled
[Q7.6 `How do I upgrade/recompile my kernel ?']. Then you can mount it using the mount
command, for example:
mkdir /hpfs mount -t hpfs /dev/hda5 /hpfs
sunsite.unc.edu
in /pub/Linux/patches/amigaffs.tar.Z
. More information is in affs-readme
in the tarfile.
Recent kernels contain support for the UFS filesystem used by System V, Coherent and Xenix.
There is alpha kernel support, readonly for the moment, for the 4.2BSD
UFS, on sunsite.unc.edu
in /pub/Linux/ALPHA/ufs
.
There is a set of user-level programs that provides read-only access
to the Macintosh hierarchical filing system (HFS). It is available on
sunsite.unc.edu
in /pub/Linux/utils/disk-management/hfs0_
36.tgz. This is being turned into a kernel module, which is available on
sunsite
.
A suite of programs called Samba provide support for Windows for
Workgroups networked filesystems (provided it's configured to use
TCP/IP). Information is available at http://lake.canberra.edu.au/samba/samba.html. There is alpha kernel support for mounting such filesystems, on
sunsite.unc.edu
in /pub/Linux/ALPHA/smbfs
.
There is no support for the rest of those yet; I have not heard of any
recent work on providing some.
Question 3.6. Can I run Microsoft Windows programs under Linux
?
Not yet. There is a project, known as WINE, to build an MS Windows
emulator for Linux, but it is not ready for users yet. Don't ask
about it unless you think you can contribute; look out for the status
reports in comp.emulators.ms-windows.wine
.
In the meantime if you need to run MS Windows programs your best bet
is probably to reboot when you want to switch environments. LILO (the
Linux bootloader) has the facility for a boot menu --- see its
documentation for more details.
Question 3.7. How can I boot Linux from OS/2's Boot Manager
?
1. Create a partition using OS/2's FDISK
(Not Linux's fdisk
).
2. Format the partition under OS/2, either with FAT or HPFS. This is so that OS/2 knows about the partition being formatted. (This step is not necessary with OS/2 "warp" 3.0.)
3. Add the partition to the Boot Manager.
4. Boot Linux, and create a filesystem on the partition using
mkfs -t ext2
or mke2fs
. At this point you may, if you like, use Linux's fdisk
to change the partition type code of the
new partition to type 83 (Linux Native) -- this may help some
automated installation scripts find the right partition to use.
5. Install Linux on the partition.
6. Install LILO on the Linux partition -- NOT on the master boot record of the hard drive. This installs LILO as a second-stage boot loader on the Linux partition itself, to start up the kernel specified in the LILO config file. To do this you should put
boot = /dev/hda2(where
/dev/hda2
is the partition you want to boot off) in your /etc/lilo/config
or /etc/lilo.config
file.
7. Make sure that it is the Boot Manager partition that is marked
active, so that you can use Boot Manager to choose what to boot.
Question 3.8. How can I share a swap partition between Linux and MS
Windows ?
See the Mini-HOWTO on the subject by H. Peter Anvin,
hpa@yggdrasil.com
. It is available on sunsite.unc.edu
in /pub/Linux/docs/HOWTO/mini/Swap-Space
.
Ian Jackson / ijackson@gnu.ai.mit.edu - 06 March 1996