0

Running CentOS. xinetd.d/clhtest entry is as follows:

service clhtest
{
        disable                 = no
        port                    = 8020
        socket_type             = stream
        protocol                = tcp
        wait                    = no
        user                    = charrison
        passenv                 = PATH
        server                  = /home/charrison/bin/clhtest
}

In debugging this I need to write to a file. I set the server process up to open /home/charrison/log/foo.txt as one of the first steps (note user=charrison), but it doesn't - and I assume it tries to. When I launch the server program from command line it opens the file successfully.

I suspect the umask parameter may be needed, but I don't know what it defaults to.

Any hints?

JasonMArcher
  • 14,195
  • 22
  • 56
  • 52
Chap
  • 3,649
  • 2
  • 46
  • 84
  • Can you set your server to a simple shell script that touches `/tmp/foo`? This will tell you the username, group, and umask. – PaulProgrammer Jul 31 '13 at 18:53
  • It's a great idea but it's not working. Don't know if xinetd has cached its pointer to the server and it's not invoking the shell script, or if the script is unable to touch. Crazy making. – Chap Jul 31 '13 at 19:24
  • Did you restart or kick inetd to read the updated config files? I usually do something like: `killall -HUP xinetd` – PaulProgrammer Jul 31 '13 at 22:35

0 Answers0