[ZBX-5609] change default disk check in freebsd from hda to da0 Created: 2012 Sep 24 Updated: 2017 May 30 Resolved: 2012 Oct 09 |
|
Status: | Closed |
Project: | ZABBIX BUGS AND ISSUES |
Component/s: | Agent (G) |
Affects Version/s: | 2.1.0 |
Fix Version/s: | 2.0.4rc1, 2.1.0 |
Type: | Incident report | Priority: | Minor |
Reporter: | Sean Chittenden | Assignee: | Unassigned |
Resolution: | Fixed | Votes: | 0 |
Labels: | agent, freebsd | ||
Remaining Estimate: | Not Specified | ||
Time Spent: | Not Specified | ||
Original Estimate: | Not Specified | ||
Environment: |
FreeBSD |
Attachments: |
![]() |
Description |
`zabbix_agent -p` crashes on FreeBSD. The attached patch at least prevents the crash, though it doesn't prevent zabbix_agentd from returning prematurely. This patch also includes a small fix for vfs.dev.*. FreeBSD doesn't have hda, it uses da0 (most likely). |
Comments |
Comment by richlv [ 2012 Sep 25 ] | ||||||||||||||||||
crash is probably a duplicate of let's leave this issue for changing default disk device | ||||||||||||||||||
Comment by Alexander Vladishev [ 2012 Sep 26 ] | ||||||||||||||||||
Yes, crash has been already fixed in | ||||||||||||||||||
Comment by Alexander Vladishev [ 2012 Sep 26 ] | ||||||||||||||||||
FreeBSD disk organization: http://www.freebsd.org/doc/handbook/disk-organization.html Disk Device Codes
Sample Disk, Slice, and Partition Names
Use of "da0" will be more logical. It should be corrected. | ||||||||||||||||||
Comment by Sean Chittenden [ 2012 Sep 26 ] | ||||||||||||||||||
Correct. Given that almost all disks these days are SAS/SATA and show up as da(4) devices, use of da(4) is correct (vs ada(4)). | ||||||||||||||||||
Comment by Alexander Vladishev [ 2012 Sep 26 ] | ||||||||||||||||||
The same problem with OpenBSD. Related link: http://www.openbsd.org/faq/faq14.html#intro
"sd0" should be used as example. | ||||||||||||||||||
Comment by Alexander Vladishev [ 2012 Sep 26 ] | ||||||||||||||||||
Fixed in the development branch svn://svn.zabbix.com/branches/dev/ZBX-5609 r30371. | ||||||||||||||||||
Comment by Andris Mednis [ 2012 Sep 28 ] | ||||||||||||||||||
Successfully tested. | ||||||||||||||||||
Comment by Alexander Vladishev [ 2012 Oct 03 ] | ||||||||||||||||||
Fixed in pre-2.0.4 r30504 and pre-2.1.0 (trunk) r30505. | ||||||||||||||||||
Comment by Sean Chittenden [ 2012 Oct 05 ] | ||||||||||||||||||
Actually, this doens't crash any more, but the vfs.dev.read and vfs.dev.write are returning not supported, incorrectly. zabbix_agentd -p | grep vfs.dev But when I run manually: zabbix_agentd -t 'vfs.dev.read[da0,operations]' It returns the right count. Omitting the second argument, things error out because ops isn't implemented correctly? zabbix_agentd -t 'vfs.dev.read[da0]' zabbix_agentd -t 'vfs.dev.read[da0,ops]' Could we maybe change the default to be operations and not bps? operations per second is a much more useful metric than the bandwidth transferred, tbh. -sc Index: src/libs/zbxsysinfo/freebsd/diskio.c
| ||||||||||||||||||
Comment by Sean Chittenden [ 2012 Oct 05 ] | ||||||||||||||||||
The second argument needs to be changed in order to be useful to people. | ||||||||||||||||||
Comment by Alexander Vladishev [ 2012 Oct 08 ] | ||||||||||||||||||
What version you used? The crash was fixed under | ||||||||||||||||||
Comment by Sean Chittenden [ 2012 Oct 08 ] | ||||||||||||||||||
2.0.3, and yes, in 2.0.3 the agent didn't crash, but its default values returned no information. I haven't tried anything from svn/branches/2.0 yet, but it looks like r30710 of branches/2.0/src/libs/zbxsysinfo/freebsd/diskio.c is still showing "bps" and not operations. Wouldn't it make more sense to have the default operations always be counters and not rates? Requiring state in either the kernel or the agent to yield a rate seems like it should be optional and derived value, but shouldn't replace "truth" in the form of a raw counter. | ||||||||||||||||||
Comment by Andris Mednis [ 2012 Oct 09 ] | ||||||||||||||||||
For "zabbix_agentd -p" keys "vfs.dev.read" and "vfs.dev.write" the default parameter was changed to "operations" while fixing this |