So this mysql instance sure has a lot of queries, took me a while to narrow
down to the queries in question. Basically it looks like there are two
separate queries:
104 Connect icinga@localhost on icinga
104 Query SET NAMES 'utf8'
104 Query SELECT n.session_entry_id AS
n__session_entry_id, n.session_id AS n__session_id, n.session_name AS
n__session_name, n.session_data AS n__session_data, n.session_checksum AS
n__session_checksum, n.session_created AS n__session_created,
n.session_modified AS n__session_modified FROM nsm_session n WHERE
(n.session_id = '883j7gf5qoki622jon6t8h0k62' AND n.session_name = 'icinga-web')
104 Query SELECT n.upref_id AS n__upref_id,
n.upref_user_id AS n__upref_user_id, n.upref_val AS n__upref_val,
n.upref_longval AS n__upref_longval, n.upref_key AS n__upref_key,
n.upref_created AS n__upref_created, n.upref_modified AS n__upref_modified FROM
nsm_user_preference n WHERE (n.upref_user_id = '3' AND n.upref_key =
'org.icinga.appkit.locale') LIMIT 1
105 Connect icinga@localhost on icinga
104 Query SELECT n.upref_id AS n__upref_id,
n.upref_user_id AS n__upref_user_id, n.upref_val AS n__upref_val,
n.upref_longval AS n__upref_longval, n.upref_key AS n__upref_key,
n.upref_created AS n__upref_created, n.upref_modified AS n__upref_modified FROM
nsm_user_preference n WHERE (n.upref_user_id = '3' AND n.upref_key =
'org.icinga.grid.refreshTime') LIMIT 1
104 Query SELECT n.upref_id AS n__upref_id,
n.upref_user_id AS n__upref_user_id, n.upref_val AS n__upref_val,
n.upref_longval AS n__upref_longval, n.upref_key AS n__upref_key,
n.upref_created AS n__upref_created, n.upref_modified AS n__upref_modified FROM
nsm_user_preference n WHERE (n.upref_user_id = '3' AND n.upref_key =
'org.icinga.grid.pagerMaxItems') LIMIT 1
104 Query SELECT n.principal_id AS n__principal_id,
n.principal_user_id AS n__principal_user_id, n.principal_role_id AS
n__principal_role_id, n.principal_type AS n__principal_type,
n.principal_disabled AS n__principal_disabled FROM nsm_principal n LEFT JOIN
nsm_role n2 ON n.principal_role_id = n2.role_id LEFT JOIN nsm_user_role n3 ON
n2.role_id = n3.usro_role_id WHERE (n3.usro_user_id = '3' OR
n.principal_user_id = '3')
104 Query SELECT n.target_id AS n__target_id,
n.target_name AS n__target_name FROM nsm_target n INNER JOIN
nsm_principal_target n2 ON n.target_id = n2.pt_target_id WHERE
(n2.pt_principal_id IN ('2', '3', '4', '7'))
104 Query SELECT n.pt_id AS n__pt_id, n.pt_principal_id
AS n__pt_principal_id, n.pt_target_id AS n__pt_target_id, n2.tv_pt_id AS
n2__tv_pt_id, n2.tv_key AS n2__tv_key, n2.tv_val AS n2__tv_val FROM
nsm_principal_target n INNER JOIN nsm_target_value n2 ON n.pt_id = n2.tv_pt_id
WHERE (n.pt_principal_id IN ('2', '3', '4', '7') AND n.pt_target_id = '8')
104 Query SELECT n.pt_id AS n__pt_id, n.pt_principal_id
AS n__pt_principal_id, n.pt_target_id AS n__pt_target_id, n2.tv_pt_id AS
n2__tv_pt_id, n2.tv_key AS n2__tv_key, n2.tv_val AS n2__tv_val FROM
nsm_principal_target n INNER JOIN nsm_target_value n2 ON n.pt_id = n2.tv_pt_id
WHERE (n.pt_principal_id IN ('2', '3', '4', '7') AND n.pt_target_id = '13')
104 Query SELECT n.pt_id AS n__pt_id, n.pt_principal_id
AS n__pt_principal_id, n.pt_target_id AS n__pt_target_id, n2.tv_pt_id AS
n2__tv_pt_id, n2.tv_key AS n2__tv_key, n2.tv_val AS n2__tv_val FROM
nsm_principal_target n INNER JOIN nsm_target_value n2 ON n.pt_id = n2.tv_pt_id
WHERE (n.pt_principal_id IN ('2', '3', '4', '7') AND n.pt_target_id = '9')
104 Query SELECT n.pt_id AS n__pt_id, n.pt_principal_id
AS n__pt_principal_id, n.pt_target_id AS n__pt_target_id, n2.tv_pt_id AS
n2__tv_pt_id, n2.tv_key AS n2__tv_key, n2.tv_val AS n2__tv_val FROM
nsm_principal_target n INNER JOIN nsm_target_value n2 ON n.pt_id = n2.tv_pt_id
WHERE (n.pt_principal_id IN ('2', '3', '4', '7') AND n.pt_target_id = '10')
104 Query SELECT n.pt_id AS n__pt_id, n.pt_principal_id
AS n__pt_principal_id, n.pt_target_id AS n__pt_target_id, n2.tv_pt_id AS
n2__tv_pt_id, n2.tv_key AS n2__tv_key, n2.tv_val AS n2__tv_val FROM
nsm_principal_target n INNER JOIN nsm_target_value n2 ON n.pt_id = n2.tv_pt_id
WHERE (n.pt_principal_id IN ('2', '3', '4', '7') AND n.pt_target_id = '11')
104 Query SELECT n.pt_id AS n__pt_id, n.pt_principal_id
AS n__pt_principal_id, n.pt_target_id AS n__pt_target_id, n2.tv_pt_id AS
n2__tv_pt_id, n2.tv_key AS n2__tv_key, n2.tv_val AS n2__tv_val FROM
nsm_principal_target n INNER JOIN nsm_target_value n2 ON n.pt_id = n2.tv_pt_id
WHERE (n.pt_principal_id IN ('2', '3', '4', '7') AND n.pt_target_id = '15')
104 Query SELECT DISTINCT n.target_id AS n__target_id,
n.target_name AS n__target_name, n.target_description AS n__target_description,
n.target_class AS n__target_class, n.target_type AS n__target_type FROM
nsm_target n INNER JOIN nsm_principal_target n2 ON n.target_id =
n2.pt_target_id WHERE (n2.pt_principal_id IN ('2', '3', '4', '7'))
105 Query select distinct h.icon_image AS
HOST_ICON_IMAGE,i.instance_name AS INSTANCE_NAME,oh.object_id AS
HOST_OBJECT_ID,oh.name1 AS HOST_NAME,h.alias AS HOST_ALIAS,h.display_name AS
HOST_DISPLAY_NAME,hs.current_state AS HOST_CURRENT_STATE,hs.last_check AS
HOST_LAST_CHECK,hs.last_state_change AS
HOST_LAST_STATE_CHANGE,hs.current_check_attempt AS
HOST_CURRENT_CHECK_ATTEMPT,hs.output AS HOST_OUTPUT,hs.max_check_attempts AS
HOST_MAX_CHECK_ATTEMPTS,h.instance_id AS
HOST_INSTANCE_ID,(hs.has_been_checked-hs.should_be_scheduled)*-1>0 AS
HOST_IS_PENDING from icinga_objects oh inner join icinga_hosts h on
h.host_object_id = oh.object_id inner join icinga_hoststatus hs on
hs.host_object_id = oh.object_id inner join icinga_instances i on
i.instance_id = h.instance_id where
oh.objecttype_id = 1 and h.config_type=1 order by oh.name1
ASC,hs.last_check DESC limit 0,30
104 Query START TRANSACTION
104 Query COMMIT
104 Quit
105 Quit
Connection 104 seems to be all about the session/permissions, most of them
return data, and the very *last* query on 104 returns the following target_name
values:
icinga.user
appkit.api.access
appkit.admin.groups
appkit.admin.users
appkit.admin
icinga.cronk.category.admin
So basically everything. That last query (105) is the one I'm familiar with in
the json output, and it returns 30 records all with lots of data.
I'm trying to keep it simple for now, so it literally is icinga/icinga/icinga
all the way. :) Both icinga and icinga-web both dump into the same 'icinga'
DB. So the important part looks like:
<ae:parameter name="config_database">icinga</ae:parameter>
<ae:parameter name="config_user">icinga</ae:parameter>
<ae:parameter name="config_password">icinga</ae:parameter>
<ae:parameter name="config_table_prefix">icinga_</ae:parameter>
<ae:parameter name="config_config_type">1</ae:parameter>
I'm sure I cleared the cache yesterday, but just did it again:
Deleting config cache (83 files) ... ok
Deleting additionak cache dirs ... ok
Restarted icinga and apache just in case, same thing.
icingaApi.log doesn't have much in the way of errors, it does have a bunch of:
2011-07-19T22:58:32+00:00 - [WARNING] Column STATEHISTORY_CURRENT_CHECK_ATTEMPT
is too long, will be COL_YMZQTUIBRHJEONXGSFPCALDVK in the query.
2011-07-19T22:58:32+00:00 - [WARNING] Column STATEHISTORY_MAX_CHECK_ATTEMPTS is
too long, will be COL_SDLMZYHBGKQERPXNJATUOFIVC in the query.
But that isn't exactly recent.
Thanks,
Jason
From: Russell Van Tassell [mailto:[email protected]]
Sent: Tuesday, July 19, 2011 7:00 PM
To: [email protected]
Subject: Re: [icinga-users] Icinga-web blank result window
Jason -
Ah... Now I remember another issue I had at one point. Is there any chance you
changed the default database/mysql users or passwords for either the "icinga"
or "icinga-web" process?
If so, did you reset them in either app/modules/Web/config/icinga-io.xml or
app/modules/Web/config/icinga-io.site.xml?
Once you do that, you'll also need to clear the cache (sudo bin/clearcache.sh)
and try again.
You should also check the API log for errors (something like
/usr/local/icinga/share/icinga-api/log/icingaApi.log).
Hope that might help...
Russell
------------------------------------------------------------------------------
10 Tips for Better Web Security
Learn 10 ways to better secure your business today. Topics covered include:
Web security, SSL, hacker attacks & Denial of Service (DoS), private keys,
security Microsoft Exchange, secure Instant Messaging, and much more.
http://www.accelacomm.com/jaw/sfnl/114/51426210/
_______________________________________________
icinga-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/icinga-users