root@vps:~# sudo dpkg --configure -a
Setting up libwbclient0:amd64 (2:4.2.14+dfsg-0+deb8u7+b1) ...
Setting up libexpat1:amd64 (2.1.0-6+deb8u4) ...
Setting up mysql-server (5.5.57-0+deb8u1) ...
Setting up libmspack0:amd64 (0.5-1+deb8u1) ...
Setting up debconf-i18n (1.5.56+deb8u1) ...
Setting up apache2-utils (2.4.10-10+deb8u10) ...
Setting up debconf-utils (1.5.56+deb8u1) ...
Setting up mysql-common (5.5.57-0+deb8u1) ...
Setting up linux-libc-dev:amd64 (3.16.43-2+deb8u3) ...
Setting up perl-modules (5.20.2-3+deb8u8) ...
Setting up apache2-data (2.4.10-10+deb8u10) ...
Setting up imagemagick-common (8:6.8.9.9-5+deb8u10) ...
Setting up libtiff5:amd64 (4.0.3-12.3+deb8u4) ...
Setting up libroken18-heimdal:amd64 (1.6~rc2+dfsg-9+deb8u1) ...
Setting up libmysqlclient18:amd64 (5.5.57-0+deb8u1) ...
Setting up libxml2:amd64 (2.9.1+dfsg1-5+deb8u5) ...
Setting up libgraphite2-3:amd64 (1.3.10-1~deb8u1) ...
Setting up perl (5.20.2-3+deb8u8) ...
Setting up libisc-export95 (1:9.9.5.dfsg-9+deb8u13) ...
Setting up libheimbase1-heimdal:amd64 (1.6~rc2+dfsg-9+deb8u1) ...
Setting up libgnutls-deb0-28:amd64 (3.3.8-6+deb8u7) ...
Setting up libonig2:amd64 (5.9.5-3.2+deb8u1) ...
Setting up libffi6:amd64 (3.1-2+deb8u1) ...
Setting up libc-dev-bin (2.19-18+deb8u10) ...
Setting up mysql-server-core-5.5 (5.5.57-0+deb8u1) ...
Setting up libperl5.20 (5.20.2-3+deb8u8) ...
Setting up libc6-dev:amd64 (2.19-18+deb8u10) ...
dpkg: dependency problems prevent configuration of apache2-mpm-prefork:
apache2-mpm-prefork depends on apache2 (= 2.4.10-10+deb8u10); however:
Version of apache2 on system is 2.4.10-10+deb8u8.
dpkg: error processing package apache2-mpm-prefork (--configure):
dependency problems - leaving unconfigured
Setting up libisccfg-export90 (1:9.9.5.dfsg-9+deb8u13) ...
Setting up libwind0-heimdal:amd64 (1.6~rc2+dfsg-9+deb8u1) ...
Setting up mysql-client-5.5 (5.5.57-0+deb8u1) ...
Setting up libasn1-8-heimdal:amd64 (1.6~rc2+dfsg-9+deb8u1) ...
Setting up rkhunter (1.4.2-0.4+deb8u1) ...
Installing new version of config file /etc/rkhunter.conf ...
Setting up libhcrypto4-heimdal:amd64 (1.6~rc2+dfsg-9+deb8u1) ...
Setting up apache2-bin (2.4.10-10+deb8u10) ...
Setting up libgd3:amd64 (2.1.0-5+deb8u10) ...
Setting up mysql-client (5.5.57-0+deb8u1) ...
Setting up libmagickcore-6.q16-2:amd64 (8:6.8.9.9-5+deb8u10) ...
Setting up libdns-export100 (1:9.9.5.dfsg-9+deb8u13) ...
Setting up libhx509-5-heimdal:amd64 (1.6~rc2+dfsg-9+deb8u1) ...
Setting up libgnutls-openssl27:amd64 (3.3.8-6+deb8u7) ...
Setting up libkrb5-26-heimdal:amd64 (1.6~rc2+dfsg-9+deb8u1) ...
Setting up libirs-export91 (1:9.9.5.dfsg-9+deb8u13) ...
Setting up libhdb9-heimdal:amd64 (1.6~rc2+dfsg-9+deb8u1) ...
Setting up libmagickwand-6.q16-2:amd64 (8:6.8.9.9-5+deb8u10) ...
Processing triggers for libc-bin (2.19-18+deb8u10) ...
Errors were encountered while processing:
apache2-mpm-prefork
root@vps:~# sudo apt-get -f install
Reading package lists... Done
Building dependency tree
Reading state information... Done
Correcting dependencies... Done
The following extra packages will be installed:
apache2
Suggested packages:
apache2-suexec-pristine apache2-suexec-custom
The following packages will be upgraded:
apache2
1 upgraded, 0 newly installed, 0 to remove and 29 not upgraded.
1 not fully installed or removed.
Need to get 0 B/208 kB of archives.
After this operation, 0 B of additional disk space will be used.
Do you want to continue? [Y/n] Y
Reading changelogs... Done
(Reading database ... 48146 files and directories currently installed.)
Preparing to unpack .../apache2_2.4.10-10+deb8u10_amd64.deb ...
Unpacking apache2 (2.4.10-10+deb8u10) over (2.4.10-10+deb8u8) ...
dpkg: error processing archive /var/cache/apt/archives/apache2_2.4.10-10+deb8u10_amd64.deb (--unpack):
error creating directory `./var/www/html': Permission denied
dpkg-deb: error: subprocess paste was killed by signal (Broken pipe)
Processing triggers for systemd (215-17+deb8u7) ...
Errors were encountered while processing:
/var/cache/apt/archives/apache2_2.4.10-10+deb8u10_amd64.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)
root@vps:~# sudo apt-get -f remove
Reading package lists... Done
Building dependency tree
Reading state information... Done
Correcting dependencies... Done
The following extra packages will be installed:
apache2
Suggested packages:
apache2-suexec-pristine apache2-suexec-custom
The following packages will be upgraded:
apache2
1 upgraded, 0 newly installed, 0 to remove and 29 not upgraded.
1 not fully installed or removed.
Need to get 0 B/208 kB of archives.
After this operation, 0 B of additional disk space will be used.
Do you want to continue? [Y/n] Y
Reading changelogs... Done
(Reading database ... 48146 files and directories currently installed.)
Preparing to unpack .../apache2_2.4.10-10+deb8u10_amd64.deb ...
Unpacking apache2 (2.4.10-10+deb8u10) over (2.4.10-10+deb8u8) ...
dpkg: error processing archive /var/cache/apt/archives/apache2_2.4.10-10+deb8u10_amd64.deb (--unpack):
error creating directory `./var/www/html': Permission denied
dpkg-deb: error: subprocess paste was killed by signal (Broken pipe)
Processing triggers for systemd (215-17+deb8u7) ...
Errors were encountered while processing:
/var/cache/apt/archives/apache2_2.4.10-10+deb8u10_amd64.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)
root@vps:~# sudo apt-get update
Hit
http://security.debian.org jessie/updates InRelease
Ign
http://http.debian.net jessie InRelease
Hit
http://http.debian.net jessie-updates InRelease
Hit
http://security.debian.org jessie/updates/main Sources
Hit
http://security.debian.org jessie/updates/contrib Sources
Hit
http://security.debian.org jessie/updates/non-free Sources
Hit
http://http.debian.net jessie-backports InRelease
Hit
http://http.debian.net jessie Release.gpg
Hit
http://security.debian.org jessie/updates/main amd64 Packages
Hit
http://security.debian.org jessie/updates/contrib amd64 Packages
Hit
http://security.debian.org jessie/updates/non-free amd64 Packages
Hit
http://http.debian.net jessie-updates/main Sources
Hit
http://security.debian.org jessie/updates/contrib Translation-en
Hit
http://security.debian.org jessie/updates/main Translation-en
Hit
http://security.debian.org jessie/updates/non-free Translation-en
Hit
http://http.debian.net jessie-updates/contrib Sources
Hit
http://http.debian.net jessie-updates/non-free Sources
Get:1
http://http.debian.net jessie-updates/main amd64 Packages/DiffIndex [8392 B]
Hit
http://http.debian.net jessie-updates/contrib amd64 Packages
Get:2
http://http.debian.net jessie-updates/non-free amd64 Packages/DiffIndex [736 B]
Hit
http://http.debian.net jessie-updates/contrib Translation-en
Get:3
http://http.debian.net jessie-updates/main Translation-en/DiffIndex [3196 B]
Get:4
http://http.debian.net jessie-updates/non-free Translation-en/DiffIndex [736 B]
Hit
http://http.debian.net jessie Release
Get:5
http://http.debian.net jessie-backports/main Sources/DiffIndex [27.8 kB]
Get:6
http://http.debian.net jessie-backports/contrib Sources/DiffIndex [27.8 kB]
Get:7
http://http.debian.net jessie-backports/non-free Sources/DiffIndex [24.5 kB]
Get:8
http://http.debian.net jessie-backports/main amd64 Packages/DiffIndex [27.8 kB]
Get:9
http://http.debian.net jessie-backports/contrib amd64 Packages/DiffIndex [25.0 kB]
Get:10
http://http.debian.net jessie-backports/non-free amd64 Packages/DiffIndex [22.9 kB]
Get:11
http://http.debian.net jessie-backports/contrib Translation-en/DiffIndex [7468 B]
Get:12
http://http.debian.net jessie-backports/main Translation-en/DiffIndex [27.8 kB]
Get:13
http://http.debian.net jessie-backports/non-free Translation-en/DiffIndex [17.2 kB]
Hit
http://http.debian.net jessie/main Sources
Hit
http://http.debian.net jessie/contrib Sources
Hit
http://http.debian.net jessie/non-free Sources
Hit
http://http.debian.net jessie/main amd64 Packages
Hit
http://http.debian.net jessie/contrib amd64 Packages
Hit
http://http.debian.net jessie/non-free amd64 Packages
Hit
http://http.debian.net jessie/contrib Translation-en
Hit
http://http.debian.net jessie/main Translation-en
Hit
http://http.debian.net jessie/non-free Translation-en
Fetched 221 kB in 6s (36.5 kB/s)
Reading package lists... Done
root@vps:~# sudo apt-get upgrade
Reading package lists... Done
Building dependency tree
Reading state information... Done
You might want to run 'apt-get -f install' to correct these.
The following packages have unmet dependencies:
apache2 : Depends: apache2-bin (= 2.4.10-10+deb8u8) but 2.4.10-10+deb8u10 is installed
Depends: apache2-data (= 2.4.10-10+deb8u8) but 2.4.10-10+deb8u10 is installed
apache2-mpm-prefork : Depends: apache2 (= 2.4.10-10+deb8u10) but 2.4.10-10+deb8u8 is installed
E: Unmet dependencies. Try using -f.
root@vps:~#