100% Free Forever
AI-Powered Learning
Industry Expert Content
Certificates & Badges
Learn At Your Own Pace
Bash

File Permissions Explained (rwx)

Understand the Linux permission model — read, write, and execute bits for owner, group, and others — and how ls -l output maps to those permissions.

Permissions & UsersBeginner8 min readJul 9, 2026
Analogies

File Permissions Explained (rwx)

Linux is a multi-user operating system at its core, and its permission model is what makes it safe for many users (and processes) to share one filesystem. Every file and directory has an owner (a user), a group, and a set of permission bits controlling three kinds of access — read (r), write (w), and execute (x) — for three categories of accessor: the owning user, the owning group, and everyone else ('other'). This nine-bit rwx model, inherited from early Unix, is deceptively simple but underpins nearly all access control on a standard Linux system, from protecting your SSH private key to preventing an unprivileged web server process from overwriting system files.

🏏

Cricket analogy: Like a stadium that lets the home team captain (owner) into the dressing room, the whole squad (group) onto the practice nets, and the general public (other) only into the stands, Linux's rwx model grants different access levels to different categories of people on the same shared ground.

Reading permissions with ls -l

Running ls -l shows a ten-character string like -rwxr-xr-- at the start of each line. The first character indicates the file type (- for regular file, d for directory, l for symbolic link, among others). The remaining nine characters are three rwx triplets in order: owner, group, other. Each triplet position is either the letter (r, w, or x) if that permission is granted, or a dash (-) if it is not. So -rwxr-xr-- means: it's a regular file; the owner can read, write, and execute; the group can read and execute but not write; and everyone else can only read.

🏏

Cricket analogy: Reading -rwxr-xr-- is like reading a scorecard header: the first symbol says it's a completed innings (not abandoned), then three blocks show what the captain, the rest of the squad, and the press box are each permitted to do with the scorebook.

bash
$ ls -l /usr/bin/passwd /etc/shadow /home/alice/notes.txt
-rwsr-xr-x 1 root root   68208 Jan 10  2025 /usr/bin/passwd
-rw-r----- 1 root shadow   1823 Jul  8 09:12 /etc/shadow
-rw-r--r-- 1 alice alice     512 Jul  9 07:40 /home/alice/notes.txt

# Decode /etc/shadow's permissions: rw-r-----
#   owner (root):  read, write
#   group (shadow): read only
#   other:          no access at all

What r, w, and x mean for files vs. directories

The three permission bits mean subtly different things depending on whether they apply to a regular file or a directory. On a file: r lets you read its contents (e.g. with cat), w lets you modify or truncate it, and x lets you execute it as a program or script. On a directory, though: r lets you list the names of entries inside it (ls), w lets you create, rename, or delete entries inside it (which is why deleting a file actually depends on the containing directory's permissions, not the file's own), and x (often called the 'search' or 'traverse' bit) lets you cd into it or access files inside it by path at all — without x on a directory, even knowing a file's exact full path won't let you open it.

🏏

Cricket analogy: The 'x' bit on a directory is like the gate to the players' pavilion: even if you know exactly which locker holds the bat (the file's path), you can't reach it without permission to walk through the pavilion gate itself, separate from being allowed to open the locker.

Numeric (octal) notation

Permissions are frequently expressed as a 3-digit octal number instead of the rwx letters, because each rwx triplet maps directly onto 3 bits: r=4, w=2, x=1, and you sum the values you want. A single digit therefore ranges from 0 (---, no access) to 7 (rwx, full access). The permission -rwxr-xr-- becomes 754 (owner: 4+2+1=7, group: 4+0+1=5, other: 4+0+0=4). This compact octal form is what chmod most commonly takes as an argument, e.g. chmod 644 file.txt.

🏏

Cricket analogy: Converting -rwxr-xr-- to octal 754 is like a scorer converting a detailed ball-by-ball commentary into a compact numeric scorecard: owner's full rwx (4+2+1=7) plus group's r-x (4+0+1=5) plus other's r-- (4+0+0=4) becomes one tidy three-digit summary.

Historical note: this rwx-for-owner/group/other scheme dates back to Unix in the 1970s and was deliberately kept simple for performance and predictability on early hardware. Modern Linux systems layer more granular access control on top when needed — POSIX ACLs (via setfacl/getfacl) allow permissions for arbitrary additional users or groups beyond the classic three categories, and SELinux/AppArmor add mandatory access control policies — but the base rwx model remains the foundation almost everything else builds on.

A common misconception is that a file's own permissions control whether it can be deleted. In fact, deleting (unlinking) a file requires write permission on its containing DIRECTORY, not on the file itself — you can delete a read-only file if you own the directory it lives in and have write+execute on that directory. This trips up many beginners who wonder why rm succeeds on a file they marked read-only.

  • Every file has an owner, a group, and three rwx permission triplets: owner, group, other, visible in ls -l as a 10-character string.
  • On files: r = read contents, w = modify/truncate, x = execute as a program.
  • On directories: r = list entries, w = create/rename/delete entries inside, x = traverse into it / access files by path.
  • Octal notation sums r=4, w=2, x=1 per triplet, so rwxr-xr-- becomes 754, and chmod commonly takes this 3-digit form.
  • Deleting a file depends on write permission on its parent directory, not on the file's own permission bits.
  • POSIX ACLs (setfacl/getfacl) and SELinux/AppArmor extend beyond the classic rwx model for finer-grained or mandatory access control.

Practice what you learned

Was this page helpful?

Topics covered

#Bash#LinuxShellScriptingStudyNotes#DevOps#FilePermissionsExplainedRwx#File#Permissions#Explained#Rwx#StudyNotes#SkillVeris

Frequently Asked Questions

21 categories · pick one to explore

Where can I get free study notes for programming and tech subjects?
SkillVeris offers completely free study notes covering programming and tech subjects, with no signup fees or paywalls. The notes are structured by course and topic, written for quick understanding, and enriched with the Learn Through Hobbies analogy method, so you can revise concepts through cricket, music, gaming, cooking and more.
Are SkillVeris study notes good for exam revision?
Yes, the study notes are designed for efficient revision: each topic answers its heading immediately, keeps explanations concise, and links to related glossary terms and cheat sheets. Students preparing for university exams or certification tests use them as quick revision notes because they distil concepts without the padding of full textbooks.
What subjects do the free study notes cover?
The study notes span the platform's main domains, including AI and machine learning, Python and programming, web development, DevOps, cloud, security and databases. Coverage mirrors the 37 live courses, so notes exist for the topics you are actually studying, and new note sets are added as courses launch.
How are SkillVeris study notes different from regular textbooks?
The notes are answer-first, concise and free, whereas textbooks are long and often expensive. Each section explains one concept directly, then reinforces it through selectable hobby analogies like cricket or cooking. Notes also cross-link to the glossary, blog and cheat sheets, letting you jump to related material instantly instead of flipping pages.
Can I use the developer study material without creating an account?
The study notes are free to access, and SkillVeris does not charge anything for its developer study material at any point. Browsing notes is straightforward from the Study Notes section, and if you want progress tracking, certificates and AI Mentor conversations tied to your learning, a free account unlocks those extras.
Do the study notes explain concepts with analogies?
Yes, this is a signature SkillVeris feature. Study notes use the Learn Through Hobbies method, explaining technical concepts through analogies from twelve domains including cricket, music, gaming, photography, travel, movies, fitness, chess, cooking, finance, business and sports. You can switch the analogy domain instantly to whichever hobby makes the concept click.
Are the revision notes suitable for last-minute exam preparation?
Yes, revision notes on SkillVeris work well for last-minute preparation because every section states the answer in its first sentences, so skimming is genuinely effective. Pair them with the relevant cheat sheet for formulas and syntax, and use the glossary for any unfamiliar term you meet while cramming.
Is there free study material for AI and machine learning?
Yes, SkillVeris provides free study notes across its AI and ML catalogue, covering Python for AI, deep learning frameworks like PyTorch and TensorFlow, Hugging Face Transformers, Large Language Models, RAG, AI agents and MLOps. All of it is free, making it a strong resource for Indian students and global learners alike.
Can beginners understand the study notes, or are they for experts?
Beginners can absolutely use them. The notes are written in plain language, define terms as they appear, and lean on hobby analogies to make abstract ideas concrete. Difficulty scales with the underlying course level, so beginner-course notes stay gentle while advanced-course notes go deeper, and the glossary supports you throughout.
How do study notes connect with SkillVeris courses?
Study notes are organised by course and topic, so they map directly to the structured courses and their 24–40-lesson curriculum. Many learners study a lesson first, then use the matching notes for revision before module assessments and the final exam, where 80 percent is required to pass and earn the certificate.
Are there study notes for Python specifically?
Yes, Python is well covered through notes tied to the Python-focused courses, including Python for AI and ML. Topics span fundamentals through applied machine learning usage. You can reinforce the notes with Python practice in Code Lab, which runs code in your browser with no installation required.
Do the study notes include code examples?
Yes, study notes include code examples wherever a concept is best shown in code, alongside explanations, key points and analogies. Reading a snippet in the notes and then reproducing it yourself in Code Lab is an effective loop, since Code Lab lets you run code in the browser across six languages.
How often is new study material added to SkillVeris?
Study material grows alongside the course catalogue. Whenever new courses join the platform's 37 live courses, matching study notes, glossary entries and cheat sheets are added so the resources stay in sync. Existing notes are also refined over time, so it is worth revisiting topics you studied earlier.
Can I use SkillVeris notes to prepare for technical interviews?
Yes, the notes make excellent interview revision because they compress each concept into direct, answer-first explanations, which mirrors how you should answer interview questions. Combine them with the SkillVeris interview questions feature, which includes readiness scoring, to test whether your revision has actually made you interview-ready.
Are the study notes mobile-friendly for studying on the go?
Yes, the study notes are built to load fast and read comfortably on mobile devices, so you can revise during a commute or between classes. Sections are short and answer-first, which suits small screens, and analogy switching works on mobile too, letting you study anywhere without carrying books.
What is the difference between study notes and cheat sheets?
Study notes explain concepts in depth with context, examples and analogies, making them ideal for learning and revision. Cheat sheets are compact quick-reference summaries of syntax, commands and key facts, ideal once you already understand a topic. Most learners study the notes first, then keep the cheat sheet handy while coding.
Do study notes help if I am stuck on a course lesson?
Yes, reading the matching study notes often clarifies a lesson because the same concept is explained from a different angle, frequently with a different analogy. If you are still stuck, ask the AI Mentor, which answers 24/7 at Quick, Detailed or Deep-dive depth until the idea genuinely makes sense.
Is there free study material for DevOps and cloud topics?
Yes, SkillVeris carries free study notes for DevOps and cloud topics as part of its coverage across 37 live courses. The material suits learners following the DevOps Engineer or Cloud Engineer paths, and it links to related glossary terms and cheat sheets so you can revise the whole toolchain in one place.
Can school or college students in India use these notes for projects?
Yes, students across India and worldwide use SkillVeris notes for coursework, projects and exam preparation, and everything is free, which matters for student budgets. The notes explain concepts clearly enough to cite in project reports, and Code Lab lets you prototype the project code directly in your browser.
How should I combine study notes with other SkillVeris resources?
A proven loop: learn from a course lesson, revise with the matching study notes, look up unfamiliar terms in the glossary, keep the cheat sheet open while practising in Code Lab, and quiz yourself with interview questions. The AI Mentor fills any remaining gaps 24/7, at whatever depth you need.

What Learners Say

Real journeys from the SkillVeris community — swipe for more.

SkillVeris taught me Python through Cricket. Now I’m building real projects and feeling confident!
Arjun S. · B.Tech Student
The best platform for hobby-based learning. Concepts finally stick.
Priya R. · Data Analyst
I went from zero coding to a portfolio of projects — all by learning through my love for gaming. Landed my first internship!
Kabir M. · CS Undergraduate
Trending Topics50 popular tags — tap to explore
Trending CoursesAll 37 free courses — tap to browse