78 votes

Le programme 'curl' n'est pas installé actuellement.

J'essaie Meteor http://meteor.com/examples/leaderboard

Je dois utiliser CURL, qui m'est familier sous Windows.

J'essaie maintenant de l'installer sur Ubuntu 12.04.

Mais je reçois ces erreurs :

kevin@ubuntu:~$ curl https://install.meteor.com | sh
The program 'curl' is currently not installed.  You can install it by typing:
sudo apt-get install curl
kevin@ubuntu:~$ apt-get curl
E: Invalid operation curl
kevin@ubuntu:~$ sudo apt-get curl
[sudo] password for kevin: 
E: Invalid operation curl

Comment installer CURL ?

RÉSOLU :

J'ai fait cette commande

sudo sed -i -e 's/us.archive.ubuntu.com/archive.ubuntu.com/g' /etc/apt/sources.list

et ensuite je pourrais faire sudo apt-get update そして sudo apt-get install curl

qui a installé curl avec succès.

UPDATE :

Désolé pour l'erreur évidente. J'ai essayé hier aussi, et là j'ai tapé la bonne commande qui m'a donné ce message d'erreur :

kevin@ubuntu:~$ sudo apt-get install curl
[sudo] password for kevin: 
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Package curl is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source
E: Package 'curl' has no installation candidate

UPDATE 2 :

J'ai essayé le apt-cache search curl | grep -i curl commande

kevin@ubuntu:~$ apt-cache search curl | grep -i curl
curlftpfs - filesystem to access FTP hosts based on FUSE and cURL
flickcurl-doc - utilities to call the Flickr API from command line - documentation
flickcurl-utils - utilities to call the Flickr API from command line
gambas2-gb-net-curl - The Gambas advanced networking component
gnupg-curl - GNU privacy guard - a free PGP replacement (cURL)
libcupt2-0-downloadmethod-curl - alternative front-end for dpkg -- libcurl download method
libcurl-ocaml - OCaml curl bindings (Runtime Library)
libcurl-ocaml-dev - OCaml libcurl bindings (Development package)
libflickcurl-dev - C library for accessing the Flickr API - development files
libflickcurl0 - C library for accessing the Flickr API
libflickcurl0-dbg - C library for accessing the Flickr API - debugging symbols
libghc-curl-dev - GHC libraries for the libcurl Haskell bindings
libghc-curl-doc - Documentation for the libcurl Haskell bindings
libghc-curl-prof - Profiling libraries for the libcurl Haskell bindings
libghc-download-curl-dev - High-level file download based on URLs
libghc-download-curl-doc - High-level file download based on URLs; documentation
libghc-download-curl-prof - High-level file download based on URLs; profiling libraries
libghc-hxt-curl-dev - LibCurl interface for HXT
libghc-hxt-curl-doc - LibCurl interface for HXT; documentation
libghc-hxt-curl-prof - LibCurl interface for HXT; profiling library
libghc6-curl-dev - transitional dummy package
libghc6-curl-doc - transitional dummy package
libghc6-curl-prof - transitional dummy package
liblua5.1-curl-dev - libcURL development files for the Lua language version 5.1
liblua5.1-curl0 - libcURL bindings for the Lua language version 5.1
libwww-curl-perl - Perl bindings to libcurl
slang-curl - transfer files using HTTP and FTP from S-Lang
spl-curl - SPL Programming Language -- curl adapter
tclcurl - Tcl bindings to libcurl
xmms2-plugin-curl - XMMS2 - curl transport for HTTP
php5-curl - CURL module for php5
libcurl3-gnutls - Multi-protocol file transfer library (GnuTLS)
libcurl3-nss - Multi-protocol file transfer library (NSS)
python-pycurl - Python bindings to libcurl
libcurl3 - Multi-protocol file transfer library (OpenSSL)

UPDATE 3 : La mise à jour a-t-elle fait sudo apt-get update avant de l'exécuter.

Mais cela n'a pas aidé, malheureusement.

kevin@ubuntu:~$ sudo apt-get install curl libcurl3 libcurl3-dev php5-curl
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Package curl is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source

Package libcurl3-dev is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source

E: Package 'curl' has no installation candidate
E: Package 'libcurl3-dev' has no installation candidate

117voto

don.joey Points 26933

Réponses aux différentes mises à jour

Première question

Vous avez besoin de la commande

sudo apt-get install curl

El installer est manquant dans la commande que vous utilisez : sudo apt-get curl ne fonctionnera pas car apt-get n'a pas de commande curl .

Première mise à jour

Vous voulez aussi lancer update d'abord :

sudo apt-get update

Et vous pourriez envisager d'utiliser cette commande :

sudo apt-get install libcurl3 php5-curl

Cela peut également dépendre de la version de php que vous utilisez ( php5-common ?) Voir aquí .

Deuxième mise à jour

Ou, pour plus de facilité, utilisez simplement la commande wget https://install.meteor.com | sh . Curl était utilisé sur les versions précédentes d'ubuntu. Ce n'est pas vraiment un outil essentiel, mais certains tutoriels l'utilisent effectivement.

1voto

MilanG Points 19

Si vous obtenez le message d'erreur que le paquet curl n'est pas trouvé, vous devrez ajouter le dépôt comme ceci avant de l'installer :

sudo add-apt-repository ppa:ondrej/php
sudo apt update

SistemesEz.com

SystemesEZ est une communauté de sysadmins où vous pouvez résoudre vos problèmes et vos doutes. Vous pouvez consulter les questions des autres sysadmins, poser vos propres questions ou résoudre celles des autres.

Powered by:

X