Guillaume Thouvenin
2006-Jan-17 07:01 UTC
[Xen-devel] [BUG?] process doesn''t inherit time left
Hello, Some of my scripts don''t work under XenoLinux. The reason is that scripts are using execvp() function and the new process image created by execvp function doesn''t inherit the time left to an alarm signal in the old process''image. According to IEEE Std 1003.1, the inheritance should be the default behavior. For example under Linux (I mean without Xen hypervisor), the following program stops after two seconds but under XenoLinux, it continues to list information about files without receiving the alarm clock. Here is the program: --------------------------B<---------------------------------- #include <unistd.h> int main() { char *args[] = {"/bin/ls", "-lR", "/", (char *) 0 }; alarm(2); execvp("/bin/ls", args); return 0; } -------------------------------------------------------------- under Linux: # ./test1 Lists all files and stops after 2 seconds (Alarm clock received) under Xen + XenoLinux: # ./test1 Lists all files recursively and continues after 2 seconds. I don''t know if it''s really a bug because under Linux, if you don''t assign a handler to the SIGALRM, by default it stops the application. Is it different with XenoLinux? Best regards, Guillaume _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel