Yum requires NET

Status
Not open for further replies.

nileshgr

Wise Old Owl
I recently installed FC-6 on my machine. It works well. I have removed Windows. When i try to install any package either using Yum GUI or TUI, it tries to obtain information about the pacakge from the NET. Why??? When i start Yum GUI, it gives an error saying "Cannot find a baseurl for repo: core" My NET @ home is down currently. What to do????? Help. :(
 

Sykora

I see right through you.
That's how yum works -- it needs the net to operate. The only thing you can do, is to get the installation files -- rpms in your case -- from other sources. Either use the FC6 installation media you used, or download them elsewhere.
 
Last edited:
OP
nileshgr

nileshgr

Wise Old Owl
Sykora said:
That's now yum works -- it needs the net to operate. The only thing you can do, is to get the installation files -- rpms in your case -- from other sources. Either use the FC6 installation media you used, or download them elsewhere.
Even if i run n rpm file from my HDD/CD its the same error. Please Help :(
 

Pathik

Google Bot
nah.. That shd work.. Jus login as root nd open terminal.. Type
rpm -ivh /path/name.rpm and install the rpm
 

amitava82

MMO Addict
Don't know about rpm packages but i've encountered some deb packages which require net to download some libs which are not packed into it. may be its the same case?
 

Sykora

I see right through you.
If an rpm requires dependencies, it'll usually throw a missing dependency error, and not try to fix it itself, afaik. That's what yum is for.

Like pathiks said, log in as root, and run the rpm. If it is an upgrade of something you already have, use -Uvh instead of -ivh and try it. rpm should not need to connect to the net.
 

mediator

Technomancer
Yea it connects to the net most probably to tell wat the application is about. So try the terminal thing then! U really need to have net when installing or updating coz we still dont have plenty of PC magazines that promote such things!
 
OP
nileshgr

nileshgr

Wise Old Owl
when logged in as root, in the terminal, i typed-
Code:
yum install php
it tries to connect. if i type
Code:
yum install /root/php.rpm
will it work?
 

mediator

Technomancer
To install rpm just do "rpm -i rpm_package_name.rpm"

For installing php via yum, if u dunno the package name just do "yum -y install php*"!
 

praka123

left this forum longback
^ just deviating a bit,
in such cases where the name of the pkgs are not known and you use terminals often,you can use bash-completion feature (provided default in debian and ubuntu) which completes the line by pressing TAB key.I think for rpm based distros bash-completion rpms are available.for eg; in fedora afaik u use "service foo restart" if u have bash-completion on working,u type in CLI bash shell= "service" <type some words of the service and press TAB OR press TAB once for full list> .though u can use /etc/init.d/* too.
thus for
"yum -y install php*" just type upto "yum -y install php" and press TAB for completion.I frequently uses bash completion in my Debian.Hope it helps for rpm users too.
for rpm distros:
*atrpms.net/dist/common/bash-completion/
 
OP
nileshgr

nileshgr

Wise Old Owl
Ok. My NET connection has been restored. Tht was the root cause of the problem. I'll try the solutions above. Anyway, thanks for helping. :)
 

Sykora

I see right through you.
praka123 said:
thus for "yum -y install php*" just type upto "yum -y install php" and press TAB for completion.

Have you specifically tried this for yum (or apt-get)? Because I don't think this works. Completion should only complete commands in your PATH, not if it needs to get a list of possibilities from an online repository. I'm not sure though.
 

praka123

left this forum longback
It works with apt.like apt-get install php:: and it completes,so i expect will work with rpm distros too.
 

mediator

Technomancer
I agree with @Sykora. I have tried the bash completion feature and noticed that it only completes the commands that r in path. Neways since u say so, then I'll surely try it out!

@prakash : I tried ur suggestion. But it didn't work! :oops:
 
Last edited:

praka123

left this forum longback
thats sad.in debian & ubuntu,i just uncommented below lines in ~/.bashrc following lines
Code:
# enable bash completion in interactive shells
if [ -f /etc/bash_completion ]; then
    . /etc/bash_completion
fi
it auto completes much more than $PATH env.

did u sourced the file corresponding to.for eg
Code:
~$source /etc/bash_completion
or
~$ [B][SIZE=4].[/SIZE] [/B]/etc/bash_completion
*www.debian-administration.org/articles/316
 
Last edited:

mediator

Technomancer
I also noted that the bash completion feature completes the name of the file in the working directory like for "more myplay tab" => "more myplaylist". But it doesn't complete anything/filename that is not in the path or in the working directory!
 

Sykora

I see right through you.
I can't say much about bash in particular, because I don't use it, but I fail to see how in principle, a shell can complete anything that is not in PATH or is not in an environment variable that bash has been set to complete. The only other option is that your bash has been given a file containing a list of all available packages to complete, which is unlikely because the repositories change very often.

And the site you mentioned doesn't say anything (as far as I can see) about completing this kind of thing.

If on the other hand, what you're saying is correct, I definitely want to know about it, so please clarify :)
 

praka123

left this forum longback
Firstly: the Debian bash package includes a file /etc/bash_completion which extends bash - for example, enabling zsh-style tab completion of hostnames. Source this file in your own .bashrc to get this functionality. It also makes it easy to extend/program bash yourself, via the directory /etc/bash_completion.d/, which is automatically sourced by /etc/bash_completion.
*www.oreillynet.com/linux/blog/2007/02/improving_bash.html
With bash competion installed you can use the TAB key to complete arguments to common commands like rpm, apt, find, grep etc. Also bash-completion will complete host-names for ssh, scp, by looking up hosts inside your $HOME/.ssh/authorized_keys file. For rpm based distros, bash-completion will even lookup package names already installed.
*bhaskarvk.info/technology/bash-tricks.html
do try ubuntu or debian.this afaik works with these distros only.there are no seperate pkgs for bash_completion in debian/ubuntu.
It is what i experiance,it completes virtually anything which i tries.it makes very easy to work with bash cli,an addiction.:p
I dont know much about the problem in fedora,mandrake rpm distros.
but look out the example quote from bash terminal in my debian:
Code:
sid:~# apt-get install php
Display all 252 possibilities? (y or n)
in next step it will display all those packages.

I think may be debian stores pkg details etc in some where in /var/
but if so,
it even completes cmd:
apt-get -t TAB TAB
Code:
root@sid:~# apt-get -t 
experimental  testing       unstable
showed my apt-pinning options too!
I dont understand much,but google may help
 
Last edited:

Sykora

I see right through you.
Found it. :

*aptsh.berlios.de/?q=node/2 said:
Aptsh is a pseudo-shell for systems with Apt package managing tool. It's similar to AptShell from AptRpm, but it works not only with AptRpm (actually, it's being developed with Debian's Apt). Also, it's inspired by The Poldek from PLD.

But, what does it exactly do? Well, if you use Apt, you should know the situation - search for a package with apt-cache and copy its name to apt-get, repeat. And, you probably do not enjoy the situation before last execution of apt-get. If so, consider using aptsh - it offers that cute TAB completion which you always use while unix-shelling. It's smart enough to decide whether you're trying to remove or install/upgrade a package, and doesn't suggests you to remove your Gnome since you are a KDE maniac who has never seen (and never installed) that ugly Gnome. In short: a tool which makes life easier, although it's not necessary.

You may find few similarities between Aptsh and things like Wajig or Feta. Yes, it's the same sort of applications.

This is probably coming installed with Debian now, giving you the completion.
Thanks for mentioning this, it'll be very useful. Now to find a yum equivalent...
 

mediator

Technomancer
I'll surely try the aptsh. Neways
it offers that cute TAB completion which you always use while unix-shelling. It's smart enough to decide whether you're trying to remove or install/upgrade a package, and doesn't suggests you to remove your Gnome since you are a KDE maniac who has never seen (and never installed) that ugly Gnome. In short: a tool which makes life easier, although it's not necessary.
:p
 
Status
Not open for further replies.
Top Bottom