Open-AudIT
https://www.open-audit.org/phpBB3/

do not show zero sized hard disks
https://www.open-audit.org/phpBB3/viewtopic.php?f=5&t=3434
Page 1 of 1

Author:  kilgor [ Wed Sep 30, 2009 5:19 pm ]
Post subject:  do not show zero sized hard disks

Hi,

Open-Audit displays zero sized hard disks like all the SD, CF, MMC etc card readers under the harddisk statistics. These are of no value and skew the stats.

Here's a fix:
[code]
$ svn diff list_viewdef_statistic_harddrive.php
Index: list_viewdef_statistic_harddrive.php
===================================================================
--- list_viewdef_statistic_harddrive.php (revision 1186)
+++ list_viewdef_statistic_harddrive.php (working copy)
@@ -9,14 +9,16 @@
SELECT count(*)
FROM hard_drive, system WHERE
system_uuid=hard_drive_uuid AND
- system_timestamp=hard_drive_timestamp
+ system_timestamp=hard_drive_timestamp AND
+ hard_drive_size!=0
)
* COUNT(*)
,$round_to_decimal_places) AS percentage
FROM hard_drive, system
WHERE
system_uuid=hard_drive_uuid AND
- system_timestamp=hard_drive_timestamp
+ system_timestamp=hard_drive_timestamp AND
+ hard_drive_size!=0
GROUP BY hard_drive_size
",
"sort"=>"count_item",
[/code]

Attached is the modified file. Please apply to svn trunk.

Attachments:
File comment: do not show zero sized disks
list_viewdef_statistic_harddrive.php.zip [706 Bytes]
Downloaded 447 times

Author:  A_Hull [ Wed Sep 30, 2009 9:21 pm ]
Post subject:  Re: do not show zero sized hard disks

Added at SVN 1187.
Thanks.

Page 1 of 1 All times are UTC + 10 hours
Powered by phpBB® Forum Software © phpBB Group
https://www.phpbb.com/