find /home/bitrix/www -type d -exec chmod 0755 {} \; # ставим дефолтные права на директории
find /home/bitrix/www -type f -exec chmod 0644 {} \; # ставим дефолтные права на файлы
chown -R bitrix:bitrix /home/bitrix/www # Меняем владельца и группу. Возьмите за правило для этой команды писать только полный путь, никогда не делайте . или ./ поскольку при первой же ошибке вы можете убить систему, работает она не в пример быстрей чем chmod
netstat -ntu | awk '{print $5}' | grep -vE "(Address|servers|77.37.156.60|79.137.175.245|192.168.5.201|95.163.251.234|127.0.0.1|8.8.8.8|8.8.4.4)" | cut -d: -f1 | sort | uniq -c | sort -n| sed 's/^[ \t]*//'
tar cvfz - --ignore-failed-read --directory /var/www/3dpaneli.ru/web . |ssh root@89.207.93.148 cd /tmp/test/aa;tar xvfz -"
<VirtualHost *:80>
DocumentRoot /var/www/clients/client1/web9/web
ServerName course.nipinfo.ru
..<VirtualHost *:80>
# The ServerName directive sets the request scheme, hostname and port that
# the server uses to identify itself. This is used when creating
# redirection URLs. In the context of virtual hosts, the ServerName
# specifies what hostname must appear in the request's Host: header to
# match this virtual host. For the default virtual host (this file) this
# value is not decisive as it is used as a last resort host regardless.
# However, you must set it for any further virtual host explicitly.
#ServerName www.example.com
ServerAdmin webmaster@localhost
DocumentRoot /var/www/html
# Available loglevels: trace8, ..., trace1, debug, info, notice, warn,
# error, crit, alert, emerg.
# It is also possible to configure the loglevel for particular
# modules, e.g.
#LogLevel info ssl:warn
ErrorLog ${APACHE_LOG_DIR}/error.log
CustomLog ${APACHE_LOG_DIR}/access.log combined
# For most configuration files from conf-available/, which are
# enabled or disabled at a global level, it is possible to
# include a line for only one particular virtual host. For example the
# following line enables the CGI configuration for this host only
# after it has been globally disabled with "a2disconf".
#Include conf-available/serve-cgi-bin.conf
</VirtualHost>server {
listen 80 default_server;
listen [::]:80 default_server;
....
}/etc/apache2 -type f -exec grep -l "/var/www/html" {} \;/etc/httpd -type f -exec grep -l "/var/www/html" {} \;/etc/nginx -type f -exec grep -l "/var/www/html" {} \;




#!/bin/bashwhich bash
/usr/bin/curl -I http://site.ru 2>/dev/null | head -n 1 | awk -F" " '{print $2}' | grep "200" || service apache2 restart








sshd -T | grep -i mac | grep --perl-regexp --only-matching ".?mac-[^,]+etm[^,]+"
Вывод:
umac-64-etm@openssh.com umac-128-etm@openssh.com hmac-sha2-256-etm@openssh.com hmac-sha2-512-etm@openssh.com hmac-sha1-etm@openssh.com
sshd -T | grep -i mac | grep --perl-regexp --only-matching "[^,]*etm[^,]*"
macs umac-64-etm@openssh.com
umac-128-etm@openssh.com
hmac-sha2-256-etm@openssh.com
hmac-sha2-512-etm@openssh.com
hmac-sha1-etm@openssh.com