Software Repository Mirror: Difference between revisions
(deb file:/usb_drive/ubuntuMirror/mirror karmic main) |
No edit summary |
||
Line 1: | Line 1: | ||
==Preparing the Hard Drive== | |||
In the directions below we will assume that you have a brand new hard drive. We will be formatting the hard drive (partition) which means that all of the data on the hard drive will be lost. | |||
'''PLEASE MAKE SURE YOU KNOW EXACTLY WHAT YOU ARE DOING IN EACH STEP''' | |||
To format the partition, we will first need to set the partition type | |||
===Change Hard Drive Partition Type=== | |||
To format the hard drive, we need to know what its "device" name is. Ubuntu should automatically mount the hard drive should automatically once you plug it in. To determine run the command: | |||
<source lang='bash'> | |||
mount | grep media | |||
</source> | |||
Running this on my machine, I see output | |||
'''/dev/sdb1'''1 on /media/3539-6663 type vfat (rw,nosuid,nodev,uid=1000,gid=1000,shortname=mixed,dmask=0077,utf8=1,showexec,flush,uhelper=udisks) | |||
Which means the '''/dev/sdb1''' is the partition we will need to use. | |||
If you see more than one line in the output then '''STOP''' as these directions may not be correct. Please contact one of the of the iHRIS developers for more help. | |||
=== | |||
===Labelling the hard drive=== | |||
Now we want to make a lablel for our newly formatted hard drive so that we can refer to it easily later: | |||
sudo tune2fs -L ihris /dev/'''sdb1''' | |||
=== | |||
==Creating the Software Repository== | ==Creating the Software Repository== | ||
Line 12: | Line 41: | ||
====sources.list.hardrive==== | ====sources.list.hardrive==== | ||
We now need to create a version of the sources.list that will use the hard drive. | We now need to create a version of the sources.list that will use the hard drive. | ||
echo "deb file:// | echo "deb file:///media/ihris/" `lsb_release -cs` "main universe " | sudo tee /etc/apt/sources.list.harddrive | ||
Revision as of 09:45, 2 April 2012
Preparing the Hard Drive
In the directions below we will assume that you have a brand new hard drive. We will be formatting the hard drive (partition) which means that all of the data on the hard drive will be lost. PLEASE MAKE SURE YOU KNOW EXACTLY WHAT YOU ARE DOING IN EACH STEP
To format the partition, we will first need to set the partition type
Change Hard Drive Partition Type
To format the hard drive, we need to know what its "device" name is. Ubuntu should automatically mount the hard drive should automatically once you plug it in. To determine run the command: <source lang='bash'> mount | grep media </source> Running this on my machine, I see output
/dev/sdb11 on /media/3539-6663 type vfat (rw,nosuid,nodev,uid=1000,gid=1000,shortname=mixed,dmask=0077,utf8=1,showexec,flush,uhelper=udisks)
Which means the /dev/sdb1 is the partition we will need to use.
If you see more than one line in the output then STOP as these directions may not be correct. Please contact one of the of the iHRIS developers for more help.
=
Labelling the hard drive
Now we want to make a lablel for our newly formatted hard drive so that we can refer to it easily later:
sudo tune2fs -L ihris /dev/sdb1
=
Creating the Software Repository
sources.list
The file /etc/apt/sources.list tells apt-get where to look for software packages to install.
We will want to have two versions of the sources.list file. One that will use the hard drive (sources.list.harddrive) and one that will use the internet (sources.list.internet). You will need to create a file /etc/apt/sources.list.harddrive
sources.list.internet
The default ubuntu installation assumes that you are connected to the interent. So we will simply copy the existing /etc/apt/sources.list to sources.list.internet
sudo cp /etc/apt/sources.list /etc/apt/sources.list.internet
sources.list.hardrive
We now need to create a version of the sources.list that will use the hard drive.
echo "deb file:///media/ihris/" `lsb_release -cs` "main universe " | sudo tee /etc/apt/sources.list.harddrive
Updating the Software Repository
Using the Software Repository
sources.list
deb file:/usb_drive/ubuntuMirror/mirror oneiric main