There is a lot of garbage in the tmp directory in the centos7 system. If you want to clear the garbage, how should you do it? Let’s take a look at the detailed tutorial below.
To view the list of files in the tmp file directory, execute the command cd tmp/ to switch to the current file directory of tmp, and execute the ll command to view the list of files in the current directory. As shown below.
Use the rm command to delete files. It should be noted that the rm command deletes files from the system forever. Therefore, it is recommended that when using the rm command, it is best to delete the file. Prompt beforehand. Use the command rm -i file name, wait for the user to confirm deletion (y) or skip deletion (n), and the system will perform corresponding operations. As shown below.
The above is the detailed content of How to access and clean junk files in /tmp directory in CentOS 7?. For more information, please follow other related articles on the PHP Chinese website!