segmentation fault on ubuntu 16.04 LTS

Post support questions that directly relate to Linux/Unix operating systems.

Moderators: Developers, Moderators

Post Reply
cherouvim
Posts: 1
Joined: Fri Apr 22, 2016 7:10 am

segmentation fault on ubuntu 16.04 LTS

Post by cherouvim »

Hello

On a vanilla ubuntu 16.04LTS which I just got from http://releases.ubuntu.com/16.04/ I do apt-get install cacti.

After I install (I get an "empty mysql port" warning during configuration by dbconfig-common, which I ignore) running cacti via apache or using its CLI scripts, gives me a segmentation fault. The dmesg output is:

Code: Select all

[ 1050.601708] php[14916]: segfault at 7ffc283ebff8 ip 000055ae36814f06 sp 00007ffc283ec000 error 6 in php7.0[55ae365f4000+3a8000]
I even downgraded php from 7 to 5.6 and still got segfault:

Code: Select all

[  773.887110] add_device.php[16973]: segfault at 7ffd2bd0ffa8 ip 000055a69e9859c8 sp 00007ffd2bd0ffa0 error 6 in php5.6[55a69e792000+3b7000]
Where should I look at to solve this?

Note that I pinpointed the php line which causes this. It's /usr/share/cacti/site/include/plugins.php:32

Code: Select all

$oldplugins = read_config_option('oldplugins');
thanks
rohrej
Posts: 1
Joined: Thu May 05, 2016 11:16 pm

Re: segmentation fault on ubuntu 16.04 LTS

Post by rohrej »

Having the exact same issue, hoping for an answer.
User avatar
micke2k
Cacti User
Posts: 261
Joined: Wed Feb 03, 2016 3:38 pm

Re: segmentation fault on ubuntu 16.04 LTS

Post by micke2k »

Can you try Php 5.4 ?
jcrzj
Posts: 1
Joined: Wed May 11, 2016 4:29 am

Re: segmentation fault on ubuntu 16.04 LTS

Post by jcrzj »

I get it:

1. Replace $database_port="" with $database_port="3306" (or whatever you want) in /etc/cacti/debian.php
2. Replace dbc_dbport='' with dbc_dbport='3306' (or whatever you want) in /etc/dbconfig-common/cacti.conf

After this, you get other errors (like me about status_fail_date). You can correct them this way:

3. Edit file /usr/share/cacti/conf_templates/cacti.sql and replace "0000-00-00" with "2016-05-11" (i.e.). REPLACE ALL entries you find!!!.

At last, retry installation.

Regards
butha
Posts: 1
Joined: Thu May 12, 2016 7:03 pm

Re: segmentation fault on ubuntu 16.04 LTS

Post by butha »

To fix error about status_fail_date do this:
remove NO_ZERO_IN_DATE,NO_ZERO_DATE from database mode
mysql -u root -p
Enter password:
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 97207
Server version: 5.7.12-0ubuntu1 (Ubuntu)

Copyright (c) 2000, 2016, Oracle and/or its affiliates. All rights reserved.

Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

mysql> SELECT @@GLOBAL.sql_mode;
+-------------------------------------------------------------------------------------------------------------------------------------------+
| @@GLOBAL.sql_mode |
+-------------------------------------------------------------------------------------------------------------------------------------------+
| ONLY_FULL_GROUP_BY,STRICT_TRANS_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION |
+-------------------------------------------------------------------------------------------------------------------------------------------+
1 row in set (0.00 sec)

mysql>
mysql> SET GLOBAL sql_mode = 'ONLY_FULL_GROUP_BY,STRICT_TRANS_TABLES,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION';
Query OK, 0 rows affected, 1 warning (0.00 sec)

mysql>
mysql> SELECT @@GLOBAL.sql_mode;
+--------------------------------------------------------------------------------------------------------------+
| @@GLOBAL.sql_mode |
+--------------------------------------------------------------------------------------------------------------+
| ONLY_FULL_GROUP_BY,STRICT_TRANS_TABLES,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION |
+--------------------------------------------------------------------------------------------------------------+
1 row in set (0.00 sec)

mysql> exit
Bye
Post Reply

Who is online

Users browsing this forum: No registered users and 3 guests