Announcement

Collapse
No announcement yet.

Problem with phpmyadmin in 18.04

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Problem with phpmyadmin in 18.04

    I can neither uninstall nor configure phpmyadmin.

    Installation of apache2 and php7.2 went smoothly. Installation of mysql has changed since16.04. Now you just install mysql-server and it installs the client automatically. But then you must run

    Code:
    sudo mysql_secure_installation
    to configure it. This is new, at least to me.

    Then when installing phpmyadmin, it asks which server, apache2 or something else, to use. That is where I messed up because I could not figure out how to choose apache2. (Need to use the space key. Who would have thought of that?) Frankly, I'm not sure what I did, but the subsequent installation of phpmyadmin failed. I tried purging it and doing all sorts of stuff I found on the web, like use 'rm -rf' to delete stuff by hand. Now I have this:

    Code:
    $ sudo apt install phpmyadmin php-mbstring php-gettext
    Reading package lists... Done
    Building dependency tree       
    Reading state information... Done
    php-gettext is already the newest version (1.0.12-0.1).
    php-mbstring is already the newest version (1:7.2+60ubuntu1).
    phpmyadmin is already the newest version (4:4.6.6-5).
    Starting pkgProblemResolver with broken count: 0
    Starting 2 pkgProblemResolver with broken count: 0
    Done
    0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
    1 not fully installed or removed.
    After this operation, 0 B of additional disk space will be used.
    Do you want to continue? [Y/n] 
    Setting up phpmyadmin (4:4.6.6-5) ...
    dbconfig-common: writing config to /etc/dbconfig-common/phpmyadmin.conf
    dbconfig-common: flushing administrative password
    dpkg: error processing package phpmyadmin (--configure):
    installed phpmyadmin package post-installation script subprocess returned error exit status 10
    Errors were encountered while processing:
    phpmyadmin
    E: Sub-process /usr/bin/dpkg returned an error code (1)
    Suggestions on the internet say to fiddle around with stuff in /var/lib/dpkg/info/phpmyadmin.postinst, but that file is meaningless to me. Another suggestion gave this:

    Code:
    $ sudo dpkg --configure -a
    Setting up phpmyadmin (4:4.6.6-5) ...
    dbconfig-common: writing config to /etc/dbconfig-common/phpmyadmin.conf
    dbconfig-common: flushing administrative password
    dpkg: error processing package phpmyadmin (--configure):
    installed phpmyadmin package post-installation script subprocess returned error exit status 10
    Errors were encountered while processing:
    phpmyadmin
    How can I get past this hurdle? I would think that a complete removal of phpmyadmin would do the trick, but the arcana of package handling are beyond my ken.
    'I must have a prodigious quantity of mind; it takes me as much as a week sometimes to make it up.' Mark Twain

    #2
    Problem with apt package

    I think my problem is with the package handler, something which is pretty much a black box to me. Following info found elsewhere on the web, I tried all of the following:

    Code:
    sudo rm  /var/lib/dpkg/info/phpmyadmin.*
    sudo rm -rf /var/lib/phpmyadmin/
    sudo apt-get autoclean
    sudo dpkg --purge --force-remove-reinstreq  phpmyadmin
    followed by a new install

    Code:
    $ sudo apt-get install  phpmyadmin
    Reading package lists... Done
    Building dependency tree       
    Reading state information... Done
    phpmyadmin is already the newest version (4:4.6.6-5).
    Starting pkgProblemResolver with broken count: 0
    Starting 2 pkgProblemResolver with broken count: 0
    Done
    0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
    1 not fully installed or removed.
    After this operation, 0 B of additional disk space will be used.
    Do you want to continue? [Y/n] 
    Setting up phpmyadmin (4:4.6.6-5) ...
    dbconfig-common: writing config to /etc/dbconfig-common/phpmyadmin.conf
    Not replacing deleted config file /etc/phpmyadmin/config-db.php
    dbconfig-common: flushing administrative password
    dpkg: error processing package phpmyadmin (--configure):
    installed phpmyadmin package post-installation script subprocess returned error exit status 10
    Errors were encountered while processing:
    phpmyadmin
    E: Sub-process /usr/bin/dpkg returned an error code (1)
    I even tried reinstalling dpkg ... and worse:
    Code:
    sudo apt-get install --reinstall dpkg
    and

    Code:
    sudo rm /var/lib/dpkg/info/*.postint
    since that the problem was with the post-installation script. All these operations followed suggestions at Ask Ubuntu or Stack Exchange.

    Now the only postinst scripts in /var/lib/dpkg/info are for dkpg and phpmyadmin, I guess due to my having reinstalled them.

    While phpmyadmin does seem to work, I am not happy seeing errors like this. What can that do to me in the future?
    'I must have a prodigious quantity of mind; it takes me as much as a week sometimes to make it up.' Mark Twain

    Comment

    Working...
    X