dpkg: erro processando o pacote php5-mysql (--configure):

0

Ao instalar o PHP e mySQL, recebi a seguinte mensagem de erro. O que fazer?

Creating config file /etc/php5/mods-available/mysql.ini with new version
cp: cannot create regular file ‘/etc/php5/mods-available/mysql.ini’: No such      file or directory
dpkg: error processing package php5-mysql (--configure):
subprocess installed post-installation script returned error exit status 1
Processing triggers for libapache2-mod-php5 (5.5.9+dfsg-1ubuntu4.14) ...
Errors were encountered while processing: php5-mysql
E: Sub-process /usr/bin/dpkg returned an error code (1)
    
por M.Lee 01.02.2016 / 00:11

1 resposta

0

Isso aconteceu comigo quando eu removi o servidor mysql e tentei reinstalar. A maneira que eu resolvi isso foi executando o seguinte

sudo apt-get purge mysql-server mysql-client mysql-common mysql-client-5.5 mysql-server-5.5 mysql-client-5.6 mysql-server-5.6 
sudo apt-get autoremove
sudo apt-get autoclean

sudo rm -rf /etc/mysql

sudo apt-get install mysql-server mysql-common mysql-client
  • Link apparmor:

    sudo ln -s /etc/apparmor.d/usr.sbin.mysqld /etc/apparmor.d/disable/usr.sbin.mysqld

    sudo /etc/init.d/apparmor restart

  • Instale o MySQL 5.6:

    sudo apt-get install mysql-server-5.6

por Jaco Toledo 01.02.2016 / 00:43