in reply to Named Pipe, Linking to It and Knowing the Name of the Link

Sorry for the missing code setting up the FIFO- it was late and I was confused. To better explain my goal:
  1. I execute a 3rd party program with an argument/parameter file='foo.bar'.
  2. The 3rd party program looks in /tmp/data for the file, '/tmp/data/foo.bar'.
  3. I need the contents of foo.bar to include the string 'ini=foo.bar.csv',yet the remaining 99% of the very large config file is the same.
  4. I know I can write the file /tmp/data/foo.bar before calling said 3rd program; however, I want the least amount of disk i/o and space if this is working with lots of files even on a ramdisk, so I thought of symlink as less overhead.
  5. I thought a named pipe/FIFO or socket would know the name of the file being read and output according to a special var for the "name of the sym link that points to the process that acts like a file".
  6. I was hoping a perl process could take over a directory and any file read attempted on that directory would call a process or communicate the name of file accessed and the contents for read would be dynamic based on the file name requested.
  7. The 3rd party program I have not control short of the file passing to it. Perhaps FUSE or otherwise is the answer instead of PERL?
  • Comment on Re: Named Pipe, Linking to It and Knowing the Name of the Link