RHCSA Series: How to Perform File and Directory Management – Part 2

Best Affordable Linux and WordPress Services For Your Business
Outsource Your Linux and WordPress Project and Get it Promptly Completed Remotely and Delivered Online.

If You Appreciate What We Do Here On TecMint, You Should Consider:

  1. Stay Connected to: Twitter | Facebook | Google Plus
  2. Subscribe to our email updates: Sign Up Now
  3. Get your own self-hosted blog with a Free Domain at ($3.45/month).
  4. Become a Supporter - Make a contribution via PayPal
  5. Support us by purchasing our premium books in PDF format.
  6. Support us by taking our online Linux courses

We are thankful for your never ending support.

Gabriel Cánepa

Gabriel Cánepa is a GNU/Linux sysadmin and web developer from Villa Mercedes, San Luis, Argentina. He works for a worldwide leading consumer product company and takes great pleasure in using FOSS tools to increase productivity in all areas of his daily work.

Your name can also be listed here. Got a tip? Submit it here to become an TecMint author.

RedHat RHCE and RHCSA Certification Book
Linux Foundation LFCS and LFCE Certification Preparation Guide

You may also like...

20 Responses

  1. Anurag says:

    I have not understand why we used second grep in below example.if first grep is capable of providing details of all apache process , what is use of second one ?

    # ps -ef | grep apache | grep -v grep.

    • Gabriel A. Cánepa says:

      Compare the output without the second pipeline and the second grep and you’ll find your answer :). Hint: also check the purpose of the -v option of grep.

  2. Neeraj Rawat says:

    Hello Gabriel,

    Nice article, also correct the typo: Note that we use to(2) pipelines in the following example > Note that we use two(2) pipelines in the following example.

    • Gabriel A. Cánepa says:

      There is no typo. Compare the output without the second pipeline and the second grep and you’ll understand why I used two greps and two pipelines :). Hint: also check the purpose of the -v option of grep.

  3. Faisal says:

    thank u for the demonstration. I got ask u a question i.e i had a file 200M and created a hardlink for this file the actual disk space will 400M for both files or 200M.since u run ls -li will show both file point to same inode and they had the same size

    • @Faisal,
      The process of creating a hard link does NOT duplicate the file. So if you have a 200 MB file and create a hard link to it, the hard link itself will not occupy another extra 200 MB. One way you can check this is by doing
      du -sch /full/path/to/directory/*
      where /full/path/to/directory/ is the directory where you have the 200 MB file. Do that and then delete the hard link, then try again. You will not see a difference in the disk usage.

  4. Eduardo Ramos says:

    In the ‘hard & soft link’, maybe the phrase ‘On the other hand, creating a hard link results in an extra disk usage of 5 bytes.’ should be ‘On the other hand, creating a soft link results in an extra disk usage of 5 bytes.’, isn’t it?

  5. Cyrille La says:

    While ‘&> ‘ works in récent Bash,
    ‘2>&1 ‘ Will redirect stdout “to where stderr is” on close to every shell around.

  6. Adam B. says:

    Small mistake, in tar compression flags you have commit (should be uppercase J instead lowercase j for xz compression ).

    Thanks for that two articles, for me is some kind of reapet …

  7. Henrik says:

    Thanks for share this content!

  8. Tomas says:

    This bit “2>>” should not be “Appends standard error to a file”?

  9. ahmedhsn says:

    Nice guide , I would like to know how I can get RHEL copy and how much is the price for it, please

Got something to say? Join the discussion.

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.