[syslinux] tftpd-hpa does not fork

Christian Hoefer
Wed, 25 Sep 2002 13:26:36 -0000

hi,

i try to get this tsize capable tftpd running,
but it doesn't fork. (as read the strace output
and the process table)

strace:

9122  execve("/usr/sbin/in.tftpd", ["/usr/sbin/in.tftpd",
"-u",
"nobody", "-s", "/var/tftpboot/"], [/* 35 vars
*/]) = 0
9122  uname({sys="Linux", node="saturn", ...}) = 0
9122  brk(0)                            = 0x808cc60
9122  old_mmap(NULL, 4096, PROT_READ|PROT_WRITE,
MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x40013000
9122  open("/etc/ld.so.preload", O_RDONLY) = -1 ENOENT (No such file
or directory)
9122  open("/etc/ld.so.cache", O_RDONLY) = 3
9122  fstat64(3, {st_mode=S_IFREG|0644, st_size=15305, ...}) = 0
9122  old_mmap(NULL, 15305, PROT_READ, MAP_PRIVATE, 3, 0) = 0x40014000
9122  close(3)                          = 0
9122  open("/lib/libc.so.6", O_RDONLY)  = 3
9122  read(3,
"\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\3\0\1\0\0\0\204\221"..., 1024) =
1024
9122  fstat64(3, {st_mode=S_IFREG|0755, st_size=1145456, ...}) = 0
9122  old_mmap(NULL, 1157888, PROT_READ|PROT_EXEC, MAP_PRIVATE, 3, 0)
= 0x40018000
9122  mprotect(0x40129000, 39680, PROT_NONE) = 0
9122  old_mmap(0x40129000, 24576, PROT_READ|PROT_WRITE,
MAP_PRIVATE|MAP_FIXED, 3, 0x111000) = 0x40129000
9122  old_mmap(0x4012f000, 15104, PROT_READ|PROT_WRITE,
MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x4012f000
9122  close(3)                          = 0
9122  munmap(0x40014000, 15305)         = 0
9122  socket(PF_UNIX, SOCK_DGRAM, 0)    = 3
9122  fcntl64(3, F_SETFD, FD_CLOEXEC)   = 0
9122  connect(3, {sin_family=AF_UNIX, path="/dev/log"}, 16) = 0
9122  brk(0)                            = 0x808cc60
9122  brk(0x808cc80)                    = 0x808cc80
9122  brk(0x808d000)                    = 0x808d000
9122  chdir("/var/tftpboot/")           = 0
9122  brk(0x808e000)                    = 0x808e000
9122  socket(PF_UNIX, SOCK_STREAM, 0)   = 4
9122  connect(4, {sin_family=AF_UNIX, path="/var/run/.nscd_socket"},
110) = -1 ENOENT (No such file or directory)
9122  close(4)                          = 0
9122  open("/etc/nsswitch.conf", O_RDONLY) = 4
9122  fstat64(4, {st_mode=S_IFREG|0644, st_size=465, ...}) = 0
9122  old_mmap(NULL, 4096, PROT_READ|PROT_WRITE,
MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x40014000
9122  read(4, "# /etc/nsswitch.conf\n#\n# Example"..., 4096) = 465
9122  read(4, "", 4096)                 = 0
9122  close(4)                          = 0
9122  munmap(0x40014000, 4096)          = 0
9122  open("/etc/ld.so.cache", O_RDONLY) = 4
9122  fstat64(4, {st_mode=S_IFREG|0644, st_size=15305, ...}) = 0
9122  old_mmap(NULL, 15305, PROT_READ, MAP_PRIVATE, 4, 0) = 0x40014000
9122  close(4)                          = 0
9122  open("/lib/libnss_compat.so.2", O_RDONLY) = 4
9122  read(4,
"\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\3\0\1\0\0\0\340\25"..., 1024) =
1024
9122  fstat64(4, {st_mode=S_IFREG|0644, st_size=40140, ...}) = 0
9122  old_mmap(NULL, 43244, PROT_READ|PROT_EXEC, MAP_PRIVATE, 4, 0) =
0x40133000
9122  mprotect(0x4013d000, 2284, PROT_NONE) = 0
9122  old_mmap(0x4013d000, 4096, PROT_READ|PROT_WRITE,
MAP_PRIVATE|MAP_FIXED, 4, 0x9000) = 0x4013d000
9122  close(4)                          = 0
9122  open("/lib/libnsl.so.1", O_RDONLY) = 4
9122  read(4, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\3\0\1\0\0\0
;\0\000"..., 1024) = 1024
9122  fstat64(4, {st_mode=S_IFREG|0644, st_size=69408, ...}) = 0
9122  old_mmap(NULL, 80896, PROT_READ|PROT_EXEC, MAP_PRIVATE, 4, 0) =
0x4013e000
9122  mprotect(0x4014f000, 11264, PROT_NONE) = 0
9122  old_mmap(0x4014f000, 4096, PROT_READ|PROT_WRITE,
MAP_PRIVATE|MAP_FIXED, 4, 0x10000) = 0x4014f000
9122  old_mmap(0x40150000, 7168, PROT_READ|PROT_WRITE,
MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x40150000
9122  close(4)                          = 0
9122  munmap(0x40014000, 15305)         = 0
9122  uname({sys="Linux", node="saturn", ...}) = 0
9122  open("/etc/passwd", O_RDONLY)     = 4
9122  fcntl64(4, F_GETFD)               = 0
9122  fcntl64(4, F_SETFD, FD_CLOEXEC)   = 0
9122  fstat64(4, {st_mode=S_IFREG|0644, st_size=1805, ...}) = 0
9122  old_mmap(NULL, 4096, PROT_READ|PROT_WRITE,
MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x40014000
9122  _llseek(4, 0, [0], SEEK_CUR)      = 0
9122  read(4, "root:x:0:0:root:/root:/bin/bash\n"..., 4096) = 1805
9122  close(4)                          = 0
9122  munmap(0x40014000, 4096)          = 0
9122  umask(0)                          = 022
9122  ioctl(0, 0x5421, [1])             = 0
9122  close(1)                          = 0
9122  close(2)                          = 0
9122  rt_sigaction(SIGCHLD, {SIG_IGN}, NULL, 8) = 0
9122  rt_sigaction(SIGHUP, {0x80492b0, [], 0x4000000}, NULL, 8) = 0
9122  select(1, [0], NULL, NULL, {900, 0}) = 0 (Timeout)
9122  _exit(0)                          = ?


to me it looks like it can't allocate the port. How can i
know if it's true and why.

thank you for any help
Christian