[ZBX-10132] customized Timeout parameter for zabbix java gateway is not applied in official zabbix packages Created: 2015 Dec 03  Updated: 2018 Aug 06  Resolved: 2018 Aug 06

Status: Closed
Project: ZABBIX BUGS AND ISSUES
Component/s: Installation (I), Java gateway (J)
Affects Version/s: None
Fix Version/s: 2.2.13rc1, 2.4.8rc1, 3.0.0rc2

Type: Incident report Priority: Blocker
Reporter: Oleksii Zagorskyi Assignee: Unassigned
Resolution: Duplicate Votes: 0
Labels: packaging, timeout
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Duplicate
duplicates ZBX-13376 Enabling jmx and TCP timeout in Java ... Closed

 Description   

After ZBX-8839 in startup.sh script these lines were added:

if [ -n "$TIMEOUT" ]; then
	ZABBIX_OPTIONS="$ZABBIX_OPTIONS -Dzabbix.timeout=$TIMEOUT -Dsun.rmi.transport.tcp.responseTimeout=${TIMEOUT}000"
fi

but they were not included to init script in all official packages at http://repo.zabbix.com/ disregarding that zabbix_java_gateway.conf was updated correctly.

It means that the customized Timeout parameter in configuration file actually doesn't have affect if gateway was installed from packages.

Default timeout in java code is 3 seconds and will be applied, but it's related to "threads handling" only.

Affected version - are versions from Fixed in the ZBX-8839



 Comments   
Comment by Oleksii Zagorskyi [ 2015 Dec 03 ]

Kodai, take a look on this

Comment by Oleksii Zagorskyi [ 2015 Dec 03 ]

Should be probably fixed together with ZBX-10105

Comment by Oleksii Zagorskyi [ 2015 Dec 04 ]

(1)
After discussion with asaveljevs we understood that even if gateway installed from sources or from other distributions (unlikely, but still: Debian/testing (init.d only, not systemd variant), OpenSuSE still have packaged zabbix v2.2.9) and if the Timeout parameter is commented out in configuration file - then it will not be passed to JVM with:

-Dsun.rmi.transport.tcp.responseTimeout=${TIMEOUT}000

which is bad and should be fixed/improved.

So probably wait upstream changes to include them in packages too.
I'll leave here suggestions after some my tests agreed with asaveljevs

Comment by Kodai Terashima [ 2016 Jan 28 ]

I updated systemd service file under ZBX-10105, but it follows startup.sh in source. Still, Timeout parameter is not applied if TIMEOUT line is commented out in configuration file.

What do you think to add TIMEOUT=3 for default value in top of the startup.sh?

Comment by Oleksii Zagorskyi [ 2016 Jan 28 ]

I think uncommenting TIMEOUT=3 in conf file will be correct decision for now.

For example when I investigated Debian official packages in ZBX-4987 I saw that they did it already (defined "Environment=TIMEOUT=3" before reading the conf file where settings may be redefined).

Comment by Kodai Terashima [ 2016 Feb 12 ]

Fixed in 2.2.12rc1, 2.4.8rc1, 3.0.0rc2.

Comment by Oleksii Zagorskyi [ 2016 Feb 12 ]

As it's still actual for installation from sources, see (1), REOPENED for now.

Comment by Oleksii Zagorskyi [ 2018 Aug 06 ]

Ok, let's close this as duplicate of  ZBX-13376

Fix version in current issue should be ignored.

Generated at Fri Apr 26 08:42:07 EEST 2024 using Jira 9.12.4#9120004-sha1:625303b708afdb767e17cb2838290c41888e9ff0.