Mastering Linux
< Previous Challenge - Home - Next Challenge >
In this challenge let’s learn about file content manipulation and discover how to count file lines, display specific lines from a file, and more.
/etc/resolv.conf
/etc/crontab
Create a file named count.log
with this content:
One
Two
Three
Four
Five
cp
to make a backup of this file to count.bkp
cat
to make a backup of this file, saving as cat-count.log
cat-count.log
, with all lines in reverse ordermore
to display /etc/selinux/semanage.conf
ls
to find the biggest file in /var/log
/etc/resolv.conf
/etc/crontab
count.log
was created as expectedcount.bkp
was createdcat-count.log
was createdcat-count.log
in reverse order/etc/selinux/semanage.conf
paged/var/log
at the top of the list