[mythtv-users] HDHomeRun, 2nd NIC and dhcpd bootup issue

scram69 scram69 at gmail.com
Wed Aug 13 05:19:15 UTC 2008


On Tue, Feb 12, 2008 at 6:09 PM, Michael Rice <mikerice1969 at gmail.com> wrote:
> On 11/5/07, Michael Rice <mikerice1969 at gmail.com> wrote:
>> On 11/5/07, Harley Peters <harley at thepetersclan.net> wrote:
>> > Well i gave it a try but i have to set it to 200+ to get it to work.
>> > So i just installed a second switch instead.
>> > The real problem is when you reboot the backend the network interface on
>> > the Hdhomerun goes down. And when it comes back up it tries to get an ip
>> > address from the dhcp server right away and the server hasn't booted up
>> > yet so the dhcp server isn't yet available.
>>
>> Makes sense and all but after installing the HDHR on the separate NIC
>> I rebooted several times and haven't seen the problem.  Does this
>> happen everytime or does it find the HDHR on some reboots?  I'd like
>> to know if I am "safe" or if I will have this happen down the road.
>> My backend is on FC6 now... what distro are you using?  I wonder if
>> the timing issues are distro specific or something else.
>>
>
> I installed a different NIC in my backend and started getting the
> "HDHR doesn't get an IP address fast enough" problem.  In case anyone
> is still having a problem with this I solved it by adding a few lines
> to my mythbackend startup scipt.  It just pings the HDHR's IP address
> until successful before starting the backend.  I haven't used it a
> long time yet but it seems better than editing the mythtv source:
>
>  # Wait for HDHR to come up
>  RESULT=1
>  CNT=0
>  while [ "$RESULT" != "0" ];
>  do
>    /bin/ping -c 1 192.168.2.30
>    RESULT="$?"
>    CNT="`expr $CNT + 1`"
>    if [ "$CNT" = "30" ]; then
>      RESULT=0
>    fi
>  done
>
> Any better ideas?
> _______________________________________________
> mythtv-users mailing list
> mythtv-users at mythtv.org
> http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-users
>
I'm also having this problem, and would rather not edit the source
(mostly because I've never been able to successfully compile myth from
anything).  But the HDHR seems to take an inordinate amount of time to
get an address from my 2nd NIC (eth1).  Here are the relevent lines
from /var/log/messages:

Aug 12 18:07:34 mediaserver kernel: [   53.246499] eth1: link up,
100Mbps, full-duplex, lpa 0x41E1
Aug 12 18:07:54 mediaserver dhcpd: Internet Systems Consortium DHCP
Server V3.0.6
Aug 12 18:07:54 mediaserver dhcpd: Copyright 2004-2007 Internet
Systems Consortium.
Aug 12 18:07:54 mediaserver dhcpd: All rights reserved.
Aug 12 18:07:54 mediaserver dhcpd: For info, please visit
http://www.isc.org/sw/dhcp/
Aug 12 18:07:54 mediaserver dhcpd: Internet Systems Consortium DHCP
Server V3.0.6
Aug 12 18:07:54 mediaserver dhcpd: Copyright 2004-2007 Internet
Systems Consortium.
Aug 12 18:07:54 mediaserver dhcpd: All rights reserved.
Aug 12 18:07:54 mediaserver dhcpd: For info, please visit
http://www.isc.org/sw/dhcp/
Aug 12 18:07:54 mediaserver dhcpd: Wrote 0 deleted host decls to leases file.
Aug 12 18:07:54 mediaserver dhcpd: Wrote 0 new dynamic host decls to
leases file.
Aug 12 18:07:54 mediaserver dhcpd: Wrote 2 leases to leases file.
Aug 12 18:07:54 mediaserver kernel: [   78.868019] NET: Registered
protocol family 17
Aug 12 18:08:38 mediaserver dhcpd: DHCPDISCOVER from 00:18:dd:01:19:75 via eth1
Aug 12 18:08:38 mediaserver dhcpd: DHCPOFFER on 192.168.0.198 to
00:18:dd:01:19:75 via eth1
Aug 12 18:08:39 mediaserver dhcpd: DHCPREQUEST for 192.168.0.198
(192.168.0.1) from 00:18:dd:01:19:75 via eth1
Aug 12 18:08:39 mediaserver dhcpd: DHCPACK on 192.168.0.198 to
00:18:dd:01:19:75 via eth1

and, inevitably, in /var/log/mythbackend.log:

2008-08-12 18:07:51.322 Current Schema Version: 1214
Starting up as the master server.
2008-08-12 18:07:51.408 mythbackend: MythBackend started as master server
2008-08-12 18:07:52.529 HDHRChan(ffffffff/0), Error: device not found
2008-08-12 18:07:52.537 New DB connection, total: 3
2008-08-12 18:07:52.586 Connected to database 'mythconverg' at host: localhost
2008-08-12 18:07:52.589 mythbackend: Problem with capture cards: Card
1failed init
2008-08-12 18:07:53.792 HDHRChan(ffffffff/1), Error: device not found
2008-08-12 18:07:53.802 mythbackend: Problem with capture cards: Card
2failed init

Here is what is in my dhcpd.conf, where I try to give the hdhr a
"fixed" address based on it's MAC:

# A slightly different configuration for an internal subnet.
subnet 192.168.0.0 netmask 255.255.255.0 {
  range 192.168.0.100 192.168.0.199;
  #option domain-name-servers ns1.internal.example.org;
  #option domain-name "internal.example.org";
  #option routers 192.168.0.1;
  option broadcast-address 192.168.0.255;
  default-lease-time 1209600;
  max-lease-time 1209600;
}

host hdhomerun {
  hardware ethernet 00:18:dd:01:19:75;
  fixed-address 192.168.0.198;
}

So it takes over a minute to give the hdhr it's address.  I've tried
the script above, and all it does is delay the address assignment that
much longer.  Any ideas as to why dhcpd takes over 60 seconds to do
anything?


More information about the mythtv-users mailing list