Posts

Showing posts from March, 2014

How to check file type in linux ?

In our last post we saw which are the different file types in linux and how to identify different file types from ls -l output. But we have a command called file to determine the file type. file command tests each file prints the fileype. The syntax for file command is

What are the different file types in linux

Image
"In a UNIX system, everything is a file; if something is not a file, it is a process ." - Unix Philosophy The above quote  is one of the philosophies Linux has inherited from Unix. i.e.  in Linux everything is a file, be it a regular text file, directory or a hardware component like hard disk. In Linux, files are classified in to 7 types. They are Regular Files Directory Block Files Character Files Symbolic Link Files Socket Files Named Pipe Files

How to search and find location of a file in linux ?

In linux there are mainly two methods by which a file's location can be searched. They are locate command find command

How to remove a file in linux ?

rm is one of the basic commands used to remove a file in linux. rm can be used to remove a file, directory, device nodes, links and so on.The rm syntax is given below

How to move or rename a file in linux?

mv (short form for move) command is the linux command used to move a file from one location to another. Just like moving the file location, mv can move file names from one name to another. i.e with mv command can be used to rename a file. The syntax for mv command is as follows