vim /etc/postfix/master.cf
amavis unix - - - - 2 smtp
-o smtp_tls_security_level=none
127.0.0.1:10025 inet n - - - - smtpd
-o smtp_tls_security_level=none
vim /etc/postfix/master.cf
amavis unix - - - - 2 smtp
-o smtp_tls_security_level=none
127.0.0.1:10025 inet n - - - - smtpd
-o smtp_tls_security_level=none
grep -ril word1 /some/path/to/search | xargs grep -i word2
pt-kill --kill-busy-commands=Query --run-time 1m --interval 1 --each-busy-time 30s --print --match-info "(select|SELECT)" --group-by=fingerprint
timedatectl | grep sync
System clock synchronized: no
sed -i 's/NTP\=/NTP=ntp.ubuntu.com/g' /etc/systemd/timesyncd.conf ; systemctl daemon-reload ; timedatectl set-ntp off ; timedatectl set-ntp on ; timedatectl | grep sync
System clock synchronized: yes
Unbound is a free, open-source, recursive, and validating DNS caching server. It uses DNS-over-TLS and DNS-over-HTTPS to encrypt connections between clients. Compared to Bind9, Unbound is lightweight and extremely fast.
echo "deb https://download.keydb.dev/open-source-dist $(lsb_release -sc) main" | sudo tee /etc/apt/sources.list.d/keydb.list
wget -O /etc/apt/trusted.gpg.d/keydb.gpg https://download.keydb.dev/open-source-dist/keyring.gpg
apt update
apt install keydb
paste from input to remote server ssh server_ip "cat - >> /tmp/some_file.txt" << "EOF" > asasas > asasas > asasas > EOF
wg set wg0 peer public_key remove
wg-quick save wg0; wg-quick down wg0; wg-quick up wg0;
su nobody -s /bin/sh -c ‘cat /tmp/some_test’
cat: /tmp/some_test: Permission denied
curl 'localhost:9200/_cat/indices?v'
bash script rotate-elasticsearch-index.sh
should to change regDate=”$yearReg\\-$monthReg\\-$dayReg” to match your index date format
curl -X PUT “localhost:9200/test_2022-08-02-test?pretty”
{
“acknowledged” : true,
“shards_acknowledged” : true,
“index” : “test_2022-08-02-test”
}
./rotate-elasticsearch-index.sh test localhost:9200 1
=== Fri Aug 12 16:35:37 EEST 2022 ===
——————————————-
INFO: Index: test_2022-08-11-110602
INFO: Found date: 2022-08-11
INFO: test_2022-08-11-110602 is less than 1 days old, doing nothing.
——————————————-
INFO: Index: test_2022-08-12-110602
INFO: Found date: 2022-08-12
INFO: testas_2022-08-12-110602 is less than 1 days old, doing nothing.
——————————————-
INFO: Index: test_2022-08-02-test
INFO: Found date: 2022-08-02
DELETE: test_2022-08-02-test is about to be deleted.
sed -i '/^search_string\=/ s/$/,text_to_add/' file
sed -i 's/search_string/&\n/g' file
FROM php:7.4.10-apache MAINTAINER ICEcoder <[email protected]> ENV DEBIAN_FRONTEND noninteractive RUN a2enmod rewrite RUN a2enmod ssl RUN service apache2 restart RUN apt-get update && \ apt-get install unzip -y && \ apt-get clean all && \ curl -o /icecoder.zip 'https://downloads.icecoder.net/ICEcoder-8.1.zip' && \ unzip -q /icecoder.zip -d /tmp/ && \ cp -r /tmp/ICE* /var/www/html/icecoder && \ echo "<!DOCTYPE html>\n<html>\n<head>\n<title>Welcome to your new site</title>\n</head>\n<body style=\"text-align: center; font-family: monospace\">\n<h1>Welcome!</h1>\n<p>Head to ICEcoder at <a href=\"/icecoder\">localhost:8080/icecoder</a> to create a password and start coding!</p>\n</body>\n</html>" > /var/www/html/index.php && \ chown -R www-data.www-data /var/www/html && \ chmod 755 /var/www/html && \ rm -rf /icecoder.zip /tmp/ICE*
check process rabbitmq-server matching "/usr/lib/erlang/erts-6.2/bin/beam"
group rabbitmq
start program = "/etc/init.d/rabbitmq-server start"
stop program = "/etc/init.d/rabbitmq-server stop"
if failed port 5672 type tcp then restart
if 3 restarts within 3 cycles then timeout