Redirecting stdin through a FIFO
Posted
by
kaoD
on Stack Overflow
See other posts from Stack Overflow
or by kaoD
Published on 2010-12-30T01:18:02Z
Indexed on
2010/12/30
1:53 UTC
Read the original article
Hit count: 631
I'm running a server app (written in Java) under GNU/Linux which takes input (from stdin, I guess) and interprets it to run some commands. I dont want to run the app inside a terminal window (I'd like to run a daemon), but I'd still like to be able to input commands whenever I want to. I thought I might be able to do that using fifos, so I created it using mknod. The problem is cat fifofile > java... and cat fifofile | java ... fail with a "file not found" error for some reason.
Using only cat to read and write and the fifo works flawlessly.
Is there any way to fix this, or any other way to achieve the same goal?
© Stack Overflow or respective owner