0% found this document useful (0 votes)
12 views

Activity Steps

Uploaded by

yashodha.p
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
12 views

Activity Steps

Uploaded by

yashodha.p
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 2

Activity Steps:

1. Open Terminal:
o Launch the terminal application on your Linux system. You can typically find
it in the applications menu or by using a keyboard shortcut like Ctrl + Alt +
T.
2. Navigate the File System:
o Use the following commands to navigate around the file system:
 pwd: Print the current working directory.
 ls: List directory contents.
 cd: Change directory.

Example:

bash
Copy code
pwd # Shows the current directory
ls # Lists contents of the current directory
cd / # Change to the root directory
ls # Lists contents of the root directory

3. Create and Manipulate Files:


o Practice creating and manipulating files with commands like:
 touch: Create an empty file.
 mkdir: Create a new directory.
 cp: Copy files or directories.
 mv: Move or rename files or directories.
 rm: Remove files or directories.

Example:

bash
Copy code
touch example.txt # Creates a new file named example.txt
mkdir mydirectory # Creates a new directory named mydirectory
cp example.txt mydirectory/example.txt # Copies example.txt into
mydirectory
mv example.txt newname.txt # Renames example.txt to
newname.txt
rm newname.txt # Removes newname.txt

4. View File Contents:


o Use commands like cat, less, or head to view the contents of files.

Example:

bash
Copy code
cat example.txt # Displays the contents of example.txt
less example.txt # View contents of example.txt with navigation
(press 'q' to exit)
head -n 10 example.txt # Displays the first 10 lines of example.txt
5. Execute Basic Commands:
o Practice running basic commands such as date, cal, or echo.

Example:

bash
Copy code
date # Displays the current date and time
cal # Displays a calendar for the current month
echo "Hello, Linux!" # Prints the text "Hello, Linux!"

6. Explore Command Options:


o Experiment with command options and flags to see how they modify
command behavior. Use the man command (e.g., man ls) to view the manual
pages for commands and learn about their options.

Example:

bash
Copy code
ls -l # Lists contents in long format
ls -a # Lists all files including hidden ones

7. Reflect and Experiment:


o Take note of any commands or concepts that are new or challenging.
o Experiment with combining commands and using them in different contexts.

Conclusion: This activity provides a hands-on introduction to basic Linux commands,


helping you become comfortable with navigating the file system, manipulating files, and
executing commands. It's a foundation for further exploration and learning in the Linux
environment.

You might also like