[RESOLVED]No internet on ubuntu when disable dhcp
-
@Farisse said in No internet on ubuntu when disable dhcp:
@bmeeks
Thank you for your answer
Indeed, i have to use the dns of the school. But what i don't understand is, i don't put anything on my windows machine except the static ip, gateway that's all and it works. But on my ubuntu machine it doesn't work. So i don't understand how it works in pfsense to let my windows machine use the dns i entered in pfsense and not my ubuntu machine. It's not logic for me :/Is your Windows machine a member of an AD domain? If so, the AD domain controller is the DNS server, and it probably forwards to the school's DNS server (or it may actually be the school's DNS server).
-
@bmeeks Nope its not :(
I just tried but my windows machine is not member of AD domain.
here is a little video : https://streamable.com/6mznjo
even with the schools dns it doesn't work anymore. Really strange things are happening here :/ -
@Farisse said in No internet on ubuntu when disable dhcp:
@bmeeks Nope its not :(
I just tried but my windows machine is not member of AD domain.
here is a little video : https://streamable.com/6mznjo
even with the schools dns it doesn't work anymore. Really strange things are happening here :/I am not a user of Hyper-V. I am an ESXi user. One place I would concentrate my research is within the networking configuration of Hyper-V.
Are you running Hyper-V on hardware by itself, or are you running Hyper-V on say a Windows desktop? There will be substantial changes to some of the networking in one installation versus the other.
-
@bmeeks
I don't think the problem should come from the hyper v configuration. I think this because all the other machines are working, and its only ubuntu machines that doesn't work. (Maybe i should go to an ubuntu forum sorry for that). I work on a windows desktop.
So i have a VPN connection to the windows machine where is installed windows server and hyper-v manager.
I think the problem should be something like resolving he dns between the ubuntu machine and pfsense but idk where to search :/ -
After a lot of research i'm asking myself if someone could maybe tell me where i could find any information about the changes that are made when the dhcp server is enabled.
I searched in the pfsense book, but it is not written how it works. If i find what changes are made i would be able to find where the problem is with my server.
Thank you guys !
-
And again - The dhcp server being on or off has ZERO to do with whatever issue your having.
The only changes that happen that you might not see when you enable a dhcp server on a specific interface, is some hidden rules get added to allow for dhcp to reach the server running on pfsense..
-
Okay, going back and reading your original post one more time, this is what I am hearing you say:
When you turn on or enable the DHCP server in pfSense and you enable DHCP in your Ubuntu machine, you have Internet access. But when you turn off the DHCP server in pfSense and try a static IP with no DHCP configured in Ubuntu, you have no Internet access.
If the above is correct, then this is what I think is happening. You are never actually disabling the DHCP client on the Ubuntu machine even though you might think you are. So when you turn off the DHCP server in pfSense, the DHCP client on Ubuntu can't get a proper IP address and thus you have no connectivity. With the DHCP server running on pfSense, the Ubuntu DHCP client can get the info it needs and the Internet works on the Ubuntu machine.
That's what I believe is happening. You think you are turning off DHCP on the Ubuntu machine and switching to a static IP, but I'm thinking perhaps you are not actually doing that. I know that it can be a real pain to re-plumb the network in modern Linux distros with their fancy GUIs. They really, really want to use the DHCP client.
-
@johnpoz You are right, but where could i find these rules ? My firewall rules are empty (or everything is open). There is something i am missing in this configuration. It makes me sick of not understanding why sometimes it works and sometimes not with the same configuration.
@bmeeks i actually don't even know when it's working or not. I had a few minutes ago an internet connection on my machine and, a few minutes later nothing anymore.
How could i get more details about this ? Logs ?
-
@Farisse said in No internet on ubuntu when disable dhcp:
My firewall rules are empty (or everything is open)
If your firewall rules are EMPTY then everything is blocked!
-
@johnpoz No sorry I mean everything is open
-
And clearly you have 13 states currently open using that rule, and have moved 63.18 MB of traffic.
How about some actual info... Lets see you ping the DMZ address from this client.. Lets see you do a dns query to what the dmz address, some other dns server?
Lets see the ifconfig output from this client. When you say it doesn't work, and then when you say it works if you turn on dhcp on pfsense.
-
@johnpoz said in No internet on ubuntu when disable dhcp:
How about some actual info... Lets see you ping the DMZ address from this client.. Lets see you do a dns query to what the dmz address, some other dns server?
Lets see the ifconfig output from this client. When you say it doesn't work, and then when you say it works if you turn on dhcp on pfsense.i am not sure about understanding the questions do you mean that i show the results of the commands you said ?
There are 2 dns servers. One one the schools network and the other in my lan network.
-
Yes lets see the output of the commands.. Not just you saying something doesn't work via what a browser? ping pfsense dmz address, if you can't then your never getting anywhere.. If you can not query dns then your never going to get anywhere via fqdn.
Lets see say a traceroute when it works, and when it doesn't work to both an IP say 8.8.8.8 and then say via a fqdn like www.google.com
Your not doing something like static arps are you in pfsense?
If you setup a static arp say for 1.2.3.4 mac xyz so that what the client gets when dhcp is on, and then you setup IP on the machine to be 1.2.3.5 then no it wouldn't work.
-
@johnpoz
the video is uploading i'll add screenshots in a few minutes
https://streamable.com/j30bzsPing from Windows Hyper-v to DMZ network
Ping from Ubuntu to DNS/DMZ network + ifconfig
Do you need more info ?
-
And that is with dhcp or static? And where is your dns query?
-
This is Static the video is when internet was functional and then after reboot ... nothing anymore
here is the dns query:
-
Well not really possible to use the internet without dns resolution..
What server are you trying to query - can not tell from that command..
Do a dig with with @ipaddress of dns server.
something like dig @192.168.1.1 www.google.com
your command is just going to ask some dns server, which don't know what that is for 192.168.1.1
Is pfsense listening on dmz interface for dns? Are you pointing dns to something else?
how about this output
networkctl status ● State: routable Address: 192.168.2.12 on ens3 fe80::11:32ff:fe22:cc7d on ens3 Gateway: 192.168.2.253 (ADI Engineering, Inc.) on ens3 DNS: 192.168.3.10 Search Domains: local.lan NTP: 192.168.3.32 192.168.2.253
-
@johnpoz Well i didn't change anything and i have an internet connection again.
maybe extra information :
I use an external DNS in pfsense
As from now i have internet this is the requested command :
-
Well from your output of nteworkctl you have NO DNS set..
Unless you setup forwarding on pfsense, those dns servers don't do anything other what pfsense itself would use for dns.
-
The DNS forwarder is indeed enabled in pfsense and dns resolver to. Does it make any change if i configure the dns on a client machine ?
And why do i get internet for a few time then no more internet and after a few time back again without changing nothing ?