chmod +t /tmp/shared

Category: Administration

chmod +t /tmp/shared

Set the sticky bit on a directory

The sticky bit means only the file owner, the directory owner, or root can delete files inside the directory, no matter who has write access. /tmp is the classic example and shows a t in the last permission position. Run chmod +t on shared drop folders to stop users deleting each other's files.
Looking for more? Search all 7,657 commands — works offline, in English or Spanish, and fixes typos.