• This is default featured slide 1 title

    Go to Blogger edit html and find these sentences.Now replace these sentences with your own descriptions.This theme is Bloggerized by NewBloggerThemes.com.

  • This is default featured slide 2 title

    Go to Blogger edit html and find these sentences.Now replace these sentences with your own descriptions.This theme is Bloggerized by NewBloggerThemes.com.

  • This is default featured slide 3 title

    Go to Blogger edit html and find these sentences.Now replace these sentences with your own descriptions.This theme is Bloggerized by NewBloggerThemes.com.

  • This is default featured slide 4 title

    Go to Blogger edit html and find these sentences.Now replace these sentences with your own descriptions.This theme is Bloggerized by NewBloggerThemes.com.

  • This is default featured slide 5 title

    Go to Blogger edit html and find these sentences.Now replace these sentences with your own descriptions.This theme is Bloggerized by NewBloggerThemes.com.

Showing posts with label Linux Essential. Show all posts
Showing posts with label Linux Essential. Show all posts

LinuxLab - User management - part I -


Welcome to my second LinuxLab which is a special part of my preparation for LPIC-1. This lab was created according to Linux LPIC-1 Certification Bible where I have recently cover a several chapter including user management in Linux, file permissions, and so on. So, in this article I will focus on four assignments in order to complete this article and to demonstrate how to add a new user, creating a unique user group, setting file permissions and I will show you how to use ssh/sftp protocol in order to extract a report.txt file on your private server and etc. 

Written by: Amar Tufo
4. October, 2017



On the image above you can see the tasks for LinuxLab which we have to solve in this article. I have even planed to make a YouTube tutorial for this LinuxLab but I have decided to write an article and then I shall see about YoutTube part. Let's begin!

Creating a new user!


The first part of this LinuxLab is to create a new Linux user named ubuntugeek with it's home directory and new user group named ubuntustation. There are dozens tutorials available online on how to make a new Linux user as well as new user group. But in this article you need to understand several major things when creating a new user. One in particular is the way you are gonna access the newly created user in Linux; Second is /etc/passwd file which holds all information on user including it's name, group, user id, group id, user home directory, and login shell. Now, here's my sample of /etc/passwd file.


Image 1: /etc/passwd file for user amar
Image source: /home/amar/Desktop/image1

It's very important to understand the /etc/passwd file since information stored in this file are crucial when it comes to user management in Linux as you can use this file to add user manually to your Linux distribution. For more on /etc/passwd file check this link. Here are three key notes on /etc/passwd file. 

root account - this account is known as superuser and it is the most privileged account on a Linux system. It gives you the ability to administer the system by adding new accounts, changhing user passwd, examining log files, installing software and changing file permissions. 

nobody account - this account is used for system services and has no shell or home directory.

the /bin account - contains the home directory of /bin with no shell assignment. 

You can get the same information on the current user by typing the following command like in this sample down bellow. 


grep amar /etc/passwd

Once you type your user name, the output should be as follow:


Image 2: Output of the command grep amar /etc/passwd
Image source: /home/amar/Desktop/image2

In the following table, here's an explanation of the command above to understand what these information are.


Image 3: Explanation of the grep amar /etc/passwd command
Image source: /home/amar/Desktop/image3

The last thing I wanna note here is the user password. Now, Linux store user password in a unique file named /etc/shadow. The x: character you see in the table above represents my encrypted password which is stored in /etc/shadow file. Password is basically showed in a bunch of random letters and numbers which are difficult to read but safe and encrypted. In other hands, you don't want others to know your password. Here's my sample of /etc/shadow file.


Image 4: Output of the command sudo grep amar /etc/shadow 
Image source: /home/amar/Desktop/image4

Creating ubuntugeek user.


The output for your user name will be different than my which is ok. Now, we can start to make our ubuntugeek user with it's user group and home directory. The command you will see here are well tested for the purpose of this article. There are several ways to create a new Linux user and one way that I prefer is via useradd command using the following command syntax:


sudo useradd -m ubuntugeek

Once you type the following command, you should be able to see the newly created ubuntugeek user as on this image down bellow.


Image 5: Accessing newly created user ubuntugeek using su ubuntugeek command
Image source: /home/amar/Desktop/image5

One note: In order to access our ubuntugeek user, in command above I have use -m to tell the Terminal to force create ubuntugeek home directory. Without home directory, we won't be able to access ubuntugeek user neither it's data. Before we make our user group and add ubuntugeek inside it, we need to assign ubuntugeek password. We can do that using the following command: 


sudo passwd ubuntugeek

The output of the following command is as follow:


Image 6: Assigning ubuntugeek password
Image source: /home/amar/Desktop/image6

The name of your user is different than my in the sample above, but it's the same syntax you should follow in order to assign your user password or change an existing password and etc.

Creating group ubuntustation.

User groups are essential part in Linux. Basically it can be described as a collection of multiple users which have default permissions on the system files and etc. Note, that groups need to be manage some how and that's where permissions comes in to play. Permissions are important part of Linux security since they allow Linux System administrator to set the permission for user as root account, groups and others. This way, I can set the permission to read, write and execute certain file or limit other users to write or modify the file, but grant them to read and execute certain file and so on. More on groups, please click the following link. Before I show you how to create ubuntustation group for our ubuntugeek user, I will show you how to view file permissions over the files or directory. The following command is used to see the file permissions.


cd Desktop
cd application
ls -l

In the command above, I have chosen application directory on Desktop which I have listed using the ls -l command. Here's the output.


Image 7: Listing file permissions on the application directory content
Image source: /home/amar/Desktop/image7

Each file has a default permission set assigned to user (root account), groups and others. This default permissions are known by characters such as rwx as shown on image7 above. What they does or mean is important to know because you will work with them a loot. In short, here is a explanation of rwx characters:

read (r) - it allows the file to be viewed or directory content to be listed.

write (w) - it allows you to modify the file or to write to the file.

execute (x) - it allows you to run the file, program or execute a script.

In the image 7 you can clearly see -rwx characters in front of main.cpp file in my application directory. In this case, main.cpp is C++ source code file on which I have set the default permission for user (amar) which is rwx, group can rw but can't execute the file, and others can execute and read the main.cpp file. Here's a command which I have used to set the main.cpp permissions:


chmod u+rwx,g+rw,o-wx main.cpp

The command used in this sample is chmod (change mod). It's this command that allow Linux System administrator to grant access on certain files and directories for user, groups and others or to take them away at will in order to protect the system or user it self. Since this is a LinuxLab, I don't have time to explain chmod and file permissions in detail but if you are interested to know more about this command which I highly recommend, then visit this link.

Finally, let's make our ubuntustation group and to complete this article. The command used to create group is groupadd. Here's the full command.


groupadd ubuntustation

Now, there's nothing special to note or add here to this command. Only thing is that our newest group has been created and we can now add our ubuntugeek user to ubuntustation group using the following command.


sudo usermod -G ubuntustation ubuntugeek

In the command above I have used the usermod command to add ubuntugeek user to ubuntustation. The Terminal command to make sure that we have added ubuntugeek to ubuntustation is the following:


Image 8: Checking that ubuntugeek user is part of ubuntustation group
Image source: /home/amar/Desktop/image8

This is it. We have successfully added our ubuntugeek to ubuntustation group and therefore completed this first part of my LinuxLab. Make sure to read entire article, comment it, share it via social media and please if you note errors while reading this article weather in text or Linux commands used in this article, please comment it down bellow so that I can fix it and update it as soon as possible. Until the next time, I see you soon in part two of my LinuxLab. 

Share:

NDG Linux Essential - week 7 final exam-


Welcome again to my NDG Linux Essential adventure, module 7 of my Linux course. Shortly, NDG Linux Essential module 7 cover mostly working with tar, gzip, bzip2, compressing/uncompressing, creating tarball, viewing it's content, extracting it into other directory on your Linux distribution and so on. I have learn so much amazing and important things on working with tarball, creating a backup of your files and directories which could be very handy when you uploading a files to your server or website and so on. Finally, my module ended with exam that consisted of 10 questions which I successfully scored with 10 grade. Here's my final exam of module 7. Oh, I almost forgot. Before you view my exam, I suggest you to jump on my tutorial of working with tarball which you can see down bellow.

Written by: Amar Tufo
16. August 2017


Video tutorial: Working with tarball ~ Amar Tufo

Ok, and here's a test for NDG Linux Essential module 7 of my intensive Linux course which consisting of 10 questions as previous modules. Question have been answered and you can access them via my website.



That's all folks for this week. I hope that this intensive Linux course will help and motivate you as well to get started your own Linux career and preparation for some serious Linux certification such as LPIC-1 which I have started. I see you soon on my YouTube channel and in NDG Linux Essential - week 8 - . Till then, have a nice weekend!
Share:

NDG Linux Essential - week 7 -


Last week I have written a short intro for my NDG Linux Essential course - module 7 - and now I can proudly announce that week 7 of my NDG Linux education is successfully completed  and here are some key notes and summary of my NDG Linux Essential - week 7 -. As noted previously in my short intro of module 7, this entire module was very short but cover some skills working with compressing, decompressing, creating .tar archive, working with gzip, bzip and so on. So here are some important notes on working with tarball, creating an tar archive, listing it's content, updating the archive and so on. I should also note that this article includes the final exam for module 7 at the end which you can see down bellow. Ok let's start. . . 

Written by: Amar Tufo
9. August, 2017

The tar utility is widely used by all Linux distributions. Along with being a useful tool for backup, tarball files are also a convenient way to distribute files. They allow a single file download and because compression can be handled with tar they also creates smaller files for download. Tarball files do not have to end with .tar extension, but it's a good practice to do so. Files that are joined and compressed often use the .tar.gz extension. In the following sample I will demonstrate how to create tarball file, how to extract it, see it's content and extract a single file out of tarball.

1# Sample: Creating archive.tar.gz file


                                                             
Image 1: Creating archive.tar.gz for final directory
Image source: /home/amar/Desktop

In this first sample I have created archive.tar.gz tarball as backup for my final directory. In the image1 above, archive contents were listed upon compressing. Short note for the command used above is following:



tar -zcvf archive.tar.gz final/

Once typed this command will compress final directory with all it's content into single tarball in this case archive.tar.gz. If you wonder what -zcvf stands for than here what they are:


tar -zcvf archive.tar.gz final/
*z - tells the tar to use gzip tool
*c - creates an archive
*v - tell me what you are doing
*f - file name

2#Sample: Listing the archive.tar.gz content and extracting it to another directory

Let's assume that you want to view the content of archive.tar.gz before extracting it. Here's the command that will do just that:


tar -tf archive.tar.gz 

Once typed into terminal this command will generate the following output:


Image 2: Listing the content of archive.tar.gz tarball
Image source: /home/amar/Desktop


Now as we have listed our content, let's extract our archive.tar.gz in /tmp directory of my home folder. Here's the command that will accomplish such a task.


tar -xvzf archive.tar.gz -C /home/amar/tmp

Note: -C in this command allow you to give the tar command a path to destination directory in which you are extracting your tarball in this case archive.tar.gz > /home/amar/tmp.

Once you typed this command this is the output you should see. Image 3:


Image 3: Extracting archive.tar.gz into /home/amar/tmp
Image source: home/amar/Desktop

Note that I have extracted the archive.tar.gz content into /home/amar/tmp directory from Desktop as my pwd directory. Keep this in mind that before each extraction of the tarball move the archive into empty directory or the directory/files will be replaced and overwritten. 


Image 4: Successfully extracted archive.tar.gz tarball file into /tmp directory
Image source: /home/amar/tmp

3#Sample: Adding log.txt file into archive.tar.gz and extracting a single file out of archive

Let's assume that you want to add a file into existing archive in this case log.txt file into archive.tar.gz. For this purpose I have created four files on my Desktop namely file1.txt, file2.txt, file3.txt and log.txt. I will now create an archive.tar.gz which will contain only file1.txt, file2.txt and file3.txt using the following command:


tar -cvf archive.tar.gz file1.txt file2.txt file3.txt


Image 5: Creating a new archive.tar.gz 
Image source: /home/amar/Desktop

Now let's update existing archive.tar.gz by adding log.txt into our archive. We can do that using the following command:


tar -rf archive.tar.gz log.txt

Your output should be the same as main if you have type it correctly. See the image 6 down bellow.


Image 6: Updating the existing archive.tar.gz with log.txt file
Image source: /home/amar/Desktop

4#Sample: Extracting log.txt into different directory

Sometimes tarball can be very big in size and you don't need an entire archive. You need only a specific file as Linux System Administrator into let's say /tmp directory. In this sample I'm about to show you how to extract log.txt file from archive.tar.gz file into /tmp directory which is in my home directory.


tar -xvf archive.tar -C /home/amar/tmp log.txt

Note when extracting a single file out of tarball, file is added at the end of command. In other case, the file will be extracted into present working directory. Here are the final results of this command.


Image 7: Extracting log.txt file from archive.tar into /tmp directory
Image source: /home/amar/Desktop

Here's the terminal output for our /tmp directory which holds log.txt file which we extracted from archive.tarball.


Image 8: /tmp directory with log.txt file
Image source: /home/amar/Desktop


This all folks for today. I hope that this article has helped you in understanding the way tar works, how to create an tarball, how to list it's content and how to extract the single tarball file into another directory. Make sure to commend down bellow and share this article. Stay on my site because I lot's of other useful and educational content for you all. We see you soon at NDG Linux Essential week 8, till then have a nice stay at my website.


Share:

NDG Linux Essential - module 7 - short intro


Welcome to my seven week of my NDG Linux Essential adventure. As you know I have recently published my first LPIC Shell Exam, final exam for SHELL chapter compiled after LPIC-1 Certification Bible which I use for LPIC-1 exam preparation alongside NDG Linux Essential course. As noted I have completed successfully LPIC-1 Shell chapter from mentioned book (link is down in description bellow). Now the NDG Linux Essential course - module 7- is covering the following tasks in order to complete it:

> > Compressing files under Linux format such as .tar.gz
> > Decompressing files . . .
> > Archiving . . .

Basically this module is very short but it does include the final 10 question exam in order to complete it. Check the image down bellow:


Image 1: NDG Linux Essential module 7 intro


As you can see, it is very short part of my NDG Linux Adventure and therefore I'm going to expend it using LPIC-1 Certification Bible /special chapter. Stay tuned and have a nice stay at my blog.

Share:

LPIC SHELL exam


It's been a week since my latest post from my LPIC - 1 preparation which is still in progress and in week seven of my Linux adventure. Last week I have cover an amazing SHELL chapter from LPIC Certification Bible which is official resource for LPIC -1 or Linux System Administrator. From my point, I'm quite experience working with SHELL, I can write a simple BASH script, create an environment variable and so on. Basically this chapter covers almost the same thing but with better advice, tips and notes on SHELL. In this article you can see my full LPIC SHELL exam which consists from 23 questions compiled using the SHELL chapter from LPIC Bible book. 

Written by: Amar Tufo
23. July 2017





As noted in the exam bellow, this is unofficial exam which I have compiled for my self to test my knowledge and get prepared better for final LPIC exam. Test is has open access and you can use it as well to see some of the very similar question from LPIC exam / Linux System Administrator. That's all for today and I'l see you next time.

Share:

NDG Linux - Video Komentar -


Iako sam nedavno uspio objaviti oba zvanična izvještaja za šestu sedmicu NDG Linux kursa, direktne pripreme za LCPI - 1 test za Linux System admina, tako sam danas iskoristio svoje znanje iz Kdenlive-a te kreirao kratak video komentar na svoju edukaciju i podijelio s vama neko stečeno znanje. Ja ovdje neću navoditi reference do zvaničnih članaka NDG Linux kursa jer su isti pomenuti u opisu mog video komentara. Prije nego pogledate video, ne zaboravite stisnuti <SUBSCRIBE> na moj YouTube kanal jer mi to pomaže da pravim bolje YouTube video klipove.

Piše: Amar Tufo
13. Juli 2017


To bi bilo sve na kraju. Ostanite još na mojoj web stranici jer možda pronađete još po koji zanimljiviji članak osim ove hard core NDG Linux obuke. Do čitanja !!!
Share:

NDG Linux Essential - module 6 final EXAM -


Finally I have written my NDG Linux Essential course - week 6 - in two parts and now I'm about to show you how my final exam look like, it's question and finally the grade I scored. I must say that these are official NDG Linux Essential exams for each week I passed and they can be really challenging when it comes to show off your Linux skills and knowledge. Ok! Let's jump into test. 

Written by: Amar Tufo
10. July 2017




This is the official and final exam for NDG Linux Essential module 6 - working with files and directories. I scored 8 grade in this test as I'm very proud on my self since these kind of skills are mostly required when working with files and directories in Linux. Make sure to comment my test, share booth articles in description bellow. That's it. I'l see you at 7 week of NDG Linux adventure.

________________ References:_______________

1) NDG Linux Essential course - week 6 - part I

2) NDG Linux Essential course - week 6 - part II
Share:

NDG Linux Essential - week 6 - part II


Welcome to my second part of NDG Linux Essential course which is preparation for LCPI - 1 exam to becoming Linux System Administrator. I have recently write a first part of NDG Linux Essential - week 6 - part I so make sure to read it first before moving on my second part. In this part I'm about to show you the rest of commands such as cp, mv,  rm, touch, cat, and example for each of this command to get idea what they do and what is their purpose. After this part, I'm about to publish separately final exam for module 6 in .pdf file so that you can see it and experience some of the Linux questions from this course in first hand. Let's begin!

Written by: Amar Tufo 
9. July, 2017

1) cp - copy

We are beginning with command cp which is used for coping files and folders from one location to another on your home folder. In the following sample I'm about to copy a empty file foo.txt from Desktop to directory named foo


Image 1: Coping foo.txt file to foo directory via cp command 
Source:  local /home/amar/Desktop

In short, this image above shows entire process of coping an empty file named foo.txt to foo directory. I have also used ls command to list the foo directory content so that you can see what's inside, in this case, an empty foo.txt file.

2) mv - move or rename

There is a god reason why you need to now how to use mv command. This command allows you to move files and directories or renamed them while moving end so on. In the following sample we are going to move image.png file to foo directory on Desktop. See the image 2 down bellow:


Image 2: Moving image.png to foo directory via mv command
Image source: local /home/amar/Desktop

In short, I have moved image.png file via mv command into foo directory. Now as I have mentioned above, mv command can be used to rename the files and directory as well. In the following sample, I'm about to rename foo directory into image directory using mv command. See the image 2.1 down bellow:


Image 2.1: Renaming foo directory into image directory via mv command
Image source: local /home/amar/Desktop

There you go, now our foo directory named has changed into image directory. Now our image directory has his child file image.png. Pretty amazing, don't you think?

3) rm - remove a file or directory

Well, there is nothing so special about this command and I assumed that most of you are already familiar with this command and how to remove a file via rm command. Just in case you don't know, here is the sample. In the following sample I'm about to remove image directory with it's image.png file from Desktop using only rm  command. See the image 3 down bellow:


Image 3: Removing image directory from Desktop using rm command
Image source: local /home/amar/Desktop

Short note, the following command 'rm -rf -v image' has successfully removed image directory with it's content, image.png file. Only thing that might confuse you is -v argument in front of rm -rf command. It's a verbose and it tells you that image directory was removed, it informs about action that just happened. 

4) touch - change a file timestamps 

One easiest way to create an report.txt file via Terminal is using touch command. Although it changes a file timestamps, this command allows you to create a file as well. In the following sample we are going to create an empty report.txt file on Desktop. See the image 4 down bellow:


Image 4: Creating empty report.txt file on Desktop using touch command
Image source: local/home/amar/Desktop

In the following image 4.1 you are going to see how I modified creation time using touch command. See the image bellow:


Image 4.1: Modifying time creation of report.txt file using touch command
Image source: local/home/amar/Desktop

Here's a short note, in the image 4.1 above I have used the following command touch to create a report.txt file. Such file was created on 18:09:13 | 10 July. Using the touch -m report.txt command, I have updated creation time to most recent on my system clock as you can see, the report.txt file is now created on 18:12:38. That's it. For more about touch command please visit man touch.

5) cat - concatenate files and print on the standard output 

Now, here's a command which you can use to write and read to a file using echo command. Since our report.txt file is empty, in the following sample we are going to fill it with some text via Terminal. See the image 5 down bellow:


Image 5: Writing to report.txt file using echo command
Image source: local/home/amar/Desktop

Short note: In this sample I have write a text 'This is NDG Linux Essential course by: Amar Tufo' into report.txt file using echo command. At the end, I have used cat command to read a report.txt file via terminal and as you can see, the text was successfully written to a file. See the image 5.1 as well:


Image 5.1: Report.txt file fill with simple message using echo command
Image source: /local/home/amar/Desktop

This is, now you know how to write to a file using echo command and how to read it using cat command via terminal. 

___________________ Conclusion: ___________________

We came to an end of my NDG Linux Essential course - week 6 - official reports in two parts. Hopefully now you know how to use some most common Linux commands such as pwd, cd, ls, mkdir, cp, mv,  rm, touch, cat, and I hope as well that you're not gonna stop it here. Linux is a vast and unexplored area for those of you willing to chase a career in Linux weather it's a Linux kernel developer, Linux system administrator or better, Linux app developer. But it's all to you, how much you are willing to learn in order to master Linux and to become a Linux ninja. Let me know in comments down bellow. Share some of your interesting Linux experience, I will be glad to share them via my YouTube channel and social networks. That's it. Thanks for reading and see you next time. 

And remember, choose wisely, choose Linux a system that works!
Share:

NDG Linux Essential - week 6 - part I


Welcome to my 6-th week of my NDG Linux Essential which cover working with files and directories. As noted previously on my recent articles related to my NDG Linux education, this course is a preparation for LCPI - 1 exam for becoming Linux System Administrator. Unlike the previous NDG Linux essential weeks, the article for week 6 of my NDG education is going to be published in two parts due to complexity of this week and subjects which it covers. I have completed it on my NDG dashboard but since this module it's self is somewhat bit complex that the previous one, it requires to write a separate report in two part. In short, I have worked with commands such as  pwd, cd, ls, mkdir, cp, mv,  rm, touch, cat, the following commands are the most common used commands when using Terminal. Final word in this intro is that the both article are going to be covered in video for my YouTube channel where I shall briefly comment it as well as my final exam.  

Written by: Amar Tufo
8. July 2017

NDG Linux Essential module 6 is successfully completed and as I have noted above, I had final exam of 10 questions to complete this week which is also finished and will be included at the end of this article. I don't know how much are you familiar with Linux terminal but this was one my favorite module of Linux education, working with Terminal and the following commands such as: pwd, cd, ls, mkdir, cp, mv,  rm, touch, cat and etc. Without knowing this commands you can't navigate trough Linux Terminal. I shall show you each command in example just to get idea of what each command does. 

1) pwd - currenty working directory

pwd command is useful since it allows you to see your current working directory. Once typed in Terminal, it gives you the following output:


Image 1: pwd command shows the current working directory in this case it's /home/amar
Image source: local/home/amar/Desktop

2) ls - list a content 

Once you find out you're current working directory, you may wanna list the directories that your home folder holds and here we are using ls command. Don't underestimate ls command, this is one hell of command which is very powerful since it have lot of options which will be demonstrated in this article.


Image 2: listing content of /home/directory using ls command
Image source: local/home/amar/Desktop

Let assume that you wanna show all hidden files and folders that begin with .gconf, in this sample you wanna show the hidden folders as well as .gconf folder of you're /home directory. You are gonna use command ls -a which will look like this.


Image 3: Listing hidden files/directories using ls -a command
Image source: local/home/amar/Desktop

What if you need to sort the files by it's size. Than you will use the ls -lS command to sort the files. Take a look at image 4.


Image 4: Listing files by it's file size using ls -lS command
Image source: local/home/amar/Desktop

In this figure you need to note on two major things; First I have used a absolute path to access Desktop using cd /home/amar/Desktop and then I have listed the file contents on my Desktop using ls -lS command which sorted the files by it's size. In this case, the biggest file on my list is movie.mp4.  Also you need to note on the numbers of my movie.mp4 file (498787589). What are these numbers. They're the size of movie.mp4 but they are very difficult to read so we need to sort them by human readable size. We can achieve that by using the ls -lSh command which will sort the files by human readable size (in MB for example). 


Image 5: Listing files by it's human readable size using ls -lSh command
Image source: local/home/amar/Desktop

Here's a few notes on image 5 when it comes to sorting files using ls -lSh command. Note on the image above where it was estimated the contents size on my Desktop total 864 MB instead of 883868. Now, note down bellow that numbers in front of my movie.mp4 file have changed as well where it writes 476 MB which is estimated file size instead of 498787589. Now you can read the files sizes in bits, bytes, kilobytes, megabytes, and gigabytes as well. All you have to do is to enter this very useful ls -lSh command. 

3) cd - navigate to directory

When it comes to cd command there is nothing so special to mention about this command only it let's you to navigate to certain directory. Only thing here to note is the absolute and relative path. I have already mention what absolute path is and how to access certain directory using absolute path. This is absolute path: cd /home/amar/Desktop


Image 6: Accessing Desktop using absolute path cd /home/amar/Desktop
Image source: local/home/amar/Desktop

Note

Absolute path begins from (/) directory.
Relative path begins from present working directory.


Image 7: Accessing ndg_lab directory on Desktop using relative path
Image source: local/home/Desktop

Short note:  In this case (image 7) I have set Desktop as my present working directory and I wanted to access ndg_lab subdirectory on Desktop. I have achieve this using the following command and this is:

cd /home/amar/Desktop/ndg_lab

And this is how you access to certain directory using relative path. 

4) mkdir - make a directory

This command simply creates a new directory on Desktop or in your home directory.


Image 8: Creating YouTube directory on Desktop using mkdir command
Image source: /local/home/amar/Desktop


____________ Final words for part 1______________

Ok. This is all for my part I of NDG Linux Essential - week 6 -. In the second part I shall cover the remaining commands such as cp, mv,  rm, touch, cat, since writing this article in a single part would be way to big to write and to read as well. I will also publish my final exam for module 6 of NDG Linux Essential course as a separate article so that you can see the exam for you're self. This is all for today. Make sure to follow me on my LinkedIn as I have make an amazing articles from Linux education as well as my YouTube where you can find some useful tutorials on basic Linux commands and etc. 
Share:

My Twitter news

Popular Posts

Recent Posts

Unordered List

  • Lorem ipsum dolor sit amet, consectetuer adipiscing elit.
  • Aliquam tincidunt mauris eu risus.
  • Vestibulum auctor dapibus neque.

Pages

Theme Support

Need our help to upload or customize this blogger template? Contact me with details about the theme customization you need.