Martyn Bright wrote:
> Can anyone suggest how I can arrange to boot a different 
> dongle.bin on each of my 3 x H3 MVP's.  
> The dongle.bin.config is happily retrieved from a seperate folder 
> for each device...

Really? Have you configured your TFTP server to honor paths? In my 
experience, TFTP servers by default will ignore any supplied path. (You 
may see the full path in the logs, but it ignores it.)


> I guess I could bastardise mvprelay to be selective about
> where it looks for the file or to modify the filename on the fly.....

This is what I was going to suggest initially, but I waited to see if 
the other suggestions panned out.

Instead of modifying mvprelay, you may find it easier to alter the Perl 
version of that code, which is a tad more polished:

http://mvpmc.wikispaces.com/perlboot

Here are some sample logs from a boot with mvpboot:

Mar 19 16:17:21 mythtv mvpboot[6242]: got mvpboot request packet from 
192.168.0.242:2048 (seq=1 id1=babe id2=fafe hwaddr=000dfe0c0128 
client_addr=3232235762 client_port=16882 guiserv_addr=0 guiserv_port=0 
conserv_addr=0 conserv_port=0 serv_addr=0 serv_port=0)
Mar 19 16:17:21 mythtv mvpboot[6242]: client hwaddr: 000dfe0c0128 ip: 
192.168.0.242 port: 16882
Mar 19 16:17:21 mythtv mvpboot[6242]: sending mvpboot reply packet to 
192.168.0.242:16882 (seq=1 id1=fafe id2=babe hwaddr=0004614bd133 
client_addr=3232235762 client_port=2048 guiserv_addr=3232235723 
guiserv_port=5906 conserv_addr=3232235723 conserv_port=6337 
serv_addr=3232235723 serv_port=16886)


As you can see, mvpboot has at its disposal the client IP and hardware 
address. Either could be used to map to different parameters in the 
response packet, like a different TFTP server port number ("serv_port"). 
Assuming the H3 honors the port number specified, you should be able to 
run all of the TFTP servers on the same IP address.

You could extend mvpboot with command line options to do the above.


MVallevand wrote:
> You need to run mvprelay on multiple machines (or vm's)...

I'm not sure that'll be necessary. These "boot glue" programs listen for 
broadcast UDP packets, so you might be able to have multiple programs 
bind to the port.

But in any case, it'll be simpler if you do this within one process. If 
you use multiple mvprelay installations, you'll have to modify them all 
- one to respond to the "test" MVP, and all the others so they ignore 
the broadcast packets from that MVP (and vice versa).

Unless...

> ...and then once you select the "Preferrred Server" the IP of
> that server will be in flash. Afterwards as long as mvprelay is 
> running on that IP, and you don't hit OK, after the short delay the
> tftp of of dongle.bin and dongle.bin.config will continue.

...you are selectively activating mvprelay instances, as Martin seems to 
be suggesting, and carefully controlling when your MVPs reboot. But if 
you're going to do that, you could simply manually move files in and out 
of your tftpboot/ directory.

(I was wondering why you actually faced this problem. Why are your MVPs 
getting rebooted at random times? In my experience they stay running for 
months at a time, easily. A little manual intervention shouldn't be too 
inconvenient for the rare reboot.)

Another option to consider is using some TCP wrapper package, assuming 
one of them works with UDP packets as well. You could then wrap the TFTP 
server, and have inbound connections trigger a script that switches a 
/tftboot/ symlink to point to a different directory specific to the 
client. Something wedged between inetd and tftpd might also work.


Martyn Bright wrote:
> I've just rebooted my test MVP, it's booted from dongle.bin...
> Even though the dhcpd.conf file is as follows:-
>         filename "dongle.bin.mvp1";
> 
> But oddly, the /etc/udhcpc.config on mvp1 says this:-
> 
> DONGLE=dongle.bin.mvp1

That's because the firmware in the H3 doesn't make use of "next-server" 
(or more properly known by its RFC name, "siaddr") or filename, but the 
mvpmc code, which I believe generates the /etc/udhcpc.config, does. In 
any case, the mvpmc (post-boot) startup scripts take the DHCP supplied 
file name and use it to derive the name of the config file.


See the thread titled "host used to download the config file" over on 
the dev list and "MVPMC is trying to download the config first from a 
wrong host" on this list for more information on the mvpmc boot process.

  -Tom

-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Mvpmc-users mailing list
Mvpmc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mvpmc-users
mvpmc wiki: http://mvpmc.wikispaces.com/

Reply via email to