试图使用owncloud但它说没有安装一些php模块

问题描述 投票:0回答:1

尝试进入http://localhost/index.php时出现此错误

PHP module zip not installed.

Please ask your server administrator to install the module.
PHP module dom not installed.

Please ask your server administrator to install the module.
PHP module XMLWriter not installed.

Please ask your server administrator to install the module.
PHP module XMLReader not installed.

Please ask your server administrator to install the module.
PHP module intl not installed.

Please ask your server administrator to install the module.
PHP module libxml not installed.

Please ask your server administrator to install the module.
PHP module mb multibyte not installed.

Please ask your server administrator to install the module.
PHP module GD not installed.

Please ask your server administrator to install the module.
PHP module SimpleXML not installed.

Please ask your server administrator to install the module.
PHP module cURL not installed.

Please ask your server administrator to install the module.
PHP modules have been installed, but they are still listed as missing?

Please ask your server administrator to restart the web server.

在安装owncloud的地方,我尝试了这个命令:

apt-get install -y apache2 mariadb-server libapache2-mod-php7.0     openssl php-imagick php7.0-common php7.0-curl php7.0-gd     php7.0-imap php7.0-intl php7.0-json php7.0-ldap php7.0-mbstring     php7.0-mcrypt php7.0-mysql php7.0-pgsql php-smbclient php-ssh2     php7.0-sqlite3 php7.0-xml php7.0-zip

但它给了我一些奇怪的错误:

Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
mariadb-server : Depends: mariadb-server-10.1 (>= 1:10.1.34-0ubuntu0.18.04.1) but it is not going to be installed
E: Unable to correct problems, you have held broken packages.

我不知道该怎么做......我搜索了所有互联网,但没有找到答案......

linux owncloud
1个回答
1
投票

对于第一部分,您需要安装几个PHP模块:

apt install -y apache2 mariadb-server libapache2-mod-php7.0 \
php7.0-gd php7.0-json php7.0-mysql php7.0-curl \
php7.0-intl php7.0-mcrypt php-imagick \
php7.0-zip php7.0-xml php7.0-mbstring

对于第二部分,似乎你有一个apt的包。您需要找出所持有的包:

 sudo aptitude why-not mariadb-server

包裹被保留的原因有多种,做什么取决于它的原因。一般来说,一旦你知道为什么这样做,你就解决了为什么你可以解决它:

sudo apt-mark unhold package_name

如果你不知道为什么它被保留,你可以尝试修复破坏的依赖关系,但如果有一个真正的原因必须保持它,这可能是坏的:

sudo apt-get install mariadb-server --fix-missing --fix-broken

如果你在托管上它可能由你的托管持有,所以你基本上可以跳过mariadb安装,因为它似乎安装在以前的版本。

© www.soinside.com 2019 - 2024. All rights reserved.