sudo apt install apache2
Reading package lists... Done
Building dependency tree
Reading state information... Done
Package apache2 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 'apache2' has no installation candidate
Asked
Active
Viewed 7,895 times
2
2 Answers
5
The most installation manuals recommends the good practice to update the repository and upgrade the existing packages before install a new one. So try:
sudo apt update && sudo apt upgrade
sudo apt install apache2
pa4080
- 29,831
1
Tasksel is a Debian/Ubuntu tool that installs multiple related packages as a co-ordinated "task" onto your system.
Installation:
sudo apt-get install tasksel
Usage:
sudo tasksel
The tasksel menu will be shown, select the checkbox you need type Space, Tab, Enter, wait… done.
Installation from terminal lamp-server (Apache/PHP/MySQL Server)
sudo tasksel install lamp-server
Optional for PHP:
sudo apt-get install php php-mysql php-mbstring php-all-dev php-cgi libapache2-mod-php php-imagick
PhpMyAdmin
sudo apt-get install phpmyadmin
sudo apt updateandsudo apt upgradebefore installingapache2? – pa4080 Dec 28 '17 at 10:59