To disable all output (STDERR and STDOUT) add the following to your awstats_updateall and logrotate cron jobs:
/dev/null 2>&1
To disable only STDOUT while getting notifications of errors add the following:
/dev/null
mercredi, avril 15 2015
mercredi, avril 15 2015. Debian et moi
To disable all output (STDERR and STDOUT) add the following to your awstats_updateall and logrotate cron jobs:
/dev/null 2>&1
To disable only STDOUT while getting notifications of errors add the following:
/dev/null
mardi, avril 14 2015
mardi, avril 14 2015. Geekeries !
Pour contrôler l'état S.M.A.R.T des disques sur un serveur ESXi un script est a disposition.
Pour l'utiliser :
- Se connecter en SSH sur le serveur
- Se rendre dans le répertoire : /usr/lib/vmware/vm-support/bin
- Exécuter le script : ./smartinfo.sh
Ce qui renvoi un tableau des états S.M.A.R.T de l'ensemble des disques du système.
Device: t10.ATA_WDC_WD10EZRX2D22L4HB0_WD2DWCC4J0963826 Parameter Value Threshold Worst- Health Status OK N/A N/A Media Wearout Indicator N/A N/A N/A Write Error Count N/A N/A N/A Read Error Count 200 51 200 Power-on Hours 92 0 91 Power Cycle Count 100 0 100 Reallocated Sector Count 200 140 200 Raw Read Error Rate 200 51 200 Drive Temperature 108 0 103 Driver Rated Max Temperature N/A N/A N/A Write Sectors TOT Count 200 0 200 Read Sectors TOT Count 200 0 200 Initial Bad Block Count N/A N/A N/A
mardi, avril 7 2015
mardi, avril 7 2015. Debian et moi
Depuis que dyndns est devenu payant, j'utilise comme alternative encore gratuite DtDns. J'ai une machine derrière du NAT que j'utilise pour mettre à jour le DNS. J'ai donc bricoler a partir d'un script dispo chez DtDns qui ne fonctionne pas derrière un routeur (il me renvoi mon ip local).
Ca donne ça :
#!/bin/bash IPADDR=`wget -qO- http://ipecho.net/plain | awk '{ print $1 }'` LASTIP=`nslookup gaers.dtdns.net | grep -A1 gaers | grep Address | awk '{ print $2 }'` echo -n "`date` - " if "$IPADDR" != "$LASTIP"; then echo -e "GET /api/autodns.cfm?id=DNS&pw=PASSWORD&client=NOM_CLIENT HTTP/1.1\nHost: www.dtdns.com\nUser-Agent: bash\n\n" | \ nc www.dtdns.com 80 > /dev/null 2>&1 echo "Posted IP change from $LASTIP to $IPADDR" else echo "IP still $IPADDR" fi