After update... libcurl4 but i need libcurl3 (>= 7.18.0)

Something really messed up happened to my pi2 after the latest update (no idea when it was).
It has replace libcurl3 with libcurl4 and now a php5.6 server that i was running with lighttpd isnt working properly anymore.
I have a pretty old php script for accounting and i was hosting it on pi because it was convinient since it was running 24/7. Mostly i need CURL running which isnt anymore.

The following packages have unmet dependencies:
 php5-curl : Depends: libcurl3 (>= 7.18.0) but it is not going to be installed
E: Unable to correct problems, you have held broken packages.

Trying to install it via aptitude gives:

Need to get 259 kB of archives. After unpacking 562 kB will be used.
The following packages have unmet dependencies:
 libcurl4 : Conflicts: libcurl3 but 7.38.0-4+deb8u16 is to be installed
The following actions will resolve these dependencies:

      Remove the following packages:
1)      apache2-bin [2.4.38-3+deb10u4 (now, stable)]
2)      armv7-network-osmc [1.7.9 (<NULL>, now)]
3)      armv7-transmission-app-osmc [2.9.4-5 (<NULL>, now)]
4)      curl [7.64.0-4+deb10u1 (now, stable)]
5)      libapache2-mod-php7.0 [7.0.33-0+deb9u10 (now)]
6)      libapache2-mod-php7.3 [7.3.19-1~deb10u1 (now, stable)]
7)      libcurl4 [7.64.0-4+deb10u1 (now, stable)]
8)      php [2:7.3+69 (now, stable)]
9)      php-curl [2:7.3+69 (now, stable)]
10)     php7.3 [7.3.19-1~deb10u1 (now, stable)]
11)     php7.3-curl [7.3.19-1~deb10u1 (now, stable)]
12)     rbp2-device-osmc [1.5.4 (<NULL>, now)]
13)     rbp2-mediacenter-osmc [18.8.0-3 (<NULL>, now)]

which grabs osmc as well which is a no no.
Is there a way i can keep both libraries ? Or does anyone know what to do in this situation ?
Thanks

PHP 5 is no longer supported, your best route of action would be to upgrade whatever you are using PHP for to be compatible with version 7

1 Like

libcurl3 was part of Debian Stretch and libcurl4 came as part of the update to Debian Buster. lighttpd should have also updated, along with any dependencies. Without logs it’s difficult to say more.

What kind of logs should i provide? I mean the lib file is just gone. PHP gives just a simple error:

Call to undefined function curl_init() in blah blah

and when i try to get the curl lib again with : apt-get install php5-curl i get the above error.

@jb2cool it is impossible to upgrade that script…I have tried…there so many files in it…it is just impossible.
@dillthedog, Any idea how to go about updating lighttpd manually? I tried to update it based on some ubuntu pages but i get nothing:

root@pi2:# apt-get install lighttpd
Reading package lists... Done
Building dependency tree
Reading state information... Done
lighttpd is already the newest version (1.4.53-4+deb10u1).
0 upgraded, 0 newly installed, 0 to remove and 4 not upgraded.

There is no php5-curl available on Debian Buster:

osmc@osmc:~$ sudo apt-get install php5-curl --dry-run
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Package php5-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 'php5-curl' has no installation candidate

Just provide the full logs: grab-logs -A

Have you tried contacting the author of the script? That would probably be your best bet.

@dillthedog, https://paste.osmc.tv/ayuhelenan
(Please bear in mind this is a very old setup…i just use it for IPTV when i jog, so ignore any module, addon errors).

@bmillham, The script hasnt been udpated since 2007 :stuck_out_tongue:

I just cant get it why cant i have an old php5 running on it parallel to osmc. I mean isnt there a way to separate the 2 ?

I’ve tried a few workarounds and had a search on the Internet but haven’t found an easy way to square this particular circle, while keeping a working system.

I’ll see if I can find a better workaround but, as things stand, your best bet is to fix the script or, if that’s not possible, move the accounting system to a separate machine, eg a Pi Zero.

Its ok @dillthedog, thank you so much for trying man. I’ll bite the bullet and try to convert the script to php7. Too many deprecated stuff to fix but i guess now that we are quarantined…what else is there to do :slight_smile:

1 Like

I am reformating the pi…tried to install the latest stuff…but for some reason i cant remove/install mysql-server.

Did you check if you had mariadb packages?

Yeah i did. Anything that i touch that has to do with maria or mysql-client/server i get this

The following packages were automatically installed and are no longer required:
  armv7-libbluray-osmc armv7-librtmp-osmc armv7-libshairplay-osmc armv7-libsqlite-osmc libaacs0 libaio1 libasound2 libasound2-data libass9 libavahi-compat-libdnssd1 libcdio18
  libconfig-inifiles-perl libcrossguid0 libdbi-perl libevdev2 libfstrcmp0 libgif7 libimagequant0 libinput-bin libinput10 libiso9660-11 libmad0 libmicrohttpd12 libmtdev1 libnfs12 libnspr4
  libnss3 libogg0 libpcrecpp0v5 libplist3 libreadline5 libsamplerate0 libsmbclient libsnappy1v5 libssh-4 libtag1v5-vanilla libtinyxml2.6.2v5 libvorbis0a libvorbisenc2 libwacom-common
  libwacom2 libwebpdemux2 libwebpmux3 libxslt1.1 libyajl2 mediacenter-addon-osmc mediacenter-eventclients-common-osmc mediacenter-send-osmc mediacenter-skin-osmc mysql-common python-apt
  python-apt-common python-certifi python-chardet python-idna python-pexpect python-pil python-ptyprocess python-requests python-six python-unidecode python-urllib3 python3-apt
  python3-certifi python3-chardet python3-idna python3-pexpect python3-ptyprocess python3-requests python3-six python3-urllib3 rbp2-libcec-osmc
Use 'apt autoremove' to remove them.
The following packages will be REMOVED:
  libdbd-mysql-perl* libmariadb3* mariadb-client-10.1* mariadb-client-10.3* mariadb-client-core-10.3* mariadb-common* mariadb-server-10.1* mariadb-server-10.3* rbp2-device-osmc*
  rbp2-mediacenter-osmc*
0 upgraded, 0 newly installed, 10 to remove and 85 not upgraded.
After this operation, 339 MB disk space will be freed.
Do you want to continue? [Y/n]

It grabs the whole osmc as well…

https://paste.osmc.tv/solisadusu

Try removing the Jessie repository from your sources.
Otherwise maybe a reinstall is the easiest.

hmmm interesting, thanks @fzinken, we are getting somewhere now. I tried both mysql-server and mysql-server-5.6 but it cant be installed.

root@pi2:~# apt-get install mysql-server-5.6 mysql-client-5.6
Reading package lists... Done
Building dependency tree
Reading state information... Done
Package mysql-client-5.6 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
However the following packages replace it:
  mariadb-client-10.1 mariadb-server-core-10.3 mariadb-server-core-10.0 mariadb-client-10.3 mariadb-client-10.0

Package mysql-server-5.6 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
However the following packages replace it:
  mariadb-server-10.1 mariadb-server-10.3 mariadb-server-10.0

E: Package 'mysql-server-5.6' has no installation candidate
E: Package 'mysql-client-5.6' has no installation candidate

but i guess i can install maria instead ?

root@pi2:~# sudo apt install mariadb-server php-mysql
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following additional packages will be installed:
  galera-3 mariadb-server-10.3 mariadb-server-core-10.3 php-common php7.3-common php7.3-mysql rsync socat
Suggested packages:
  mailx mariadb-test netcat-openbsd tinyca
Recommended packages:
  libhtml-template-perl
The following NEW packages will be installed:
  galera-3 mariadb-server mariadb-server-10.3 mariadb-server-core-10.3 php-common php-mysql php7.3-common php7.3-mysql rsync socat
0 upgraded, 10 newly installed, 0 to remove and 85 not upgraded.
Need to get 11.2 MB of archives.
After this operation, 98.3 MB of additional disk space will be used.
Do you want to continue? [Y/n] n

I’ve never tried mariadb before…always did it with mysql-server. I’ll give it a go tomorrow then.
Maybe i can skip the format.
Thanks @fzinken!

Basically it’s the same and mariadb is the go to standard nowdays.

lol reading the comments on that post!
Well if it works i am all in :slight_smile: i am not that picky. Thank you!
After 3h on this…finally some good news.

Well interesting you tripped over something from 2017 :wink:

To tell you the truth…this pi2 has been running since 2016 with this setup, so when i installed everything back then this problem didnt exists lol.

Thanks @fzinken. Everything is working now :slight_smile:
I didnt have to format my pi…happy camper!