Web Proxy Stats not showing PC name

NethServer Version: NethServer release 7.6.1810 (final)
Module: Web Proxy Stats

Hiya,

I am having an issue with PC names showing on the report if NethServer is not the DHCP server or the PC has a static IP address. I have made sure my first DNS is the domain controller and the second 8.8.8.8. But it seems that ip2name help does not pick up the actual PC name.

Anybody got any tips for me?

Thanks
Andrew

You should use the Nethserver DNS only because 8.8.8.8 can’t resolve the internal names.

For static IP clients you may setup a DNS entry to make it resolvable.

What are DNS of NethServer and DNS of your PCs?
Check that NS is configured with DNS of DHCP server.
Why don’t pass DHCP control to NethServer that is also Proxy?

Hi Markuz,

The 8.8.8.8 is for external sites that need to be resolved. If I set the DNS to the Nethservers IP, how will it get the names of the DHCP is handled externally?

Thanks
Andrew

Hi Federico, The issue with NethServer as the DHCP server is that it does not give enough control of controlling Ip addresses. The current DHCP has a subnet of 255.255.254.0 and is handling router and gateway info etc.

NethServer DHCP just does not give that sort of control.

Thanks for your time.
Andrew

This is a server with a 255.255.254.0 as subnet

All these settings are not enough?

You can set subnet mask to green interface (and not here) from Network page

Yes, I understand what you mean, and I have these settings in the current DHCP server. Unfortunately, the DHCP is not negotiable. I should have said that up front. The sites DHCP has to be on another server.

What I need is for the ip2name to be able to translate the Ip to a PC name on the Stats report.

Are you able to guide me on that?

Thanks
Andrew

First of all, check this.

It has to be set at your Nethserver, go to network and there to DNS Server at your server gui and set your external DNS.

Hi Michael,

The DNS is set to look at the DHCP server for first DNS and then 8.8.8.8 for second DNS server, as per the image below:

HER01%20NethServer%20DNS

You will see the proxy IP is 192.168.0.100, the DHCP server is 192.168.0.3.

For whatever reason, the DNS is not pull through the Name of the PC’s from the DHCP/DNS server.

Thanks
Andrew

Could you post a complete output of this command?

nslookup 192.168.0.xxx

Change ‘xxx’ to compose an IP of one of your PCs. Execute this from CLI of NS.

Ahh, I think you are on to something. Herewith a lookup of the DNS/DHCP server and a random user on the network:
HER01%20NethServer%20NSLOOKUP

So, where do I change the settings to get the server to look at the correct DNS server. My networks file looks like this:

HER01%20NethServer%20NETWORKS

I am not hugely familiar with CENTOS so I am not sure if I am looking in the right place.

Thanks
Andrew

Try to remove 8.8.8.8 as secondary DNS. Then launch command ifconfig /flushdns and then retry with nslookup command.

Could you also check that DC accept connection on port 53 TCP and UDP?

1 Like

ifconfig /flush gives me a: “/flush: error fetching interface information: Device not found” error.

Yes the server is accepting 53 on UDP and TCP.

I have removed 8.8.8.8 and am re-running lightparser.pl to see if that makes a difference.

Will keep you posted.

Sorry. Was a command for windows :sweat_smile:
Probably restarting dnsmasq service clear cache of DNS.

Wait for your feedback.

Please have a look at the following link:

https://www.cyberciti.biz/faq/rhel-debian-ubuntu-flush-clear-dns-cache/

1 Like

Hi Michael,

thanks for all your suggestions so far. I have already restarted the dnsmasq service after the dns change. I am just waiting for the lightparser.pl to finish and will check from there.

I am concerned that the nslookup resolves to 127.0.0.1 as a default. Is it possible I have got the network configured incorrectly? Internet is working fine but maybe the machine needs a tweek.
Let me know

Cheers
Andrew

It’s correct that nslookup shows 127.0.0.1 because dns service is execute directly on NethServer. You have to check if it solve local names through nslookup command.

1 Like

What is your configuration? I think the right one should be

  • Clients have Proxy as DNS
  • Proxy has DC as DNS
  • DC has Router or an external as DNS

No, it does not seem to resolve local IP address to names. So if I do nslookup 192.168.0.3 (which is the server dns and dhcp server) it does not resolve to a name.

Thanks

Andrew