• The Horde webmail has been deprecated. Its complete removal is scheduled for April 2025. For details and recommended actions, see the Feature and Deprecation Plan.
  • We’re working on enhancing the Monitoring feature in Plesk, and we could really use your expertise! If you’re open to sharing your experiences with server and website monitoring or providing feedback, we’d love to have a one-hour online meeting with you.

Resolved Application Piwik installation ends with error

Oliver Marugg

Basic Pleskian
Hi all

Ubuntu 16.04.1 (latest updates done), latest Onyx MU4 on VPS Virtuzzo (I guess) with current Plesk Migrator updates.

I tried to install Piwik through Applications installer as a custom install ended with an error.

I tested it with or without/within a subdomain, tried with different username/password (from weak to strong)/dbtable_prefixes up to 4 letters/dbnames, all have same behaviour. I did not test with other applications.

I anonymized the Username and PW and domain information:
Code:
Error: The following error has occurred during the installation of application:
Installation of Piwik at https://subdomain.domain.ext/ failed. Non-zero exit status returned by script. Output stream: 'PHP Fatal error:  Uncaught Error: Call to undefined function mysql_connect() in /opt/psa/var/apspackages/apscatalogXwUnEw.zip6feec709-2bad-b8/cache/scripts/db-util.php:66
Stack trace:
#0 /opt/psa/var/apspackages/apscatalogXwUnEw.zip6feec709-2bad-b8/cache/scripts/app-util.php(39): mysql_db_connect('localhost:3306', 'DBUSER', 'DBPASSWD', 'DBNAME')
#1 /opt/psa/var/apspackages/apscatalogXwUnEw.zip6feec709-2bad-b8/cache/scripts/app-util.php(13): import_sql_scripts_to_databases(Array, Array, Array, Array, Array, Array, Array, Array)
#2 /opt/psa/var/apspackages/apscatalogXwUnEw.zip6feec709-2bad-b8/cache/scripts/configure(100): configure(Array, Array, Array, Array, Array, Array, Array, Array, Array)
#3 {main}
  thrown in /opt/psa/var/apspackages/apscatalogXwUnEw.zip6feec709-2bad-b8/cache/scripts/db-util.php on line 66
'. Error stream: 'PHP Fatal error:  Uncaught Error: Call to undefined function mysql_connect() in /opt/psa/var/apspackages/apscatalogXwUnEw.zip6feec709-2bad-b8/cache/scripts/db-util.php:66
Stack trace:
#0 /opt/psa/var/apspackages/apscatalogXwUnEw.zip6feec709-2bad-b8/cache/scripts/app-util.php(39): mysql_db_connect('localhost:3306', 'DBUSER', 'DBPASSWD', 'DBNAME')
#1 /opt/psa/var/apspackages/apscatalogXwUnEw.zip6feec709-2bad-b8/cache/scripts/app-util.php(13): import_sql_scripts_to_databases(Array, Array, Array, Array, Array, Array, Array, Array)
#2 /opt/psa/var/apspackages/apscatalogXwUnEw.zip6feec709-2bad-b8/cache/scripts/configure(100): configure(Array, Array, Array, Array, Array, Array, Array, Array, Array)
#3 {main}
  thrown in /opt/psa/var/apspackages/apscatalogXwUnEw.zip6feec709-2bad-b8/cache/scripts/db-util.php on line 66

Greets Oliver
 
Try to run

# plesk bin aps --clear-cache

before aps installation and check how it goes on.
 
Hi @IgorG

I tried it with a aps cache clean several times and it ends with same error. But I looked deeper into the error message and I found that the form will add some dots instead of + to the password in one case (i tested that with copy of pw and direct typein). But it's also not working with other PWs. This time I show you the test passwords (!querUlAnt2016!+ AND Pe64wu$9) in just to show you what happens:

Code:
TYPEDIN/COPIED PASSWORD
#0 /opt/psa/var/apspackages/apscatalogXg4ART.zip1b8484cf-238c-f8/cache/scripts/app-util.php(39): mysql_db_connect('localhost:3306', 'DBUSER','!querUlAnt2016!...', 'DBNAME')


GENERATED PW
#0 /opt/psa/var/apspackages/apscatalogBAdfHF.zipfaaf0b4f-2a94-38/cache/scripts/app-util.php(39): mysql_db_connect('localhost:3306', 'DBUSER', 'Pe64wu$9', 'DBNAME')

Greets Oliver


Try to run

# plesk bin aps --clear-cache

before aps installation and check how it goes on.
 
Last edited:
I have tried to reproduce this issue on Onyx and chose the custom Piwik installation. I set admin and database user passwords as !querUlAnt2016!+++
Installation was finished successfully.
Have you tried to use default quick (not custom) installation?
 
Hello @Oliver Marugg,

Code:
Uncaught Error: Call to undefined function mysql_connect() in /opt/psa/var/apspackages/apscatalogXwUnEw.zip6feec709-2bad-b8/cache/scripts/db-util.php:66

Looks like this application install-script uses deprecated mysql driver. It was deprecated since PHP 5.5 and removed in PHP 7.0: http://php.net/manual/en/function.mysql-connect.php
As workaround I suggest you to select PHP 5.x at your domain's "PHP Settings" and check in phpinfo() that old mysql driver is enabled. If not it could be enabled at "Tools & Settings" -> "PHP Settings" -> Your domain's PHP version. After successful Piwik installation you could return back PHP Settings because it is only install-script issue, Piwik itself works normally without such mysql driver even on PHP 7.0.
 
Hi Kingsley
No currently not yet, I had another problem with Piwik (some pages lost a part of the url, why i do not know).
But for pecl geoip under 12.5 I had to switch back to php5.6 and that worked fine. But good news for you: With geoip 1.1.1 php7 is support according to their website.
Have a nice day
Oliver
 
Hi Kingsley
No currently not yet, I had another problem with Piwik (some pages lost a part of the url, why i do not know).
But for pecl geoip under 12.5 I had to switch back to php5.6 and that worked fine. But good news for you: With geoip 1.1.1 php7 is support according to their website.
Have a nice day
Oliver

alright thanks
 
Back
Top