Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[dev.icinga.com #10744] build of icinga2 with gcc 4.4.7 segfaulting with ido #3728

Closed
icinga-migration opened this issue Nov 28, 2015 · 7 comments
Labels
area/db-ido Database output bug Something isn't working
Milestone

Comments

@icinga-migration
Copy link

This issue has been migrated from Redmine: https://dev.icinga.com/issues/10744

Created by pschoenfeld on 2015-11-28 16:48:22 +00:00

Assignee: gbeutner
Status: Resolved (closed on 2015-11-30 07:20:04 +00:00)
Target Version: 2.4.2
Last Update: 2015-12-08 14:39:49 +00:00 (in Redmine)

Icinga Version: 2.4.1
Backport?: Already backported
Include in Changelog: 1

Problem:
icinga2 crashing with ido enabled. icinga2 was compiled manually (on centos 6.7 with gcc in base)

Build params were:

make -DCMAKE_INSTALL_PREFIX=/opt/icinga2 -DICINGA2_USER=icinga -DICINGA2_GROUP=icinga -DICINGA_COMMAND_GROUP=apache -DICINGA2_GIT_VERSION_INFO=false -DCMAKE_VERBOSE_MAKEFILE=ON -DBoost_NO_BOOST_CMAKE=ON

gdb output:

[2015-11-29 01:21:34 +0900] critical/IdoMysqlConnection: Error "Duplicate entry '0' for key 'object_id'" when executing query "INSERT INTO icinga_hoststatus (current_notification_number, last_notification, next_notification) VALUES ('1', FROM_UNIXTIME(1448727693), FROM_UNIXTIME(1448729493));COMMIT;BEGIN"
[2015-11-29 01:21:34 +0900] critical/IdoMysqlConnection: Exception during database operation: Verify that your database is operational!
[2015-11-29 01:21:38 +0900] information/IdoMysqlConnection: MySQL IDO instance id: 1 (schema version: '1.14.0')

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 0x7fffdb33d700 (LWP 27375)]
0x00007ffff5037258 in std::basic_string, std::allocator >::basic_string(std::basic_string, std::allocator > const&) ()
   from /usr/lib64/libstdc++.so.6
Missing separate debuginfos, use: debuginfo-install boost-program-options-1.41.0-27.el6.x86_64 boost-regex-1.41.0-27.el6.x86_64 boost-system-1.41.0-27.el6.x86_64 boost-thread-1.41.0-27.el6.x86_64 glibc-2.12-1.166.el6_7.3.x86_64 keyutils-libs-1.4-5.el6.x86_64 krb5-libs-1.10.3-42.el6.x86_64 libcom_err-1.41.12-22.el6.x86_64 libedit-2.11-4.20080712cvs.1.el6.x86_64 libgcc-4.4.7-16.el6.x86_64 libicu-4.2.1-12.el6.x86_64 libselinux-2.0.94-5.8.el6.x86_64 libstdc++-4.4.7-16.el6.x86_64 mysql-libs-5.1.73-5.el6_6.x86_64 ncurses-libs-5.7-4.20090207.el6.x86_64 nss-softokn-freebl-3.14.3-23.el6_7.x86_64 openssl-1.0.1e-42.el6.x86_64 zlib-1.2.3-29.el6.x86_64

--- FULL BACKTRACE BELOW ---

#0  0x00007ffff5037258 in std::basic_string, std::allocator >::basic_string(std::basic_string, std::allocator > const&) ()

from /usr/lib64/libstdc**.so.6
No symbol table info available.

#1  0x00007fffdbd4febd in String (this=) at /vagrant/buildroot/icinga2-2.4.1/lib/base/string.hpp:77

No locals.

#2  icinga::DbType::GetTable (this=) at /vagrant/buildroot/icinga2-2.4.1/lib/db_ido/dbtype.cpp:41

No locals.

#3  0x00007ffff0434f60 in icinga::IdoMysqlConnection::FillIDCache (this=0x7fffd0019100, type=...) at /vagrant/buildroot/icinga2-2.4.1/lib/db_ido_mysql/idomysqlconnection.cpp:920

query = {static NPos = 18446744073709551615, m_Data = "Zone"}
result = {px = 0x7fffdb33ada0, pn = {pi_ = 0x7ffff043a0b7}}
row = {px = 0x7fffdb33ad60}

#4  0x00007fffdbd525c1 in icinga::DbConnection::PrepareDatabase (this=0x7fffd0019100) at /vagrant/buildroot/icinga2-2.4.1/lib/db_ido/dbconnection.cpp:424

type = 0x7fffb801abd0 _foreach_continue423 = false _foreach_col423 = 0x7fffdb33ae20

#5  0x00007ffff0433104 in icinga::IdoMysqlConnection::Reconnect (this=0x7fffd0019100) at /vagrant/buildroot/icinga2-2.4.1/lib/db_ido_mysql/idomysqlconnection.cpp:345

ihost = {static NPos = 18446744073709551615, m_Data = "localhost"}
iuser = {static NPos = 18446744073709551615, m_Data = "root"}
db =
port = -617364288
result = {px = 0x7fffb801a960, pn = {pi_ = 0x7fffb801aa10}}
my_endpoint = {px = 0x0}
passwd = 0x7fffdb33c4b0 "H\251\001\270\377\177"
row = {px = 0x7fffb8007480}
dbVersionName = {static NPos = 18446744073709551615, m_Data = "idoutils"}
q1buf =
active_dbobjs = std::vector of length 0, capacity 0
ipasswd = {static NPos = 18446744073709551615, m_Data = "root"}
socket_path =
user =

PRETTY_FUNCTION = "void icinga::IdoMysqlConnection::Reconnect()"
currentContextFrame = {}
idb = {static NPos = 18446744073709551615, m_Data = "icinga"}
host = 0x7fffdb33c4a0 "\210h\001\270\377\177"
version = {static NPos = 18446744073709551615, m_Data = "1.14.0"}
instanceName = {static NPos = 18446744073709551615, m_Data = "default"}
reconnect = 16
isocket_path = {static NPos = 18446744073709551615, m_Data = ""}

#6  0x00007ffff717d0c9 in operator() (this=0x7fffd00193c0) at /usr/include/boost/function/function_template.hpp:1013

No locals.

#7  icinga::WorkQueue::WorkerThreadProc (this=0x7fffd00193c0) at /vagrant/buildroot/icinga2-2.4.1/lib/base/workqueue.cpp:211

task = {<boost::function0> = {boost::function_base = {vtable = 0x7ffff065d3f1, functor = {obj_ptr = 0x7ffff0431c90, type = {type = 0x7ffff0431c90, const_qualified = false,
volatile_qualified = false}, func_ptr = 0x7ffff0431c90 icinga::IdoMysqlConnection::Reconnect(), bound_memfunc_ptr = {memfunc_ptr = (void (boost::detail::function::X::*)(
boost::detail::function::X *, int)) 0x7ffff0431c90 icinga::IdoMysqlConnection::Reconnect(), obj_ptr = 0x7fffd0019100}, obj_ref = {obj_ptr = 0x7ffff0431c90, is_const_qualified = false,
is_volatile_qualified = false}, data = -112 '\220'}}, static args = , static arity = }, }
idbuf =
lock = {m = 0x7fffd00193d0, is_locked = false}

#8  0x00007ffff7bd2d47 in thread_proxy () from /usr/lib64/libboost_thread-mt.so.5

No symbol table info available.

#9  0x00007ffff4556a51 in start_thread () from /lib64/libpthread.so.0

No symbol table info available.

#10 0x00007ffff485493d in clone () from /lib64/libc.so.6

No symbol table info available.

printing \*this in frame 2 is not particular helpful:
(gdb) p *this
value has been optimized out

Changesets

2015-11-30 07:16:39 +00:00 by (unknown) 8269556

Disable --std=c++11 for ancient GCC versions

fixes #10744

2015-12-08 14:39:23 +00:00 by (unknown) 91c2a59

Disable --std=c++11 for ancient GCC versions

fixes #10744

Relations:

@icinga-migration
Copy link
Author

Updated by gbeutner on 2015-11-28 16:50:13 +00:00

  • Description updated

@icinga-migration
Copy link
Author

Updated by gbeutner on 2015-11-30 07:17:32 +00:00

  • Status changed from New to Assigned
  • Assigned to set to gbeutner
  • Target Version set to 2.5.0

@icinga-migration
Copy link
Author

Updated by Anonymous on 2015-11-30 07:20:05 +00:00

  • Status changed from Assigned to Resolved
  • Done % changed from 0 to 100

Applied in changeset 8269556.

@icinga-migration
Copy link
Author

Updated by gbeutner on 2015-11-30 11:38:06 +00:00

Can you please check whether this fixes your problem?

@icinga-migration
Copy link
Author

Updated by formorer on 2015-12-01 08:17:59 +00:00

gunnarbeutner wrote:

Can you please check whether this fixes your problem?
Looks good, we tested icinga2 over night and didn't had another segfault.

Thanks for the patch!

@icinga-migration
Copy link
Author

Updated by mfriedrich on 2015-12-08 14:39:49 +00:00

  • Target Version changed from 2.5.0 to 2.4.2
  • Backport? changed from Not yet backported to Already backported

@icinga-migration
Copy link
Author

Updated by mfriedrich on 2015-12-11 11:17:44 +00:00

  • Relates set to 10826

@icinga-migration icinga-migration added bug Something isn't working area/db-ido Database output labels Jan 17, 2017
@icinga-migration icinga-migration added this to the 2.4.2 milestone Jan 17, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/db-ido Database output bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant