Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3844564
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 19, 20262026-05-19T16:06:33+00:00 2026-05-19T16:06:33+00:00

I need to configure a server with a few files and I want to

  • 0

I need to configure a server with a few files and I want to do it programmatically.

I need to create files say /home/a.config, /var/spool/b.config, /etc/c.config

Files above have some contents (multi lines).

I want to create ONE shell script which can create all three file with multiple lines (around 10).
I would like to know the how can I use CAT command to do that. (inside shell script).

I am looking something like this

echo " going to create  /home/a.config"

cat "HOW CAN I HAVE MULTIPLE LINES HERE?? " >  /home/a.config 

thanks

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-19T16:06:34+00:00Added an answer on May 19, 2026 at 4:06 pm

    You can use a here document:

    cat <<EOF >filename
    first line
    second line
    third line
    EOF
    

    You can place several of these in the same script.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

In my program I need to programmatically configure an ApplicationContext. Specifically, I have a
I need configure connect to server via SSL protocol. I got from server owners
I have VisualSVN Server and I want to create an internet facing repository on
I need to configure Team Build Server (TFS 2010) to run xUnit tests as
Need to configure email, name, mail server and other by c#. How do I
In my iOS app, I need to configure a socket server for receiving data
I have a remote server configured on archlinux and I need to install the
I need to configure 'Client certificate authentication' in Glassfish 3. I tried many scenarios
What would I need to configure and what would automatically work? As far as
I'm currently working on a NuGet package which need to configure a couple of

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.