Linux - NetworkingThis forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.
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.
Sorry it seems I misunderstood the question but anyway that's not the way to make it permanent like was said is via your router or /etc/network/interfaces configuration or your network manager graphically.
You don't need to change your ip there only to test dns for locally purposes, and it's not recommended.
In other words you will have another ip via dhcp working regardless of that file and you don't need to restart services.
I still lag behind regarding IPv6 configurations! I'll have to look into that...
I thought of just deleting the line with the hostname (with the transient IP address) leaving just the one with "localhost", but I am aiming for correctness - I'd like to have tools like hostname and others report correct hostname, domainname, FQDN...
Next question will be the same but for /etc/networks. :-)
You want to use debian as server? Or just set static ip in every lan you connect? (this later not every networks support)
I was thinking more of laptops with DHCP.
They get carried around between several networks, some controlled by me, some not so. Some are friendly some are not...
I'd like to have the current (transient, correct) domain name appear on the login screen, tools like route report the correct networks...
Having the local domain name appear on the login screen would be (almost) a magic trick since the laptop would have no communication with that network (not even the AP) until powered on and would have nothing from dns on the network until already logged in and authenticated. The connection to the AP does not AFAIK do any DNS handshaking.
You need some sort of script to do that. I have never done it before, even with radius, when you login that is.
Otherwise you can add a conky file with that info or add it to conky.
FQDN you don't need it since you're not a server. But should be something like this:
hostnamectl set-hostname ninguem
You can edit hosts, and comment line 127.0.1.1 - it's debian related and no need for it.
You need some sort of script to do that. I have never done it before, even with radius, when you login that is.
Otherwise you can add a conky file with that info or add it to conky.
You might be right. The solution I think will have to be creating a script for post-dhcp. A script in /etc/dhcp/dhclient-exit-hooks.d/, I guess.
I'm not sure what you mean with conky. Those applets floating on the desktop? Nahhh! :-)
Quote:
Originally Posted by zrong
FQDN you don't need it since you're not a server.
Why do you say this? Shouldn't all computers have its FQDN correctly set?
Quote:
Originally Posted by zrong
You can edit hosts, and comment line 127.0.1.1 - it's debian related and no need for it.
Hum!...
I don't have that line. But what is it for, really?
This quest aims for correctness, not a practical necessity I have right now. I'm being pedantic, I guess...
But picture this situation: You BYOD to a place to start working there (It could be a friend you want to help debugging network issues at home).
You connect to a network, but you want which network to be immediately apparent so you don't hack his neighbor network by mistake.
Makes sense?
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.