For the past day, I have been trying unsuccessfully to let my Ubuntu VM be able to resolve NetBIOS names on the local network, to find some non-computer devices (Printers, special barcode machines, etc..) that don't have a fixed IP.
At first, I assumed I am failing to configure the usage of winbind/wins for resolving, even though I had read every webpage that ever mentioned nsswitch.conf, and I was sure my configuration should be correct.
nmblookup printername returns a successful result that looks like:
And this was my first clue, the <00> service type. I fired up wireshark, and tried to
ping printername, and I saw a NetBIOS broadcast asking for
printername<20>, to which no one replied.
I stopped the winbindd service, and run it manually in foreground using:
sudo winbindd -F -S -d 10
then tried the same ping, and I saw winbindd attempting the same erroneous query with <20> instead of <00>.
Why is this happening? Where can this be configured?
EDIT: Closing this question as this is hardcoded in the source. Digging through the code, I found the function in winbindd_wins_byname.c, harcoded as such:
subreq = resolve_wins_send(state, ev, state->request->data.winsreq,