[CDash] Upgrading from 2.0.2 to 2.4.0

François Bertel fbopensource at gmail.com
Fri Jul 14 01:27:18 UTC 2017

Hi Zack,

I figured out that the php-mbstring package was not installed on my Ubuntu.
That fixed the issue. Even after upgrading the DB I still see the warning

Here are the details of my investigation:

1. I checked all the write permissions you listed and they were all correct.
2. I did not find anything relevant in /var/log/syslog. However, I saw the
following error in /var/log/apache2/error.log (I masked the IP address and
port with *): Call to undefined function mb_detect_encoding()

[:error] [pid 3726] [client *.*.*.*:*] PHP Fatal error:  Uncaught Error:
Call to undefined function mb_detect_encoding() in
/var/www/CDashRoot/include/common.php:139\nStack trace:\n#0
/var/www/CDashRoot/include/common.php(1838): add_XML_value('cssfile',
'css/cdash.css')\n#2 /var/www/CDashRoot/include/login_functions.php(383):
begin_XML_for_XSLT()\n#3 /var/www/CDashRoot/public/login.php(61):
LoginForm('')\n#4 /var/www/CDashRoot/public/user.php(20):
include('/var/www/CDashR...')\n#5 {main}\n  thrown in
/var/www/CDashRoot/include/common.php on line 139, referer: http://

Using grep in /var/www/CDashRoot for mb_detect_encoding gave the following
$ find . -name '*' -print0 | xargs -r -0 grep -n mb_detect_encoding | less

Binary file ./composer.phar matches
./public/install.php:50:if (function_exists('mb_detect_encoding') ===
false) {
./include/common.php:139:    if (mb_detect_encoding($str, 'UTF-8', true)
=== false) {
./include/common.php:2072:        if (function_exists('mb_detect_encoding')
./include/common.php:2073:            mb_detect_encoding($value, 'UTF-8',
true) === false

Searching around, I found that this php function is provided by the
php-mbstring package, which was not installed on my Ubuntu machine.

3. I installed the php-mbstring package and restarted apache2.
4. I went back the CDash main page and was able to login as administrator!
I was able to go the maintenance page and clicked on the push button at the
bottom "Upgrade CDash" . Now the CDash maintenance page says:
*Current CDash database schema: *2.5
Upgrading tables:
Applying 2.6 patches:

*CDash Upgrade Successful.*
5. However, if I go back again the CDash homepage, I have the same red
message: "The current database schema doesn't match the version of CDash
you are running, upgrade your database structure in the
Administration/CDash maintenance panel of CDash"

Of course the weird thing is I installed 2.4.0 but the maintenance page
says current schema 2.5 and there is also this line "Applying 2.6 patches".
Each time a different version number. That could explain why I am still
seeing this message. I did not find anything new the apache2 log this time.
Any idea?


François Bertel
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/cdash/attachments/20170713/96106fbf/attachment-0001.htm>

More information about the CDash mailing list