0

I am updating curl from 7.35.0 to 7.60.0 on an ubuntu 14.04.3 server. Followed the steps here https://gist.github.com/fideloper/f72997d2e2c9fbe66459

sudo apt-get build-dep curl
mkdir ~/curl
cd ~/curl
wget http://curl.haxx.se/download/curl-7.60.0.tar.bz2
tar -xvjf curl-7.60.0.tar.bz2
cd curl-7.60.0
./configure
make
sudo make install
sudo ldconfig

Looks like curl was updated. But curl -V still shows

curl: /usr/local/lib/libcurl.so.4: no version information available (required by curl)
curl 7.35.0 (x86_64-pc-linux-gnu) libcurl/7.60.0

which curl shows

/usr/local/bin/curl

whereis curl shows

curl: /usr/bin/curl /usr/local/bin/curl /usr/share/man/man1/curl.1.gz

/usr/bin/curl is the older version and /usr/local/bin/curl should be the new version. How do I get the new version of curl used? Can I safely remove /usr/bin/curl?

Thanks in advance!

  • What happens when you run /usr/local/bin/curl -V directly? With the full file path to it instead of just 'curl' – Thomas Ward May 24 '18 at 19:51
  • @ThomasWard that does output the correct updated curl version. – User007 May 24 '18 at 19:53
  • Have you closed your terminal and reopened it yet, then run just curl? Just to rule out some odd PATH problem. – Thomas Ward May 24 '18 at 20:24
  • @ThomasWard got the updated curl version by reopening the terminal. I had restarted Apache and thought that would have been enough. Thanks! – User007 May 24 '18 at 20:32
  • Glad that fixed the problem. I converted that to an answer for you so you can mark the question as answered/solved by accepting the answer. – Thomas Ward May 24 '18 at 20:34
0

When you install a new software that would have a version which supersedes the version in /usr/bin/ or anywhere else in the $PATH, you need to usually restart your terminal session.

Close out your terminal session or your SSH connection. Once you start it back up, you should then be able to use the 'newer' version (/usr/local/bin/... will supersede /usr/bin/... when the same application is in both locations but with different versions, typically.)

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.