Troubleshooting - LAMP

Aus HS Syswiki
(Unterschied zwischen Versionen)
Wechseln zu: Navigation, Suche
 
(Eine dazwischenliegende Version von einem Benutzer wird nicht angezeigt)
Zeile 23: Zeile 23:
  
 
### count IP addresses - access
 
### count IP addresses - access
awk '{print $1}' /home/www/WEB-XY/log/access_log | sort | uniq -c | sort -r | head -10
+
awk '{print $1}' /home/www/WEBXYZ/log/access_log | sort | uniq -c | sort -r | head -10
 
awk '{print $1}' /var/log/httpd/access_log | sort | uniq -c | sort -r | head -10
 
awk '{print $1}' /var/log/httpd/access_log | sort | uniq -c | sort -r | head -10
 
</syntaxhighlight>
 
</syntaxhighlight>

Aktuelle Version vom 24. Juni 2014, 15:37 Uhr

# IP address list from FTP log
zgrep webXYZ /var/log/xferlog* | cut -d ' ' -f7 | sort -t . -k 1,1n -k 2,2n -k 3,3n -k 4,4n | uniq
 
# Test network connection
mtr -s 1500 -r -c 1000 -i 0.1 nagios3a.hoststar.ch
 
# port 25 listening
netstat -anp --tcp --udp | grep LISTEN | grep 25
 
# Files used by Apache and PHP processes
lsof -c httpd -c php | grep home | grep -v log
lsof -p 12848
 
# Show current mail logs without POP3/IMAP login/logout
tail -f /var/log/mail | grep -v LOGIN | grep -v LOGOUT
 
### Restart Apache + MySQL
service apache2 stop && service mysql restart && service apache2 start
 
### Exec CounterScript
/usr/local/confixx/confixx_counterscript.pl -fa -sc -dbg
 
### count IP addresses - access
awk '{print $1}' /home/www/WEBXYZ/log/access_log | sort | uniq -c | sort -r | head -10
awk '{print $1}' /var/log/httpd/access_log | sort | uniq -c | sort -r | head -10

[Bearbeiten] Links

Test internet connection between two UNIX/Linux servers

Meine Werkzeuge
Namensräume

Varianten
Aktionen
Navigation
Werkzeuge