Kali Dns Problems
Clash Royale CLAN TAG#URR8PPP
up vote
1
down vote
favorite
I have a problem. So, when I connect to any wi-fi station I can't use google or yandex. I solved that. The thing was in dns. I added google dns servers to 'resolv.conf' and it worked fine. However, after reconnection it does the same thing and I have to write manually or with script to set dns.
Is there any way to make this process automatically when the computer connects to the network? I tried to do it through the network/interfaces post-up and if-up.d . But it didn't help. The code is like that.
interfaces:
auto wlan0
iface wlan0 inet dhcp
post-up /etc/network/ssh_and_dns_start
ssh_and_dns_start:
#!/bin/sh
add_dns()
echo "nameserver 8.8.8.8
nameserver 8.8.4.4" >> /etc/resolv.conf
add_dns
exit 0
networking dns kali-linux
add a comment |Â
up vote
1
down vote
favorite
I have a problem. So, when I connect to any wi-fi station I can't use google or yandex. I solved that. The thing was in dns. I added google dns servers to 'resolv.conf' and it worked fine. However, after reconnection it does the same thing and I have to write manually or with script to set dns.
Is there any way to make this process automatically when the computer connects to the network? I tried to do it through the network/interfaces post-up and if-up.d . But it didn't help. The code is like that.
interfaces:
auto wlan0
iface wlan0 inet dhcp
post-up /etc/network/ssh_and_dns_start
ssh_and_dns_start:
#!/bin/sh
add_dns()
echo "nameserver 8.8.8.8
nameserver 8.8.4.4" >> /etc/resolv.conf
add_dns
exit 0
networking dns kali-linux
1
See askubuntu.com/questions/2321/â¦
â Panther
Dec 26 '15 at 14:08
@bodhi.zazen Thank you very much! But is there any chance to set default dns settings? Or should I add these dns to every network manually?
â ÃÂøüð ÃÂþûóþÿþûþò
Dec 26 '15 at 16:00
What are you trying to do exactly ? In the link there are several options to set your dns server. And what do you mean by "dns to every network manually"?
â Panther
Dec 26 '15 at 18:33
@bodhi.zazen there is a method for setting dns for one network through Network Settings. But I want these setting for every network that I will connect in the future. Kinda default settings. That is my question.
â ÃÂøüð ÃÂþûóþÿþûþò
Dec 27 '15 at 14:44
Those settings should work on all networks you connect to.
â Panther
Dec 28 '15 at 16:42
add a comment |Â
up vote
1
down vote
favorite
up vote
1
down vote
favorite
I have a problem. So, when I connect to any wi-fi station I can't use google or yandex. I solved that. The thing was in dns. I added google dns servers to 'resolv.conf' and it worked fine. However, after reconnection it does the same thing and I have to write manually or with script to set dns.
Is there any way to make this process automatically when the computer connects to the network? I tried to do it through the network/interfaces post-up and if-up.d . But it didn't help. The code is like that.
interfaces:
auto wlan0
iface wlan0 inet dhcp
post-up /etc/network/ssh_and_dns_start
ssh_and_dns_start:
#!/bin/sh
add_dns()
echo "nameserver 8.8.8.8
nameserver 8.8.4.4" >> /etc/resolv.conf
add_dns
exit 0
networking dns kali-linux
I have a problem. So, when I connect to any wi-fi station I can't use google or yandex. I solved that. The thing was in dns. I added google dns servers to 'resolv.conf' and it worked fine. However, after reconnection it does the same thing and I have to write manually or with script to set dns.
Is there any way to make this process automatically when the computer connects to the network? I tried to do it through the network/interfaces post-up and if-up.d . But it didn't help. The code is like that.
interfaces:
auto wlan0
iface wlan0 inet dhcp
post-up /etc/network/ssh_and_dns_start
ssh_and_dns_start:
#!/bin/sh
add_dns()
echo "nameserver 8.8.8.8
nameserver 8.8.4.4" >> /etc/resolv.conf
add_dns
exit 0
networking dns kali-linux
networking dns kali-linux
asked Dec 26 '15 at 12:03
ÃÂøüð ÃÂþûóþÿþûþò
5917
5917
1
See askubuntu.com/questions/2321/â¦
â Panther
Dec 26 '15 at 14:08
@bodhi.zazen Thank you very much! But is there any chance to set default dns settings? Or should I add these dns to every network manually?
â ÃÂøüð ÃÂþûóþÿþûþò
Dec 26 '15 at 16:00
What are you trying to do exactly ? In the link there are several options to set your dns server. And what do you mean by "dns to every network manually"?
â Panther
Dec 26 '15 at 18:33
@bodhi.zazen there is a method for setting dns for one network through Network Settings. But I want these setting for every network that I will connect in the future. Kinda default settings. That is my question.
â ÃÂøüð ÃÂþûóþÿþûþò
Dec 27 '15 at 14:44
Those settings should work on all networks you connect to.
â Panther
Dec 28 '15 at 16:42
add a comment |Â
1
See askubuntu.com/questions/2321/â¦
â Panther
Dec 26 '15 at 14:08
@bodhi.zazen Thank you very much! But is there any chance to set default dns settings? Or should I add these dns to every network manually?
â ÃÂøüð ÃÂþûóþÿþûþò
Dec 26 '15 at 16:00
What are you trying to do exactly ? In the link there are several options to set your dns server. And what do you mean by "dns to every network manually"?
â Panther
Dec 26 '15 at 18:33
@bodhi.zazen there is a method for setting dns for one network through Network Settings. But I want these setting for every network that I will connect in the future. Kinda default settings. That is my question.
â ÃÂøüð ÃÂþûóþÿþûþò
Dec 27 '15 at 14:44
Those settings should work on all networks you connect to.
â Panther
Dec 28 '15 at 16:42
1
1
See askubuntu.com/questions/2321/â¦
â Panther
Dec 26 '15 at 14:08
See askubuntu.com/questions/2321/â¦
â Panther
Dec 26 '15 at 14:08
@bodhi.zazen Thank you very much! But is there any chance to set default dns settings? Or should I add these dns to every network manually?
â ÃÂøüð ÃÂþûóþÿþûþò
Dec 26 '15 at 16:00
@bodhi.zazen Thank you very much! But is there any chance to set default dns settings? Or should I add these dns to every network manually?
â ÃÂøüð ÃÂþûóþÿþûþò
Dec 26 '15 at 16:00
What are you trying to do exactly ? In the link there are several options to set your dns server. And what do you mean by "dns to every network manually"?
â Panther
Dec 26 '15 at 18:33
What are you trying to do exactly ? In the link there are several options to set your dns server. And what do you mean by "dns to every network manually"?
â Panther
Dec 26 '15 at 18:33
@bodhi.zazen there is a method for setting dns for one network through Network Settings. But I want these setting for every network that I will connect in the future. Kinda default settings. That is my question.
â ÃÂøüð ÃÂþûóþÿþûþò
Dec 27 '15 at 14:44
@bodhi.zazen there is a method for setting dns for one network through Network Settings. But I want these setting for every network that I will connect in the future. Kinda default settings. That is my question.
â ÃÂøüð ÃÂþûóþÿþûþò
Dec 27 '15 at 14:44
Those settings should work on all networks you connect to.
â Panther
Dec 28 '15 at 16:42
Those settings should work on all networks you connect to.
â Panther
Dec 28 '15 at 16:42
add a comment |Â
2 Answers
2
active
oldest
votes
up vote
1
down vote
Try adding this to /etc/dhcp/dhclient.conf
interface "wlan0"
supersede domain-name-servers 8.8.8.8, 8.8.4.4;
add a comment |Â
up vote
0
down vote
The way I did it was hackish and probably not the way you would want to do it, but if you just need the bleeping thing working...
So I had set up Kali connected to ethernet and when I went to add a wifi connection, no DNS. /etc/resolv.conf pointed to something like /run/resolvconf/... which pointed to yet another thing.
There's not the option to sudo
yourself and vim /etc/resolv.conf
- for a few reasons. So logout, login as root, delete the symlink /etc/resolvconf/... points to, then vim /etc/resolv.conf
and add the nameservers you want, e.g.
nameserver your.gateway.ip
or
nameserver 8.8.8.8
nameserver 8.8.4.4
Before this, you can try
root@kali# dhclient wlan0
to get some information. I didn't find it very helpful. Editing the wireless connection settings with the GUI didn't work for me, even though it picked up on the nameservers. I just went ahead and deleted the symlink for /etc/resolv.conf and created /etc/resolv.conf, and all was fine.
add a comment |Â
2 Answers
2
active
oldest
votes
2 Answers
2
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
1
down vote
Try adding this to /etc/dhcp/dhclient.conf
interface "wlan0"
supersede domain-name-servers 8.8.8.8, 8.8.4.4;
add a comment |Â
up vote
1
down vote
Try adding this to /etc/dhcp/dhclient.conf
interface "wlan0"
supersede domain-name-servers 8.8.8.8, 8.8.4.4;
add a comment |Â
up vote
1
down vote
up vote
1
down vote
Try adding this to /etc/dhcp/dhclient.conf
interface "wlan0"
supersede domain-name-servers 8.8.8.8, 8.8.4.4;
Try adding this to /etc/dhcp/dhclient.conf
interface "wlan0"
supersede domain-name-servers 8.8.8.8, 8.8.4.4;
answered Feb 13 '16 at 19:04
ncomputers
8481418
8481418
add a comment |Â
add a comment |Â
up vote
0
down vote
The way I did it was hackish and probably not the way you would want to do it, but if you just need the bleeping thing working...
So I had set up Kali connected to ethernet and when I went to add a wifi connection, no DNS. /etc/resolv.conf pointed to something like /run/resolvconf/... which pointed to yet another thing.
There's not the option to sudo
yourself and vim /etc/resolv.conf
- for a few reasons. So logout, login as root, delete the symlink /etc/resolvconf/... points to, then vim /etc/resolv.conf
and add the nameservers you want, e.g.
nameserver your.gateway.ip
or
nameserver 8.8.8.8
nameserver 8.8.4.4
Before this, you can try
root@kali# dhclient wlan0
to get some information. I didn't find it very helpful. Editing the wireless connection settings with the GUI didn't work for me, even though it picked up on the nameservers. I just went ahead and deleted the symlink for /etc/resolv.conf and created /etc/resolv.conf, and all was fine.
add a comment |Â
up vote
0
down vote
The way I did it was hackish and probably not the way you would want to do it, but if you just need the bleeping thing working...
So I had set up Kali connected to ethernet and when I went to add a wifi connection, no DNS. /etc/resolv.conf pointed to something like /run/resolvconf/... which pointed to yet another thing.
There's not the option to sudo
yourself and vim /etc/resolv.conf
- for a few reasons. So logout, login as root, delete the symlink /etc/resolvconf/... points to, then vim /etc/resolv.conf
and add the nameservers you want, e.g.
nameserver your.gateway.ip
or
nameserver 8.8.8.8
nameserver 8.8.4.4
Before this, you can try
root@kali# dhclient wlan0
to get some information. I didn't find it very helpful. Editing the wireless connection settings with the GUI didn't work for me, even though it picked up on the nameservers. I just went ahead and deleted the symlink for /etc/resolv.conf and created /etc/resolv.conf, and all was fine.
add a comment |Â
up vote
0
down vote
up vote
0
down vote
The way I did it was hackish and probably not the way you would want to do it, but if you just need the bleeping thing working...
So I had set up Kali connected to ethernet and when I went to add a wifi connection, no DNS. /etc/resolv.conf pointed to something like /run/resolvconf/... which pointed to yet another thing.
There's not the option to sudo
yourself and vim /etc/resolv.conf
- for a few reasons. So logout, login as root, delete the symlink /etc/resolvconf/... points to, then vim /etc/resolv.conf
and add the nameservers you want, e.g.
nameserver your.gateway.ip
or
nameserver 8.8.8.8
nameserver 8.8.4.4
Before this, you can try
root@kali# dhclient wlan0
to get some information. I didn't find it very helpful. Editing the wireless connection settings with the GUI didn't work for me, even though it picked up on the nameservers. I just went ahead and deleted the symlink for /etc/resolv.conf and created /etc/resolv.conf, and all was fine.
The way I did it was hackish and probably not the way you would want to do it, but if you just need the bleeping thing working...
So I had set up Kali connected to ethernet and when I went to add a wifi connection, no DNS. /etc/resolv.conf pointed to something like /run/resolvconf/... which pointed to yet another thing.
There's not the option to sudo
yourself and vim /etc/resolv.conf
- for a few reasons. So logout, login as root, delete the symlink /etc/resolvconf/... points to, then vim /etc/resolv.conf
and add the nameservers you want, e.g.
nameserver your.gateway.ip
or
nameserver 8.8.8.8
nameserver 8.8.4.4
Before this, you can try
root@kali# dhclient wlan0
to get some information. I didn't find it very helpful. Editing the wireless connection settings with the GUI didn't work for me, even though it picked up on the nameservers. I just went ahead and deleted the symlink for /etc/resolv.conf and created /etc/resolv.conf, and all was fine.
edited Mar 10 '17 at 10:42
Thomas
3,63141124
3,63141124
answered Mar 10 '17 at 10:22
James Young
1
1
add a comment |Â
add a comment |Â
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f251620%2fkali-dns-problems%23new-answer', 'question_page');
);
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
1
See askubuntu.com/questions/2321/â¦
â Panther
Dec 26 '15 at 14:08
@bodhi.zazen Thank you very much! But is there any chance to set default dns settings? Or should I add these dns to every network manually?
â ÃÂøüð ÃÂþûóþÿþûþò
Dec 26 '15 at 16:00
What are you trying to do exactly ? In the link there are several options to set your dns server. And what do you mean by "dns to every network manually"?
â Panther
Dec 26 '15 at 18:33
@bodhi.zazen there is a method for setting dns for one network through Network Settings. But I want these setting for every network that I will connect in the future. Kinda default settings. That is my question.
â ÃÂøüð ÃÂþûóþÿþûþò
Dec 27 '15 at 14:44
Those settings should work on all networks you connect to.
â Panther
Dec 28 '15 at 16:42