• DHCP, name resolution

    From askfor@21:1/5 to askfor on Thu Oct 29 12:14:37 2015
    askfor wrote:
    My problem is not unique, but I still don't have a solution. My home computers obtain IP addresses from DHCP server on my home router. The addresses change.

    I could force fixed addresses, but I wonder if there is a more elegant solution. I could create dummy network devices with fixed addresses, but
    that is more or less the same, but more complicated.

    There is a daemon named NMBD which comes with Samba. It does the right
    thing, only for NetBIOS protocol. Clients register with it when they
    'come alive'. My guess is that NMBD requires fixed IP address, too ?

    Is there any way I could put NMBD in the good use ?

    I suppose DNSmasq could not be configured to use external DHCP server ?

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Java Jive@21:1/5 to All on Thu Oct 29 13:01:34 2015
    Couple of minor corrections ...

    On Thu, 29 Oct 2015 12:30:36 +0000, Java Jive <java@evij.com.invalid>
    wrote:
    Therefore, if you want to mix Linux and Windows on the same network,

    ... and not use fixed IPs ...

    you either have to use Samba on the Linux machines - which means the daemons to offer shares, and the client to connect to shares offered
    by others -

    ... and/or ...

    do something about the router - which means either
    replacing it (but how do you know in advance that the replacement will
    be any better), or reflashing it with open source firmware, such as
    OpenWRT, the DNS of which can be configured to work properly.
    --
    ========================================================
    Please always reply to ng as the email in this post's
    header does not exist. Or use a contact address at:
    http://www.macfh.co.uk/JavaJive/JavaJive.html
    http://www.macfh.co.uk/Macfarlane/Macfarlane.html

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Java Jive@21:1/5 to askfor on Thu Oct 29 12:30:36 2015
    You haven't stated clearly what your problem really is, but ...

    On Thu, 29 Oct 2015 12:08:46 +0100, askfor <askfor@nowhere.net> wrote:

    My problem is not unique, but I still don't have a solution. My home computers obtain IP addresses from DHCP server on my home router. The addresses change.

    So far, so normal.

    I could force fixed addresses, but I wonder if there is a more elegant solution. I could create dummy network devices with fixed addresses, but
    that is more or less the same, but more complicated.

    Why do you want to do this? I think I can guess as below, but you
    haven't actually said what is the original problem that fixed IP
    addresses would, erm, 'address'?!

    There is a daemon named NMBD which comes with Samba. It does the right
    thing, only for NetBIOS protocol. Clients register with it when they
    'come alive'. My guess is that NMBD requires fixed IP address, too ?

    Is there any way I could put NMBD in the good use ?

    smbd and nmbd are the server daemons to run samba/cifs which is
    Windows-style file sharing for Linux PCs, and both daemons are
    required for a Linux PC to offer shares to Windows PCs.

    Your mentioning of NETBIOS gives me some clue as to what is the real
    problem that you haven't actually stated ...

    Yer average common-or-garden router has two modes of running DHCP, as
    a server, and as a relay. As a server, it dishes out IPs to your
    local subnet, as a relay, it obtains them from an authority higher up,
    usually your ISP. The server arrangement is by far the most commonly
    used. In principle, DHCP is primarily designed to dish out IP
    addresses, but in practice usually doles out other network-related configuration data as well, most importantly, DNS settings.

    DNS is what dynamically associates a name with an IP address, so that
    in a Windows machine you can type into Explorer \\Server\Share rather
    than \\IPAddress\Share, and on a Linux machine you can connect via nfs
    to Sever:Path rather than IPAdress:Path. However, a lot of
    programmers of router software do not realise that the above model of
    either being a server or a relay is inadequate for DNS. A local DNS
    server still needs to relay upstream those DNS requests it cannot meet
    locally, but many common-or-garden routers cannot do this - if
    configured as a server, they think the entire world is encapsulated in
    the LAN, so you can ping by name any local machine, but a ping fails
    for a device on the internet, or they relay everthing upstream, so you
    can ping by name anything on the internet, but not anything local, or
    perhaps you can, but only at the cost of your ISP knowing the details
    of all the machines on your LAN, which certainly shouldn't be
    necessary, and some may think an undesirable lapse of security.

    With such a router, the above is the basic situation wrt to Linux
    devices on the LAN, but Windows devices are more fortunate, in that
    NETBIOS over TCP/IP can at least cover for the lack of proper router
    DNS functionality by the Browser Master, on a SOHo LAN usually the
    first PC to power up, dispensing NETBIOS names. As Windows is by far
    the most common OS, and many SOHo networks consist only of Windows
    machines, many routers appear only to be tested on such LANs, so the
    lack of proper DNS functionality is never found, and never corrected.

    Therefore, if you want to mix Linux and Windows on the same network,
    you either have to use Samba on the Linux machines - which means the
    daemons to offer shares, and the client to connect to shares offered
    by others - or do something about the router - which means either
    replacing it (but how do you know in advance that the replacement will
    be any better), or reflashing it with open source firmware, such as
    OpenWRT, the DNS of which can be configured to work properly.

    Does that answer your unstated question?
    --
    ========================================================
    Please always reply to ng as the email in this post's
    header does not exist. Or use a contact address at:
    http://www.macfh.co.uk/JavaJive/JavaJive.html
    http://www.macfh.co.uk/Macfarlane/Macfarlane.html

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From J.O. Aho@21:1/5 to askfor on Thu Oct 29 18:28:00 2015
    On 10/29/2015 12:08 PM, askfor wrote:
    My problem is not unique, but I still don't have a solution. My home computers obtain IP addresses from DHCP server on my home router. The addresses change.

    I could force fixed addresses, but I wonder if there is a more elegant solution. I could create dummy network devices with fixed addresses, but
    that is more or less the same, but more complicated.

    You can let the dhcp server update the nameserver with help of the ddns-update-style see this Ubuntu documentation for how to do it:

    http://askubuntu.com/questions/162265/how-to-setup-dhcp-server-and-dynamic-dns-with-bind

    Don't forget to provide which nameserver the dhcp clients should use, if
    they use another nameserver than the one working for your dhcp server,
    it will not work.


    --

    //Aho

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From J.O. Aho@21:1/5 to All on Thu Oct 29 18:31:52 2015
    XPost: alt.os.linux

    On 10/29/2015 12:08 PM, askfor wrote:

    Removed the stupid follow up, as it destroys the thread for everyone
    else who don't subscribe c.u.a


    My problem is not unique, but I still don't have a solution. My home computers obtain IP addresses from DHCP server on my home router. The addresses change.

    I could force fixed addresses, but I wonder if there is a more elegant solution. I could create dummy network devices with fixed addresses, but
    that is more or less the same, but more complicated.


    You can let the dhcp server update the nameserver with help of the ddns-update-style see this Ubuntu documentation for how to do it:

    http://askubuntu.com/questions/162265/how-to-setup-dhcp-server-and-dynamic-dns-with-bind

    Don't forget to provide which nameserver the dhcp clients should use, if
    they use another nameserver than the one working for your dhcp server,
    it will not work.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From J.O. Aho@21:1/5 to askfor on Fri Oct 30 10:01:15 2015
    XPost: alt.os.linux

    On 10/30/2015 02:59 AM, askfor wrote:
    J.O. Aho wrote:
    On 10/29/2015 12:08 PM, askfor wrote:

    My problem is not unique, but I still don't have a solution. My home
    computers obtain IP addresses from DHCP server on my home router. The
    addresses change.

    I could force fixed addresses, but I wonder if there is a more elegant
    solution. I could create dummy network devices with fixed addresses, but >>> that is more or less the same, but more complicated.


    You can let the dhcp server update the nameserver with help of the
    ddns-update-style see this Ubuntu documentation for how to do it:

    http://askubuntu.com/questions/162265/how-to-setup-dhcp-server-and-dynamic-dns-with-bind


    Don't forget to provide which nameserver the dhcp clients should use, if
    they use another nameserver than the one working for your dhcp server,
    it will not work.


    You are not THAT Aho, are you :)

    No, I'm not Alfred, but I do use awk.


    I forgot to mention that none of my machines is up 24/7, so there is no
    point of installing any servers.

    I would suggest you spend a few bucks on a better router, which
    nameserver you can update. Solves a lot of issues for you.


    However there is something else I could do. I can run a program which broadcasts its own name over UDP and collects name address pairs from
    other machines which do the same. Collected addresses might be
    appended to existing /etc/hosts with header and footer like:

    feels like a bit overhead, shouldn't all new machines broadcast I'm new
    here, my name is and my ip is (ipv4/ipv6) and then all the others just
    answer I'm and my ip is (ipv4/ipv6).

    I personally don't like to have any temporary lines in my hosts file,
    IMHO it should be as clean as possible.


    --

    //Aho

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From askfor@21:1/5 to J.O. Aho on Fri Oct 30 12:53:35 2015
    XPost: alt.os.linux

    J.O. Aho wrote:
    On 10/30/2015 02:59 AM, askfor wrote:
    J.O. Aho wrote:
    On 10/29/2015 12:08 PM, askfor wrote:

    My problem is not unique, but I still don't have a solution. My home
    computers obtain IP addresses from DHCP server on my home router. The
    addresses change.

    I could force fixed addresses, but I wonder if there is a more elegant >>>> solution. I could create dummy network devices with fixed addresses,
    but
    that is more or less the same, but more complicated.


    You can let the dhcp server update the nameserver with help of the
    ddns-update-style see this Ubuntu documentation for how to do it:

    http://askubuntu.com/questions/162265/how-to-setup-dhcp-server-and-dynamic-dns-with-bind



    Don't forget to provide which nameserver the dhcp clients should use, if >>> they use another nameserver than the one working for your dhcp server,
    it will not work.


    You are not THAT Aho, are you :)

    No, I'm not Alfred, but I do use awk.


    I forgot to mention that none of my machines is up 24/7, so there is no
    point of installing any servers.

    I would suggest you spend a few bucks on a better router, which
    nameserver you can update. Solves a lot of issues for you.


    However there is something else I could do. I can run a program which
    broadcasts its own name over UDP and collects name address pairs from
    other machines which do the same. Collected addresses might be
    appended to existing /etc/hosts with header and footer like:

    feels like a bit overhead, shouldn't all new machines broadcast I'm new
    here, my name is and my ip is (ipv4/ipv6) and then all the others just answer I'm and my ip is (ipv4/ipv6).

    I personally don't like to have any temporary lines in my hosts file,
    IMHO it should be as clean as possible.



    At the moment, host files on my machines serve no purpose, except to
    hold machines own name.

    I've learned about thing called Avahi,but it simply doesn't work for me.
    It is supposed to incorporate a minimum DNS server on each machine,
    which collects other addresses via multicast. Also, it uses
    nsswitch.conf to redirect name resolution queries to itself.
    Unfortunately neither machine is able to ping anything based on the
    name. I can ping any address, I can ping localhost and I can ping using
    name in hosts file. However, Avahi is supposed to assign 'fqdn' in form
    of <machinename>.local to each machine, but I can't ping that.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Marek Novotny@21:1/5 to askfor on Sat Oct 31 12:37:05 2015
    On 2015-10-29, askfor <askfor@nowhere.net> wrote:
    My problem is not unique, but I still don't have a solution. My home computers obtain IP addresses from DHCP server on my home router. The addresses change.

    I could force fixed addresses, but I wonder if there is a more elegant solution. I could create dummy network devices with fixed addresses, but
    that is more or less the same, but more complicated.

    There is a daemon named NMBD which comes with Samba. It does the right
    thing, only for NetBIOS protocol. Clients register with it when they
    'come alive'. My guess is that NMBD requires fixed IP address, too ?

    Is there any way I could put NMBD in the good use ?

    What about increasing the lease period?

    --
    Marek Novotny
    https://github.com/marek-novotny

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From wimpunk@21:1/5 to askfor on Fri Dec 4 12:16:56 2015
    XPost: alt.os.linux

    On 10/30/15 12:53, askfor wrote:
    J.O. Aho wrote:

    At the moment, host files on my machines serve no purpose, except to
    hold machines own name.

    I've learned about thing called Avahi,but it simply doesn't work for me.
    It is supposed to incorporate a minimum DNS server on each machine,
    which collects other addresses via multicast. Also, it uses
    nsswitch.conf to redirect name resolution queries to itself.
    Unfortunately neither machine is able to ping anything based on the
    name. I can ping any address, I can ping localhost and I can ping using
    name in hosts file. However, Avahi is supposed to assign 'fqdn' in form
    of <machinename>.local to each machine, but I can't ping that.


    It works out of the box in most cases. I have avahi running and even my
    android devices find every host if I use .local as domain name.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)