FedoraForum.org - Fedora Support Forums and Community
Results 1 to 2 of 2
  1. #1
    Join Date
    Jun 2005
    Location
    Montreal, Que, Canada
    Posts
    4,982

    Temporary Concatenation of files

    In other systems (eg IBM), one can catenate two or more files to serve as a single input.
    In a way, with the linux command cat, we can join file1, file2, file..n and create an input to a Target_Program
    Use of cat requires the build of a temporary before it gets to Target_Program. What to do if each file was one or two terrabytes in size? what then?

    It would be great if one could have a standard way to indicate to any "Target_Program" a new input option that takes a dynamic list of files, similar to the list found in a Path statement. There are many advantages, for such an improvement or enhancement.
    One example would be to read catenation of 30 days of log files. Another would be a concatenated list of sales by city or sales between two dates.

    My view is that Linux is useful for much larger systems if the above catenation could be addressed. Gnome uses an approach as follows:
    x=["file1","file2","file3",... ]. This approach is quite similar to presenting to the Path format: "file1:file2:file3:..".

    I have given it some thought, and a way to trigger a difference could be to use an environment variable to signal a system library open routine to proceed differently. The program would still open File1, but at end of file1, file 1 would close and file2 would open, without any change to program logic.

    Rambling of a IT futurist.
    Last edited by lsatenstein; 23rd December 2017 at 12:42 AM.
    Leslie in Montreal

    Interesting web sites list
    http://forums.fedoraforum.org/showth...40#post1697840

  2. #2
    Join Date
    Oct 2010
    Location
    Canberra
    Posts
    2,865

    Re: Temporary Concatenation of files

    After just looking at the source for cat, I don't think it builds a temporary file. It just reads the files into an internal buffer and then writes the buffer to stdout once it fills or the current file ends.
    If the target program requires a file name rather than stdin then you can use a named pipe (aka fifo).
    Obviously if the target program wants to seek within the file then you would need a temporary file.

Similar Threads

  1. F14 freezes temporary
    By naraesk in forum Hardware & Laptops
    Replies: 6
    Last Post: 12th January 2011, 07:28 PM
  2. SELinux, postfix problem with temporary files
    By scog28 in forum Servers & Networking
    Replies: 1
    Last Post: 13th December 2007, 05:19 PM
  3. Checking temporary internet files' size
    By tech291083 in forum Using Fedora
    Replies: 6
    Last Post: 20th October 2007, 10:00 AM
  4. C Concatenation
    By cdlaforc in forum Programming & Packaging
    Replies: 2
    Last Post: 24th April 2006, 08:42 AM
  5. Temporary Files
    By Clunixchit in forum Using Fedora
    Replies: 9
    Last Post: 3rd May 2005, 02:50 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •