-
Step 1
Log into the Unix system with your user name and password.
-
Step 2
Open a command line window. In most Unix GUI environments, click on the icon that looks like a computer terminal.
-
Step 3
Type "touch filename" to create a file called "filename." This command creates a zero length file called filename. This method is commonly used to create lock files, where a program will stop running if it detects a lock file exists, which means another instance of the same program is running.
If the file already exists, this command updates the last modified date and time attribute for the file without changing the contents of the file. -
Step 4
Type "cat /etc/hosts > filename". This command copies the content of the /etc/hosts file into a new file called filename. This is a good way to create a new file with data in it.













