Connecting to hddtemp-daemon for multiple disks with netcat randomly gives only partial results
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
hddtemp (Ubuntu) |
Confirmed
|
Undecided
|
Unassigned |
Bug Description
Binary package hint: hddtemp
Having five disks (boot plus raid) and running hddtemp in daemon mode (default except explicitely given disks)
by 'netcat localhost 7543' I get shortened result strings. I assume this to be a classcal problem of the following structure:
hddtemp (tested with strace in no-fork mode) produces strings for each disk
with an extra 'write(send, whaever)';
these 'are sent' to the network one after the opther,
but hddtemp closes the connection too fast, so the 'out of band close (FIN?)'
overruns from all to none parts/packets/
and the receivers randomly sees shortened answers.
This may be fixed by collecting all parts of the answer in one string first to send at once
and by waiting a time before closing.
seen in: (ubuntu 10.10; hddtemp 0.3-beta15-46)
Stucki
ProblemType: Bug
DistroRelease: Ubuntu 10.10
Package: hddtemp 0.3-beta15-46
ProcVersionSign
Uname: Linux 2.6.35-28-generic i686
NonfreeKernelMo
Architecture: i386
Date: Sun May 1 19:26:15 2011
InstallationMedia: Ubuntu 10.04.1 LTS "Lucid Lynx" - Release i386 (20100816.1)
ProcEnviron:
PATH=(custom, user)
LANG=de_DE.UTF-8
SHELL=/bin/zsh
SourcePackage: hddtemp
Status changed to 'Confirmed' because the bug affects multiple users.