I have been trying to install the GD toolkit on my Ubuntu VM. The operation is simple enough:
sudo apt-get install php5-gd
However, when I run this, I get a 404 (Not Found error) for a package:
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following NEW packages will be installed:
php5-gd
0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
3 not fully installed or removed.
Need to get 38.8 kB of archives.
After this operation, 163 kB of additional disk space will be used.
Err http://us.archive.ubuntu.com/ubuntu/ precise-updates/main php5-gd amd64 5.3.10-1ubuntu3.1
404 Not Found [IP: 91.189.92.153 80]
Err http://security.ubuntu.com/ubuntu/ precise-security/main php5-gd amd64 5.3.10-1ubuntu3.1
404 Not Found [IP: 91.189.92.151 80]
Failed to fetch http://security.ubuntu.com/ubuntu/pool/main/p/php5/php5-gd_5.3.10-1ubuntu3.1_amd64.deb 404 Not Found [IP: 91.189.92.151 80]
E: Unable to fetch some archives, maybe run apt-get update or try with --fix-missing?
Has anyone encountered this problem?
Got the answer from user1190992 apt-get was simply out of date....
This command did the trick:
sudo apt-get update
Internets might be all broken. try
$ curl 91.189.92.153
Related
I'd like to install php7.4-redis on my debian server. My php is 7.4 version.
When I run the "sudo apt install php7.4-redis" command , it shows 404 not found so I can't finish my setting.
However , I found the page has other version :
php7.4-redis version
I've run command "sudo apt-get update" to update the repository but why am I still getting the 404 error?
sudo apt install php7.4-redis
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following additional packages will be installed:
php7.4-igbinary
The following NEW packages will be installed:
php7.4-igbinary php7.4-redis
0 upgraded, 2 newly installed, 0 to remove and 70 not upgraded.
Need to get 142 kB/202 kB of archives.
After this operation, 848 kB of additional disk space will be used.
Do you want to continue? [Y/n] y
Err:1 https://packages.sury.org/php stretch/main amd64 php7.4-redis amd64 5.3.2+4.3.0-7+0~20210228.34+debian9~1.gbp893bd4
404 Not Found
E: Failed to fetch https://packages.sury.org/php/pool/main/p/php-redis/php7.4-redis_5.3.2+4.3.0-7+0~20210228.34+debian9~1.gbp893bd4_amd64.deb 404 Not Found
E: Unable to fetch some archives, maybe run apt-get update or try with --fix-missing?
Try running apt update, then it should work afterwards.
APT caches the packages available from each repository locally when running apt update. If you install a package, apt will use this cache. However, when a package is updated on the server and the old version gets deleted, apt will try to retrieve a no longer present file. This is indicated by this log output:
404 Not Found
E: Failed to fetch https://packages.sury.org/php/pool/main/p/php-redis/php7.4-redis_5.3.2+4.3.0-7+0~20210228.34+debian9~1.gbp893bd4_amd64.deb 404 Not Found
If you take a look at the repos listing, your Version 5.3.2+4.3.0-7+0~20210228.34+debian9~1.gbp893bd4 is notably missing. Thus, after an apt update apt will know from where to load the package.
EDIT: You have an old signing key from php sury on your system, thus the repo can not be updated and the current version to download can not be obtained. This is a known issue, I faced it to on all my hosts.
In the linked GitHub thread, the recommended fix was to simple run these commands (posted by stefanux):
$ apt-key del 95BD4743 # If this throws an error about the key not being present, it's fine
$ wget -O /etc/apt/trusted.gpg.d/php.gpg https://packages.sury.org/php/apt.gpg
$ apt-get update
Now you should be able to install the redis package.
When installing the php5-xsl package, I get errors:
Err http://ppa.launchpad.net/ondrej/php5-5.6/ubuntu/ trusty/main php5-> xsl amd64 5.6.14+dfsg-1+deb.sury.org~trusty+1 403 Forbidden
E: Failed to fetch http://ppa.launchpad.net/ondrej/php55.6/ubuntu/pool/main/p/php5/php5-xsl_5.6.14+dfsg-1+deb.sury.org~trusty+1_amd64.deb 403 Forbidden
E: Unable to fetch some archives, maybe run apt-get update or try with --fix-missing?
I tried also this before installing:
sudo apt-get update
sudo apt-get upgrade
But with no luck.
How can I install php5-xsl? I need this in my PHP project because this code gives a fatal error (class not found):
new \XSLTProcessor();
Thank you!
I was told to install mysqlnd by running sudo apt-get install php5-mysqlnd. However, I seem to have received an error. Any idea what's going on and how I can fix it? I'm running Ubuntu Server.
zerg#server:~$ sudo apt-get install php5-mysqlnd
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages will be REMOVED:
php5-mysql
The following NEW packages will be installed: php5-mysqlnd
0 upgraded, 1 newly installed, 1 to remove and 0 not upgraded.
Need to get 134 kB of archives.
After this operation, 247 kB of additional disk space will be used.
Do you want to continue? [Y/n] y
Err http://archive.ubuntu.com/ubuntu/ trusty-updates/universe php5- mysqlnd amd64 5.5.9+dfsg-1ubuntu4.14
404 Not Found [IP: 2001:67c:1560:8001::11 80]
Err http://security.ubuntu.com/ubuntu/ trusty-security/universe php5-mysqlnd amd64 5.5.9+dfsg-1ubuntu4.14
404 Not Found [IP: 2001:67c:1560:8001::11 80]
E: Failed to fetch http://security.ubuntu.com/ubuntu/pool/universe/p/php5/php5-mysqlnd_5.5.9+dfsg-1ubuntu4.14_amd64.deb 404 Not Found [IP: 2001:67c:1560:8001::11 80]
E: Unable to fetch some archives, maybe run apt-get update or try with --fix-missing?
zerg#server:~$ sudo apt-get install php5-mysqlnd --fix-missing
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages will be REMOVED: php5-mysql
The following NEW packages will be installed:
php5-mysqlnd
0 upgraded, 1 newly installed, 1 to remove and 0 not upgraded.
Need to get 134 kB of archives.
After this operation, 247 kB of additional disk space will be used.
Do you want to continue? [Y/n] y
Err http://archive.ubuntu.com/ubuntu/ trusty-updates/universe php5- mysqlnd amd64 5.5.9+dfsg-1ubuntu4.14
404 Not Found [IP: 2001:67c:1560:8001::11 80]
Err http://security.ubuntu.com/ubuntu/ trusty-security/universe php5-mysqlnd amd64 5.5.9+dfsg-1ubuntu4.14
404 Not Found [IP: 2001:67c:1560:8001::11 80]
(Reading database ... 28529 files and directories currently installed.)
Removing php5-mysql (5.5.9+dfsg-1ubuntu4.14) ...
php5_invoke prerm: Disable module mysql for fpm SAPI
php5_invoke prerm: Disable module mysql for cli SAPI
php5_invoke prerm: Disable module mysqli for fpm SAPI
php5_invoke prerm: Disable module mysqli for cli SAPI
php5_invoke prerm: Disable module pdo_mysql for fpm SAPI
php5_invoke prerm: Disable module pdo_mysql for cli SAPI
Processing triggers for php5-fpm (5.5.9+dfsg-1ubuntu4.14) ...
php5-fpm stop/waiting
php5-fpm start/running, process 17187
E: Failed to fetch http://security.ubuntu.com/ubuntu/pool/universe/p/php5/php5-mysqlnd_5.5.9+dfsg-1ubuntu4.14_amd64.deb 404 Not Found [IP: 2001:67c:1560:8001::11 80]
I have a Linux Mint machine I am working on. I want Laravel to install on it.
When I search for this I got this command: curl -sS https://getcomposer.org/installer | php from "https://getcomposer.org/download/" to put in terminal but it gives me this:
The program 'php' is currently not installed. You can install it by typing:
sudo apt-get install php5-cli
The program 'curl' is currently not installed. You can install it by typing:
sudo apt-get install curl
After i have done sudo apt-get install curl
libcurl3 curl
Install these packages without verification [y/N]? y
Err http://archive.ubuntu.com/ubuntu/ quantal-updates/main libcurl3 i386 7.27.0-1ubuntu1.9
404 Not Found [IP: 91.189.91.15 80]
Err http://security.ubuntu.com/ubuntu/ quantal-security/main libcurl3 i386 7.27.0-1ubuntu1.9
404 Not Found [IP: 91.189.91.14 80]
Err http://security.ubuntu.com/ubuntu/ quantal-security/main curl i386 7.27.0-1ubuntu1.9
404 Not Found [IP: 91.189.91.14 80]
Failed to fetch http://security.ubuntu.com/ubuntu/pool/main/c/curl/libcurl3_7.27.0-1ubuntu1.9_i386.deb 404 Not Found [IP: 91.189.91.14 80]
Failed to fetch http://security.ubuntu.com/ubuntu/pool/main/c/curl/curl_7.27.0-1ubuntu1.9_i386.deb 404 Not Found [IP: 91.189.91.14 80]
E: Unable to fetch some archives, maybe run apt-get update or try with --fix-missing?
got this which is not successfully installed curl
How can any one I successfully install these things and Composer and Laravel?
The Composer already hints you the way to install those, you should run those commands, enter your password en those libraries should be installed automatically, after you install those libraries rerun the composer download.
First make sure that you have the latest version of curl installed.
I made a bash file for the whole process of global installation of Laravel and Composer.
Download it from here
Open a terminal in the bash file directory
Run the command below:
bash Laravel_Global_Installer.sh
This bash file manages installations of:
Latest version of PHP and its extensions
Latest version of Composer (Global)
Latest version of Laravel (Global)
I am trying to install curl module of php by following command on my Ubuntu machine-
sudo apt-get install php5-curl
But it is not getting installed and I am getting following error messages on console. Could you assist me and explain what is happening here. Why are those urls Forbidden?
sudo apt-get install php5-curl
root#XXXXXXXX:/etc/apt# apt-get install php5-curl
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following extra packages will be installed:
libapache2-mod-php5 php5-cli php5-common php5-mysql
Suggested packages:
php-pear php5-suhosin
The following NEW packages will be installed:
php5-curl
The following packages will be upgraded:
libapache2-mod-php5 php5-cli php5-common php5-mysql
4 upgraded, 1 newly installed, 0 to remove and 29 not upgraded.
Need to get 6,522kB of archives.
After this operation, 127kB of additional disk space will be used.
Do you want to continue [Y/n]? Y
Err http://us-east-1.ec2.archive.ubuntu.com/ubuntu/ maverick-updates/main php5-cli i386 5.3.3-1ubuntu9.10
403 Forbidden
Err http://us-east-1.ec2.archive.ubuntu.com/ubuntu/ maverick-updates/main php5-mysql i386 5.3.3-1ubuntu9.10
403 Forbidden
Err http://us-east-1.ec2.archive.ubuntu.com/ubuntu/ maverick-updates/main libapache2-mod-php5 i386 5.3.3-1ubuntu9.10
403 Forbidden
Err http://us-east-1.ec2.archive.ubuntu.com/ubuntu/ maverick-updates/main php5-common i386 5.3.3-1ubuntu9.10
403 Forbidden
Err http://us-east-1.ec2.archive.ubuntu.com/ubuntu/ maverick-updates/main php5-curl i386 5.3.3-1ubuntu9.10
403 Forbidden
Failed to fetch http://us-east-1.ec2.archive.ubuntu.com/ubuntu/pool/main/p/php5/php5-cli_5.3.3-1ubuntu9.10_i386.deb 403 Forbidden
Failed to fetch http://us-east-1.ec2.archive.ubuntu.com/ubuntu/pool/main/p/php5/php5-mysql_5.3.3-1ubuntu9.10_i386.deb 403 Forbidden
Failed to fetch http://us-east-1.ec2.archive.ubuntu.com/ubuntu/pool/main/p/php5/libapache2-mod-php5_5.3.3-1ubuntu9.10_i386.deb 403 Forbidden
Failed to fetch http://us-east-1.ec2.archive.ubuntu.com/ubuntu/pool/main/p/php5/php5-common_5.3.3-1ubuntu9.10_i386.deb 403 Forbidden
Failed to fetch http://us-east-1.ec2.archive.ubuntu.com/ubuntu/pool/main/p/php5/php5-curl_5.3.3-1ubuntu9.10_i386.deb 403 Forbidden
E: Unable to fetch some archives, maybe run apt-get update or try with --fix-missing?
I upgraded my distro from ubuntu 10.10 to Ubuntu 12.04 LTS. It solved my problem.
If so, try the following sequence:
sudo apt-get update --fix-missing
sudo apt-get update
sudo apt-get install php5-curl