Actualicé IPv6 Toolkit en Debian

He actualizado IPv6 Toolkit in Debian. IPv6 Toolkit es una herramienta de diagnóstico y evaluación para los protocolos de IPv6, escrito por Fernando Gont.

Principalmente, esta actualización previene que IPv6 Toolkit sea eliminado de Bullseye, pues la compilación se había roto bajo el nuevo GCC 10.

Esta es la bitácora de cambios completa (en inglés):

ipv6toolkit (2.0+ds.1-1) unstable; urgency=medium

  * Refreshed patches using gbp pq export. Added:
    - Fixed GCC-10 compilation. Closes: #957370.
    - Silenced compilation warnings that are already fixed upstream.
    - Fixed stringop-truncation warning.
  * Bumped compat level to 12.
  * Bumped Standards-Version to 4.5.0.
    - Changed Priority to optional.
  * Disabled debian/watch.

 -- Octavio Alvarez <alvarezp@alvarezp.com>  Tue, 04 Aug 2020 23:21:55 -0500

Gracias, Luciano, por tu ayuda!

Updated IPv6 Toolkit in Debian

I recently updated IPv6 Toolkit in Debian. IPv6 Toolkit is a security assessment and troubleshooting tool for the IPv6 protocols, written by Fernando Gont.

Mainly, this update prevented it from being removed from Bullseye, as compilation broke under the new GCC 10.

This is the full changelog:

ipv6toolkit (2.0+ds.1-1) unstable; urgency=medium

  * Refreshed patches using gbp pq export. Added:
    - Fixed GCC-10 compilation. Closes: #957370.
    - Silenced compilation warnings that are already fixed upstream.
    - Fixed stringop-truncation warning.
  * Bumped compat level to 12.
  * Bumped Standards-Version to 4.5.0.
    - Changed Priority to optional.
  * Disabled debian/watch.

 -- Octavio Alvarez <alvarezp@alvarezp.com>  Tue, 04 Aug 2020 23:21:55 -0500

Thanks, Luciano, for your help!

Calculating values for the Xfce Sensors Plugin

I extensively use the Xfce panel to monitor my system. I like having a picture of its state without having to launch any diagnostic tool. This proves to be quite useful! Also, should my computer experience a sudden problem and not respond anymore, I can glance at its last state before rebooting.

I have never liked the excess of colors that is present on the bar, though:

The top panel on my Xfce session showing multiple sensors and how it shows too many distracting colors.

The top panel on my Xfce session showing multiple sensors and how it shows too many distracting colors. Taken from My laptop was broken into.

This takes away from noticing effortlessly whenever something out of the ordinary is occurring. So I put everything (or as much as possible) in gray shades. I managed to change its appearance quite easily:

  • For the Applications menu I chose an already-available gray-scale icon.
  • I removed unneeded icons, favoring a shortcut in Superkb.
  • For the weather applet I used the Liquid Dark icon theme.
  • I also changed the notification area by switching my whole Xfce appearance to the Adwaita-Dark style with Moka icons.
  • I changed the system monitors colors so it’s all gray if everything is normal:
    • CPU chart colors (the bars are hardcoded blue, but this is okay since I want to somewhat notice any CPU usage).
    • The RAM monitor uses fixed colors so I put physical RAM in gray. I put swap on bright yellow, as it’s bad to be using too much swap and I want to notice it.
    • Both NIC monitors follow a similar approach: gray for download, yellow for upload.
    • The disk monitor also uses the gray/yellow approach: gray for reading, yellow for writing.
    • For the weather plugin I used Kevin Hanselman’s WSky-Light theme.

The Sensors Plugin needed some fine-tuning, though…

Fine-tuning the Sensors Plugin

The Sensors Plugin has many display modes. The most unobtrusive is the bar mode. Also, you can set lower and upper limits for each sensor. With its Show colored bars mode, a bar will change from the set color to yellow if its value is within 20% of a limit and to red if it’s within 10% of a limit. So, if I measure a sensor and I configure it to plot between 0 and 10, the bar will turn yellow when the sensor measures 1.5 or 8.5 and red for measurements like 0.5 or 9.5.

I want the colors to turn yellow or red only if I want to notice something; otherwise just plain, boring, unnoticeable gray. I want the bars not stand out if everything is within normal values. That implies making some calculations to figure out the actual minimum and maximum values for the sensor on configuration so nominal values always stay between 20% and 80% area.

This suits most cases. However, in the case of CPU temperature, though, I am rather interested on fixing the red value, so instead of calculating between 20% and 80% I wanted to calculate between 20% and 90%; it does not matter if the CPU sensor turns yellow.

Calculating the plotting range: the minimum and maximum values

For the calculations, there are four inputs given:

  • P_high: The percentage within the plotting range I want to use for fixing the too high value.
  • V_high: The value to be fixed to the P_high percentage point of the plotting range.
  • P_low: The percentage within the plotting range I want to use for fixing the too low value.
  • V_low: The value to be fixed to the P_low percentage point of the plotting range.

I am calling the plotting range the absolute minimum and maximum values on a bar. If a value goes below the minimum, the bar will be empty. If it goes beyond the maximum, the bar will be full.

Notice that minimum and low are not the same thing: minimum is the lowest possible value in the plotting range (as explained just above) while low is the value I am interested in fixing to a specific color on the lower side.

First, a intermediate range value must be calculated:

range = ( V_high - V_low ) / ( P_high - P_low )

Once having the Range calculated the minimum and maximum can be determined by:

min = V_low - (P_low)*(range)

max = V_high + (1 - P_high )*(range)

Example

For the CPU temperature I want this behavior:

Start gray at 39 C, the lowest temperature I measured when idle ever. It should turn yellow below this value. This is the 20% point in the chart.

Turn red if it goes above than 81 C, the highest temperature I measured under the heaviest load possible with the new thermal paste. 81 C is quite high already, being 89 C the shutdown limit. This is why I want it directly red by then and I don’t care if it’s yellow a bit before. So, this will be the 90% point in the chart.

range = ( 81 - 39 ) / ( 0.9 - 0.2 ) = 60

min = 39 - ( 0.2 )*( 60 ) = 27

max = 81 + ( 1 - 0.9 )*( 60 ) = 87

So I configured that bar on the Sensors Plugin to plot from 27 to 87 C. This way, the sensor will turn red above 81 C and yellow only below 39 C.

Final result

Since I started writing this post to the moment I finished it, some additional unrelated changes occurred:

  1. I switched from Hexchat to Quassel. This was done because I installed Quassel core so I could have a better IRC experience.
  2. I installed the kbdleds plugin. It’s old and obsolete, but it works. I have an on-screen indicator of NumLock, as my laptop keyboard does not provide one.

This is how the final bar looks like:

final

It will probably be too wide for most displays, so here it is again, split in three sections:

Bar, left section: applications menu with gray icon, terminal launcher in black, and CPU, RAM, NICs and disk monitors; the only color shown is blue, by the CPU monitor.

Left section of the bar.

Bar, center section: two weather widgets and the date and time with seconds and timezone, all in the same color.

Center section of the bar.

Bar, right section: keyboard pseudo-LED indicators, notification area, temperature sensors and user menu, all in the same color except for the keyboard pseudo-LEDs.

Right section of the bar.

I like it! It’s much less distracting, much less cartoony!

Update: BTW, if you want to make your own calculations quickly, download and use this LibreOffice Calc spreadsheet: sensors.ods

Rejuveneciendo mi laptop: chasís, resultados y conclusiones

Esta es la octava y última parte de la serie Rejuveneciendo mi Laptop en la que narro, componente por componente, el proyecto en el cual busco darle una nueva vida a mi vieja laptop. Para la tabla de contenido, visita el primer post: Introducción: los problemas.

El tema pendiente: el chasís

No hay mucho que trabajar en este aspecto, pero sí hubo algunos pequeños detalles:

  1. ¿Se acuerdan de la pieza extraña cuya foto agregué en el post anterior? Le hice un par de rendijas con un mototool. Las rendijas se ven horribles pero están discretas. Preferí eso que volver a abrir la laptop. Debería ayudar a controlar la temperatura un poco al permitir un poco más de aire fresco al ventilador.
  2. Cuando le puse el disco SSD, rompí la carátula del DVD anterior y quedó pegada con cinta adhesiva negra. Inicialmente la iba a dejar así porque no se notaba (al ser negra la tapa inferior de la laptop) pero encontré un DVD de remplazo barato en MercadoLibre y lo compré. Esta vez no rompí la carátula y ya no tiene ese horrible hack. Ya se ve como se veía originalmente.
  3. Hace 2 años, cuando le mandé hacer el mantenimiento a la laptop, el teclado quedó mal colocado. Ahora con este proyecto, lo acomodé como corresponde.
  4. Cada que se abre la laptop existe el riesgo de romper postes de tornillos. Desde la primera vez que abrí la tapa de la memoria, una pieza sonaba al mover la laptop. Ahora que abrí la laptop eliminé todas las piezas sueltas.

Parece mentira que cosas tan simples como un teclado bien acomodado, la eliminación de piezas sueltas y la carátula bien puesta, cambie toda la percepción sobre la edad de la laptop.

Sigue leyendo

Rejuveneciendo mi laptop: temperatura, parte 2

Esta es la séptima parte de la serie Rejuveneciendo mi Laptop en la que narro, componente por componente, el proyecto en el cual busco darle una nueva vida a mi vieja laptop. Para la tabla de contenido, visita el primer post: Introducción: los problemas.

Temperatura, parte 2: la revancha

Estuve a punto de aceptar la primera derrota con una pasta chafa. Me resistía a abrir la laptop de nuevo porque cada vez que la abro le rompo alguna de las uniones cantilever snap-fit. Aún está en buen estado en general, así que opté por no retirarme de la guerra.

La mejor manera de conocer los límites de temperatura que mi laptop tiene por diseño de hardware es colocando la mejor pasta posible de la mejor manera posible. Encontré dos opciones: La Thermal Grizzly Kryonaut y la Noctua NT-H1.

Sigue leyendo