. * All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ require_once("functions.inc"); require_once("guiconfig.inc"); require_once('notices.inc'); require_once('system.inc'); include_once("includes/functions.inc.php"); $sysinfo_items = array( 'name' => gettext('Name'), 'system' => gettext('System'), 'bios' => gettext('BIOS'), 'version' => gettext('Version'), 'cpu_type' => gettext('CPU Type'), 'hwcrypto' => gettext('Hardware Crypto'), 'uptime' => gettext('Uptime'), 'current_datetime' => gettext('Current Date/Time'), 'dns_servers' => gettext('DNS Server(s)'), 'last_config_change' => gettext('Last Config Change'), 'state_table_size' => gettext('State Table Size'), 'mbuf_usage' => gettext('MBUF Usage'), 'temperature' => gettext('Temperature'), 'load_average' => gettext('Load Average'), 'cpu_usage' => gettext('CPU Usage'), 'memory_usage' => gettext('Memory Usage'), 'swap_usage' => gettext('Swap Usage'), 'disk_usage' => gettext('Disk Usage') ); if ($_REQUEST['getupdatestatus']) { require_once("pkg-utils.inc"); if (isset($config['system']['firmware']['disablecheck'])) { exit; } $system_version = get_system_pkg_version(); if ($system_version === false) { print(gettext("Unable to check for updates")); exit; } if (!is_array($system_version) || !isset($system_version['version']) || !isset($system_version['installed_version'])) { print(gettext("Error in version information")); exit; } $version_compare = pkg_version_compare( $system_version['installed_version'], $system_version['version']); switch ($version_compare) { case '<': ?>
%s', gettext("The system is on the latest version.")); break; case '>': print(gettext("The system is on a later version than
the official release.")); break; default: print(gettext( "Error comparing installed version
with latest available
")); break; } exit; } elseif ($_POST['widgetkey']) { $validNames = array(); foreach ($sysinfo_items as $sysinfo_item_key => $sysinfo_item_name) { array_push($validNames, $sysinfo_item_key); } if (is_array($_POST['show'])) { $user_settings['widgets'][$_POST['widgetkey']]['filter'] = implode(',', array_diff($validNames, $_POST['show'])); } else { $user_settings['widgets'][$_POST['widgetkey']]['filter'] = implode(',', $validNames); } save_widget_settings($_SESSION['Username'], $user_settings["widgets"], gettext("Saved System Information Widget Filter via Dashboard.")); header("Location: /index.php"); } /* Adding one second to the system widet update period * will ensure that we update the GUI right after the stats are updated. */ $widgetperiod = isset($config['widgets']['period']) ? $config['widgets']['period'] * 1000 : 10000; $widgetperiod += 1000; $filesystems = get_mounted_filesystems(); $skipsysinfoitems = explode(",", $user_settings['widgets'][$widgetkey]['filter']); $rows_displayed = false; ?>
/dev/null', $biosvendor); $_gb = exec('/bin/kenv -q smbios.bios.version 2>/dev/null', $biosversion); $_gb = exec('/bin/kenv -q smbios.bios.reldate 2>/dev/null', $biosdate); /* Only display BIOS information if there is any to show. */ if (!empty($biosvendor[0]) || !empty($biosversion[0]) || !empty($biosdate[0])): ?>




()

">

1): ?>
:
    {$dns}"; } ?>
% () 
% ()
% of MiB
% of MiB
 ( )
%iB -