Device Name

log in

Advanced search

Message boards : BOINC Manager : Device Name

Author Message
kyle.arnone
Send message
Joined: 19 Mar 07
Posts: 1
Message 8898 - Posted: 19 Mar 2007, 18:51:07 UTC

In regards to the computer "device" name, "domain" name, host, etc. Using the Windows or Mac client, if I change the computer name, the next time I load Boinc, it updates the client_state.xml file with the new name, and then that gets updated to the World Community Grid project I am doing. However, I am having an issue with the changing of the Boinc Linux client. I've tried many different methods, but it still just says localhost.localdomain in the client_state.xml, and reading 127.0.0.1 as the ip. If anyone knows how I can change the hostname properly on Linux so Boinc will read it, let me know. Thank you!

River~~
Avatar
Send message
Joined: 12 Mar 07
Posts: 59
Message 8915 - Posted: 20 Mar 2007, 11:31:58 UTC - in response to Message 8898.
Last modified: 20 Mar 2007, 11:36:52 UTC

In regards to the computer "device" name, "domain" name, host, etc. Using the Windows or Mac client, if I change the computer name, the next time I load Boinc, it updates the client_state.xml file with the new name, and then that gets updated to the World Community Grid project I am doing. However, I am having an issue with the changing of the Boinc Linux client. I've tried many different methods, but it still just says localhost.localdomain in the client_state.xml, and reading 127.0.0.1 as the ip. If anyone knows how I can change the hostname properly on Linux so Boinc will read it, let me know. Thank you!


There are two different issues here. I spent hours on this last autumn.

1. Why does your boinc client pick up the loopback ip rather than the external ip?

2. Given that it does, is there a workaround that will at least show the desired name?

1. I never got to the bottom of it. It seems to be something to do with how you set up the network cards, I mean not the settings but the exact order you set them up. It went on reporting 127.0.0.1 as the ip till I reinstalled the OS from scratch... then it never happened again and I lost interest in chasing it ;-)

I concluded however that it is not a BOINC issue but something deep inside linux. BOINC asks the os for its own ip address and can't do anything but believe what it is told.

2. If I remember rightly, the workaround that got the name right for me was to put the preferred name in the /etc/hosts file.

If the file has these lines in it

127.0.0.1 foo localhost.localdomain localhost
10.4.2.1 bar burble.mydomain burble

then when boinc thinks its ip is 127.0.0.1 it also thinks its name is foo.

When it thinks its ip is 10.4.2.1 then it thinks its name is bar.

When you edit /etc/localhost, don't remove any names unless you really know what you are doing. And especially don't remove the localhost names or a lot of things will break that you really need and that have nothing to do with boinc...

It is OK to add new names to a line, and in particular I found no adverse effects from squeezing in a 'foo' as the first name on the 127... line. How unix interprets this is that any of the names on the line resolve to the ip, but the ip reverse-resolves only to the first name on the line.

I never tried making foo the same as bar - my guess is that it would work but that is only a guess.

Don't forget to restart boinc before expecting to see the results of your edit!

Not a complete solution, but at least it gets the right name onto the web pages when you look at them.

By the way, this is only for your own benefit - nobody else gets to see your ip or your host names even if you allow your hosts to be visible.

In my case, I did want the machine name to show on my own listings as I had several of the same hardware - had they all gone 'localhost' at once I wouldn't have known which was which.

River~~
____________

Sekerob
Send message
Joined: 25 Aug 06
Posts: 1398
Message 8926 - Posted: 20 Mar 2007, 16:34:14 UTC - in response to Message 8915.

One thing to add from doing the same research just yesterday, applying it and finding another problem disappearing was to put the fixed IP address the LAN knows the machine by, before the localhost address as in

192.xxx.xxx.15 MYFASTESTPC
127.0.0.1 localhost.localdomain

one comment was to not meddle with the localhost.localdomain name giving of 127.0.0.1. Not delved into why or why not.

If someone anywhere samples real IP addresses and device names, be aware that hackers are always on the lookout :O
____________
Coelum Non Animum Mutant, Qui Trans Mare Currunt

River~~
Avatar
Send message
Joined: 12 Mar 07
Posts: 59
Message 8955 - Posted: 21 Mar 2007, 12:17:41 UTC - in response to Message 8926.

one comment was to not meddle with the localhost.localdomain name giving of 127.0.0.1. Not delved into why or why not.


The names localhost and localhost.localdomain must both resolve to 127.0.0.1 unless you really really know what you are doing. Many *nix programs connect to localhost meaning the local machine, rather fewer automatically append a domain name which defaults to localdomain.

For example, you might discover if you use a gui for Linux, KDE of gnome, it may tell X to draw the window on localhost - change the value of localhost in the hosts file and your window will come up on some other machine, if the other machine knows what to do with the request... Even if that is what you wanted, changing localhost is not the way to do it.

Certainly BoincMgr assumes localhost by default.

Adding more aliases to that ip address is no problem, as in the example I gave before. Taking away the two assumed ones is strictly for experts.

R~~

Nicolas
Send message
Joined: 19 Jan 07
Posts: 1174
Message 8959 - Posted: 21 Mar 2007, 15:01:16 UTC - in response to Message 8955.

Taking away the two assumed ones is strictly for experts.

Experts looking for trouble, I might add.

mki
Send message
Joined: 13 Apr 08
Posts: 1
Message 16639 - Posted: 13 Apr 2008, 18:28:43 UTC - in response to Message 8959.

I had the same problem.
I noticed that boinc takes the first hostname from /etc/hosts for the 127.0.0.1 ip, so the solution is to put your hostname before localhost.

For example:

127.0.0.1 myhostname localhost

Profile KSMarksPsych
Volunteer moderator
Avatar
Send message
Joined: 30 Oct 05
Posts: 1193
Message 16645 - Posted: 13 Apr 2008, 23:03:43 UTC

Crud...

I wonder how bad I'd break things if I tried this.
____________
Kathryn :o)
The BOINC FAQ Service
The Unofficial BOINC Wiki
The Trac System
More BOINC information than you can shake a stick of RAM at.

Profile KSMarksPsych
Volunteer moderator
Avatar
Send message
Joined: 30 Oct 05
Posts: 1193
Message 16649 - Posted: 14 Apr 2008, 3:07:24 UTC - in response to Message 16647.

Crud...

I wonder how bad I'd break things if I tried this.


It's pretty much goof proof. I know because I tried it last year and it works. Dang, I thought everybody was doing it.



You underestimate my ability to seriously screw things up :-)
____________
Kathryn :o)
The BOINC FAQ Service
The Unofficial BOINC Wiki
The Trac System
More BOINC information than you can shake a stick of RAM at.

Sekerob
Send message
Joined: 25 Aug 06
Posts: 1398
Message 16651 - Posted: 14 Apr 2008, 9:58:35 UTC

my onederful new 802.11n router allows a mix of dhcp+fixed(preferred) IP's assigned to specific devices & mac-code. Works a treat.

Still going around with putting localhost IP after the LAN IP though.
____________
Coelum Non Animum Mutant, Qui Trans Mare Currunt

Message boards : BOINC Manager : Device Name


BOINC home page · Log in · Create account

Copyright © 2014 University of California. Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2 or any later version published by the Free Software Foundation.