Linux: Clear Memory Cache

unix linux

The Linux kernel uses unused main memory as a cache to keep page cache, filesystem dentries and inodes. The use of the cache or buffer memory accelerates access to files stored on non volatile storage such as hard disks. The cached items can be cleared from memory by sending a signal to the Linux kernel using the /proc filesystem or the sysctl command.

Linux: How to Monitor File System for Changes

unix linux

The Filesystem notification APIs allows applications to watch certain files and be notified when they are opened, modified, deleted, or renamed. This greatly aids the applications, because before such filesystem event monitoring tools existed, such applications would have to read the disk repeatedly to detect any changes, which resulted in high disk and CPU usage.

How to Watch Singapore Free to Air Channels Online

MediaCorp Singapore offers 7 FTA (free-to-air) terrestrial television channels. Both Pay-TV operators, StarHub and SingTel, bundle the FTA channels together with their Pay-TV subscription packages.

Shell Script: Epoch Time to Human Readable Time

shell script

Log files are sometimes written with epoch timestamps. To analyse the log file entries, we will first need to convert the time to a human readable format. In this article, we will look at a few available methods to convert the epoch time to real time or human readable time.

Linux: Check CPU for 64-bit Support

unix linux

To check for a 64-bit capable CPU on a x86 system running on Linux, we can make use the /proc/cpuinfo file. Note that this will not determine if the OS is 64-bit or not. It will only determine if the CPU is capable of running a 64-bit OS. To check if the Linux OS is running 32-bit or 64-bit, you can refer to this article instead.

Linux: How to Check If Linux Kernel is 32 or 64 Bit

unix linux

When writing configure scripts, it’s good to check if we are running on a 32-bit or 64-bit kernel or OS on a x86 system. There are a few ways to determine the machine architecture of a Linux system.

Android: Spinner Text Is White on White Background

source code

On Android, if you have a Spinner widget inside a Fragment, the Spinner could have white text on a white (or on a Light theme) background. The problem is most often due to an incorrect reference to the Context object.

Linux: IO Performance Tuning with noatime, nodiratime, relatime

unix linux

The POSIX standard mandates that operating systems maintain file system metadata that records when each file was last accessed. This timestamp is known as atime and atime comes with a performance penalty – every read operation on a filesystem generates a write operation.