CS551 Operating Systems and Implementation

MINIX Installation Tips


FIPS

FIPS is freely available from Tucows and the GNU archives. It is a dos based program that will allow you to resize your partitions on your hardrive. Make sure you read all the documentation that comes with FIPS. Mistakes made on your partition table can cause loss of data or even clear your whole hardrive.

If you are trying to split your existing partition from dos , win3.1x, or win95, you have to run scandisk (or chkdsk for old version dos) first. Then run defrag tool to defragment your current partition. For win3.1x and win95 users, you have to disable the virtual memory before defragmentation. You can find it from control panel, after you split your partition successfully then enable it back. There probably are some problems to split a winNT's partition or you want to make MINIX co-exist with your NT. I won't suggest you to do this. Since NT and MINIX always need to save their code of boot and partition table in the MBR (Master Boot Record). If you do want to install them on one machine, I suggest you to buy SysCommander or try Linux LiLo that can allow multiple OS on one system. But this is under your risk. I won't be responsible for it.

Notice for large size disk users (> 512 Mbytes):

Since lots of students mess their system now. You have to be very careful to backup your whole system before you start to make a new partition for MINIX. As I knew, most of you have some large disks whose spaces are over 512 Mbytes. This may derive serious troubles to make a new partition for any PC unix system if you have already partitioned them by dos, win95, or nt partition tools. Because all ot these large size disks need to use some tools embedded in your EIDE or SCSI card to extend the partition table such that the O.S. can read the maximum size of the hard disks. For EIDE, it is LBA, for SCSI, there should have an options to enable the functions similar to the LBA. But this action actually fool the OS with the fake number of cylinders, sectors and heads. That is what the large disk space you saw. However, for a unix system you should not enable this option. Since unix can directly recognize the real size of the disk. That is the most possible reason why students failed to install the MINIX on a new partition which was even not created by fips. The only way to do it successfully is to backup your all of stuff first, then repartition the disk for dos, win95, and MINIX by the MINIX's part tool, then re-install dos, win95, and MINIX. Now, you ought to have all of them together. Again, NT is still have problem to join with them together unless you have a commercial tools, like the sys commander.

One frequent problem people encounter is that their defragmentation program leaves unmovable sectors at the end of the partition. It is addressed in detail in FIPS.DOC.

vi editor

Type vi from the prompt then you will start a vi editor process. Vi has edit and command modes, and you can disable edit mode by pressing. Edit mode means that you can input your data or program. Command mode means you can only input the command you want to edit. I only list some simple edit commands may help you quickly start your editing jobs. The letters between brackets are the special key on a standard US keyboard. The letter means the key itself. Notice that UNIX/MINIX are a case sensitive system. a differs from A.
Move coursor : coursor key up, down, right, left or j,k,l,h

     goto : 

          :n, n is the line number

     Page Up : Cntrl + b

     Page Dn : Cntrl + f

insert : (will change to edit mode)

     i : insert after current position

     I : insert from beginning of line

     A : append at current line

delete : all of data been deleted will copy to the shared buffer.

     dd : delete current line

     n dd : dd n lines from current line where n is an integer.

     x : delete current characters

copy / move:

     n Y : copy n lines from current line into clipboard (a shared buffer)

     p : under the current line, past data from clipboard (copy data from buffer) 

     P: above the current line, past data from clipboard (copy data from buffer) 

find :

     :/ pattern : where pattern is the string you are interesting. Sometimes your patten my contain

          some special characters which should have a back slash \ in front of each of them to sperate

          them with the normal charactors. E.g. find !/123abc should type :/\!\/123abc

     n : find next

save : 

     :w filename : write buffer data into file

     :wq : write buffer data into current file and quit from vi

     :q! : quit without save, if you changed something.

     :q : quit, if you did not change anything

At last, a small trip will help you :

vi

0. start vi with command mode

1. press i then you can start to insert characters (now in edit more)

2. type abcdefghijklmnopqrstuvwxyz

3. Now press ESC to command mode

4. move cursor to d

5. press x twice then you will get abcfghijklmnopqrstuvwxyz

6. press i again, type 123 then you will get abc123fghijklmnopqrstuvwxyz

7. press ESC, then :w testvi, your data will be saved to file testvi

8. press :q will leave vi to prompt