Quantcast
Channel: UNIX and Linux Forums
Viewing all articles
Browse latest Browse all 16232

Copy(append ) the contents of file1 and file2 to file3

$
0
0
Platform : Oracle linux 6.5

I have two log files with the following contents

Code:

[root@tblmanh236 test]# ls -l
total 8
-rw-r--r--. 1 root root 75 Dec 10 20:55 myLogfile1.log
-rw-r--r--. 1 root root 51 Dec 10 20:57 myLogfile2.log

[root@tblmanh236 test]#
[root@tblmanh236 test]# cat myLogfile1.log
hello world
jaded zombies acted quaintly but kept driving the oxen forward

[root@tblmanh236 test]#
[root@tblmanh236 test]#
[root@tblmanh236 test]#
[root@tblmanh236 test]#
[root@tblmanh236 test]# cat myLogfile2.log
The quick brown fox jumped over the lazy dog
hello
[root@tblmanh236 test]#

I want the contents of myLogfile1.log and myLogfile2.log to be copied(appended) to a single logfile called named mySingleLogfile.log .
How can I do this ?

Viewing all articles
Browse latest Browse all 16232

Trending Articles