troubleshooting Question

How do I concatenate many files into a single file?

Avatar of IT_ETL
IT_ETL asked on
Shell ScriptingLinuxUnix OS
10 Comments1 Solution433 ViewsLast Modified:
I have got around 100 files. I would like to concatenate them into a single file. Just a note, these are all text files and there should not be any spaces in between file1 and file2 or file2 and file3 and so on. Also, contents of the file2, file3 and so on will start from the next line wherever the previous file end. For example,


100        20140101
101        20140102


1000     20130101
1001     20130102


2000    20140601
2001    20140602

When I concatenate above three files, it should look like below,


100        20140101
101        20140102
1000      20130101
1001      20130102
2000      20140601
2001      20140602

Considering above example, how do I concatenate around 100 files into a single file in UNIX. Please advise.
Join our community to see this answer!
Unlock 1 Answer and 10 Comments.
Start Free Trial
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 10 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros