DriversRecommendedOutdated drivers can make a good PC feel brokenScan driver issues before chasing fixes manually.Scan NowOctober DealsAmazon USOctober deal check: compare before you payAmazon US: current deals, useful picks and tech finds.Check DealsClean PCRecommendedOne scan can reveal what keeps slowing WindowsLook for cleanup and repair opportunities.Run Scan×
Skip to content
VGSources
Blog

Linux File Permissions and Ownership Explained for Server Admins

A practical administrator’s guide to Linux ownership, chmod numbers, directory semantics, special bits, umask, POSIX ACLs and a safe troubleshooting workflow.
Length9 min Posted Quest giverVGSources Team
Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Linux access control becomes predictable once you separate three things: the account and group that own a path, its classic mode bits, and any ACL or system-level control layered on top. Inspect those in that order, then make the narrowest change that fixes the problem. This guide explains how to read permission strings, translate chmod numbers, change ownership safely, account for directories and special bits, and diagnose denials involving umask and POSIX ACLs.

The three questions to answer for every path

When a process cannot open, create, delete or execute something, identify these facts before changing anything:

As an Amazon Associate I earn from qualifying purchases.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
  • Who owns it? Every inode has a user owner and a group owner.
  • What do the mode bits allow? Linux evaluates read, write and execute/search rights separately for the owner, group and everyone else.
  • Is another control involved? An extended ACL, a special attribute, a read-only mount or a security policy can override what the nine familiar bits appear to say.

Ownership and permissions are different controls. chown changes the user owner and, optionally, group owner. chgrp changes only the group. chmod changes mode bits and special bits; it does not transfer ownership.

How to read ls -l output

A typical line such as -rw-r-----+ 1 alice web 1842 Oct 15 12:10 settings.conf can be read from left to right:

#1 Best Overall
Sale
Gaoye Blue Light Blocking Glasses
  • BLUE LIGHT BLOCKING GLASSES: Our blue light glasses for women boast UV400 protection, blocking harmful blue rays from computer screens. With these bluelight glasses women, you can enjoy gaming, reading, or watching TV with no worries of eye strain.
  • EYE RELIEF: Our blue light glasses are engineered to reduce blurry vision or strain caused by prolonged screen time. These womens blue light glasses aid in better sleep by preventing blue light from disrupting your natural sleep cycle, helping you fall asleep faster and enjoy a more restful night's sleep, making them the perfect christmas present.
  • COMFORTABLE: Crafted from durable material, our trendy blue light glasses for woman or blue light glasses men ensure long-lasting comfort. The high-transmittance lenses accessories, gamer gifts for men, help keep your eyes relaxed. Perfect stocking stuffers, gifts for gamers men, christmas gifts for men, halloween costumes.
  • LIGHTWEIGHT: These clear blue light glasses feature a lightweight frame, meaning they’ll stay comfy for long-term wear. Perfect as blue blockers glasses for women or mens blue light glasses, these non-prescription fake glasses for men can be worn throughout the day. The blue light blocking glasses women feature polycarbonate HD lenses, which are anti-reflective and restore true color.
  • WORRY-FREE PURCHASE: If you experience any issues, our support team is ready to assist you quickly. These are the perfect costume glasses for cosplay dressing up.
  • The first character identifies the file type. A hyphen is a regular file; d is a directory; other characters identify objects such as symbolic links or devices.
  • The next nine characters are three groups of three: owner, group and other.
  • The username and group name after the link count are the inode’s user and group owners.
  • A trailing + after the mode means extended ACL data is present on ACL-aware systems. Use getfacl rather than assuming the nine mode characters tell the whole story.

Read the permissions in class order: owner, group, other. In -rw-r-----, the owner has read and write, the group has read, and everyone else has no rights. A capital letter such as S or T can indicate a special bit whose corresponding execute bit is not set.

What read, write and execute mean

Regular files

  • Read (r) permits obtaining file contents.
  • Write (w) permits changing contents; it does not by itself permit deleting the directory entry that names the file.
  • Execute (x) permits running the file as a program, subject to the file format and interpreter requirements.

Directories

  • Read permits listing names in the directory.
  • Write permits creating and removing directory entries, but practical use normally also requires execute/search.
  • Execute/search permits traversing the directory and accessing an entry when its name is known.

Directory access is cumulative along the entire path. A service may have permission on /srv/app/config.yml but still fail if it lacks search permission on /srv or /srv/app. To inspect each component, use namei -l /srv/app/config.yml where available, or run ls -ld on each parent.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Converting chmod numbers into rights

Each classic permission class uses a three-bit value: read is 4, write is 2 and execute is 1. Add the values for owner, group and other to form a three-digit mode.

Digit Rights Meaning
0 — No rights
1 –x Execute/search only
2 -w- Write only
3 -wx Write and execute/search
4 r– Read only
5 r-x Read and execute/search
6 rw- Read and write
7 rwx Read, write and execute/search

For example, chmod 640 file sets owner read/write (6), group read (4), and no rights for other (0). chmod 750 program gives the owner full access, the group read and execute, and other execute only.

Rank #2
Windex Gaming Cleaning Wipes, Pre-Moistened Wipes to Instantly Clean all Gaming Gear and Electronics, Resealable Packaging for a Freshness Lock, 25 count (Pack of 1)
  • WINDEX GAMING WIPES: effortlessly clean all your gaming gear and gaming electronics in one easy step with our new Windex Gaming Wipes
  • AMMONIA FREE: our ammonia-free formula is safe to use on all of your favorite gaming equipment like consoles, headsets, controllers, screens, keyboards, and more
  • PRE-MOISTENED WIPES: each wipe instantly removes dust, dirt, and stubborn smudges and fingerprints leaving a streak-free shine
  • ANTI-STATIC: great for cleaning and wiping down your gaming gear and electronics leaving behind no visible residue
  • COMPACT RESEALABLE PACKAGE: store your pack of Windex Gaming Wipes anywhere in your home for whenever a quick and easy wipedown is needed

A fourth, leading octal digit controls special bits:

Digit Bit Typical use
4 setuid An executable runs with the file owner’s effective user identity.
2 setgid An executable runs with the file group’s effective group identity; on most directories, new entries inherit the directory’s group.
1 sticky In a directory, users generally may remove or rename only entries they own (or an administrator may); commonly used on shared temporary directories.

Thus chmod 2770 /srv/team sets setgid plus rwx for owner and group and no rights for other. A mode such as 1777 is appropriate only for a deliberately world-writable directory that also needs sticky deletion protection; using it on ordinary application data is unsafe.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Symbolic chmod for targeted changes

Use symbolic mode when you need to change one dimension while preserving unrelated bits. The form is who operator permissions, where u, g, o and a mean owner, group, other and all; operators are +, - and =.

  • chmod g+rX directory adds group read and adds execute only to directories and files that already have an execute bit.
  • chmod o-rwx file removes all rights for other.
  • chmod u=rw,go= file establishes a private regular-file mode without changing ownership.
  • chmod g-w config removes group write while retaining any existing group read or execute bit.

Use an explicit octal mode when establishing a complete, known policy. Before applying either form, inspect a sample with ls -l and confirm that the path is the intended one.

Changing owners and groups

chown: user and group ownership

chown appuser:appgroup /srv/app/config.yml sets both owners in one operation. Omitting the colon and group changes only the user: chown appuser /srv/app/config.yml. Use a narrowly scoped path first, then verify with stat or ls -l.

Rank #3
Sale
LISEN Cell Phone Stand Phone Holder for Desk, Office Decor Gadgets for Men
  • Ergonomic & Adjustable Design: Fight "text neck" and improve your posture. Designed for comfort, it offers an adjustable height (7.1in-8.5in) (1.4in adjustable range) and angle (5°-85°) Please note: cell phone stand is only 9 inches tall—the length of a standard pencil
  • Without blocking subtitles Perfect for office desk Tiktok Face Time Zoom video—this is the ultimate kitchen desk essential for phones! Perfect viewing experience while reducing neck back strain, A must-have for gamers streamers desk, and anyone who values both style and support!
  • Sleek & Stable Design fits Otterbox Case: Say goodbye to bent cables, tangles, and tip-overs! LISEN’s stylish adjustable desk phone holder features a built-in charging hole and smart cable management, keeping your phone secure and your workspace clutter-free cool gadgets for men
  • ANTI-SLIP DESIGN free hands: The under 10.00 items easy gadgets back and the bottom of this kitchen essentials for women are fully covered by anti-skid silicone, which LISEN stand up desk decor can provide maximum protection device from any scratches and slides
  • Your Perfect Viewing Companion:If your product arrives damaged or breaks within 365 days, reach out to LISEN for a quick and hassle-free solution. Struggling with assembly, like tightening the screw? We’ve got your back! Your experience matters to us. (Product including: phone Holder stand*1, screw*1, hexagon screwdriver*1, specification*1)

chgrp: group only

chgrp appgroup /srv/team/report.csv changes the group while leaving the user owner intact. This is useful when ownership is correct but collaboration should be granted through a different Unix group.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Recursive changes

chown -R and chmod -R are high-impact operations. They can modify service files, nested directories and symbolic-link targets, and a recursive mode applied uniformly can remove required directory search bits or add execute bits to data files. Review the exact path, preview a representative listing, and prefer separate commands for directories and regular files when their policies differ.

Setgid and sticky directories for shared workspaces

A common team-directory design is a dedicated group, membership for every collaborating account, and a setgid directory such as 2770. The setgid bit causes newly created entries to inherit the directory’s group on most Linux filesystems, reducing group drift. It does not automatically make files group-writable; the creating process’s mode and umask still matter.

Verify group membership with the system’s account tools and have users start a new login session after membership changes where required. For a directory where users may create files but must not delete one another’s files, add the sticky bit, for example chmod 3770 shared when both setgid and sticky behavior are intentionally required.

How umask changes newly created objects

The process umask removes permission bits during creation. It affects system calls such as open and mkdir; it is not a repair command for existing files.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Rank #4
Ledagic IC+RGBW USB Powered Led Light Bar with App & Remote Control, 2 Pack
  • Easy Installation: Our gaming lights have been designed to enhance your entertainment experience. Simply position the led light bar next to your TV or game console to create a game room environment with ease. They come with USB power and a 60 inch cord for direct mounting and mobility
  • Audio Syncing & Extensive Mode: The built-in high-sensitivity music sensor allows you to sync the TV led lights to your favorite music. Lights react and move to the beat of music, film and game audio, creating an incredible immersive sound and light experience – and all without the need for an additional hub. You can choose from 64+ patterns, including strobe, illusion, jump, energy, gradient, running, chasing, fluttering mode etc. Each mode can be applied to different scenes
  • 64+ Chasing IC+RGB & W Effect: The independent control design of IC+RGB and white all-in-one multifunctional rgbw led bar lights monitor backlight allows you to easily switch the led lights for desk between IC+RGB and white to enjoy a variety of lighting effects, you can choose white lighting mode with high brightness for better illumination when working, etc. Choose IC+RGB lighting mode when you need to create an entertaining atmosphere for the light show, 16 million colours of Color changing rgb light bar let you dance to the beat and create a dynamic party atmosphere
  • Dynamic and Dimmable Lights: 1%-full brightness free brightness adjustment gives you the flexibility to adjust dimmable led light bar for room decorations or a variety of occasions
  • USB Powered: USB light bars for room can be powered by powernank, usb charger, TV, Monitor, laptop PC mainframe, making behind TV led lighting bar easy to install in any location.TV led lights are powered by the TV usb interface / PC mainframe, can be turned on/off synchronously with TV / PC

For a regular file requested with mode 0666 and a 022 umask, the resulting mode is 0644: the owner can read and write, while group and other can read. Directories are commonly requested with execute bits (for example 0777), so the same umask commonly yields 0755. The creating program can request a different base mode, and a default ACL can further change the result.

Check the effective setting in the shell or service context with umask. A shell’s umask does not automatically describe a daemon launched by a service manager, container runtime or supervisor; inspect the environment that actually creates the object.

Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

POSIX ACLs when three classes are not enough

Classic modes can express one owner, one owning group and other. POSIX ACLs add named-user and named-group entries and can define default entries on directories for inheritance. They are appropriate when one additional account needs access without placing every user in the owning group, or when a shared tree needs an inherited policy that mode bits alone cannot represent.

Use getfacl path to display access ACL entries and, for directories, default ACL entries. A mask entry limits the effective rights of named users (other than the owner), named groups and the owning-group entry. getfacl may show an effective-rights comment when the mask reduces what an entry appears to grant.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Best Value
Sale
HUANUO FlowLift™ Dual Monitor Stand, Fully Adjustable Gaming Monitor Desk Mount for 13–32″ Computer Screens, Full Motion VESA 75x75/100x100 with C-Clamp & Grommet Base, Each Arm Holds 4.4 to 19.8 lbs
  • Compatible with Wide Screens - To ensure compatibility with the dual monitor mount, your each monitor must meet three conditions at the same time: First, computer screens size range: 13 to 32 inches. Second, screen weight range: 4.4 to 19.8 lbs. Third, the back of the monitor screen must have VESA mounting holes with a pitch of 75x75mm or 100x100mm.
  • Regarding the compatibility with desks - Your desk must meet three conditions at the same time: First, desk material: Only wooden desks are recommended, plastic or glass desks cannot be used. Second, desk thickness range: 0.59" - 3.54". Third, the bottom of the desk should not have any cross beams or panels, as this will interfere with installation. We recommend carefully checking that your desk and monitors meets all above conditions before purchasing.
  • Dual C-Clamp Hold - Worried your dual monitors might wobble or slip? Our upgraded base uses a larger platform plus a dual C-clamp structure to lock the dual monitor arm firmly to your desk. Each arm safely keeps your screens steady while you type, click and game—no shaking, no sliding, just a clean and secure setup you can trust every day. It also provides Grommet Mounting installation choice, both options ensure stable and secure fixation for your 0.59" - 3.54" desk.
  • Full-Motion Adjustment For Comfortable View - Pull the screen closer when you’re deep in a spreadsheet, push it back to watch videos, or rotate to portrait for coding — moving everything smoothly with just one hand. The monitor stand offers +85°/-50° tilt, ±90° swivel and 360° rotation. Raise your monitor up to 15.75″ to support a healthy sitting posture. Whether you’re working from home, gaming through the night, or switching between video calls and documents, getting the screens to your natural line of sight helps relieve neck, shoulder and back strain so you can stay focused longer with less fatigue.
  • Keep Your Desk Organized: By lifting both screens off the desktop, this dual monitor stand opens up valuable space for your keyboard, notebook, docking station or a simple, clutter-free work area. Built-in cable management guides wires along the arms, keeping cords out of sight and out of the way. Enjoy a tidy, modern workstation that looks as good as it feels to use.

For example, an ACL entry can name user backup with read access while leaving the file’s owner unchanged. Set ACLs deliberately with setfacl, then immediately run getfacl to verify both the entry and its mask. A + in ls -l is a signal to perform this check, not proof that a particular user is allowed.

Criterion Classic mode bits POSIX ACLs
Principals One owner, one owning group and other Named users and groups in addition to the owner and owning group
Audit method Compact output from standard ls, stat and chmod Requires ACL-aware inspection such as getfacl
Inheritance Directory setgid handles group inheritance; mode bits alone do not provide named-user defaults Directory default ACLs provide inherited named entries
Portability Compact and broadly portable across Unix filesystems Support and behavior vary by filesystem and Unix implementation
Common trap Cannot express a second independent group policy The ACL mask can silently limit effective rights

A safe permission-change workflow

  1. Inspect first. Run ls -l path, stat path, and namei -l path (or inspect every parent directory). If ls -l shows +, run getfacl path.
  2. Classify the failure. Decide whether the wrong account owns the object, the mode is too restrictive, a parent directory blocks traversal, or an ACL/special control is involved.
  3. Fix ownership only when ownership is wrong. Use a scoped chown user:group path or chgrp group path; do not use ownership changes as a substitute for a missing permission bit.
  4. Choose the narrowest mode edit. Use symbolic chmod to add or remove one right; use octal when you are intentionally defining all three classes and any special bit.
  5. Account for creation policy. Check the creating process’s umask and any parent default ACL before assuming future files will match the current file.
  6. Verify as the service identity. Test the actual account, not only an administrator’s shell. Confirm traversal through every parent and inspect the resulting path with stat and getfacl.
  7. Apply recursion last. If a tree-wide change is unavoidable, review the path, test on a small subset, and separate directory and file rules where necessary.

Diagnosing a permission denied error

Work from the outside of the path inward:

  1. Parent traversal: every directory component needs search permission for the process’s relevant class.
  2. Owner and group selection: confirm the process’s effective user and supplementary groups; Linux does not simply add owner, group and other rights together.
  3. Mode bits: check the required operation—read, write, execute, directory listing, creation or deletion.
  4. ACL and mask: inspect access and default ACLs, including the mask that may reduce an apparently permissive entry.
  5. Special attributes: immutable or append-only attributes can block writes even when mode bits allow them.
  6. Filesystem and policy: a read-only mount, container boundary, mandatory security policy or other service restriction can deny access outside the classic permission model.

Do not “solve” an unexplained denial with chmod 777. That grants read, write and execute/search to everyone in the classic mode and still may not overcome an ACL mask, immutable attribute, read-only mount or security policy. It also expands the blast radius of a compromised process. Identify the failing layer and grant only the required right to the required principal.

Practical patterns

Private configuration readable by a service group

Assign the intended service account and group with chown service:app /etc/app/settings.conf, then use chmod 640 /etc/app/settings.conf. The owner can edit, the group can read, and other users have no mode-bit access. Verify that the daemon actually runs with membership in app.

Team directory with inherited group

Create or select a group, grant the directory to that group, and set chmod 2770 /srv/team. Check that every collaborator belongs to the group. If a named user outside that group needs inherited access, use a default ACL and verify its mask with getfacl.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

One-time access for a backup account

Keep the file’s owner and normal group unchanged, add a named-user ACL for the backup account, and inspect the result with getfacl. Remove the entry when the job no longer needs it; otherwise future administrators may overlook the extra principal because the basic ls -l view only shows a plus sign.

Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.

Leave a Reply

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

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

More quests from Patch Notes

  1. How to Set Up a RedM (RDR2) Server in 2026: License Key, txAdmin and server.cfg, Step by StepBlog11min
  2. Best RedM (RDR2) Server Hosting in 2026: Comparing Four Hosts on Slots, Memory and PriceBlog10min
  3. How to Host a Mindustry Server in 2026: server-release.jar, Port 6567 and the Commands That MatterBlog7min
Recommended PC Tool
Recommended PC Tool
Outdated Drivers Are Slowing You DownFree scan - exact matches
PC Slower Than It Used to Be?Free scan - under a minute

Two free Windows tools

One Free Minute Could Fix That PC

Before you go - each of these free tools takes about a minute and tackles what quietly slows a Windows PC down.

Special offer. View Outbyte info, uninstall instructions, EULA, and Privacy Policy.