SlackwareThis Forum is for the discussion of Slackware Linux.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
In 14.1 i could ping other conmputers in my lan by its host name instead of the ip.
I added "wins" to the line "hosts: files dns" in /etc/nsswitch.conf. and "yes" to the line "wins support =" in /etc/samba/smb.conf.
But now in 14.2, after making this changes, i still can't ping hosts by its name, and because i use dhcp i have to find the ip in each host so i can acces with remote clients or share files.
I know this doesn't solve your problem, but another option might be found within your router. Many routers will allow you to assigned "static" IPs through the dhcp based on the MAC address (on my router running dd-wrt, it is called "static leases" and is found under the "Services" tab). I put in my computer's MAC address into the router and pick an IP within the valid range, then when I use dhcp on my computer, my computer will get the IP I told the router.
I have this for all my computers except for my wife's iPhone (since I never need to connect to that).
With that being said, hopefully someone else can help you figure out the name problem.
1) Make sure that you have your router's dynamic IP in /etc/resolv.conf. If, for example, you have 8.8.8.8 there, then obviously Google knows nothing about your internal home network (at least I hope so :-)
2) Alternatively, you can also edit /etc/hosts by adding new lines to this file, for example:
192.168.1.7 teddy.laptop
That's on a bare installation of Slackware 14.2 on a Virtual Machine, where you can perfectly access the Google on Firefox or Konqueror. No more than a VM because looks like all my existent computers have strong opinions against this release and there are no money and will to buy yet another one, wondering if it will work with.
PS. I would like to say Sorry!!! if this console excerpt insult someone!
Last edited by Darth Vader; 08-04-2016 at 05:28 AM.
I know this doesn't solve your problem, but another option might be found within your router. Many routers will allow you to assigned "static" IPs through the dhcp based on the MAC address (on my router running dd-wrt, it is called "static leases" and is found under the "Services" tab). I put in my computer's MAC address into the router and pick an IP within the valid range, then when I use dhcp on my computer, my computer will get the IP I told the router.
I have this for all my computers except for my wife's iPhone (since I never need to connect to that).
With that being said, hopefully someone else can help you figure out the name problem.
Hi bassmadrigal.
I want to leave that as a last resort.
It really confuses me why it was working in 14.1 and not working in 14.2 making the same changes.
What has changed??
1) Make sure that you have your router's dynamic IP in /etc/resolv.conf. If, for example, you have 8.8.8.8 there, then obviously Google knows nothing about your internal home network (at least I hope so :-)
2) Alternatively, you can also edit /etc/hosts by adding new lines to this file, for example:
192.168.1.7 teddy.laptop
.
1) My /etc/resolv.conf shows the corresponding lines of my router.
That's on a bare installation of Slackware 14.2 on a Virtual Machine, where you can perfectly access the Google on Firefox or Konqueror. No more than a VM because looks like all my existent computers have strong opinions against this release and there are no money and will to buy yet another one, wondering if it will work with.
PS. I would like to say Sorry!!! if this console excerpt insult someone!
Pinging google works ok..
Code:
bash-4.3# ping www.google.com
PING www.google.com (173.194.219.99) 56(84) bytes of data.
64 bytes from ya-in-f99.1e100.net (173.194.219.99): icmp_seq=1 ttl=41 time=109 ms
64 bytes from ya-in-f99.1e100.net (173.194.219.99): icmp_seq=2 ttl=41 time=108 ms
64 bytes from ya-in-f99.1e100.net (173.194.219.99): icmp_seq=3 ttl=41 time=109 ms
64 bytes from ya-in-f99.1e100.net (173.194.219.99): icmp_seq=4 ttl=41 time=109 ms
64 bytes from ya-in-f99.1e100.net (173.194.219.99): icmp_seq=5 ttl=41 time=108 ms
64 bytes from ya-in-f99.1e100.net (173.194.219.99): icmp_seq=6 ttl=41 time=117 ms
^C
--- www.google.com ping statistics ---
6 packets transmitted, 6 received, 0% packet loss, time 5007ms
rtt min/avg/max/mdev = 108.199/110.303/117.093/3.073 ms
bash-4.3#
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.