From the course: Red Hat Certified System Administrator (EX200) Cert Prep: 1 Deploy, Configure, and Manage (2021)
Unlock the full course today
Join today to access over 22,600 courses taught by industry experts or purchase this course individually.
Remove files and directories
From the course: Red Hat Certified System Administrator (EX200) Cert Prep: 1 Deploy, Configure, and Manage (2021)
Remove files and directories
- [Instructor] 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 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 dir{1,2} 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 dir1/file1.txt this will create a file inside the directory named dir1. Let's create a couple more files by typing in touch file{a,b,c,d}.txt and hit enter. We can verify our…
Practice while you learn with exercise files
Download the files the instructor uses to teach the course. Follow along and learn by watching, listening and practicing.
Contents
-
-
-
-
-
(Locked)
Use input-output redirection (>, >>, |, 2>, and more)5m 2s
-
Use grep and regular expressions to analyze text5m 55s
-
(Locked)
Archive files using tar4m 40s
-
(Locked)
Compress files and archives4m 14s
-
(Locked)
Create files and directories5m 18s
-
Copy files and directories5m 48s
-
(Locked)
Move files and directories4m 59s
-
(Locked)
Remove files and directories6m 2s
-
(Locked)
Create hard and soft links4m 55s
-
(Locked)
Introduction to vim3m 33s
-
(Locked)
Editing text with vim2m 45s
-
(Locked)
Locate, read, and use system documentation5m 2s
-
(Locked)
Locate and interpret system log files6m
-
(Locked)
Reading the system journal3m 18s
-
(Locked)
-
-