You are on page 1of 16

3/25/2017 51 Useful Lesser Known Commands for Linux Users


Now!
Blog
Your
Start
Find great images...   Get started!
55 MILLION AMAZING STOCK IMAGES

LINUX COMMANDS  38 I  TecMint :     

 BEGINNER'S GUIDE FOR LINUX 


51 Useful Lesser Start learning Linux in minutes 

Known Commands
for Linux Users
20 Linux YUM (Yellowdog Updater, Modiퟺ�ed) Commands
http://www.tecmint.com/51­useful­lesser­known­commands­for­linux­users/ 1/16
3/25/2017 51 Useful Lesser Known Commands for Linux Users

by Editor | Published: December 24, 2013 | Last


Updated: January 3, 2017

AdChoices Linux Commands Unix Commands

 Download Your Free eBooks NOW - 10 Free


Linux eBooks for Administrators | 4 Free Shell
Scripting eBooks

Linux command line is


attractive and fascinating,
and there exists a ៙�ock of
Linux user who are addictive  Vi/Vim Editor BEGINNER'S GUIDE 
to command Line. Linux Learn vi/vim as a Full Text Editor 
command line can be funny
Advertise Here
and amusing, if you don’t
believe me, you can check
one of our article below.

20 Funny Commands
of Linux or Linux is Fun
in Terminal

 Linux Foundation Certiퟺ�cation 


Exam Study Guide to LFCS and LFCE

51 Lesser Known Commands for Linux

As well as extremely
powerful, at the same time.
We brought to you, ៗ�ve
articles on “Lesser Known
Linux Commands”
consisting of 50+ lesser
20 Linux YUM (Yellowdog Updater, Modiퟺ�ed) Commands
http://www.tecmint.com/51­useful­lesser­known­commands­for­linux­users/ 2/16
3/25/2017 51 Useful Lesser Known Commands for Linux Users

known Linux command.


This article aims at
concatenating all those ៗ�ve SHARE
articles as one, and lets you
+
know, what is where, in
brief. 
0
11 Lesser Known
Commands – 
Part I 537

This article was highly



appreciated by our readers, 101
which contains simple yet
very important commands.

The article summaries as.

1. sudo!! : Forgot to run


a command with sudo?
You need not re-write
the whole command,
just type “sudo!!” and
the last command will
run with sudo.  
2. Python -m
SimpleHTTPServer : How to Add Linux Host to Nagios Monitoring
Creates a simple web Server Using NRPE Plugin
page for the current
Nagios 4.2.0 Released – Install on RHEL/CentOS
working directory over
7.x/6.x/5.x and Fedora 24-19
port 8000.
3. mtr : A command Install Cacti (Network Monitoring) on
which is a combination RHEL/CentOS 7.x/6.x/5.x and Fedora 24-12

of ‘ping’ and ‘traceroute’


Google Chrome 56 Released – Install on
command. RHEL/CentOS 7/6 and Fedora 25-20
20 Linux YUM (Yellowdog Updater, Modiퟺ�ed) Commands
http://www.tecmint.com/51­useful­lesser­known­commands­for­linux­users/ 3/16
3/25/2017 51 Useful Lesser Known Commands for Linux Users

4. Ctrl+x+e : This key Ebook: Introducing the RHCSA and RHCE Exam
Preparation Guide
combination ៗ�res up, an
editor in the terminal, How to Install Ubuntu 16.10/16.04 Alongside With
instantaneously. Windows 10 or 8 in Dual-Boot
5. nl : Outputs the
content of text ៗ�le with
lines Numbered.
6. shuf : Randomly
selects line/ៗ�le/folder
from a ៗ�le/folder.
7. ss : Outputs Socket
Statistics.
8. Last: Want to know
history of last logged in
users? This command
comes to rescue here.
9. curl ifconퟺ�g.me :
Shows machine’s
external IP Address.
10. tree : Prints ៗ�les and
folders in tree like
fashion, recursively.
Linux System Administrator Bundle
11. Pstree : Prints with 7-Courses (96% off)
running processes with
child processes, Add to Cart - $69
recursively.
 Ending In: 3 days
11 Lesser Known Useful
Linux Commands – Part I Computer Hacker Professional
Certiퟺ�cation Course (96% Off)

Add to Cart - $59


 Ending In: 4 days

20 Linux YUM (Yellowdog Updater, Modiퟺ�ed) Commands


http://www.tecmint.com/51­useful­lesser­known­commands­for­linux­users/ 4/16
3/25/2017 51 Useful Lesser Known Commands for Linux Users

The great response,


received on this article, and DOWNLOAD FREE LINUX EBOOKS
requests to provide another Complete Linux Command Line Cheat Sheet
list of ‘Lesser Known Linux The GNU/Linux Advanced Administration Guide
Commands‘, from our Securing & Optimizing Linux Servers
readers, we wrote next Linux Patch Management: Keeping Linux Up To

article of the series is: Date


Introduction to Linux – A Hands on Guide
Understanding the Linux® Virtual Memory
10 Lesser Known Manager

Commands – Getting Started with Ubuntu 16.04


A Newbie’s Getting Started Guide to Linux
Part II Linux from Scratch – Create Your Own Linux OS
Linux Shell Scripting Cookbook, Second Edition
This article again was warm Securing & Optimizing Linux: The Hacking
welcomed. The summary of Solution
the article, below is enough User Mode Linux – Understanding and
to describe this. Administration

12. <space> command :


    
A space before a bash
command, is not
Never Miss Any Linux Tutorials,
recorded in history. Guides, Tips and Free eBooks
13. stat : Shows the
Join Our Community Of 150,000+ Linux Lovers
status information of a and get a weekly newsletter in your inbox
ៗ�le as well as of a ៗ�le
system. YES! SIGN ME UP
14. <alt>. And <esc>. : A
tweak which put the last
command argument at
prompt, in the order of
last entered command,
appearing ៗ�rst.
15. Pv : outputs
simulating text, similar
to hollywood movies.
20 Linux YUM (Yellowdog Updater, Modiퟺ�ed) Commands
http://www.tecmint.com/51­useful­lesser­known­commands­for­linux­users/ 5/16
3/25/2017 51 Useful Lesser Known Commands for Linux Users

16. Mount | column -t :


Lists mounted ៗ�le
system, in nice
formatting with
speciៗ�cation.
17. Ctrl + l: clear shell
prompt,
instantaneously.
18. curl -u gmail_id –
silent
“https://mail.google.com/mail/feed/atom”
| perl -ne ‘print “\t” if //;
print “$2\n” if /(.*)/;’.
This simple scripts,
opens up, unread mail
of an user, in the
terminal itself.
19. screen : Detach and
Reattach, long running
process from a session.
20. ퟺ�le : Outputs
information, regarding
types of ៗ�le.
21. id : Print User and
Group Id.

10 Lesser Known Linux


Commands – Part 2

Getting over 600 Likes on


different social Networking
sites and many thankful
comments, we were ready
with our third article of the
series is:
20 Linux YUM (Yellowdog Updater, Modiퟺ�ed) Commands
http://www.tecmint.com/51­useful­lesser­known­commands­for­linux­users/ 6/16
3/25/2017 51 Useful Lesser Known Commands for Linux Users

10 Lesser Known
Commands –
Part 3
This article summaries as
below:

22. ^foo^bar : Run last


command with
modiៗ�cation, without
the need of rewriting
the whole command
again.
23. > ퟺ�le.txt : Flush the
content of a text ៗ�le, in
a single go, from the
command prompt.
24. at : Run a particular
command, time based.
25. du -h –max-depth=1
Command : Outputs the
size of all the ៗ�les and
folders within current
folder, in human
readable format.
26. expr : Solve simple
mathematical
calculations from the
terminal.
27. look: Check for an
English word, from the
dictionary, in case of
confusion, right from
the shell.
20 Linux YUM (Yellowdog Updater, Modiퟺ�ed) Commands
http://www.tecmint.com/51­useful­lesser­known­commands­for­linux­users/ 7/16
3/25/2017 51 Useful Lesser Known Commands for Linux Users

28. yes : continues to


print a sting, till
interrupt instruction is
given.
29. factor: Gives all the
possible factors of a
decimal number.
30. ping -i 60 -a
IP_address : Pings the
provided IP_address,
and gives audible sound
when host comes alive.
31. tac : Prints content
of a ៗ�le, in reverse
order.

10 Lesser Known
Commands for Linux – Part
3

Our Hard-work was paid by


the response we received
and fourth article of the
series was:

10 Lesser Known
Linux Commands
– Part IV
Need not say, again this
article was appreciated. The
article summarises below:

32. strace : A debugging


tool.
20 Linux YUM (Yellowdog Updater, Modiퟺ�ed) Commands
http://www.tecmint.com/51­useful­lesser­known­commands­for­linux­users/ 8/16
3/25/2017 51 Useful Lesser Known Commands for Linux Users

33. disown -a && exit


Command : Run a
command in
background, even after
terminal session is
closed.
34. getconf LONG_BIT
Command : Output
Machine Architecture,
very clearly.
35. while sleep 1;do
tput sc;tput cup 0
$(($(tput
cols)-29));date;tput
rc;done & : The script
outputs date and time
on the top right corner
of shell/ terminal.
36. convert : converts
the output of a
command in picture,
automatically.
37. watch -t -n1 “date
+%T|ퟺ�glet” : Show
animated digital clock
at the prompt.
38. host and dig : DNS
lookup utility.
39. dstat : Generates
statistics regarding
system resource.
40. bind -p : Shows all
the shortcuts available
in Bash.
20 Linux YUM (Yellowdog Updater, Modiퟺ�ed) Commands
http://www.tecmint.com/51­useful­lesser­known­commands­for­linux­users/ 9/16
3/25/2017 51 Useful Lesser Known Commands for Linux Users

41. Touch /forcefsck :


Force ៗ�le-system check
on next boot.

10 Lesser Known Effective


Linux Commands – Part IV

10 Lesser Known
Linux
Commands- Part
V
The commands from here
was getting biased towards
scripts, yes single line
powerful shell scripts and
we thought to provide at
least one more article on
this series.

42. lsb_release : Prints


distribution
speciៗ�cation
information.
43. nc -ZV localhost
port_number : Check if
a speciៗ�c port is open
or not.
44. curl ipinfo.io :
Outputs Geographical
Information, regarding
an ip_address.
45. ퟺ�nd .-user xyz :
Lists all ៗ�le owned by
user ‘xyz’ 20 Linux YUM (Yellowdog Updater, Modiퟺ�ed) Commands
http://www.tecmint.com/51­useful­lesser­known­commands­for­linux­users/ 10/16
3/25/2017 51 Useful Lesser Known Commands for Linux Users

46. apt-get build-dep


package_name: Build all
the dependency,
automatically while
installing any speciៗ�c
package.
47. lsof -iTCP:80 -
sTCP:LISTEN. The
script, outputs all the
service/process using
port 80.
48. ퟺ�nd -size +100M :
This command
combination, Lists all
the ៗ�les/folders the size
of which is 100M or
more.
49. pdftk : A nice way to
concatenate a lot of pdf
ៗ�les, into one.
50. ps -LF -u user_name
: Outputs Processes
and Threads of a user.
51. Startx — :1 (This
command creates
another new X session).

10 Lesser Known Useful


Linux Commands- Part V

That’s all for now. Don’t


forget to give us your
valuable feedback in our
comment section. This is
not an end of lesser known
20 Linux YUM (Yellowdog Updater, Modiퟺ�ed) Commands
http://www.tecmint.com/51­useful­lesser­known­commands­for­linux­users/ 11/16
3/25/2017 51 Useful Lesser Known Commands for Linux Users

Linux commands, and we


will keep them bringing to
you, from time to time, in
our articles. I’ll be coming
with another article, very
interesting and useful for
our readers. Till then stay
tuned and connected to
Tecmint.com.

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. Use our Hosting referral
link if you planning to start

your blog ($3.82/month).


4. Become a Supporter - Make
a contribution via PayPal

5. Support us by purchasing
our premium books in PDF
format.
20 Linux YUM (Yellowdog Updater, Modiퟺ�ed) Commands
http://www.tecmint.com/51­useful­lesser­known­commands­for­linux­users/ 12/16
3/25/2017 51 Useful Lesser Known Commands for Linux Users

6. Support us by taking our

online Linux courses

We are thankful for your never


ending support.

Tags: lesser known commands

linux commands

PREVIOUS NEXT STORY

STORY FireStarter – A
Showterm.io – High-Level
A Graphical

 Terminal/Shell Interface
Recording, Iptables
Upload and Firewall For
Share Tool for Linux Systems
Linux

 YOU MAY ALSO LIKE...

 44  10  72

MySQL The
Backup and Complete
20 Linux YUM (Yellowdog Updater, Modiퟺ�ed) Commands
http://www.tecmint.com/51­useful­lesser­known­commands­for­linux­users/ 13/16
3/25/2017 51 Useful Lesser Known Commands for Linux Users

Restore How to Run Guide to


Commands ‘sudo’ “useradd”
for Command Command
Database Without in Linux –
Administrat Entering a 15 Practical
ion Password Examples
2 NOV, 2012
in Linux 28 MAR, 2014
25 JAN, 2017

38 RESPONSES

 Comments 3  Pingbacks 0

Geoff  January 2, 2017 at 3:24 pm


Change
25. du -h –max-depth=1

to
25. du -h –max-depth=1 Note that -m is
not the same as –m. Use two of hex 2D.
Reply

Ravi Saive
  January 3, 2017 at 11:01 am
@Geoff,
Thanks for pointing out,
corrected in the writeup..
Reply

Jeff  December 14, 2016 at 6:49 pm


Regarding the ퟺ�rst command, you can
try “sudo!!” a thousand times, it does
not work. I looked it up, and it’s “sudo !!”
(with a space).
Reply

« Older Comments

GOT SOMETHING TO SAY? JOIN THE


DISCUSSION.
20 Linux YUM (Yellowdog Updater, Modiퟺ�ed) Commands
http://www.tecmint.com/51­useful­lesser­known­commands­for­linux­users/ 14/16
3/25/2017 51 Useful Lesser Known Commands for Linux Users

Comment

Name * Email *

Website

Notify me of followup comments via e-


mail. You can also subscribe without
commenting.

Post Comment

LINUX MONITORING TOOLS LINUX INTERVIEW QUESTIONS OPEN SOURCE TOOLS

How to Add Windows Host 10 Interview Questions and How to Track Business or
to Nagios Monitoring Server Answers on Various Personal Expenses Using
22 NOV, 2013 Commands in Linux GnuCash (Accounting
22 MAR, 2014 Software) in Linux
Lynis 2.2.0 Released – 14 JAN, 2016
Security Auditing and 10 Useful SSH (Secure
Scanning Tool for Linux Shell) Interview Questions Adminer – A Advanced Web
Systems and Answers Based Databases
18 MAR, 2016 15 MAR, 2014 Administration Tool for
Linux
Cockpit – A Powerful Tool to 10 Useful Interview 29 JAN, 2014
Monitor and Administer Questions on Linux Services
Multiple Linux Servers Using and Daemons Install Adobe Flash Player
a Web Browser 10(Yellowdog
20 Linux YUM 11.2 On CentOS/RHEL 7/6
MAR, 2014 Updater, Modiퟺ�ed) Commands

http://www.tecmint.com/51­useful­lesser­known­commands­for­linux­users/ 15/16
3/25/2017 51 Useful Lesser Known Commands for Linux Users

6 OCT, 2016 and Fedora 25-20


Basic Linux Interview
7 DEC, 2016
BCC – Dynamic Tracing Questions and Answers –
Tools for Linux Performance Part II
How to Test Your Internet
23 NOV, 2013
Monitoring, Networking and Speed Bidirectionally from
More Command Line Using
23 SEP, 2016 ‘Speedtest-CLI’ Tool
11 MAR, 2015


Tecmint: Linux Howtos, Tutorials & Guides © 2017.
All Rights Reserved.     
This work is licensed under a (cc) BY-NC
The material in this site cannot be republished
either online or ofែ�ine, without our permission.

20 Linux YUM (Yellowdog Updater, Modiퟺ�ed) Commands


http://www.tecmint.com/51­useful­lesser­known­commands­for­linux­users/ 16/16

You might also like