- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- cat buffering
Operating System - HP-UX
1819802
Members
3163
Online
109607
Solutions
Forums
Categories
Company
Local Language
юдл
back
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Discussions
Forums
Forums
Discussions
юдл
back
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Blogs
Information
Community
Resources
Community Language
Language
Forums
Blogs
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-19-2004 03:01 AM
тАО11-19-2004 03:01 AM
cat buffering
we have a multi thread process that creates smaller files from original file for processing (validations etc). once the validations are complete, the files are put together to create the original files.
cat command is used to put all the small files together to create one file. this is a sequential process, only one file from group of files is selected at a time.
we have noticed that the cat takes longer as it progresses through the files.
the example would be, cat starts with the first file, concatenates it to the file taking about 10 minutes. when the second file is picked, it takes about 15 minutes to concatenate the file, and so on. all the files are approximately same size. the total volume of the records is about 10 million.
does the cat command's buffering anything to do with the process being slow or any other OS setting needs to be changed? any information would be of great assistance.
cat command is used to put all the small files together to create one file. this is a sequential process, only one file from group of files is selected at a time.
we have noticed that the cat takes longer as it progresses through the files.
the example would be, cat starts with the first file, concatenates it to the file taking about 10 minutes. when the second file is picked, it takes about 15 minutes to concatenate the file, and so on. all the files are approximately same size. the total volume of the records is about 10 million.
does the cat command's buffering anything to do with the process being slow or any other OS setting needs to be changed? any information would be of great assistance.
3 REPLIES 3
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-19-2004 03:08 AM
тАО11-19-2004 03:08 AM
Re: cat buffering
Hi
Each time it starts the buffer displacement that must be rewritten gets bigger and thus slower
Use the format
cat file1 file2 > file3
concatenates file1 and file2, and places the result in file3.
It will be a lot quicker
Steve STeel
Each time it starts the buffer displacement that must be rewritten gets bigger and thus slower
Use the format
cat file1 file2 > file3
concatenates file1 and file2, and places the result in file3.
It will be a lot quicker
Steve STeel
If you want truly to understand something, try to change it. (Kurt Lewin)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-19-2004 08:16 AM
тАО11-19-2004 08:16 AM
Re: cat buffering
It sounds as though you are writing a new output file each time and then feeding that output file + 1 additional file to cat each time to produce a newer output file.
What you should be doing instead is
cat file1 > ofile
cat file2 >> ofile
cat file3 >> ofile
...
...
cat file99 >> ofile
The append does an lseek() to EOF and then starts writing so that the only data that need be read is the current input file.
What you should be doing instead is
cat file1 > ofile
cat file2 >> ofile
cat file3 >> ofile
...
...
cat file99 >> ofile
The append does an lseek() to EOF and then starts writing so that the only data that need be read is the current input file.
If it ain't broke, I can fix that.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-03-2004 03:21 AM
тАО12-03-2004 03:21 AM
Re: cat buffering
with the approach, "cat file1 file2 > file3" we have seend about 6% reduction in time.
Is there any other way to improve the speed while concatenating files, this does not necessarily a cat command but, any variation or some other command with same functoinality.
we are interested in making the concatenation faster.
Is there any other way to improve the speed while concatenating files, this does not necessarily a cat command but, any variation or some other command with same functoinality.
we are interested in making the concatenation faster.
The opinions expressed above are the personal opinions of the authors, not of Hewlett Packard Enterprise. By using this site, you accept the Terms of Use and Rules of Participation.
Company
Learn About
News and Events
Support
© Copyright 2025 Hewlett Packard Enterprise Development LP