0

We have this sript in ksh file.

FIFO_FILE=${FOLDER}/fifo_FIFOFILE.$$
mkfifo $FIFO_FILE

Sometimes it's working. Sometimes it's not, and there is no error or warning, just a log

mkfifo: must specify file
Usage: mkfifo [-m mode] file ...

I search on internet but not found any thing about the mkfifo message "must specify file". And it sure do not have that message in our code base. I'm not sure it's a warning or anything. Do anyone have anything (document,...) regards that mkfifo message?

I found some info about mkfifo here enter link description here but nothing about error message.

EDIT1: We have many script before that script that run ok. So, it not possible that FOLDER have space. Does anyone have any resource involve message "mkfifo: must specify file" of mkfifo?

1 Answers1

0

The version of mkfifo in AIX 6.1 definitely has this message:

$ strings `which mkfifo`
@(#)61
1.16  src/bos/usr/ccs/lib/libc/__threads_init.c, libcthrd, bos61B, b2007_33A0 8/2/07 13:09:21
mkfifo:
%s %s %s
mkfifo.cat
XPG_UNIX98
/usr/bin/chmod
mkfifo: must specify file
Usage: mkfifo [-m mode] file ...
@(#)06  1.6  src/bos/usr/bin/mkfifo/mkfifo.c, cmdposix, bos610 1/18/03 05:12:06

It's easily triggered by not specifying a file:

$ mkfifo
mkfifo: must specify file
Usage: mkfifo [-m mode] file ...

But curiously, you can also hit this with an "invalid" -m parameter (ie. it doesn't validate the mode parameter before throwing the missing filename error):

$ mkfifo -mabcdefg
mkfifo: must specify file
Usage: mkfifo [-m mode] file ...

If you potentially end up with '-m' at the start of the variable expansion it could trigger this as well.

J. Cordasco
  • 836
  • 6
  • 15