Reputation: 462
I am busy setting up my ec2 for my website. I am using the Ubuntu 18.04 AMI(Amazon Machine Image).I need to run these commands:
sudo apt-get install php7.0 php7.0-mcrypt php7.0-mysql mysql-server
apache2
But when I try to execute the installation I receive these errors:
Reading package lists... Done
Building dependency tree
Reading state information... Done
Note, selecting 'php7.0-remctl' for regex 'php7.0'
Note, selecting 'php7.0-common' for regex 'php7.0'
Note, selecting 'php-remctl' instead of 'php7.0-remctl'
E: Unable to locate package libapache2-mod-php7.0
E: Couldn't find any package by glob 'libapache2-mod-php7.0'
E: Couldn't find any package by regex 'libapache2-mod-php7.0'
E: Unable to locate package php7.0-mysql
E: Couldn't find any package by glob 'php7.0-mysql'
E: Couldn't find any package by regex 'php7.0-mysql'
I am running these commands through MobaXterm on Windows 10. Any ideas what I'm doing wrong??
Upvotes: 1
Views: 2282
Reputation:
PHP 7.0 is obsolete -- it reached end-of-life in January 2019 -- and it is not available in Ubuntu 18.04. The appropriate version for this release is PHP 7.2 (e.g. php7.2
, php7.2-mysql
, etc); you will need to change your install commands accordingly.
The mcrypt extension was deprecated in PHP 7.1 and subsequently removed in PHP 7.2. If you are using this extension in your application, you will need to rework those parts of your code.
Upvotes: 1