LDP/LDP/howto/docbook/Install-Strategies.sgml

937 lines
53 KiB
Plaintext

<!DOCTYPE article PUBLIC "-//OASIS//DTD DocBook V4.1//EN">
<!--
DocBook 4.1 markup
2001/04/10 - Philippe Martin - feloy@free.fr
-->
<article>
<articleinfo>
<title>Linux Installation Strategies mini-HOWTO</title>
<author>
<firstname>Tobby</firstname>
<surname>Banerjee</surname>
<affiliation>
<address><email>tobbyb@usa.net</email></address>
</affiliation>
</author>
<othercredit>
<firstname>Philippe</firstname>
<surname>Martin</surname>
<contrib>Conversion to DocBook SGML</contrib>
</othercredit>
<revhistory>
<revision>
<revnumber>1.0.1</revnumber>
<date>2001-05-02</date>
<authorinitials>pm</authorinitials>
<revremark>
Conversion to DocBook SGML.
</revremark>
</revision>
<revision>
<revnumber>1.0</revnumber>
<date>2000-12-20</date>
<authorinitials>tb</authorinitials>
<revremark>
Initial release.
</revremark>
</revision>
</revhistory>
<abstract>
<simpara>This document discusses a few installation strategies for those
who intend to dual-boot between Windows and Linux.</simpara>
</abstract>
</articleinfo>
<sect1>
<title>License</title>
<simpara>You are free to do with this document
whatever you please but reading it would be a good idea. I am naturally not
responsible for any consequence or action arising out of the use of
information provided in this document. I am not a very responsible person
and you heed me at your own peril.</simpara>
</sect1>
<sect1>
<title>Mail</title>
<simpara>Should you find this document helpful please
feel free to mail me at <email>tobbyb@hotmail.com</email>. Microsoft shares
will be highly appreciated but short of that flattery will do just fine.
</simpara>
</sect1>
<sect1>
<title>The basics</title> <simpara>The primary purpose of this document is
to make the co-existance between Windows and Linux as simple and uncomplex
as possible which means as far as Windows is concerned Linux doesn't
exist. It is now possible to install Linux on a Windows partition as a disk
image with what is known as the <systemitem>loopback</systemitem> filesystem
&ndash; RedHat and Mandrake offer this &ndash; but it's an extremely bad
idea because of the way Windows handles files. Defragmenting the system will
become a nightmare and Linux itself will crawl and it will ruin both your
Windows and Linux experience. The same applies to the
<systemitem>Umsdos</systemitem> filesystem (though Linux won't crawl) and
it's best to install Linux on a partition of its own. This document makes a
few presumptions but nothing to worry about &ndash; just a few.</simpara>
<para><itemizedlist>
<listitem>
<simpara>You are using Windows 9x (95,98) not Me or 2000.</simpara>
</listitem>
<listitem>
<simpara>You are familiar with computers <abbrev>ie</abbrev> you know
how to boot the system using the floppy or cdrom drive</simpara>
</listitem>
<listitem>
<simpara>You know your way around DOS and Windows</simpara>
</listitem>
<listitem>
<simpara>You know what a partition is and want to install Linux on a
partition of its own</simpara>
</listitem>
<listitem>
<simpara>You have a large hard disk &ndash; upward of
<literal>8.4</literal>&nbsp;Gb &ndash; which currently holds
Windows and on which you intend to install Linux (even
those who with smaller disks can read on).</simpara>
</listitem>
</itemizedlist>
</para>
<simpara>With that out of the way we can begin. The first thing to do is to
make space for Linux. Like other Linux wannabes you are likely to be stuck
with a huge single partition with Windows on it. This would be your
<medialabel>C</medialabel> drive. In my case it was hogging
<literal>13.5</literal>&nbsp;gigs. You have to make a separate partition
for Linux out of this space (which would then be labelled as
<medialabel>D</medialabel>). You can either use Windows
<application>Fdisk</application> which really is not a good idea as it
would entail losing all your data and making new partitions from scratch,
one for Windows and one for Linux, or you can take the easier and far more
convenient way out and use a free and excellent non-destructive
partitioning utility called <application>Fips</application>. What makes
<application>Fips</application> special is its ability to create a new
partition out of the free space in your <MediaLabel>C</MediaLabel>
partition without any loss of data. The latest version of
<application>Fips</application> (<literal>2.0</literal>) is available at
its homepage <ulink url="http://www.igd.fhg.de/~aschaefe/fips/"></ulink>
and most Linux distributions carry it under the
<filename class="directory">/dostools</filename> or
<filename class="directory">/dosutils</filename> directory in the primary
cd.</simpara>
<simpara>We are going to concentrate on using
<application>Fips</application> so if you are going to use Windows
<application>Fdisk</application> &ndash; which actually is totally
unnecessary unless you have just bought a new system and even then it's a
better idea to make a single partition with Windows
<application>Fdisk</application>, install Windows on it and then use
<application>Fips</application> to split it for reasons that I'm going to
explain later in this document &ndash; or a commercial partition utility
like <application>Partition Magic</application> you are on your
own.</simpara>
</sect1>
<sect1>
<title>A note about hard disks and partitions</title>
<simpara>A hard disk can have a maximum of <literal>4</literal> primary
partitions &ndash; don't ask me why, I don't know. Apart from primary
partitions a hard disk can also have what is known as an extended partition
which inturn can hold a number of logical partitions &ndash; I believe the
number is close to <literal>15</literal>. The extended partitions are not
real partitions like primary or logical partitions in that they don't store
data but are actually containers for logical partitions which is where data
is actually stored &ndash; as you can see it is uneccessarily complex. Thus
in Windows <medialabel>C</medialabel> is a primary partition and if you used
Windows <application>Fdisk</application> &ndash; Windows
<application>Fdisk</application> will not make more than one primary
partition to partition your hard disk &ndash; <medialabel>D</medialabel> is
usually the first logical partition of the extended
partition. <medialabel>E</medialabel> would be the second logical partition
and so on. In Linux things are slightly different. The first primary
partition is called <filename class="devicefile">/dev/hda1</filename>, the
second primary partition <filename class="devicefile">/dev/hda2</filename>
upto the fourth which is <filename class="devicefile">/dev/hda4</filename>.
Linux refers to the an extended partition as in the case of a disk with
<literal>1</literal> primary and one extended partition as
<filename class="devicefile">/dev/hda1</filename> for the primary and
<filename class="devicefile">/dev/hda2</filename> for the extended. The
logical partitions of the extended partitions are referred to as
<filename class="devicefile">/dev/hda5</filename>,
<filename class="devicefile">/dev/hda6</filename> and so on. The second hard disk
would be referred to as <filename class="devicefile">/dev/hdb</filename>,
the third <filename class="devicefile">/dev/hdc</filename> (usually the
cdrom drive if set as secondary master) and the fourth and last hard disk as
<filename class="devicefile">/dev/hdd</filename> (last because the
motherboard has place for a maximum of <literal>4</literal>
<acronym>IDE</acronym> devices) <acronym>SCSI</acronym> devices are referred
to as <filename class="devicefile">/dev/sda</filename> &ndash; thank god for
that.</simpara>
</sect1>
<sect1>
<title>The concepts</title>
<simpara>What <application>Fips</application> does is make a new primary
partition out of the free space in your hard disk. This is an inherently
dangerous operation and it's a good idea to back up all your important
data lest something go wrong. Having said that
<application>Fips</application> has been used successfully by a large
number of people in different conditions and unless there is something
already wrong with your hard disk, <acronym>FAT</acronym> (File Allocation
Table) or partition table things will work just fine. You should read the
<application>Fips</application> documentation.</simpara>
<simpara>Before you set out to partition the hard disk you have to decide
how you want to boot into Linux. The default and most common method is to
use <application>Lilo</application> &ndash; a simple and basic bootloader
program that overwrites (after saving) your hard disk's
<acronym>MBR</acronym> (Master Boot Record) and on booting the system
gives you a choice between booting either Windows or Linux. If you select
Windows it boots Windows and you are met with the familiar windows screen
or if you select Linux it boots Linux and if you don't make a choice in
the stipulated time &ndash; could be anything from
&plusmn;<literal>5</literal> seconds depending on how you set it up
&ndash; it boots the default operating system, Windows or Linux, again
depending on how you set it up. You can restore your original
<acronym>MBR</acronym> anytime, when uninstalling Linux for instance,
either by typing <command>/sbin/lilo <option>-u</option></command> within
Linux or typing <command>fdisk <option>/MBR</option></command> in DOS
(this will overwrite the <acronym>MBR</acronym> with the original Windows
<acronym>MBR</acronym>) needless to say you would lose the option to boot
into Linux after this and thus access to your Linux partition.</simpara>
<simpara>The problem with using <application>Lilo</application> especially
for those with large disks is you would have to give up a substantial
chunk of your disk space to Linux. This is not a flexible solution since
while you can access your Windows partition from within Linux &ndash; the
large <acronym>MPEG</acronym> files can thus be stored in Windows and
accessed by both operating systems &ndash; the alternate is not
true.</simpara>
<simpara>This is because of an arcane <acronym>BIOS</acronym> limitation
that limits <application>Lilo</application> to the first
<literal>1024</literal> cylinders of the hard disk. Windows and Linux have
no such limitations &ndash; it has something to do with address
translation and <acronym>LBA</acronym> which I have yet to fully
understand. Suffice to know the <acronym>BIOS</acronym> cannot access data
that is beyond this <literal>1024</literal> cylinder limit and since
<application>Lilo</application> is dependent on the
<acronym>BIOS</acronym> to boot the <acronym>OS</acronym>'s nor can
it. Thus if you want to use <application>Lilo</application> to boot Linux
you got to make sure that the Linux partition is well below the
<literal>1024</literal> cylinder limit. My hard disk &ndash; and most
modern hard disks have more than <literal>1024</literal> cylinders &ndash;
has <literal>1650</literal> cylinders and using
<application>Lilo</application> means making the Linux partition at about
the <literal>1000</literal> or <literal>1010</literal> cylinder mark which
translates into a whopping <literal>5.2</literal>&nbsp;Gb of
<literal>12.9</literal>&nbsp;Gb to Linux and this wasn't working for me
since my Linux stuff hardly need more than <literal>2</literal>&nbsp;Gb
and my Windows data on the other hand with <acronym>MP3</acronym>'s and
<acronym>MPEG</acronym> movies needs a lot more than
<literal>7</literal>&nbsp;Gb.</simpara>
<simpara>The solution, and in Linux there are always solutions, is
<application>Loadlin</application>, an underrated alternative to
<application>Lilo</application> which is inexplicably not as popular or
widespread, inexplicable because it's far more flexible. If you intend to
use <application>Loadlin</application> and for those with large hard-disks
it's an excellent alternative you don't have to worry about the
<literal>1024</literal> cylinder limit. Even better you can launch Linux
from your Windows desktop and modify your
<filename>autoexec.bat</filename> file to give you an option to boot into
either of the <acronym>OS</acronym>'s during boot time not unlike
<application>Lilo</application>. You are then free to size your partitions
as you please. In my case a <literal>2.2</literal>&nbsp;Gb extended
partition with <literal>3</literal> logical partitions. That's right
<literal>3</literal> partitions. It's normal to make three partitions, one
for the Kernel boot files, one for the root partition and one for the swap
partition but more on that later.</simpara>
<simpara>If you must use <application>Lilo</application> but are unwilling
to give up a lot of space there is a solution. Place the Linux partition
in the middle of the disk. You have to split the new partition you just
created using <application>Fips</application> into <literal>2</literal>
(you would have to use <application>Fips</application> once again for
this) the first partition which falls within the <literal>1024</literal>
cylinder limit can be used for Linux and the second you can use for
Windows. Thus your hard disk will then have <literal>3</literal>
partitions the first and third for Windows and the one in the middle for
Linux. I don't like this arrangement but it's up to you. (At the moment we
are refering to the Linux partition as one but during the installation you
will split it into <literal>3</literal> using the Linux tools) You can
also make a small <literal>15</literal>-<literal>20</literal>&nbsp;Mb
<filename class="directory">/boot</filename> partition and place it before
the <literal>1024</literal> cylinder mark and the rest of the installation
anywhere on the hard disk but again I quite don't like this.</simpara>
</sect1>
<sect1>
<title>Partitioning</title>
<simpara>Now we are ready to actually partition the hard disk. First make a
DOS boot disk (type <command>format a: <option>/s</option></command> at
the DOS prompt or in DOS). Put the following three files in the disk,
<filename>fips.exe</filename>, <filename>restorrb.exe</filename> and
<filename>errors.txt</filename>. Defragment your hard disk &ndash; this
puts all the data at the beginning leaving enough space for
<application>Fips</application> to create a new partition from. If you use
<application>Norton SpeedDisk</application> select the unfragment free
space option. <application>Norton</application> usually puts data at the
end of the disk and this will prevent <application>Fips</application> from
creating a new partition. Run <application>Scandisk</application> and
reboot using the bootdisk you just created.</simpara>
<simpara>Type <command>fips</command> at the prompt and
<application>Fips</application> will show you your partition table with a
warning about partition table inconsistency. If your disk has more than
<literal>1024</literal> cylinders its usually safe to ignore this
warning. Next <application>Fips</application> will ask you is you want to
proceed &ndash; the program is extremely meticulous &ndash; answer yes
obviously and when prompted to save a backup of your partition table and
boot sector answer yes &ndash; this step is absolutely vital as it allows
you to restore your hard disk to its unpartioned single partition state
should anything go wrong. It also comes in handy if you want to uninstall
Linux or resize your Linux partition. It doesn't matter what happens to
the new partition in the meantime, if you have the back up you can restore
your hard disk to its original unpartioned state. This reversible
operation will work in all circumstances but one; if you format your
original (Windows) partition which was split to make space for Linux in
the meantime, the original <acronym>FAT</acronym> is overwritten with a
new and smaller one and the restore operation will not work.</simpara>
<simpara>After making the backup you will be presented with a screen with
<literal>3</literal> numbers, the first represents your original partition
&ndash; notice it is at its smallest size, <application>Fips</application>
has allocated all free space in the hard disk to the new partition, this
is the default behavior. The second column shows the cylinder info which
will be the guide for those who plan to use
<application>Lilo</application>. The third shows the size of the new
partition you are going to create &ndash; it is at its largest size. Use
the arrow keys to resize the partition, you would just have to reduce the
size of the new partition since it is at its maximum to a size you
want. For <application>Lilo</application> users the new partition has to
be below the <literal>1024</literal> cylinder mark,
<literal>1000</literal> is a reasonable beginning for the new
partition. After you are satisfied with the size of your new partition
press enter, <application>Fips</application> will ask you to confirm and
write the new partition table.</simpara>
<simpara>Reboot your system. Remember to change the <acronym>BIOS</acronym>
settings to boot from the hard disk or you will end up rebooting with the
floppy. Double click <guiicon>My Computer</guiicon> and you will see the
result of all the hard work, there will be a new drive labelled
<medialabel>D</medialabel> alongside the original
<medialabel>C</medialabel>. Don't touch <medialabel>D</medialabel>, run
<application>scandisk</application> on your original partition
(<medialabel>C</medialabel>) &ndash; hopefully there will be no errors
&ndash; and at this point you are ready to install Linux.</simpara>
<simpara>Some of the Linux documentation mistakenly ask you to delete the
newly created partition using Windows <application>Fdisk</application>. Do
not commit that blunder because if you do the Linux partitions will show
up in <guiicon>My Computer</guiicon> when you reboot after installing
Linux and since Windows obviously cannot read these drives and the
<acronym>ext2</acronym> filesystem, using
<application>Explorer</application> and acessing your hard disk in Windows
will become a time consuming and destabilizing affair. So don't do
it.</simpara>
</sect1>
<sect1>
<title>Installation</title>
<simpara>Reboot using your Linux Installation CD &ndash; I use Redhat 6.2 which is
fairly straight forward and I will focus on it. Most Linux distributions
have really worked on their installation programs and you shouldn't have a
problem. Just have the details about your hardware in hand, the horizontal
and vertical refresh rate of your monitor in case the installation program
doesn't automatically detect it ( you will find the exact figures in the
manual ), the video card, its memory type ( <acronym>SDRAM</acronym> or
<acronym>SGRAM</acronym> ) and size, and your mouse type &ndash;
<acronym>PS2</acronym> or Serial. As I mentioned earlier you will have to
make about <literal>3</literal> partitions for Linux, you can make more
but <literal>3</literal> is the recommended number. There are
<literal>3</literal> main installation types,
<emphasis>Workstation</emphasis>, <emphasis>Server</emphasis> and
<emphasis>Custom</emphasis>. The Server class install erases everything in
the hard disk so beware. The workstation and custom installs have
sub-classes but that's for you to explore.</simpara>
<simpara><application>Loadlin</application> users have to select custom
installation and dump <application>Lilo</application> when given the
oppurtunity because the other types of installations install
<application>Lilo</application> by default and without asking and we dont
want that do we? <application>Lilo</application> users have no
restrictions; you can opt for whichever install type you like.</simpara>
</sect1>
<sect1>
<title>The <application>Lilo</application> way</title>
<simpara><application>Lilo</application> fans can use <application>Disk
Druid</application> which is RedHat's default partitioning utility
&ndash; yes we haven't finished with partitioning just yet. First delete
the second partition which will show up in
<application>Disk Druid</application>'s screen as
<filename class="devicefile">/dev/hda2.</filename> Then create a new
partiton, set its mount point to
<filename class="directory">/boot</filename> and size to
<literal>16</literal>&nbsp;Mb. Create the second partition and set its
mount point to <filename class="directory">/</filename>(that's called the
root partition) and size to <emphasis>growable</emphasis>. This tells
<application>Disk Druid</application> to reclaim all free space after you
have finshed partititoning . Create the third partition and set its mount
point to <systemitem>swap</systemitem> and size to about
<literal>127</literal>&nbsp;Mb presuming you have
<literal>64</literal>&nbsp;Mb <acronym>RAM</acronym>, those with less can
make a <literal>64</literal>&nbsp;Mb swap partition.</simpara>
</sect1>
<sect1>
<title>The <application>Loadlin</application> way</title>
<simpara>Those who intend to use <application>Loadlin</application> however
cannot use <application>Disk Druid</application>, they will have to use
Linux <application>Fdisk</application> which may have an intimidating
reputation but is actually pretty simple. When presented with the
<guilabel>installation type</guilabel> screen select
<guibutton>custom</guibutton> and with <guibutton>fdisk</guibutton> (you
will find a small button with <guibutton>fdisk</guibutton> on it at the
top of the screen). For some reason <application>Disk Druid</application>
doesn't let you proceed with the installation if your
<filename class="directory">/boot</filename> partition is above the
<literal>1024</literal> cylinder limit so if you try to use it to create
the partitions the install program will refuse to
proceed. <application>Fdisk</application> is a pretty straight forward
program and easy to use too. First you have to delete the partition you
just created using <application>Fips</application>. Many people don't
understand why they have to delete the partition they just created at
considerable risk. This new partition is actually a
<acronym>FAT32</acronym> partiton which Linux cannot use and when you
delete it, it doesn't revert to being a part of <medialabel>C</medialabel>
but is actually <guilabel>UNPARTITIONED FREE SPACE</guilabel> which you
can use to create new partitions.</simpara>
<simpara>You have to understand a few <application>Fdisk</application>
operations, typing <keycap>m</keycap> lists all the options, typing
<keycap>p</keycap> at the prompt shows you the current partition table,
<keycap>d</keycap> deletes a partiton, <keycap>n</keycap> creates a
partition, <keycap>q</keycap> quits without saving changes so if you make
any mistakes there is nothing to worry about just type <keycap>q</keycap>
and start all over again, <keycap>w</keycap> writes changes to the
partition table use only after you are sure and <keycap>L</keycap> shows
you the hex numbers for different partition types but you only need to
know <literal>2</literal>, <symbol>Linux native</symbol> is hex number
<constant>83</constant> and <symbol>Linux swap</symbol> is hex number
<constant>82</constant>. So why do you need the Hex numbers? While
<application>Disk Druid</application> allows you to mount a swap partition
without going into the hex numbers in <application>Fdisk</application> the
only way to make a swap partiton is to give it its correct hex number
which is <constant>82</constant>.</simpara>
<simpara>Let's start, in <application>Fdisk</application> type
<keycap>p</keycap> at the prompt and you will see the current partition
table. Type <keycap>d</keycap> and select the partition you want to delete
which in this case would be
<filename class="devicefile">/dev/hda2</filename> (just type <literal>2</literal>)
type <keycap>p</keycap> again and you will see the change reflected in the
partition table. There will now be a single <acronym>FAT32</acronym>
partition <filename class="devicefile">/dev/hda1</filename> (which is
actually <medialabel>C</medialabel>). Type <keycap>n</keycap> to create a
new partition and for <prompt>type of partition</prompt> the choices being
<emphasis>primary</emphasis> or <emphasis>extended</emphasis> select
<keycap>e</keycap>. There is no hard and fast rule about this for instance
you could have a primary partition for
<filename class="directory">/boot</filename> and an extended partition
holding two logical partitions <filename class="directory">/</filename> and
<systemitem>swap</systemitem>. I recommend an extended partition that
holds three logical partitions. Now you have to size your extended
partition properly since it's a container for the three logical
partitions. From now on you just have to respond to
<application>Fdisk</application>. It will ask you to set the size of the
extended partition that you want to create. This partition will start
where your Windows partition ends and ends at the end of the disk. You can
either give the size in <acronym>M</acronym> (megabytes) in cylinder
numbers or in <acronym>K</acronym> (kilobytes). Just accept the default
for the start of the partition and select the end cylinder number for the
end &ndash; <application>Fdisk</application> will give you the end
cylinder number.</simpara>
<simpara>Repeat the operation for the three logical partitions, only this
time you would have to select logical instead of extended and the
appropriate sizes which are <literal>16</literal>&nbsp;Mb for the boot
partition, <literal>127</literal>&nbsp;Mb for the swap partition (the size
of the swap partition is variable depending on installed
<acronym>RAM</acronym>, double your <acronym>RAM</acronym> is recommended)
and the rest of the free space for the root
( <filename class="directory">/</filename> ) partition. Find your way
&ndash; it's simple, really! After creating the three partitions type
<keycap>p</keycap> and you will see the partitions you just created. There
will be <filename class="devicefile">/dev/hda2</filename> (extended)
<filename class="devicefile">/dev/hda5</filename> (logical)
<filename class="devicefile">/dev/hda6</filename> (logical) and
<filename class="devicefile">/dev/hda7</filename> (logical). There is just
one thing left to do, set the hex number for the swap partition. Type
<keycap>t</keycap> and select the <literal>127</literal>&nbsp;Mb partition
you created which would be
<filename class="devicefile">/dev/hda6</filename> enter
<constant>6</constant> for the partition number and
<constant>82</constant> for the hex number (you will be prompted) and you
have just finished with partitioning. Type <keycap>w</keycap> after making
sure and <application>Fdisk</application> will write the new partition
table and exit. The next screen will be the
<application>Disk Druid</application> screen our
<application>Lilo</application> friends
have already seen and you just have to mount the partitions with
<application>Disk Druid</application>. Select
<filename class="devicefile">/dev/hda5</filename> (the
<literal>16</literal>&nbsp;Mb partition) and mount it as
<filename class="directory">/boot</filename>. Select
<filename class="devicefile">/dev/hda7</filename> and mount it as
<filename class="directory">/</filename> (the root partition)</simpara>
</sect1>
<sect1>
<title>Rebooting</title>
<simpara>The rest of the installation is straight forward and requires no
hand holding. Select the packages you want, make the boot disk when given
the oppurtunity to (absolutely essential especially for
<application>Loadlin</application> users) and reboot the
system. <application>Lilo</application> users should press
<userinput>dos</userinput> at the <application>Lilo</application> prompt
to boot into Windows. Like promised none of the Linux partitions will be
visible to Windows and we can all rest in peace for
that. <application>Lilo</application> users should reboot the system and
boot into linux this time by typing <userinput>linux</userinput> at the
<application>Lilo</application> prompt and depending on the choices you
made you will either be at the console or the
<application>gnome</application> or <application>kde</application>
desktop. From one amateur to another it's always a good idea to log into
the console first and not graphically and then starting
<application>X</application> because if <application>X</application>
crashes on you still have access to the system to make amends.
<application>Lilo</application> is set to boot into Linux by default after
a gap of <literal>5</literal> seconds, you can change the default to
Windows by editing the <filename>lilo</filename> file in
<filename class="directory">/etc</filename>. Look for the line that says
<emphasis>default=linux</emphasis> and change it to
<token>dos</token>. Alternative launch <application>lilo</application>
from an <application>xterm</application> and change the asterisk from
<token>linux</token> to <token>dos</token> (use the arrow buttons,
dummy). That's set now for <application>Lilo</application>
users.</simpara>
</sect1>
<sect1>
<title>Setting up <application>Loadlin</application></title>
<para><application>Loadlin</application> users still have a little work to
do. First boot into Linux with the floppy. If you logged in graphically
start a terminal emulator like <application>xterm</application> or some
other. There are always a couple of these under the utilities menu. Type
<command>mkdir /mnt/dosc</command>. This is the first step to make your
Windows partition accessble to Linux and this is particularly important
for <application>Loadlin</application> users as it is the easiest way to
tranfer the Linux kernel to your Windows partition. Next start
<application>linuxconf</application> from the system menu or the
<application>xterm</application> and look for the filesystem menu. Expand
<guibutton>accesss local drives</guibutton> and select
<guibutton>add</guibutton>. Type <userinput>/dev/hda1</userinput> in the
partition field, <userinput>vfat</userinput> in the type field and
<userinput>/mnt/dosc/</userinput> in the mount point field and mount the
partition. Alternatively you can directly edit the
<filename>fstab</filename> file in
<filename class="directory">/etc</filename> in a text editor
(<application>Gedit</application> is a good choice) and add the following
line exactly as shown.
<programlisting>/dev/hda1 /mnt/dosc vfat defaults 0 0</programlisting>
</para>
<para>This should give you access to your Windows partition, it will be in
<filename class="directory">/mnt/dosc/</filename>. Copy the linux kernel
to your <medialabel>C</medialabel> directory and rename it to
<filename>vmlinuz</filename>. You will find it in
<filename class="directory">/boot</filename> and probably called
<wordasword>vmlinuz</wordasword> followed by your kernel version number in
my case <filename>vmlinuz-2.2.14-5.0</filename>. Do not copy the
<filename class="symlink">vmlinuz</filename> with an arrow in it, its a
symbolic link. Reboot into windows, get the
<application>loadlin</application> package from the Linux cd &ndash; it
will be in the <filename class="directory">/dostools/utils</filename>
subdirectory. Unzip it and place <filename>Loadlin.exe</filename> in the
<medialabel>C</medialabel> directory. <application>Loadlin</application>
and the kernel can be anywhere on your windows partition but for the time
being we will leave it in root directory of Windows. Now its up to you how
you want to boot into Linux. Read the <application>loadlin</application>
documentation for the details. The roundabout way is to restart the system
in <acronym>DOS</acronym> mode and type:
<screen><prompt>C:&gt;</prompt> <userinput>loadlin vmlinuz root=/dev/hda7 ro</userinput></screen>
</para>
<simpara>This will boot you into Linux. The easier way is to make a
<filename>.bat</filename> file with the same information and placing it on
your desktop. Open <application>notepad</application> type
<userinput>c:\loadlin c:\vmlinuz root=/dev/hda7 ro</userinput> and save
the file as <filename>linux.bat</filename>, right click the file, select
<guisubmenu>advanced</guisubmenu>, and check the msdos mode and warn
settings. Make a shortcut to this file and put it on your desktop. The
next time you want to boot into Linux just double click this file and you
will be in &ndash; talk about convenience.</simpara>
<para>If you want to be prompted to boot into linux before Windows boots
like the <application>Lilo</application> guys you have to make another
<filename>.bat</filename> file and call it from your
<filename>autoexec.bat</filename> file. It's very simple and the details
are available in the <application>Loadlin</application> documentation. The
file looks a bit like this.
<programlisting>
@echo off
cls
echo.
echo.
echo.
echo.
choice /t:n,5 "Do you wish to boot Linux?"
if errorlevel 2 goto End
c:\loadlin c:\vmlinuz root=/dev/hda6 ro
End
</programlisting>
<emphasis>(This little script has been filched from the
<application>Loadlin</application> documentation which you would know if
you did the sensible thing and read the documentation)</emphasis>
</para>
<simpara>Save this text as <filename>linux.bat</filename> or if there
already is a <filename>linux.bat</filename> in your Windows root directory
you can place it in another directory or give it another name. Add the
following line to your <filename>autoexec.bat</filename> file
<userinput>c:\linux '</userinput>(or whatever you have named the
<filename>.bat</filename> file). The main thing if you are using a
<filename>.bat</filename> file is to tell
<application>Loadlin</application> where to find the kernel image file
(<filename>vmlinuz</filename>). The above <filename>.bat</filename> file
gives you the option to boot into Linux before Windows loads by typing
<keycap>y</keycap> (for Linux) or <keycap>n</keycap> (for Windows) within
five seconds at which point it boots Windows. Enjoy.</simpara>
</sect1>
<sect1>
<title>Removing Linux and restoring your Windows partition to its Original
state</title>
<simpara>Depending on whether you are using <application>Lilo</application>
or <application>Loadlin</application> the method differs
slightly. <application>Lilo</application> users have to first restore
their original <acronym>MBR</acronym> either by typing <command>/sbin/lilo
<option>-u</option></command> within Linux or typing <command>fdisk
<option>/MBR</option></command> in <acronym>DOS</acronym>. The next steps
are common for both <application>Loadlin</application> and
<application>Lilo</application> users. These are not really neccessary but
just to be on the safe side I do them all the same.</simpara>
<simpara>Boot using the Linux installation CD and type <userinput>Linux
expert</userinput> at the first prompt, answer whatever you wish to the
next questions until you get to the install selection screen. Here select
<emphasis>Install</emphasis> and <emphasis>With Fdisk</emphasis> and use
<application>Fdisk</application> to delete all Linux partitions. Write the
changes to disk and
<keycap>Ctrl</keycap>&ndash;<keycap>Alt</keycap>&ndash;<keycap>Delete</keycap>
your way out of the installation program or reset your system to
reboot. Remember to change the <acronym>BIOS</acronym> settings to boot
from the hard disk or else you will reboot from the
<acronym>CDROM</acronym> again.</simpara>
<simpara>Reboot once again, this time with the
<application>fips</application> disk that has the backup of your partition
table and boot sector &ndash; you saved it, didn't you? &ndash; and type
<command>restorrb</command> at the prompt. Answer
<userinput>yes</userinput> to the question, the program will restore your
partition table and boot sector and you can pat yourself on the back for
accomplishing the impossible &ndash; reclaiming lost partition space! This
is all the more reason for making sure that the crucial backup file
(<filename>Rootboot.000</filename>) is saved in at least
<literal>5</literal> different locations. You can never be too
careful. Reboot back into Windows and run
<application>scandisk</application> on the newly increased
<medialabel>C</medialabel> drive. It will report one error in the
<systemitem>fsinfo</systemitem> sector which is just a used and free space
accounting error. Your Linux data is now naturally lost for
ever. Hopefully this procedure won't be neccessary unless you are
increasing space allocated to Linux or getting rid of Windows.</simpara>
</sect1>
<sect1>
<title><application>XFree 4.01</application></title>
<simpara>It's a good idea to upgrade your <application>Xserver</application>
to <literal>4.01</literal>. At the moment only RedHat 7.0 ships with this
version of <application>X</application> but it is availabe from the X
consortium's (how corny) ftp site &ndash;
<ulink url="ftp://ftp.xfree86.org/">ftp.xfree86.org/</ulink>. It provides direct
acceleration and increased performance for a large number of accelerated
cards and those with Nvidia cards are in luck for not only does
<application>X 4.01</application> natively provide excellent support for
most of their cards but Nvidia have made available high performance
<acronym>OpenGL</acronym> accelerated drivers &ndash; cheers to them. See
<application>XFree</application>'s home site &ndash;
<ulink url="http://www.xfree86.org/"></ulink> &ndash; for more info.</simpara>
</sect1>
<sect1>
<title>Tips and Suggestions</title>
<para>
<itemizedlist>
<listitem><simpara>Whatever soundcard you have Alsa drivers will deliver
better performance and if like me you have the Yamaha 724 the Alsa
drivers are nearly as good as those provided by Yamaha for
Windows. You will of course have to compile them for your system but
don't let that deter you. Its a simple matter of three commands. The
alsa drivers are available at
<ulink url="http://www.alsa-project.org/"></ulink>
</simpara></listitem>
<listitem><simpara>Those used to scrolling with their mouse wheel/s will
not like Linux if they can't scroll. The good news is you can but it is
not set up by default. Add the following line to your
<filename>XF86Config</filename> file in
<filename class="directory">/etc/X11/</filename> in the mouse
section <userinput>"ZAxisMapping 4 5"</userinput>
(obviously without the quotes though in
<application>Xfree 4.01</application> you would have to
enclose the numerical values in quotes) If this doesn't work visit the
Linux scroll wheel homepage at
<ulink url="http://www.inria.fr/koala/colas/mouse-wheel-scroll/"></ulink>
set up by a curiously named fellow called Colas Nahaboo.
</simpara></listitem>
<listitem><simpara>By default the hard disk is not configured to perform
at its optimum and in most cases the difference can be dramatic.
<acronym>DMA</acronym>, 32&nbsp;bit <acronym>IO</acronym> and
multiple sector transfers are disabled by default and you
should enable them at the earliest this is of course presuming you have
a relatively new hard disk that support these features. As a test you
should benchmark your <acronym>hdd</acronym> before and after you
change the settings just to see the difference tweaking can do to
your system. The utility to change the settings is
<application>hdparm</application> and you can run it from an
<application>xterm</application> or the console but for a permanent
solution append the command to your <filename>rc.d</filename> local
file in <filename class="directory">/etc/rcd</filename>. Before you
use <application>hdparm</application> read the documentation
carefully. Its a powerful utility and misusing it can trash your
disk. First run <command>hdparm</command> with the
<option>-i</option> option to get the
info on your <acronym>hdd</acronym>, then benchmark it without the
changes by running
<command>hdparm <option>-Tt</option> /dev/hda</command>. Then run
<command>hdparm <option>-c 1</option> <option>-d 1</option>
<option>-m16</option> <option>-k 1</option> /dev/hda</command>
</simpara>
<simpara><command>hdparm <option>-d 1</option></command> (sets
<varname>dma</varname> to <constant>on</constant>)
<option>-m<replaceable>x</replaceable></option>(this sets
multiple transfers where <replaceable>x</replaceable> represents the
maximum (in my case <literal>16</literal>) that your
<acronym>hdd</acronym> allows &ndash; running
<command>hdparm</command> with the <option>-i</option> option gives
you the maximum that your <acronym>hdd</acronym> allows )
<option>-c 1</option> (sets 32&nbsp;bit <acronym>io</acronym>) and
<option>-k 1</option> keeps the setting. In my case the data
transfer shotup from a mere <literal>3.16</literal> to
<literal>16.8</literal>&nbsp;Mb/sec!</simpara>
</listitem>
<listitem><simpara>A file system driver for the
<acronym>ext2</acronym> filesystem for Windows,
<systemitem>ext2fs</systemitem> is available from its homepage
<ulink url="http://uranus.it.swin.edu.au/~jn/linux/"></ulink>
giving you the added convienience of reading your Linux partitions from
within Windows.</simpara></listitem>
</itemizedlist>
</para>
</sect1>
<sect1>
<title>The State of Linux &ndash; What to Expect</title>
<simpara>Programmers and Enthusiasts &ndash; For programmers Linux is already a
near perfect solution. No other system gives so offers you a wider array of
tools and platforms for development. The flexibility is simply amazing and
it doesn't carry a price tag. An added benefit is the sense of community and
that's priceless.</simpara>
<simpara>Enthusiasts never had it so good. There is aways something new to
discover and since the system is totally transparent your chances of
understanding computing and programming in general &ndash; you will be
interested if you aren't already &ndash; are infinitely higher than in
Windows. Tinkering will never be the same again.</simpara>
<simpara>For the home user &ndash; There are <literal>5</literal> separate
areas here, the internet,
gaming, basic word processing, administration and multimedia. We aren't
going to talk about ease of use here because the days of an ugly and
unwieldy interface are long gone, at the moment as far as usability and
sheer visual pizazz is concerned <application>Gnome</application> has
taken the pants off Windows so
there is nothing to worry about there. File management, installing and
uninstalling software and basic administration are more streamlined and
centralized and as you use Linux more you probably will get over any
prejudice toward the command line which is nothing like the impotent
<acronym>DOS</acronym> prompt. This is an outrageously powerful shell that
will accomplish anything
you can think off faster than it takes you to select a button. You might be
intimidated at first but its the heart of Linux the control centre, the
headquarters, your direct line to the kernel. Hardware configuration is not
as simple as in Windows mostly because plug and play has complicated things
not eased them but it's not difficult either, the best thing to do is set
your <acronym>BIOS</acronym> to <emphasis>non pnp</emphasis> so that it
can configure things especially the sound
card, but <emphasis role="bold">read read read</emphasis>. There is a lot
of documentation on your system and with that behind you everything
becomes simple. There is no excuse for ignorance.</simpara>
<sect2>
<title>The Specifics &ndash; Wordprocessing</title>
<simpara><application>Corel WordPerfect</application> is good but for the
simplest solution try <application>Abiword</application> &ndash;
<ulink url="http://www.abisource.com/"></ulink>. It's good
and bears an uncanny resemblance to <application>MSWord</application>
&ndash; now now. Both are free and
widely available &ndash; I don't know about
<application>Wordperfect 9</application> , <application>8</application>
is free, good and available. Other options are
<application>Applixware</application> and <application>Star
Office</application>. I haven't used <application>Applix</application>
but <application>Star Office</application> is really ugly and slow and
just the sort of software that could put you off Linux and its just as
bad in Windows. Version 5.1 was tolerable but after Sun took it over its
deteriorated and version 5.2 is the pits. Plain text and html editors are
sprouting by the day. Most distribution carry a lot of software so
look. I'm not much of a spreadsheet person but there is
<application>GNUmeric</application> which is
not unlike <application>Excel</application> and a glaring inadequacy in
printing is now rectified. It looks good. Corel have ported nearly all
their apps and they are not as expensive as their Windows counterparts
and with the same functionality.</simpara>
</sect2>
<sect2>
<title>Multimedia</title>
<simpara>This is one area where Linux will not be found wanting. There are
as many if not more <acronym>mp3</acronym> players than Windows. The
most common is <application>XMMS</application>, is somewhat like
<application>Winamp</application> and just as good &ndash; has some
great visualization plugins. Other <acronym>mp3</acronym> players are
<application>Gqmpeg</application>, <application>Freeamp</application>,
<application>Alsaplayer</application>. That's enough
for me. <acronym>Mpeg1</acronym> <acronym>vcd</acronym> players are a
bit scarce, <application>MTV</application> is good and available &ndash;
<ulink url="hteztp://www.mtvplayer.com/"></ulink> free for personal
use &ndash; a totally free solution is available from lokigames &ndash;
<ulink url="http://www.lokigames.com/"></ulink> There are
more. There are a few <acronym>mp2</acronym> players
<application>movie</application> is good. I' don't have a <acronym>dvd</acronym>
player so I don't know but <application>Xmovie</application> should
tackle <acronym>mpeg2</acronym> streams. Most of my
<acronym>mpeg1</acronym> players are <acronym>GL</acronym> accelerated
and perhaps my vcd playsback as well as
<application>Windows Media Player</application>. Ripping is a reality
with a lot of options &nbsp; no more <acronym>ASPI</acronym> headaches
&ndash; most of the Linux apps read digital data directly from
the discs and all the popular codecs are available;
<application>Xing</application>, <application>Fraunhofer</application> but I
use <application>Blade</application> and <application>Lame</application>
&ndash; two excellent freeware encoders avalible for all
platforms. There are also a couple of tools for cdwriting. Check some of
the Linux archives.</simpara>
</sect2>
<sect2><title>Internet</title>
<simpara>Again things are really happening here though one wishes there
were a few more browsers other than <application>Netscape</application>
but then <application>Netcape</application> is adequate. There are all
the other stuff you will find for Windows, chat utils, instant
messaging, ftp, downLoaders etc.</simpara>
</sect2>
<sect2><title>Games</title>
<simpara>The problem area is games, there is a project on to port
popular games to Linux by Lokigames and they have a number of titles
ready &ndash;
<ulink url="http://www.lokigames.com/"></ulink> &ndash;
<application>Quake</application>
2&3 are out, <application>System Shock</application>,
<application>Heavygear</application> etc. The thing here is to make
sure you have at least <application>Xfree 4.01</application> and support
for your video card.</simpara>
</sect2>
<sect2><title>Desktop Publishing</title>
<simpara>That leaves us with <acronym>DTP</acronym> and this is one area
where Linux could pound Windows but the thrust has been missing. Linux could
really be optimized for
<acronym>DTP</acronym>. <application>Ghostscript</application> - a
PostScript RIP &ndash; already
offers a professional (if you know how) solution for printing and your
printer is probably supported. If you already have a postscript
printer there is no problem to start with. For image editing there is
<application>Gimp</application>. It is nearly as good as
<application>Photoshop</application> &ndash; and
that's some compliment &ndash;
but for lack of <acronym>CMYK</acronym> and colour management support
ruling it out of
serious print work but it can be a good semi-professional solution and
for web work perfect and it's fun to
use. <application>Gimp</application> also has a couple of
good drivers for Epson printers. <application>Ghostscript</application>
has a problem with bitmaps &ndash; not all bitmaps but photographs, you
could eventually get some good output but it will take some amount of
tweaking. As far as text and vector graphics is concerned it's good
enough to replace my Epson driver in Windows (it has a Windows
version) <application>GhostScript</application> is available at its
homepage <ulink url="http://www.cs.wisc.edu/~ghost/"></ulink>
</simpara>
<simpara>Word processing is already covered. The problem areas are
vector editing and page layout. <application>Framemaker</application>
for Linux is a solution and <application>CorelDraw</application> is
available but they are both commercial offerings. There are
vector editors but all are at a nascent stage.
<application>Sketch</application>,
<application>Killustrator</application> and
<application>Impress</application> are coming along but far away from
professional solutions like
<application>Draw</application> and
<application>Adobe Illustrator</application>. For page layout there is
<application>Tex</application> but those used
to <application>Pagemaker</application>,
<application>Quark</application> or <application>InDesign</application>
are not going to be amused, its tough to
learn and difficult to control and there are way too many issues with
things like fonts and its not <acronym>wysiwyg</acronym> &ndash; we
can't live without that.</simpara>
<simpara>On a last note at the moment the only difference in
productivity for me is in vector graphics, page layout and games. They
are perhaps a year away at which point Linux would have over taken
Windows &ndash; at least as far as I'm concerned &ndash; and I would
have little reason to dual boot but I think having Windows is in a odd
way comforting as is having Linux, perhaps I will always use them
both.</simpara>
</sect2>
</sect1>
</article>