Wednesday, November 2, 2011

installing debian using local mirror

A 'local' mirror comes in handy when debian is to be installed in multiple number of computers using netboot.

Usually, after the target system is booted by a debian 'image' loaded from a DHCP/TFTP server using bootp protocol by the target system, the installation program gives a choice of debian mirrors located in different countries to download files and complete the full system install on the hard-disk.

However, if this process is ok if its done to a single system. To install to many number of systems, it becomes tedious and time consuming, and if the internet connection fails, the process needs to be restarted from the beginning.

Taking these factors, I decided to have a very own local mirror for installation purpose.

I. First, I downloaded ISO image of CD #1 (containing installation files for debian MIPS systems).There are many such CDs containing the full debian packages. Usually, CD#1 is enough to make a system completely bootable. I can't use this CD for SGI O2 because, O2 does not recognize the ISO-9660 format which most CD burners use. The CDs to boot O2 needs to be burned with the linux CDRECORD command with some kind of 'boot' partition. Anyway, that is cumbersome, therefore, we opt for netboot approach.


II. Preparing the ftp server for installation:-

1. create a folder in your ftp server. name it say, debian6.

2. copy the dists and pool folder of the MIPS cd to this folder.





3. Take care that the debian6/dists/squeeze folder contains the files Release and Release.gpg. replace the existing files.

4.Also, please note that there are two folders called contrib and non-free in the /dists/squeeze folder. These folders refer to contributed and non-free software available in debian.

5. CD#1 does not contain much of contributed and non-free software. Therefore, during the installation, just answer 'no' to questions asked for using contrib and non-free software. Answering 'yes' may stop your installation as these files won't be found.

6. The bulk of installation files are present in the /debian6/pool/main/ folder. During the installation, if any files are shown as missing, then the same can be copied from the ftp.debian.org site to the folders located in the /pool/main/ folder to resume installation.


III. INSTALLING FROM THE LOCAL MIRROR
Step by Step installation:-
1. Change DEBCONF priority

2. Select the debconf priority to ‘low’
3. Now go to choose a mirror :-








Since, our mirror server ( otwo 69) supports http, choose http. Had we not done step # 1 and directly proceeded to step # 3, this option of choosing http/ftp would not have come up. This can be useful in situations when you are planning to install from a ftp location.
5. Enter the IP address of the mirror in hostname

6. Enter the directory name where the debian files are stored in the mirror


7. Enter the proxy information (if any), since we have none, select continue
8.The system finds an installation candidate and the version is listed as ‘squeeze’. Select the same and

Choose ‘continue’.
9. Now you are taken to the next step ‘Download Installer components, click ‘continue’

10. you can choose some optional components, but we don’t have to choose any, so we choose

‘continue’.

You will see the screen above. Now, Debian installation should proceed, answer any questions which the installation manager will ask, partition the disk as documented/blogged earlier.
11. when you come to the question of using NTP server, select ‘No’ since we are not using NTP server.

No comments: