Posted On September 9, 2025

LINUX COMMAND OF THE DAY

admin 0 comments
>> Cybersecurity Journey - Semester 1 >> LINUX COMMAND OF THE DAY

1. cat (concatenate and display file contents)

  • Used to view contents of a file or combine multiple files.
  • Syntax: cat filename

2. less (view file one page at a time)

  • Used for viewing large files page by page (scrollable).
  • Syntax: less filename
  • Controls while inside:
    • Space → move down one page
    • b → move back one page
    • /word → search for a word
    • q → quit

3. head (show beginning of file)

  • Shows the first 10 lines by default.
  • Syntax: head filename

4. tail (show end of file)

  • Shows the last 10 lines by default.
  • Syntax: tail filename

Quick Comparison Table

CommandPurposeDefault Behavior
catDisplay entire filePrints whole file content
lessScroll through filePage-by-page viewing
headShow start of fileFirst 10 lines
tailShow end of fileLast 10 lines

Leave a Reply

Your email address will not be published. Required fields are marked *

Related Post

WHAT IS ENCRYPTION ?

Encryption is the process of converting readable data (called plaintext) into an unreadable format (called…

ANTIVIRUS vs FIREWALL

1. What is a Firewall? A firewall acts as a barrier between your computer or…

DIFFERENCE BETWEEN PRIVATE IP ADDRESS AND PUBLIC IP ADDRESS

FeaturesPublic IP AddressPrivate IP AddressDefinitionAssigned by ISP, identifies your device/network on the internetUsed within a…