Most day-to-day administration comes down to finding, inspecting, copying and moving files. These commands appear everywhere on the exam, often inside a larger scenario about disk space, permissions or troubleshooting, so it pays to know their most useful options by heart and to understand the inode model underneath them. ls lists directory contents. ls -l gives the long format: type and permissions, link count, owner, group, size, modification time and name. -a shows hidden 'dot' files, -h prints human-readable sizes, -t sorts by modification time, -r reverses the order, -R recurses, -d lists a directory itself rather than its contents, -i shows inode numbers and -Z shows SELinux contexts. The first character of the long listing tells you the type: - regular file, d directory, l symbolic link, b block device, c character device, p named pipe, s socket.
Keep reading for free
Create a free StudyToCert account to read the rest of this lesson: 7 more sections, 6 key terms, a real-world example, an exam tip and self-check questions. Every lesson, lab and practice test is free with an account.