Posted by The TechMentor in Journal, System Monitoring
on Jul 6th, 2016
On the receiver run: tcpdump host <ip of sender> On sender run: echo "PING" > /dev/udp/<ip of receiver>/<port #> Example: Sender $ echo "PING" > /dev/udp/192.9.20.115/6000" Receiver $ sudo tcpdump host 192.9.20.111 [sudo] password for jeverson: tcpdump: verbose output suppressed, use -v or -vv for full protocol decode listening on enp0s25, link-type EN10MB (Ethernet), capture size 65535 bytes 12:13:51.616237 IP mc-server.all-offroad.net.37052 > kate.all-offroad.net.6000: UDP, length 5 12:13:51.616314 IP kate.all-offroad.net >...
Posted by The TechMentor in Journal, System Monitoring
on Jan 23rd, 2013
After what seemed like days of messing with permissions, SELinux was the problem. To solve the dreaded Could not stat() command file ‘/usr/local/nagios/var/rw/nagios.cmd’!” error, when trying to reschedule a test or acknowledge an alert, a simple setenforce 0 was the solution. Though, permissions do also have to be correct. chown nagios.nagcmd /usr/local/nagios/var/rw chmod g+rwx /usr/local/nagios/var/rw chmod g+s /usr/local/nagios/var/rw
Posted by The TechMentor in Journal, System Monitoring
on Dec 1st, 2012
The first thing I wanted to do was deal with the web server. I didn’t want apache serving any pages other than nagios. I decided to redirect everything to techmentor.com. To do this I has to allow overrides int the main conf file: <Directory “/var/www/html”> Options Indexes FollowSymLinks AllowOverride All Order allow,deny Allow from all </Directory> Then in /var/www/html I created the following .htaccess file: RewriteEngine on AddType text/cache-manifest manifest RewriteCond %{HTTP_HOST} ^backwater\.techmentor\.com$ RewriteRule ^/?$...
Posted by The TechMentor in System Monitoring
on Nov 14th, 2012
Amount of Memory sysctl -a | grep hw.memsize: or /usr/sbin/system_profiler SPHardwareDataType | grep Memory Amount of Swap ls -al /private/var/vm/swapfile0 | awk ‘{print $5}’ Amount of Free Swap vm_stat | awk ‘/Pages free:/ {print substr($3,1,match($3,/\./)-1)}’