The 'redhat' shutdown mode does not work. Excerpts from the source code: static char *halt_command[] = { "/usr/bin/halt", "halt", NULL }; static char *reboot_command[] = { "/usr/bin/reboot", "reboot", NULL }; [...] if (command == XFSM_SHUTDOWN_POWEROFF) argv = halt_command; else argv = reboot_command; [...] execv (argv[0], argv); Hence the halt or reboot command, which should be invoked without a real parameter, is actually invoked with an extra halt or reboot parameter, just as if I typed this at the command prompt: /sbin/halt halt A possible workaround is to modify the execv call to this: execv (argv[0], argv+1);
Indeed, thanks!