Henrique-RJ
(usa Outra)
Enviado em 13/06/2018 - 06:57h
Mauricio
Acabei aproveitando a tua solução para corrigir a RPM dos fans no Conky mas primeiro tive que acrescentar duas linhas no /etc/sensors.d/sensors:
chip "it87-*"
label in8 "Vbat"
compute in3 @*((6.8/10)+1), @/((6.8/10)+1)
compute in4 @*((30/10)+1), @/((30/10)+1)
compute fan1 @/4, 2*@
compute fan2 @/4, 2*@
Agora no /etc/conky/conky.conf o código ficou todo do jeito abaixo:
# Conky, a system monitor, based on torsmo
#
# Any original torsmo code is licensed under the BSD license
#
# All code written since the fork of torsmo is licensed under the GPL
#
# Please see COPYING for details
#
# Copyright (c) 2004, Hannu Saransaari and Lauri Hakkarainen
# Copyright (c) 2005-2010 Brenden Matthews, Philip Kovacs, et. al. (see AUTHORS)
# All rights reserved.
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
#
alignment no
background no
border_width 1
cpu_avg_samples 2
default_color white
default_outline_color white
default_shade_color white
draw_borders no
draw_graph_borders yes
draw_outline no
draw_shades no
use_xft yes
xftfont DejaVu Sans Mono:size=10
gap_x 720
gap_y 60
minimum_size 5 5
net_avg_samples 2
no_buffers yes
out_to_console no
out_to_stderr no
extra_newline no
own_window yes
own_window_class Conky
own_window_argb_visual yes
own_window_type normal
own_window_hints undecorated,below,sticky,skip_taskbar,skip_pager
stippled_borders 0
update_interval 1.0
uppercase no
use_spacer none
show_graph_scale no
show_graph_range no
TEXT
${color white}Conky - System Monitor
$hr
${color white}Uptime:$color $uptime
${color white}Frequency (in MHz):$color $freq
${color white}Frequency (in GHz):$color $freq_g
${color white}RAM:$color $mem / $memeasyfree / $memfree / $memmax
${color white}Swap:$color $swap/$swapmax - $swapperc% ${swapbar 4}
${color white}CPU Usage:$color $cpu% ${cpubar 4}
${color white}CPU Fan:$color ${exec sensors | awk '/fan1/ {print $2}'}rpm ${if_match ${hwmon 1 fan 1} < 1000} ${exec zenity --warning --text "Rotação CPU Fan abaixo do normal"} ${endif} Chassis Fan:$color ${exec sensors | awk '/fan2/ {print $2}'}rpm ${if_match ${hwmon 1 fan 2} < 1000} ${exec zenity --warning --text "Rotação Chassis Fan abaixo do normal"} ${endif}
$hr
${color white}UPS APC BE600N-BR:
Charge:$color ${apcupsd localhost 3551} ${apcupsd_charge}% Load:${apcupsd_load}% ${if_match ${apcupsd_load} > 30} ${exec zenity --warning --text "Consumo do PC acima de 30% do Nobreak"} ${endif} ${apcupsd_loadbar 4}
Inp Volt: ${apcupsd_linev}V Time Left: ${apcupsd_timeleft}min
Reason: ${apcupsd_lastxfer}
$hr
${color white}Voltages:
Vcore:${exec sensors | awk '/in0/ { print $2 }'}V ${if_match ${hwmon 1 vol 0} < 1} ${exec zenity --warning --text "Tensão Vcore abaixo do normal"} ${endif} ${if_match ${hwmon 1 vol 0} > 1} ${exec zenity --warning --text "Tensão Vcore acima do normal"} ${endif} NB:${exec sensors | awk '/in1/ { print $2 }'}V ${if_match ${hwmon 1 vol 1} < 1} ${exec zenity --warning --text "Tensão NB abaixo do normal"} ${endif} ${if_match ${hwmon 1 vol 1} > 1} ${exec zenity --warning --text "Tensão NB acima do normal"} ${endif} +3,3V:${exec sensors | awk '/in2/ { print $2 }'}V ${if_match ${hwmon 1 vol 2} < 3} ${exec zenity --warning --text "Tensão +3,3V abaixo do normal"} ${endif} ${if_match ${hwmon 1 vol 2} > 3} ${exec zenity --warning --text "Tensão +3,3V acima do normal"} ${endif}
+5,0V:${exec sensors | awk '/in3/ { print $2 }'}V ${if_match ${hwmon 1 vol 3} < 3} ${exec zenity --warning --text "Tensão +5,0V abaixo do normal"} ${endif} ${if_match ${hwmon 1 vol 3} > 3} ${exec zenity --warning --text "Tensão +5,0V acima do normal"} ${endif} +12,0V:${exec sensors | awk '/in4/ { print $2 }'}V ${if_match ${hwmon 1 vol 4} < 3} ${exec zenity --warning --text "Tensão +12,0V abaixo do normal"} ${endif} ${if_match ${hwmon 1 vol 4} > 3} ${exec zenity --warning --text "Tensão +12,0V acima do normal"} ${endif} DRAM:${exec sensors | awk '/in5/ { print $2 }'}V ${if_match ${hwmon 1 vol 5} < 1} ${exec zenity --warning --text "Tensão DRAM abaixo do normal"} ${endif} ${if_match ${hwmon 1 vol 5} > 2} ${exec zenity --warning --text "Tensão DRAM acima do normal"} ${endif}
LDT:${exec sensors | awk '/in6/ { print $2 }'}V ${if_match ${hwmon 1 vol 6} < 1} ${exec zenity --warning --text "Tensão LDT abaixo do normal"} ${endif} ${if_match ${hwmon 1 vol 6} > 1} ${exec zenity --warning --text "Tensão LDT acima do normal"} ${endif} 3VSB:${exec sensors | awk '/in7/ { print $2 }'}V ${if_match ${hwmon 1 vol 7} < 2} ${exec zenity --warning --text "Tensão 3VSB abaixo do normal"} ${endif} ${if_match ${hwmon 1 vol 7} > 3} ${exec zenity --warning --text "Tensão 3VSB acima do normal"} ${endif} Vbat:${exec sensors | awk '/Vbat/ { print $2 }'}V ${if_match ${hwmon 1 vol 8} < 3} ${exec zenity --warning --text "Tensão Vbat abaixo do normal"} ${endif} ${if_match ${hwmon 1 vol 8} > 3} ${exec zenity --warning --text "Tensão Vbat acima do normal"} ${endif}
$hr
${color white}Temperatures:
CPU:$color ${hwmon 1 temp 1}°C NB:$color ${hwmon 1 temp 2}°C SB:$color ${hwmon 1 temp 3}°C
HDD:$color ${execi 5 hddtemp /dev/sda}
$hr
${color white}File systems:
/ $color${fs_used /}/${fs_size /} ${fs_bar 6 /}
${color white}Networking:
Up:$color ${upspeed eth0} ${color white} - Down:$color ${downspeed eth0}
$hr
${color white}Name PID CPU% MEM%
${color white} ${top name 1} ${top pid 1} ${top cpu 1} ${top mem 1}
${color white} ${top name 2} ${top pid 2} ${top cpu 2} ${top mem 2}
${color white} ${top name 3} ${top pid 3} ${top cpu 3} ${top mem 3}
${color white} ${top name 4} ${top pid 4} ${top cpu 4} ${top mem 4}
Veja o Conky como ficou no meu desktop com a maioria dos dados mais precisos:
https://s33.postimg.cc/4bn9423db/conky1.png
As temperaturas do NB e do SB ( chipsets da placa-mãe ) são um pouco doidas mas pelo que pesquisei, quando uma ou outra fica negativa é sinal de que não houve leitura ( talvez o diodo costume ter variações altas ).
O Conky tem me ajudado muito a acompanhar e entender o gerenciamento de memória nesta distro com memória usada, memória cache + livre, memória livre e memória física total ( vendo da esquerda para a direita em RAM ).