Hello,
If udp-receiver is writing to a pipe and the pipe fails, udp-receiver
will incorrectly exit with a returncode of zero. This is easily tested
with a trivial pipe program that copies stdin to stdout, but exits with
a nonzero status upon encountering eof.
Adding the following to startReceiver() in udpr-negotiate.c is
sufficient to fix this behavior:
<---- cut here
int ret;
...
if(pipePid) {
ret=udpc_waitForProcess(pipePid, "Pipe");
}
...
return ret;
<---- cut here
Regards,
George Coulouris
National Center for Biotechnology Information (contractor)
Hello,
While using udpcast, I found out that it may be very verbose on stderr, even if
a logfile is specified.
This turns out to be a problem for our embedded application where the stderr is
a (slow) serial port.
So here is a patch which replace every occurrence of fprint(sdterr,...) by the
flprintf() function defined in log.c.
I thought it might be of some use for people.
(This patch also happen to cleanup the blank spaces at end of lines)
Julien
--
People in the embedded space don't do prototypes. They hack something until it
works, then it's done.
---
Always code as if the person who will maintain your code is a maniac serial
killer that knows where you live
I want to use Udpcast from iso image in this scenario:
- first pc boots from udpcast iso image
-second pc boots from ethernet using pxe that sends him udpreceiver How can
I do it?
thanks
Hello,
I've made the attached patch to prevent the situation where the udp-receiver
hang out indefinitly waiting for data when the server has been killed after
having started to send data.
In this case, the udp-received program would hang indefinitly.
Since in my program, udp-receiver is called through system(...); the result is
a hang.
With this patch I use a SIGALARM signal to reset a flag to 0, and act as a
watchdog. The watchdog is started just before the sending data phase of the
protocol, and is feed each time a packet is received from the server.
If 2 times in a row the watchdog is not feed, the program exit in error.
The current value is set as a #define as 60s, which is in effect 2mn before
udp-receiver is actually killed.
However I am aware that this implementation is somehow crude, and I would be
interested by any other way to do that.
Additionally, if someone is interested by this patch, I could make it so that
the watchdog period is configurable on the command-line.
Thanks for your time,
Julien
--
People in the embedded space don't do prototypes. They hack something until it
works, then it's done.
---
Always code as if the person who will maintain your code is a maniac serial
killer that knows where you live
I tried booting a recent Apple iMac with the latest kernel and an
initrd from cast-o-matic, but the kayboard fails to work.
Looking at an installed Debian system, the module hid_apple is loaded.
Is this driver missing from the udpcast images, and is it possible to
add it?
--
Frederik Himpe <fhimpe(a)vub.ac.be>
Vrije Universiteit Brussel
Hello,
I´m using latest udpcast versión (20100130) in Debian machines to transfer
files in unidirectional mode. Sometimes I see the next message in receiver
machine: Receiver error
After putting some fprintf I realized the problem is in the file
udpr-negotiate.c in line 191:
sock = udpc_selectSock(client_config.socks, NR_CLIENT_SOCKS,
net_config->startTimeout);
if(sock < 0) {
return -1;
}
Why sock is < 0? What should I do?
Thanks
Hi all
I've been using udpcast to clone about 32 pc on a classroom for a months, i
don't remember exactly which versión of udpcast but now after upgrade to
20100131 version
things stop working, after loading of initrd image boot process stops with
message about:
No filesystem could mount root, tried:
Kernel - panic .... unable to mount rootfs on unknown-block(1,0)
I tried to dissasemble initrd to look at init, but isn't a cpio image ( cpio
-i < ../initrd )
By now, i return tu use last image, have a backup at
/var/lib/tftpboot/udpcast.orig, but i like tu use new version to know if it
corrects some delay with boot on systems with usb keyboards.
ns1:/var/lib/tftpboot# tree -sf
.
├── [ 4096] ./udpcast
│ ├── [ 4415169] ./udpcast/initrd
│ ├── [ 708192] ./udpcast/linux
│ ├── [ 9360] ./udpcast/pxelinux.0
│ └── [ 4096] ./udpcast/pxelinux.cfg
│ └── [ 134] ./udpcast/pxelinux.cfg/default
└── [ 4096] ./udpcast.orig
├── [ 4142599] ./udpcast.orig/initrd
├── [ 619632] ./udpcast.orig/linux
├── [ 9360] ./udpcast.orig/pxelinux.0
└── [ 4096] ./udpcast.orig/pxelinux.cfg
└── [ 784] ./udpcast.orig/pxelinux.cfg/default
ns1:/var/lib/tftpboot# cat udpcast/pxelinux.cfg/default
default linux
label linux
kernel linux
append load_ramdisk=1 initrd=initrd root=01:00 auto=yes lang=US kbdmap=US
ipappend 3
ns1:/var/lib/tftpboot# cat udpcast.orig/pxelinux.cfg/default
default linux
label linux
kernel linux
# append load_ramdisk=1 initrd=initrd root=/dev/ram0 auto=yes lang=US
kbmap=US dhcp=yes port=9000 enableDiskmodule=yes netmodparm= diskmodparm=
udpcparam= disk=/dev/sda compr=lzop
append load_ramdisk=1 initrd=initrd root=/dev/ram0 auto=yes lang=US
kbmap=US dhcp=yes port=9000 enableDiskmodule=yes netmodparm= diskmodparm=
udpcparam= disk=/dev/sda6 compr=lzop
ipappend 1
Thanks for this great tool.
--
... en el país de los ciegos el tuerto es el rey y diciendo esto se arranco
un ojo ...