curl / Mailing Lists / curl-and-php / Single Mail

curl-and-php

Re: After dist upgrade to Ubuntu 18.04, PHP 7.2 no longer finds the cURL module

From: luis jury <zeui16_at_gmail.com>
Date: Tue, 21 Aug 2018 09:39:27 -0300

Hi Dave,

Looking at your phpinfo and php.ini, it looks like you don't have curl
extension enabled. Anyway I'm not sure if you really have it installed
for php 7.2??. You changed your php version, and you need to install
modules as well, upgrading ubuntu won't install modules by default.

Try to install it with: `sudo apt-get install php-curl`, (you can also try
with `sudo apt-get install php7.2-curl` but, as ubuntu 18 default php
versión is 7.2, with the first command should work. )
Then try to enable it with: `phpenmod curl`
if the second command doesn't work, try `phpenmod -v 7.2 curl` (-v is for
the php version, but, as default is 7.2, this should not be required)

That should do the work, but, if any of those works, look at your php.ini
for php 7.2 and look for this line `;extension=curl` and delete the `;`
character. (the `;`is a comment, so, your .ini is not loading that
extension)

if any of those works, please share the versión of php running on your cli,
`php -v`. Most of the time upgrading Ubuntu is a bad idea, things like
those always happen when doing a dist upgrade.

Hope this work for you.
Good luck!

*ars longa, vita brevis*

El mar., 21 ago. 2018 a las 3:04, Dave Nelson (<dave_at_x2592.com>) escribió:

> Hi people, I was using cURL successfully on Ubuntu 16.04 (server
> edition) with PHP 5.6, and did a distribution upgrade to Ubuntu 18.04.
> That now gives me PHP 7.2. I'm using cURL for a NextCloud instance
> (that was running quite happily). Now my NextCloud instance is giving
> me the following message when I go to the login page:
>
> "PHP module cURL not installed.
> Please ask your server administrator to install the module.
> PHP modules have been installed, but they are still listed as missing?
> Please ask your server administrator to restart the web server."
>
> Running 'php -m' lists curl as being there, and curl.so is indeed
> present at /usr/lib/php/20170718/curl.so
>
> Why isn't PHP seeing cURL? And what's the solution?
>
> For info, there is a pastebin of my /etc/php/7.0/apache2/php.ini at
> http://pasted.co/791ed426
>
> There is a pastebin of my /etc/php/7.2/apache2/php.ini at
> http://pasted.co/eb43179d
>
> And there is a pastebin of my /etc/php/7.2/apache2/conf.d/20-curl.ini
> at http://pasted.co/6930a601
>
> My PHP info can be seen at https://tardis.world/info.php
>
> Many thanks in advance for any help,
>
> Dave
> _______________________________________________
> https://cool.haxx.se/cgi-bin/mailman/listinfo/curl-and-php
>

_______________________________________________
https://cool.haxx.se/cgi-bin/mailman/listinfo/curl-and-php
Received on 2018-08-21