
| This forum is proudly powered by Scientific Linux 6 | SL website Download SL Help Search Members |
| Welcome Guest ( Log In | Register ) | Resend Validation Email |
![]() ![]() ![]() |
| AndrewSerk |
Posted: Jan 21 2012, 05:05 AM
|
|||||||||||||||
![]() SLF Moderator ![]() ![]() ![]() ![]() ![]() ![]() Group: Moderators Posts: 524 Member No.: 54 Joined: 14-April 11 |
Create a local repo from a install DVD
There has been a few threads with people asking how to create a local repo from the install DVD lately so I thought I would share the method I use. I will be using the ScientificLinux 6.1x86_64DVD installation DVD and the Gnome Desktop Environment for this guide. Start by creating a directory for the local repo:
Then we put the DVD in the reader. The DVD will be auto-mounted in the /media directory. We now need to copy the .rpm files from the Packages folder inside the DVD to the new directory we created “/SL_DVD_localrepo“. The easiest way is to use the < tab> key for auto-complete function.
When I used the auto-complete <tab> key above it found/completed the directory of the DVD. We now need to create a repo from the directory /SL_DVD_localrepo . This requires the package “createrepo” . If you do not have the package createrepo installed :
Once you have the package “createrepo” installed you can create the repo with:
The last thing to do is create a repo file (for this purpose I used gedit but you can use whatever text editor you prefer) :
Make the SL_DVD_localrepo.repo file read as follows and save:
If you have other repos enabled and you want to use just the local repo you can do that with a command like:
or change “enable=1” to “enable=0” in all .repo files except SL_DVD_localrepo.repo Hope this helps someone, |
|||||||||||||||
| certainquirk |
Posted: Aug 28 2012, 01:24 PM
|
|
![]() SLF Newbie Group: Members Posts: 7 Member No.: 932 Joined: 16-October 11 |
Thanks for this. Since many distros do this by default and I've been more familiar with them, this was most helpful.
Edit: I should clarify that "many distros" leave the CD/DVD enabled as a repo, but they don't create a local repo for it. -------------------- Motherboard: ASUS M3A78-EM AM2+/AM2 AMD 780G;
CPU: AMD Athlon 64 X2 5000 2.6GHz; RAM: Kingston 2GB SDRAM DDR2 800; System: SL63 |
|
| basefilm |
Posted: May 14 2013, 02:33 PM
|
|||||||||
|
SLF Newbie Group: Members Posts: 1 Member No.: 2489 Joined: 14-May 13 |
Great instructions, thanks. I found a number of non-working ones out there before yours. Yours worked for me for SL6.4 and RHEL6.4.
A couple improvements: 1. To turn off gpg checking for your local repo, allowing you to skip the "--nogpgcheck" argument when using yum, add this line to the /etc/yum.repos.d/SL_DVD_localrepo.repo file:
2. Its nice to have 'yum grouplist' and 'yum groupinstall' working for a local repository. Here's how:
Note: On RHEL, the file to copy is in a different directory. Look for the one named <huge random string>-comps-rhel6-Server.xml, e.g.:
Test it with:
|
|||||||||
| AndrewSerk |
Posted: May 14 2013, 04:56 PM
|
|
![]() SLF Moderator ![]() ![]() ![]() ![]() ![]() ![]() Group: Moderators Posts: 524 Member No.: 54 Joined: 14-April 11 |
Thanks for the additions basefilm and welcome to SLF,
![]() I am sure many will find the info usefull! This post has been edited by AndrewSerk: May 14 2013, 04:57 PM |
|
![]() |
![]() ![]() ![]() |