#vmstat (summary information for system load and usage, but does not show individual processes) #ps aux (display all processes running on the Linux system)(to search for specific processes or list them all) #ps aux | grep auth (all the processes that have auth in them) #ps auxf | sort -nr -k 4 | head -10Continue reading “System information commands”
Author Archives: Farzand Ali
To see the load average and the uptime ona Linux system
#uptime or #watch -n 1 uptime
iftop to monitor traffic bandwidth usage
iftop -i ethF iftop -i ethF -f “dst host Linux.com” iftop -i ethF -f “dst host 8.8.8.8”
Netstat commands on Linux
To see the number of concurrent DNS requests at a time through the Smoothwall: netstat -anp | grep dnsmasq | wc -l To see the number of sessions open through the external connection: netstat -an | wc -l To see the process ID ofthe windows process using netstat: netstat -a -n -o
Change MAC address on the interface in case the virtual box clone gave you the same MAC addresses or MAC address is causing a problem
ip link show ethX ip link set dev ethX down ip link set dev ethX address XX:XX:XX:XX:XX:XX ip link set dev ethX up
Duplex and Speed on Linux
To check duplex and speed on the Smoothwall: #ethtool ethA (always recommended to set the auto-negotiate on the switch side for the interface where Smoothwall is connected) (for example to change the MTU size on the fly for testing purposes) (Shows the network speed and information about the interface) To change the speed, duplex andContinue reading “Duplex and Speed on Linux”
Speed test (speedtest) / slow speed issue
Install iperf client on windows from: https://iperf.fr/ or Ubuntu using: sudo apt-get install iperf Try the following from the client machines inside the network and/or from the Smoothwall: (using speedtest sites through the Smoothwall are not recommended) iperf -c iperf.securityinspection.com iperf -c iperf.saratov.ertelecom.ru iperf -c st2.nn.ertelecom.ru iperf -c iperf.ips.versatel.de iperf -c iperf.testdebit.info iperf -c iperf.cds.comContinue reading “Speed test (speedtest) / slow speed issue”
To see live traffic on an interface especially external interface (updates every second)
watch -n 1 /sbin/ifconfig ethC To check the latest NIC drivers in the database for the Smoothwall’s linux kernel #lspci -nnn (to check the ethernet controllers and the hardware detected by smoothwall)(To check the company ID and the unique hardware ID i.e. PCI-ID) (to check the ethernet controllers and the hardware detected by smoothwall) orContinue reading “To see live traffic on an interface especially external interface (updates every second)”
To enable or disable the network interface
#ip link set ethX up #ip link set ethX down
CPU usage Linux scripts and commands
Script to run top command after every 5 minutes CPU utilization: #!/bin/sh top -b -n 1 | head -17 >> /var/log/logging.txt echo “=========” >> /var/log/logging.txt To show CPU and process information (press q to quit): #top (resource usage and running processes) (uptime and the load average) (CPU usage: us for users, sy for system andContinue reading “CPU usage Linux scripts and commands”