refs #2374 fix dstat by starting/stopping pmcd once #80
|
@ -5,6 +5,12 @@ All notable changes to this project will be documented in this file.
|
|||
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
|
||||
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
||||
|
||||
## [0.22.7] - 2025-07-03
|
||||
|
||||
### Fixed
|
||||
|
||||
- Fix dstat--show bandwith in the local cgi
|
||||
|
||||
## [0.22.6] - 2025-07-03
|
||||
|
||||
### Changed
|
||||
|
|
|
@ -7,10 +7,7 @@
|
|||
#@date 2012-01-12
|
||||
#*/
|
||||
|
||||
# Montar efivar filesystem
|
||||
ogIsEfiActive && mount -t efivarfs none /sys/firmware/efi/efivars
|
||||
|
||||
# Lanzar servicios complementarios del cliente.
|
||||
echo "${MSG_OTHERSERVICES:-.}"
|
||||
|
||||
# stunnel start
|
||||
|
@ -57,7 +54,7 @@ mkdir -p /var/run/stunnel4; chown stunnel4:stunnel4 /var/run/stunnel4
|
|||
stunnel /etc/stunnel/menu.conf &>/var/log/stunnel4/menu.log &
|
||||
# stunnel end
|
||||
|
||||
# Iniciar dbus
|
||||
# dbus
|
||||
if [ -e /etc/dbus-1/system.d/ogbrowser.conf ]; then
|
||||
mkdir -p /run/dbus
|
||||
DBUS_SESSION_BUS_ADDRESS=$(dbus-daemon --print-address --system --nosyslog)
|
||||
|
@ -65,26 +62,16 @@ if [ -e /etc/dbus-1/system.d/ogbrowser.conf ]; then
|
|||
dbus-monitor --system &>/var/log/dbus-monitor.log &
|
||||
fi
|
||||
|
||||
# Iniciar rsyslog, si es necesario.
|
||||
[ -S /dev/log ] || service rsyslog start
|
||||
|
||||
# Adpatar la clave de "root" para acceso SSH.
|
||||
PASS=$(grep "^[ ]*\(export \)\?OPTIONS=" /scripts/ogfunctions 2>&1 | \
|
||||
sed 's/\(.*\)pass=\(\w*\)\(.*\)/\2/')
|
||||
# root password
|
||||
PASS=$(grep "^[ ]*\(export \)\?OPTIONS=" /scripts/ogfunctions 2>&1 | sed 's/\(.*\)pass=\(\w*\)\(.*\)/\2/')
|
||||
PASS=${PASS:-"og"}
|
||||
echo -ne "$PASS\n$PASS\n" | passwd root 2>/dev/null
|
||||
# Cargar el entorno OpenGnsys en conexión SSH.
|
||||
|
||||
cp -a $OPENGNSYS/etc/preinit/loadenviron.sh /etc/profile.d/
|
||||
# Arrancar SSH.
|
||||
/etc/init.d/ssh start &>/dev/null
|
||||
|
||||
# Desactivado apagado de monitor.
|
||||
#setterm -blank 0 -powersave off -powerdown 0 < /dev/console > /dev/console 2>&1
|
||||
|
||||
# Activado WOL en la interfaz usada en arranque PXE.
|
||||
ethtool -s $DEVICE wol g 2>/dev/null
|
||||
|
||||
# TODO Localizar correctamente el script de arranque.
|
||||
#setterm -blank 0 -powersave off -powerdown 0 < /dev/console > /dev/console 2>&1 ## apagado de monitor
|
||||
ethtool -s $DEVICE wol g 2>/dev/null ## Activado WOL en la interfaz usada en arranque PXE.
|
||||
[ -f /opt/opengnsys/scripts/runhttplog.sh ] && /opt/opengnsys/scripts/runhttplog.sh 2>/dev/null
|
||||
|
||||
|
||||
|
|
|
@ -1,15 +1,22 @@
|
|||
#!/bin/bash
|
||||
|
||||
#httd-log-status
|
||||
cp /etc/lighttpd/lighttpd.conf /etc/lighttpd/lighttpd.conf.back
|
||||
cp /opt/opengnsys/lib/httpd/lighttpd.conf /etc/lighttpd/
|
||||
cp /etc/lighttpd/lighttpd.conf /etc/lighttpd/lighttpd.conf.back
|
||||
cp /etc/lighttpd/conf-enabled/10-cgi.conf /etc/lighttpd/conf-enabled/10-cgi.conf.back
|
||||
cp /opt/opengnsys/lib/httpd/10-cgi.conf /etc/lighttpd/conf-enabled/
|
||||
/etc/init.d/lighttpd start
|
||||
chmod 755 /opt
|
||||
|
||||
cp /opt/opengnsys/lib/httpd/lighttpd.conf /etc/lighttpd/
|
||||
cp /opt/opengnsys/lib/httpd/10-cgi.conf /etc/lighttpd/conf-enabled/
|
||||
|
||||
chmod 755 /opt
|
||||
mkdir -p /usr/lib/cgi-bin
|
||||
cp /opt/opengnsys/lib/httpd/* /usr/lib/cgi-bin
|
||||
#TODO:
|
||||
dstat -dn 10 > /tmp/bandwidth &
|
||||
/etc/init.d/lighttpd start
|
||||
|
||||
## dstat fails because /var/lib/pcp/pmns/root does not exist.
|
||||
## we work around that by starting/stopping pmcd once. When it starts, it creates the missing file.
|
||||
if [[ ! -f /var/lib/pcp/pmns/root ]]; then
|
||||
/etc/init.d/pmcd start &>/dev/null
|
||||
/etc/init.d/pmcd stop &>/dev/null
|
||||
fi
|
||||
dstat --disk --net > /tmp/bandwidth &
|
||||
|
||||
echo "WAITING" >> $OGLOGSESSION
|
||||
# http-log-status
|
||||
|
|
Loading…
Reference in New Issue