Menu="Device:1" Title="$name _(Settings)_" Tag="hdd-o" --- 0 ? round(100*$val/$size,1) : 0; $unit = '%'; if ($size < 1) { $units = ['KB','MB','GB','TB','PB','EB','ZB','YB']; $base = $val>0 ? floor(log($val,1000)) : 0; $size = round($val/pow(1000,$base),1); $unit = _var($units,$base); } [$dot,$comma] = str_split(_var($display,'number','.,')); return $size>0 ? number_format($size,$size-floor($size)?1:0,$dot,$comma).' '.$unit : ''; } function fsSize() { global $disks,$pools; $fsSize = []; foreach ($pools as $pool) $fsSize[] = '"'.$pool.'":"'._var($disks[$pool],'fsSize',0).'"'; return implode(',',$fsSize); } function fsType($type) { global $disk; return strpos(_var($disk,'fsType'),$type)!==false; } function diskStatus($status) { global $disk; return strpos(_var($disk,'status'),$status)!==false; } function diskType(...$types) { global $disk; $pass = false; foreach ($types as $type) $pass |= _var($disk,'type')==$type; return $pass; } function makeList($list) { return implode(',',array_map('escapestring',$list)); } function sharename($share) { return basename($share,'.cfg'); } function displayTemp($temp) { global $display; return (_var($display,'unit')=='F' && is_numeric($temp)) ? round($temp*9/5)+32 : $temp; } function maintenance_mode() { global $var; return _var($var,'fsState')=="Started" && _var($var,'startMode')=="Maintenance" && _var($disk,'luksState',0)<=1; } function isPool($name) { global $pools; return in_array($name,$pools); } $sheets = []; $i = $n = 0; foreach ($disks as $sheet) { if (_var($sheet,'type')=="Flash" || _var($sheet,'color')=="grey-off" || empty($sheet['name'])) continue; $sheets[] = $sheet['name']; if ($sheet['name']==$name) {$i = $n;} $n++; } $tag = _var($disk,'name'); $end = count($sheets)-1; $prev = $i>0 ? $sheets[$i-1] : $sheets[$end]; $next = $i<$end ? $sheets[$i+1] : $sheets[0]; $text = isPool($name) ? _('This will ERASE content of ALL devices in the pool') : _('This will ERASE ALL device content'); ?> "> ">
_(Name)_: : _(Name)_: : _(Identification)_: : _(No device)_ _(Identification)_: :  () _(Comments)_: : :info_comments_help: _(Partition size)_: : KB (K=1024) _(Partition format)_: : _(Spinup group(s))_: : _(Spin down delay)_: : _(File system status)_: :   _(File system type)_: : style="display:none"> _(ReiserFS is deprecated, please use another file system)_! :info_file_system_help: 1):?> _(File system type)_: : _(Enable user share assignment)_: : :info_share_assignment_help: _(Minimum free space)_: : _(Calculated free space value)_ :info_free_space_help: _(Warning disk utilization threshold)_ (%): : :info_warning_utilization_help: _(Critical disk utilization threshold)_ (%): : :info_critical_utilization_help:   : > > >_(Unassign **ALL** devices to delete this pool)_
_(Balance Status)_
_(btrfs filesystem df)_: : ".shell_exec("/sbin/btrfs filesystem df /mnt/$tag").""?> _(btrfs balance status)_: : ".implode("\n", $balance_status).""?>   :  _(Current usage ratio)_: % --- 0 && $usage <= 50) ? "_(Full Balance recommended)_" : "_(No Balance required)_"?>   : 1):?> *_(Perform full balance)_* :info_btrfs_balance_help:   : :info_balance_cancel_help:   : "._('Balance')." "._('is only available when array is Started') : sprintf(_('See %s Settings'),ucfirst(prefix($tag)))?>

_(Balance schedule)_: : _(Day of the week)_: : _(Day of the month)_: : _(Time of the day)_: : : _(Block group usage)_ (%): :   :
_(Scrub Status)_
_(btrfs scrub status)_: : ".implode("\n", $scrub_status).""?>   : :info_btrfs_scrub_help:   : :info_scrub_cancel_help:   : "._('Scrub')." "._('is only available when array is Started') : sprintf(_('See %s Settings'),ucfirst(prefix($tag)))?>

_(Scrub schedule)_: : _(Day of the week)_: : _(Day of the month)_: : _(Time of the day)_: : :   :
_(Check Filesystem Status)_
_(btrfs check status)_: : ".implode("\n", $check_status).""?>   : _(Options (see Help))_ :info_btrfs_check_help:   : *_(Running)_* :info_check_cancel_help:   : **_(Check)_** _(is only available when array is Started in **Maintenance** mode)_.   : .
_(Pool Status)_
_(zfs pool status)_: :
  : :info_zfs_scrub_help:   : :info_scrub_cancel_help:   : "._('Scrub')." "._('is only available when array is Started') : sprintf(_('See %s Settings'),ucfirst(prefix($tag)))?>

_(Scrub schedule)_: : _(Day of the week)_: : _(Day of the month)_: : _(Time of the day)_: : :   :
_(Check Filesystem Status)_
_(reiserfsck status)_: : ".implode("\n", $check_status).""?>   : _(Options (see Help))_ :info_reiserfs_check_help:   : *_(Running)_* :info_reiserfs_cancel_help:   : **_(Check)_** _(is only available when array is Started in **Maintenance** mode)_.
_(Check Filesystem Status)_
_(xfs_repair status)_: : ".implode("\n", $check_status).""?>   : _(Options (see Help))_ :info_xfs_check_help:   : *_(Running)_* :info_xfs_cancel_help:   : **_(Check)_** _(is only available when array is Started in **Maintenance** mode)_.
_(SMART Settings)_
_(Warning disk temperature threshold)_ (°): : :info_warning_temp_help: _(Critical disk temperature threshold)_ (°): : :info_critical_temp_help: _(SMART notification value)_: : :info_smart_notifications_help: _(SMART notification tolerance level)_: : :info_tolerance_level_help: _(SMART controller type)_: : /dev/ _(enter disk index and device name as applicable to your controller)_ :info_controller_type_help: _(SMART attribute notifications)_: : _(Custom attributes (use comma to separate numbers))_   : >_(Attribute)_ = :info_attribute_notifications_help: :
'>