Removing files incorrectly can end badly. Linux supports asking for confirmation before deleting files using the interactive option. Linux also provides rmdir a safe way to delete empty directories. Using both of these and testing file globs with ls before utilizing them will make deleting files safer.
- [Narrator] We have a couple of commands dedicated…to removing files and directories, namely rm and rmdir.…You may want to note that on the command line,…Linux doesn't have a recycle bin.…If you delete a file, it is for…all practical purposes, deleted.…Be careful, recovering files requires extra work.…Let's create a directory for this exercise and cd into it.…In a terminal, type in mkdir space rmexercise…and hit Enter.…Then type in cd rmexercise and hit Enter again.…
You can verify your path by typing in pwd.…Now that we have a directory and we've changed into it,…let's create some files.…Type in mkdir space dir left curly bracket,…1 comma 2, right curly bracket and hit Enter.…I've used brace expansion to create two directories…called dir1 and dir2.…You can verify this by typing in ls.…Now let's type in touch space dir1 slash file1 dot txt.…
This will create a file inside the directory named dir1.…Let's create a couple more files by typing in…touch space file, left curly bracket, a comma,…b comma, c comma, d right curly bracket dot txt.…
- Define file Access Control Lists.
- Describe what extended globs add to Linux pattern matching.
- State why file system recovery tools are so important for Linux users.
- Recall what execute permissions on a directory allows.
- Cite the maximum allowed default permissions on a file in Linux.
- List some of the advantages of ACLs over standard Unix permissions.
Skill Level Intermediate
Linux: Desktops and Remote Accesswith Grant McWilliams1h 44m Intermediate
1. Linux Files
2. Manipulate Files
3. Standard Unix Permissions
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
This will not affect your course history, your reports, or your certificates of completion for this course.Cancel
Take notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.
Notes are saved with you account but can also be exported as plain text, MS Word, PDF, Google Doc, or Evernote.