im wondering which tool is meant to assign and configure the DNS server address for the Galileo1.
Im using the Intel IoT Devkit Linux galileo 3.8.7-yocto-standard # 1 Tue Jun 9 22:07:14 GMT 2015 i586 GNU/Linux.
Everytime I reboot the Galileo i have to set the address manually again.
I tried to add the line to /etc/resolv.conf or with the /usr/lib/connman/test/set-nameservers command.
Both changes are working but are not persistent. Someone has an idea?
The same holds for other commands as well. For example the content and modifications done to /proc/sys/net/ipv4/ip_forward are always resetted if I restart the board.
I have workarounds with a startscript. But I cant imagine that there is no way of keeping these settings permanent.
Thanks in Advice
I found a solution to this problem via Hipstercircuits... (you'd have to search for the link yourself)
connmanctl services # figure out your ethernet device eg. mine was: ethernet_984fee05a892_cable
connmanctl config ethernet_984fee05a892_cable --nameservers 18.104.22.168 22.214.171.124 # these are Google's nameservers
Let me know if this fixed the problem...
Hi Taimoor, Hi CMata_Intel ,
thanks for your and sorry for my late reply.
With Taimoor's command I can add the nameservers to connmanctl:
root@galileo:/var/lib/connman# cat ethernet_984feeaabbcc_cable/settings
This is permanent and survives Galileo's reboots. So far so good.
Anyhow the problem is that the device is not using the nameservers. I have to run the command again after reboot:
root@galileo:~# ping google.de
ping: bad address 'google.de'
root@galileo:~# connmanctl config ethernet_984feeaabbcc_cable --nameservers 192.168.0.1
root@galileo:~# ping google.de
PING google.de (126.96.36.199): 56 data bytes
64 bytes from 188.8.131.52: seq=0 ttl=51 time=36.464 ms
64 bytes from 184.108.40.206: seq=1 ttl=51 time=36.128 ms
64 bytes from 220.127.116.11: seq=2 ttl=51 time=35.942 ms
64 bytes from 18.104.22.168: seq=3 ttl=51 time=36.137 ms
64 bytes from 22.214.171.124: seq=4 ttl=51 time=35.960 ms
--- google.de ping statistics ---
5 packets transmitted, 5 packets received, 0% packet loss
round-trip min/avg/max = 35.942/36.126/36.464 ms
Im just curious about how other people solve this problem. I have the feel that Im missing some elementary basics configuring the network connection with the yocto os / galileo image.
I have not yet found working connmanctl commands.
Here are my (dirrty) workarounds using the /etc/resolv.conf file if someone is interested:
First I used a Startup Script:
- Create a file, e.g., /etc/init.d/startScript:
# ! /bin/sh
echo 'nameservers 192.168.0.1' > /etc.resolv.conf
- The script runs on systemboot when I use the command:
chmod a+x startScript
update-rc.d startScript defaults
Later I found a simpler solution: Write lock the resolv.conf after adding the required settings.
chattr +i /etc/resolv.conf
I would like to know more information regarding your case.
Which image are you using? Please run uname -a
Are you behind a proxy?
Are you using connmanctl config ethernet_984fee054a0e_cable --nameservers X.41.38.1 like Lemming above?
I was having the same problem but with the command: connmanctl config internet+hash --nameservers 192.168.10.1 I was able to ping to google.
Please try with the command:
connmanctl config ethernet_984fee054a0e_cable --nameservers 192.168.10.1
If this doesn't work, are you receiving an error message after using this command? Are you completely sure that there are no issues in the wired network you are using and that the network is not being blocked.
Thank you, you given me an idea
i connected Galileo through my PC then it got another IP adress : 192.168.x.x
So i only changed the last number to 1 and it works
Can you please explain it in more detail if possible with screenshots ? I'm very new to Linux and half of the things are just going over my head. Screenshots of steps will long way in making things more clear. Thanks in advance