In Linux and other *NIX systems, we have a facility called cron. This wakes up every second, reads a file where all processes that need to be started up automatically on a timed basis is entered and executes those that match. You can see this file by typing ‘contab -e’ in the prompt. Every user has a crontab and we also have a system-wide crontab owned by root.
The crontab entry will look like
The 5 asterisks are wildcards for seconds, minutes, hours, day of the month, month, day of the week
eg. If you give 2 in the first place, the command will be executed on the 2nd second of every minute. If you say*/20, then the command will be executed 20 times in a minute. For a deeper explanation, please see https://www.pantz.org/software/cron/croninfo.html