How to log CPU usage over a period of time on Linux.

Logging CPU usage over a certain period of time is very easy. The command below will print 24 lines of CPU statistics, printing a line every 4 seconds. ┌──[[email protected]]─[~] └──╼ ╼ $ sar -u 4 24 –human Linux 5.8.0-41-generic (jason-desktop) 12/04/21 _x86_64_ (4 CPU)   09:05:33 CPU %user %nice %system…

Read More

Windows 8.1 still very annoying and insecure these days.

Windows 8.1 at the moment is giving me a lot of problems. There is constant disk activity at 0.1 megabytes per second. This is very annoying, there are Windows services doing this, but it only recently started. T think it is better to use Linux instead, which does not have…

Read More

Use the find command in Linux to look for multiple file types at once.

The Linux find command is useful for finding files on your Linux system. It is possible to look for more than one file type. This example will search for all text and png files under the /usr/share directory. jason@neo:/usr/share$ find -regex ‘.*txt\|.*png’jason@neo:/usr/share$ find -regex ‘.*txt\|.*png’ This example will search for…

Read More

Get information about your network connection with netstat on Windows.

Get network information on Windows with netstat Netstat on Windows can provide a lot of information about your network connection. This example shows netstat showing Ethernet statistics. c:\Windows\System>netstat -e Interface Statistics   Received Sent   Bytes 2307072092 27407417 Unicast packets 1757202 320154 Non-unicast packets 0 0 Discards 0 0 Errors…

Read More

How to see free memory on a Linux machine with the free command.

The free command in Linux is used to show the amount of free memory in Linux. The example below shows the default usage of this command. ubuntu@ip-172-31-0-140:~$ free total used free shared buffers cached Mem: 602736 294680 308056 16928 17632 146320 -/+ buffers/cache: 130728 472008 Swap: 0 0 0ubuntu@ip-172-31-0-140:~$ free…

Read More

Using the iostat command to keep track of disk usage on Linux.

This example shows the iostat command printing information about disk usage on my Ubuntu system. jason@jason-desktop:~$ iostat Linux 4.6.0-rc1-jason (jason-desktop) 01/05/16 _x86_64_ (4 CPU)   avg-cpu: %user %nice %system %iowait %steal %idle 2.50 0.43 1.28 24.37 0.00 71.42   Device: tps kB_read/s kB_wrtn/s kB_read kB_wrtn sda 1.49 147.22 0.00 64455…

Read More

Using the tar command on Debian Linux.

The Linux shell offers many ways to compress files for backup. The tar or tape archive program will concantenate many files into one. tar –create –verbose myfile.tar file1 file2 file3 file4tar –create –verbose myfile.tar file1 file2 file3 file4 Then you may use either the gzip or bzip commands to compress…

Read More