Tuesday , 24 January 2017
Home » Tag Archives: rm

Tag Archives: rm

Linux: Tarball Delete ( remove ) File

How do I delete or remove a single file from within a tar ball under Linux operating systems? You can use the following syntax to delete a file from a tar ball:   tar --delete -f example.tar filename Example: Delete a File From a Tar Ball First, create a tar ball for testing purpose using the tar command, enter: # cd …

Read More »

Linux: How To Empty a Directory

How do I empty a directory (delete all files) under Linux / Unix without deleting directory itself? You can use the following commands: [a] rm command – Delete one or more files or directories. [b] find command – Find and delete all files from a specific directory. Linux Empty Directory Using the rm Command Consider the following directory structure: /tmp/ | |------foo/ |---file1 |---file2 …

Read More »

How to delete a file

How do I delete a file under Linux  operating system? To remove a file or directory in Linux use the rm command. rm command syntax rm (short for remove) is a Unix / Linux command which is used to delete files from a filesystem. Usually, on most filesystems, deleting a file requires write permission on the parent directory (and execute …

Read More »