Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Hi,
I am using centOS 5 on my system.When I try to add or remove a software by "Add/Remove Software" it show me an error message.Kindly find the attachment herewith.
yes I know. I does not want to connect the system with internet.I want to disable this feature that the system should not check it through internet. There is a place# cd /etc/yum.repos.d directory and in CentOS 5 there are two files in it i.e
CentOS-Base.repo
CentOS-Media.repo
I am also using Fedora 7 in my 2nd PC and i also want same solution for it also (should be thankful).
In Fedora 7 there is
In short I just want that the system should not go to internet and for any changes I use my DVD .Like I want to uninstall openoffice and install vim editor (Just for example) so how can I disable settings in the files and redirect it to my DVD ?
Firstly, edit each repository file and change "enabled=1" to "enabled=0". That will stop yum trying to go online. Then create file /etc/yum.repos.d/dvd.repo containing these lines:
Replace *** by whatever your DVD gets called when mounted. Thus the Fedora 10 DVD appears as "Fedora 10 i386 DVD" and so you have "Fedora\ 10\ i386\ DVD" (with "\" to prevent the spaces causing trouble).
Thanks "DavidMcCann" for your kind reply. Well I have made changes as I understand according to your post. Unfortunately when I click on "Add/Remove Software" it show me an error. I have also changed the file "fedora.repo" and one of its head from "enabled=1" to "enabled=0".There are more heads which are already "0" but it is confusing me that it will be used for my task or not.
Well Iam attaching the "fedora.repo"(if you think to change something more in this file) and the error snapshot so you my easily understand the problem.
can you elaborate "The backslashes are placed before the spaces
Well, you put backslashes before the spaces. Whenever there's a space in a filename, but a backslash before it so that the shell treats itas a literal character instead of a seperator.
Basically, putting a backslash in front of any special character in bash will make it a literal character.
Thanks "MTK358" for the reply. Well still yet there is an ambiguity to do it piratical. As you mention in the post
"you put backslashes before the spaces. Whenever there's a space in a filename, but a backslash before it so that the shell treats itas a literal character instead of a separator."
I shell be too moch thankfull if do write the procedure.As i understand I write please make necessary correction so I may implement on the system
[Fedora-DVD]
name=Fedora 7 DVD
baseurl=file:///media/Fedora\ 7\ i386\ DVD/
enabled=1
gpgcheck=0
then
Code:
# yum clean all
Loading "installonlyn" plugin
Options Error:Error parsing 'file:///Fedora\\ 7\\ i386\\ DVD/' : URL must be http,ftp,file or http not ""
Still can not change any software from add/remove software
Just before doing as u mentionedin the post I have made some little changes in my system.I remove spaces as following
Code:
[Fedora-DVD]
name=Fedora 7 DVD
baseurl=file:///media/Fedora\7\i386\DVD/
enabled=1
gpgcheck=0
Then i go
Code:
[root@localhost yum.repos.d]# vi dvd.repo
[root@localhost yum.repos.d]# yum repolist
Loading "installonlyn" plugin
repo id repo name status
Fedora-dvd Fedora 7 DVD enabled
[root@localhost yum.repos.d]# yum repolist
Loading "installonlyn" plugin
repo id repo name status
Fedora-dvd Fedora 7 DVD enabled
[root@localhost yum.repos.d]# vi Dedora 7 DVD
3 files to edit
[root@localhost yum.repos.d]# yum clean all
Loading "installonlyn" plugin
Cleaning up Everything
[root@localhost yum.repos.d]# yum update
Loading "installonlyn" plugin
Setting up Update Process
file:///Fedora%5C7%5Ci386%5CDVD/repodata/repomd.xml: [Errno 5] OSError: [Errno 2] No such file or directory: '/Fedora\\7\\i386\\DVD/repodata/repomd.xml'
Trying other mirror.
Error: Cannot open/read repomd.xml file for repository: Fedora-dvd
[root@localhost yum.repos.d]#
I think I am just away from my solution.
kinds regards
garden
file:///Fedora%5C7%5Ci386%5CDVD/repodata/repomd.xml: [Errno 5] OSError: [Errno 2] No such file or directory: '/Fedora\\7\\i386\\DVD/repodata/repomd.xml'
These %5C symbols are the hex codes for the backslash character. Please, remove the backslash characters from the baseurl... you don't need them! Then create a link to the mount point of your installation DVD without spaces and put the link path in the baseurl, as shown in my previous post.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.