• Home
  • Archive
  • Tools
  • Contact Us

The Customize Windows

Technology Journal

  • Cloud Computing
  • Computer
  • Digital Photography
  • Windows 7
  • Archive
  • Cloud Computing
  • Virtualization
  • Computer and Internet
  • Digital Photography
  • Android
  • Sysadmin
  • Electronics
  • Big Data
  • Virtualization
  • Downloads
  • Web Development
  • Apple
  • Android
Advertisement
You are here:Home » echo Command : Practical Examples For SSH

By Abhishek Ghosh April 17, 2015 5:13 pm Updated on April 17, 2015

echo Command : Practical Examples For SSH

Advertisement

Not much is usually known by a unix/GNU Linux newbie about the potential power of echo. echo can be used on command line or used within a shell script. The later usage is more common and actual powerful usage of echo is done only within the shell scripts.

 

echo Command : Basics

 

echo not only echoes the text. The name of the utility points to a bit lesser capability.

There is not much to write about the examples given in the echo™s manual page. One can run man echo to read and master echo. This guide covers only some practical commons which we can use on, for example SSH.

Advertisement

---

 

echo Command : Practical Examples For SSH

 

We are providing only few examples of echo here. First one is to list only the files with certain extension at certain location. Some times on SSH we need to list only the .conf file, just for example; if we need to list all the .conf files at /etc/nginx location, we can change directory there and run :

Vim
1
echo *.conf

This will list all the files under that directory :

Vim
1
echo *

we can count them :

Vim
1
echo * | wc -w

As we written before, echo can be used to empty any file, for example, we want to empty /etc/nginx/nginx.conf , then we can do this :

Vim
1
echo ' ' > /etc/nginx/nginx.conf

> writes data to an exiting file. >> is a kind of forcing. It will either overwrite or create a new file.

echo Command - Practical Examples For SSH

In the reverse way, we can write stuffs in the file :

Vim
1
echo -e "server \t{\n\tuser\twww-data;\n\terror_log\tlogs/error.log notice;\t\n\t}

\t, \n, -e are explained in the man page of echo. This ends the story with echo. Obviously, the commands can be combined or piped. One example of unix piping is given in the example, a bit practice will give more ideas on how to use echo.

Tagged With echo command ssh , ssh echo , echo ssh , how do I do ssh after a echo command in vim
Facebook Twitter Pinterest

Abhishek Ghosh

About Abhishek Ghosh

Abhishek Ghosh is a Businessman, Surgeon, Author and Blogger. You can keep touch with him on Twitter - @AbhishekCTRL.

Here’s what we’ve got for you which might like :

Articles Related to echo Command : Practical Examples For SSH

  • Nginx WordPress Installation Guide (All Steps)

    This is a Full Nginx WordPress Installation Guide With All the Steps, Including Some Optimization and Setup Which is Compatible With WordPress DOT ORG Example Settings For Nginx.

  • Command Prompt Commands : Alphabetical list of all commands in Windows 7

    Command Prompt Commands in Windows 7 provides the user access to 180+ command line commands. Here is a list of 200 Command Prompt Commands in Windows 7.

  • Steps To Install Nginx Plus on Ubuntu Server (HP Cloud)

    Here Are the Steps To Install Nginx Plus on Ubuntu Server Running on HP Cloud. Nginx Plus is the Paid Version of Nginx with Extra Features.

  • WordPress Multisite on Nginx on Ubuntu 14.04 on HP Cloud

    Here is a Step by Step Guide on Setting Up WordPress Multisite on Nginx on Ubuntu 14.04 on HP Cloud with All Commands and the Configuration.

performing a search on this website can help you. Also, we have YouTube Videos.

Take The Conversation Further ...

We'd love to know your thoughts on this article.
Meet the Author over on Twitter to join the conversation right now!

If you want to Advertise on our Article or want a Sponsored Article, you are invited to Contact us.

Contact Us

Subscribe To Our Free Newsletter

Get new posts by email:

Please Confirm the Subscription When Approval Email Will Arrive in Your Email Inbox as Second Step.

Search this website…

 

Popular Articles

Our Homepage is best place to find popular articles!

Here Are Some Good to Read Articles :

  • Cloud Computing Service Models
  • What is Cloud Computing?
  • Cloud Computing and Social Networks in Mobile Space
  • ARM Processor Architecture
  • What Camera Mode to Choose
  • Indispensable MySQL queries for custom fields in WordPress
  • Windows 7 Speech Recognition Scripting Related Tutorials

Social Networks

  • Pinterest (24.3K Followers)
  • Twitter (5.8k Followers)
  • Facebook (5.7k Followers)
  • LinkedIn (3.7k Followers)
  • YouTube (1.3k Followers)
  • GitHub (Repository)
  • GitHub (Gists)
Looking to publish sponsored article on our website?

Contact us

Recent Posts

  • Market Segmentation in BriefSeptember 20, 2023
  • What is Booting?September 18, 2023
  • What is ncurses?September 16, 2023
  • What is JTAG in Electronics?September 15, 2023
  • iPhone 15 Pro Max Vs Samsung Galaxy S22/S23 UltraSeptember 14, 2023
PC users can consult Corrine Chorney for Security.

Want to know more about us?

Read Notability and Mentions & Our Setup.

Copyright © 2023 - The Customize Windows | dESIGNed by The Customize Windows

Copyright  · Privacy Policy  · Advertising Policy  · Terms of Service  · Refund Policy