I searched on askubuntu, stackoverflow and I found this:

  1. $ mkfifo fif.pipe

  2. $ bash script.sh < fif.pipe

  3. $ echo 'say HELLO' > fif.pipe (say command do something in the script)

But after $ bash script.sh < fif.pipe I got a blank output:


cd /opt/cfx-server
[ -d cache ] || mkdir cache

exec /opt/cfx-server/FXServer $SERVER_ARGS $*


bash start.sh +exec server.cfg

closed as unclear what you're asking by Thomas, jimmij, Christopher, Sparhawk, roaima Feb 18 at 15:57

Please clarify your specific problem or add additional details to highlight exactly what you need. As it's currently written, it’s hard to tell exactly what you're asking. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.

  • Welcome on U&L! Please avoid adding images, as they make questions less readable. Try to paste text instead. – fra-san Jan 30 at 9:35
  • Ok sorry! I'll delete! – Bogdan Jan 30 at 9:43
  • 1
    What happens if you try a simple cat < fif.pipe and, in another shell, echo 'say HELLO' > fif.pipe? The issue might depend on your script. What does it do? – fra-san Jan 30 at 9:49
  • The script starts a game server(FiveM) – Bogdan Jan 30 at 9:51
  • How about running your script in the background? – oh.dae.su Jan 30 at 9:53

That's because if you read or write to pipe, program will wait until other side will open pipe.

mkfifo pipe

In one terminal: echo "hey" > pipe

Program is waiting

In second terminal: cat pipe

In both terminals you can see prompt.

Not the answer you're looking for? Browse other questions tagged or ask your own question.