Testlink PHP Version upgrade

Keywords: TestLink - Linux - How to - Upgrade
Hi Team,
Currently i am using testlink version 1.9.19 in bitnami and the php version is 7.3.6.
We are getting the security vulnariablity cause of lower php version.

  1. Is it possible to upgrade only php module in bitnami testlink ? yes means what are all the steps we need to follow to achive the same.
  2. If its not possible to upgrade only php then how we will do the complete test link upgrade with the current data.

Kindly please do the needful to overcome our security vuln issue.

Hello @saranya.ranganayaki,

Please note that Bitnami Stacks are completely self-contained and run independently of the rest of the software or libraries installed on your system. For that reason, it is not possible to upgrade one component of the stack (in this case PHP).

You need to upgrade de full stack and then restore your files. You should launch a new cloud image with the latest version, and then migrate your data there.

I hope it helps

Hi David,
Thank you for the details!
When i try to do the data backup, by refereing the wiki i ran the below command
/opt/bitnami/mysql/bin/mysqldump -A -u root -p > backup.sql
while i ran this nothing happened.
Could you please guide to check, my data get back up properly or not?

Thanks in Advance!
Kind Regards,

Hi @saranya.ranganayaki,

It probably worked, could you check if the backup.sql has been created?


Hi David,

Yes it did.
Thank you for the details.

Hi David,

I have installed the new version of testlink 1.9.20 in my machine.
When i tried to moved mysql_old data to new version
I am unable to do start the mysql service via ctlscript.sh start

Kindly could you please share the steps to restore my data to new verison ?

Hello @saranya.ranganayaki,

What issues did you find starting MySQL service?

We have a Support Tool that will gather relevant information for us to analyze your configuration and logs. Could you please execute it on the machine where the stack is running by following the steps described in the guide below?

Hi David,

Here is my issue,
Previously we have used the Test-link version 1.9.19 (PHP 7.3.6) under the folder bitnami in our Linux machine.
I took the data backup in Bitnami folder (Test-link version 1.9.19 (PHP 7.3.6) by using below comment
/opt/bitnami/mysql/bin/mysqldump -A -u root -p > backup.sql
I have stopped the old bitnami folder cltscript.sh

I have moved Manually “bitnami-testlink-1.9.20-10-linux-x64-installer.run” to Linux server and installed the new version
I have changed my Env path from “PATH=/opt/bitnami/sqlite/bin:/opt/bitnami/php/bin:/opt/bitnami/mysql/bin:/opt/bitnami/letsencrypt/:/opt/bitnami/apache2/bin:/opt/bitnami/common/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
_=/usr/bin/env” to “PATH=/opt/testlink-1.9.20-10/sqlite/bin:/opt/testlink-1.9.20-10/php/bin:/opt/testlink-1.9.20-10/mysql/bin:/opt/testlink-1.9.20-10/letsencrypt/:/opt/testlink-1.9.20-10/apache2/bin:/opt/testlink-1.9.20-10/common/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin”

Have tried in below ways to transfer my old version data to new version( each step separately)
1.Have tried to copy old version mysql folder to new version
If i did this i am unable to start the mysql service.
2. Have tried to copy only data from old version mysql/data to new version mysql/data
In this also i am unable to start the mysql service
3.Have tried to copy old version config_db.inc.php to new version.
I am able to start the mysql service but again i get “1045-Access denied error ‘bn-testlink’@‘localhost’”

Now i revert back all the changes.
In our Linux server new version is up and running. Need a help on steps to copy Old version Database data to this new version ?

Hi david,

Oops i missed the code in previous message.

The support bundle was uploaded successfully to the Bitnami servers. Please copy the following code:


Hi @saranya.ranganayaki,

The table name should be bitnami_testlink. Can you login mysql and check the databases?

mysql -uroot -p
show databases;


Hi Michiel,

Yes, table name is ‘bitnami_testlink’ in new version.

Hi @saranya.ranganayaki,

Can you check if the database configuration in the config_db.inc.php file is correct? It should look like this:

define('DB_TYPE', 'mysql');
define('DB_HOST', '');
define('DB_NAME', 'bitnami_testlink');
define('DB_USER', 'bn_testlink');
define('DB_PASS', 'PASSWORD');


Please, click on :heart: if you think my answer was helpful

Yes configuration looks as below,

root@TP-TESTLINK01:/opt/testlink-1.9.20-10/php/bin# cat /opt/testlink-1.9.20-10/

<?php define('DB_TYPE', 'mysql'); define('DB_USER', 'bn_testlink'); define('DB_PASS', 'PASSWORD'); define('DB_HOST', 'localhost:3306'); define('DB_NAME', 'bitnami_testlink'); root@TP-TESTLINK01:/opt/testlink-1.9.20-10/php/bin# ![image](upload://fdSo8sB5edNDVKXl4wItEdeMECy.png)

Hi @saranya.ranganayaki,

Can you try changing:

 define('DB_HOST', 'localhost:3306');


define('DB_HOST', ''); 

And restart:

sudo /opt/bitnami/ctlscript.sh restart


Hi Michiel,

still i am getting the same error,

Hi @saranya.ranganayaki,

Can you try the following:

Login to mysql with root:

mysql -root -p

Then change the bn_testlink password to the same password as used in the db_config.php:


Please note that you need to replace DBCONFIG_PASSWORD with the actual password.

Then exit mysql and restart the services:

sudo /opt/bitnami/ctlscript.sh restart


hi Michiel,

I am unable to change the bn_testlink password.
when i ran the given command i am prompted to enter my password.
Have given my root password and also tried with Bitnami credentials.
Still i am getting the access denied error. Unable to place SET PASSWORD FOR ‘bn_testlink’ = PASSWORD(‘DBCONFIG_PASSWORD’); command.
Please guide me is there any other way to reset the bn_testlink password.

Hi @saranya.ranganayaki,

Can you try to reset the password following the steps mentioned in this guide?



Hi Michiel,

I have tried the ways given in the link, but still its not working.



Hi @saranya.ranganayaki,

You need create a script and add the MySQL command to it.

First stop mysql:

sudo /opt/bitnami/ctlscript.sh mysql stop

Then create the script:

nano  /tmp/mysql-init

Then add:


Save and exit nano ( Ctrl X and choose “Yes” to save the file and exit)

And then restart MySQL passing the script as a parameter:

sudo /opt/bitnami/mysql/bin/mysqld_safe --pid-file=/opt/bitnami/mysql/data/mysqld.pid --datadir=/opt/bitnami/mysql/data --init-file=/tmp/mysql-init --lower_case_table_names=1 2> /dev/null &

And remove the script as it contains sensitive data (the password)

sudo rm /tmp/mysql-init

Best regards,