How to install Freesco on a harddrive with a USB stick .

If you need some help, this should be the first place to look.

How to install Freesco on a harddrive with a USB stick .

Postby Peppe/Sweden » Mon Sep 21, 2009 11:24 am

This howto covers a installation from a Linux client and I use Debian Linux and this guide should work fine with Ubuntu and any other Linux flavor .

§ Preperations

Your Freesco box needs to have the option to boot from USB .
Some motherboards that only has USB 1.1 don't have the ability to boot a USB 2.0 stick , if that is the case you'll need to find older usb-stick .
My motherboard - a VIA ITX 5000 hasn't a floppy controller which complicate things - Freesco won't boot if the kernel changed but, this is covered in this howto .
You don't have to make any Freesco floppy - since you're using Linux.
Download the Latest Freesco 0.4.x version

§ Install necessary package on your Debian client.

apt-get install dosfstools syslinux lilo

§ Partion your USB stick .

*ALL YOUR PREVIOUS DATA WILL BE DESTROYED*
Insert your usb-stick
Usually , the usb-stick will automount - and we don't want that .
Open a terminal and become root with the su command - sudo will work fine as well .
Check what type device your usb-stick has been assiged to with mount or if it's already umounted with fdisk -ll
A usb disk is often assiged with /dev/sda but in my case it is /dev/sdb and I will refer to /dev/sdX and you will have to replace X with your device name .
Unmount your stick with umount /dev/sdX
Create a partion with fdisk with the following command ; fdisk /dev/sdX
First - remove all partions with the command d
Second - create a partion with the command n , I choose the hole area for the disk
Third - change the filesystem type with the command t , and choose type 6 (Fat 16 win95)
Fourth - change so that the usb-stick is bootable with the command a
Five - save your changes with the command w
Now , one or two things can happen after fdisk writes the changes to the disk 1) you get an error that the partion tabel cannot be read and will be used in the next reboot , 2) your usb stick gets mounted again .
Unmount it with umount /dev/sdX and check that your changes have been written with fdisk -ll or fdisk /dev/sdX

§ Installing Freesco on the USB stick.

Unpack your Freesco version to a folder , might be /tmp/freesco
I will substitute the last version number with X .
Make the following folder with mkdir /mnt/ram
And the second one mkdir /mnt/usb
Create a filesystem on the usb-stick mkdosfs /dev/sdb1
Make the usb-stick bootable with syslinux /dev/sdb1
Mount the usb-stick mount /dev/sdx1 /mnt/usb
Mount the Freesco image with mount /mnt/freesco.04X /mnt/ram -o loop
Copy Freesco to the usb-stick cp /mnt/ram/kernel /mnt/usb/
Copy the ramdisk to the usb-stick cp /mnt/ram/ramdisk /mnt/usb/
Copy the syslinux file to the usb stick cp /mnt/ram/syslinux.cfg /mnt/usb/
We need to change all entries from fd0 to USB in the following file /mnt/usb/syslinux.cfg , open it with your fabvorit editor and edit it.
Additional command to make the usb-stick bootable lilo -S /dev/null -M /dev/sdb1 ext
Additional command to make the usb-stick bootable lilo -S /dev/null -A /dev/sdb1 1
Several times , I got errors about thease two commands but , the usb-stick seems to boot fine either way.
Unmount the usb-stick umount /mnt/usb
Unmount your Freesco image umount /mnt/ram
Additional command to make the usb-stick bootable install-mbr /dev/sdb

Now , If your motherboard has a floppy controller - you can skip this step .
Download a kernel from http://www.freesco.org without floppy support - I choose kernel-040.386-no_fd
Copy the kernel to a new folder and change the name to kernel
Mount the usb-stick mount /dev/sdX /mnt/usb
Copy the kernel to the usb stick cp /XXX/XXX/kernel /mnt/usb

You should be able to boot your USB stick .

§ Moving Freesco to the harddrive

Now , If everthing works - you should be able to see Freesco to boot fine .
Hopefully , Freesco has detected your network card and has booted up in a stupied mode (no router functions) .
First , we need to change the download URL to have the ext2 package to work .
Edit the follwoing file with this command edit /etc/system.cfg
Scroll down to PKGDOMAIN= and type your closest Freesco mirror and save the file .
Make the package file blank with >/etc/packages.txt
Now , you should be able to install Freesco on your harddrive !
Type --> setup and press x to get back to the first menu and press --> g to get into the add on packages menu and press--> o to install the ext2 package .
I'm not going to describe how to the ext2 package prepares and moves Freesco to the harddrive - it's covered a lot in the forum .
If everything worked fine - you should have a bootable Freesco harddrive ,unless you have a motherboard without a floppy controller .

§ Changing the kernel (only if the motherboard dosen't have a floppy controller)
You might ask yourself , but hey - I have already changed the kernel ! , yes this is true but the ext2 package downloads a standard kernel and therefore the kernel needs to be changed again .
mount the harddrive with mount /dev/hda1 /mnt/hd
Run the package manager with pkg
Search after your favorit kernel choose it , when asked if you want to install it choose no , when asked if you want to save the kernel ansver yes .
Now , your kernel should be located under /www/downloads/kernelxxxx .
Change the kernel name to kernel and copy it to /mnt/hd/router/
unmount your harddrive with umount /mnt/hd
Update lilo with this command rc_ext2 repair-lilo

Enjoy your new way to install Freesco without a floppy drive !
Thanks Lewis for all your support to making this possible !

Sidenote , Many steps in this guide may seem unneccisary and might not seem to be a simple and clean install .
Not to worry , this will be perfected and adapted to be simplier in future versions .
[COLOR=blue] You mean that I don?t fly airplanes , I don?t have a grilfriend and don?t have a dog ? Buuh , I grow up to be a real loser! (The Kid , walt disney) [COLOR=blue]
User avatar
Peppe/Sweden
Junior Advanced Member
 
Posts: 161
Joined: Wed Feb 05, 2003 4:41 pm

Return to FAQ - Frequently Asked Questions

Who is online

Users browsing this forum: No registered users and 1 guest

cron