Linux is an open-source, Unix-like operating system kernel created by Linus Torvalds in 1991. The kernel is the core part of the operating system, managing system resources and hardware interactions.
This is a thorough template for an Ubuntu learning guide that covers everything from downloading Multipass **to **system information, file and directory operations, search and locate, and text file editing. Ubuntu is a popular Linux distribution developed by Canonical.
Download and configure Ubuntu Desktop:
- https://ubuntu.com/download/desktop.
After it has been successfully installed, it appears like this. Go ahead, configure and start running any virtual machine.
This is what it looks like once it is ready for use: To run command as an administrator (user "root"), use "sudo "
I'll now go over how to use Powershell to operate an Ubuntu virtual machine.
- We begin by identifying the "Root user" and using this command to do so "sudo su" as seen below.
Navigating the file system
ls: List directory/file content. These shows the contents in the directory/file as shown below. Although we haven't done anything but the command is important and will revisit it.
mkdir: To create a directory/file. Make we will be create some and listing them out using the ls command.
cd ..: Move you in and out directory level. cd as means change directory.
To play around with firsts of commands and introduce some common commands like:
history: this shows you all commands carried out
exit: Exit the root/ or current path.
cp: Copy file or directory. I copied a file into directory Busaspace1 and leaving the original copy in it folder
mv: move file to different locations/paths. Just like the command "cp". Moving a file to directory Busaspace2.
Viewing and Editing files
- cat: Display the contents of a file. After editing a file using the command "vim", I used cat to show the content edited without opening the whole file
vim: is an editor. Open file and allows you to edit a file after pressing the i key for insert.
System Information and Management
uname -a: Display detailed information about the system
df -h: Display disk space usage.
free -h: Displays usage and available space
- top: Display running process and system resource usage. And to stop it press Ctrl C if the terminal keeps running.
Search and Find/Locate
-grep [pattern or search item][file]: Search for a pattern within a file.
How to quit a text editor
![quit](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/72mid4izrxay8kwns4pw.png\
Task
- How does one quit a vim file?
- how do you list the content of a directory?
- what command can be used to delete the content of a directory?
- What command can be used to switch from a normal user to a root user?
Top comments (0)