[ZBX-7578] Template Import fail with Undefined variable: graph [conf.import.php:130 ? CConfigurationImport->import() Created: 2013 Dec 23  Updated: 2017 May 30  Resolved: 2014 Jan 09

Status: Closed
Project: ZABBIX BUGS AND ISSUES
Component/s: Frontend (F), Server (S)
Affects Version/s: 2.2.1
Fix Version/s: 2.2.2rc1, 2.3.0

Type: Incident report Priority: Major
Reporter: Stefan Sabolowitsch Assignee: Unassigned
Resolution: Fixed Votes: 0
Labels: import
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

FreeBSD 9.2 4GB RAM / 4-core


Attachments: XML File zbx_export_templates_SSG550_org.xml    

 Description   

If I want to import a working template v2.0.9, i get this error message:
Undefined variable: graph [conf.import.php:130 ? CConfigurationImport->import() ? CConfigurationImport->processGraphs() ? CAPIObject->create() ? CAPIObject->__call() ? czbxrpc::call() ? czbxrpc::callAPI() ? call_user_func() ? CGraphGeneral->create() ? CGraph->validateCreate() ? CGraph->validateItems() in /usr/local/www/zabbix22/api/classes/CGraph.php:721]
Cannot add a non-numeric item "RFC1213-MIB::tcpCurrEstab.0" to graph "".

If i delete this item from this template, a new error message will generate.
array_flip(): Can only flip STRING and INTEGER values! [conf.import.php:130 ? CConfigurationImport->import() ? CConfigurationImport->processGraphs() ? CAPIObject->create() ? CAPIObject->__call() ? czbxrpc::call() ? czbxrpc::callAPI() ? call_user_func() ? CGraphGeneral->create() ? CGraph->validateCreate() ? CGraph->validateItems() ? CItem->get() ? dbConditionInt() ? array_flip() in /usr/local/www/zabbix22/include/db.inc.php:1047]
No permissions to referred object or it does not exist!



 Comments   
Comment by Stefan Sabolowitsch [ 2014 Jan 04 ]

Any chance here to solve this problem ?
I need this Template for our netscreen devices.

thx
Stefan

Comment by Eduards Samersovs (Inactive) [ 2014 Jan 08 ]

Fixed in development branch svn://svn.zabbix.com/branches/dev/ZBX-7578

Comment by Stefan Sabolowitsch [ 2014 Jan 08 ]

Eduards, thanks for patching.
But can i use only this ZBX-7578-frontend on my v2.2.1 Version and not this complete ZBX-7578-2.3.0 Alpha ?

Eduards Yes, it will be fixed in 2.2.2rc1 and trunk

Comment by Stefan Sabolowitsch [ 2014 Jan 08 ]

also in rev41348 2.2.2.rc1 or wait until 12:00UTC to next build

Comment by richlv [ 2014 Jan 08 ]

this fix has not been merged to 2.2 branch or trunk- if you would like to test it right away, you would have to check out from svn : https://www.zabbix.org/wiki/Get_Zabbix

Comment by Stefan Sabolowitsch [ 2014 Jan 08 ]

OK, i test now with frontend from svn://svn.zabbix.com/branches/dev/ZBX-7578 with server/agent from rev41348 2.2.2.rc1
change for testing in defines.inc.php ZABBIX_DB_VERSION from 2030000 to 2020000

but i get always this error:

 
Cannot add a non-numeric item "RFC1213-MIB::tcpCurrEstab.0" to graph "Network: RFC1213 - TCP".
Comment by Stefan Sabolowitsch [ 2014 Jan 08 ]

get with this patch this error message:

 
Cannot add a non-numeric item "RFC1213-MIB::tcpCurrEstab.0" to graph "Network: RFC1213 - TCP".

Eduards You can use only numeric items in graphs.

Comment by Stefan Sabolowitsch [ 2014 Jan 08 ]

OK, why this works on v2.0.9 and the export is here successfully ?

Eduards Sorry, non-numeric items cannot be displayed in the graph, so in ZBX-6866 we add a validation on it.

Comment by Oleg Egorov (Inactive) [ 2014 Jan 08 ]

TESTED

Comment by Stefan Sabolowitsch [ 2014 Jan 08 ]

i can now confirm without this non-numeric items this patch will work.
You can close this ticket.
thanks for this fast patching here.

Comment by Eduards Samersovs (Inactive) [ 2014 Jan 08 ]

Fixed in versions 2.3.0 (trunk) r.41378, 2.2.2rc1 r.41377

Comment by Pavels Jelisejevs (Inactive) [ 2014 Jan 09 ]

(1) Found a minor API regression. According to the docs, the "color" parameter for graph items must be mandatory. It's currently not and this request works:

{
    "name": "MySQL bandwidth",
    "width": 900,
    "height": 200,
    "gitems": [
        {
            "itemid": "23287"
        }
    ]
}

Eduards Fixed in development branch svn://svn.zabbix.com/branches/dev/ZBX-7578

jelisejev TESTED.

Comment by Pavels Jelisejevs (Inactive) [ 2014 Jan 09 ]

TESTED.

Comment by Eduards Samersovs (Inactive) [ 2014 Jan 09 ]

Fixed in versions 2.3.0 (trunk) r.41399, 2.2.2rc1 r.41398

Generated at Sat Apr 20 12:51:02 EEST 2024 using Jira 9.12.4#9120004-sha1:625303b708afdb767e17cb2838290c41888e9ff0.