vBulletin Search Engine Optimization
| |||||||
| Register | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| ||||
| I have a simple home network in which two computer are connected through a dhcp router. The router is connected to a cable modem. One computer is running SUSE-LINUX and the other WinXP. I can use cygwin on the XP machine to open up a remote desktop with the command $ X -query IP_address Where IP_address is the IP address. I would like instead to use the name of the linux computer instead of the IP_address. Some other information. On the LINUX box the command line is user_name@linux:~> I take it then that the computer name is "linux". Is this correct? On the LINUX machine I then type user@linux:~> nslookup linux The message indicates the the server can't find a computer named linux. Enough of the preamble: Can somebody give me some hints to what I have to do so that I can use the computer name rather than IP address to identify my linux box? thanks!! |
| |||
| "jeanluc" <jeanluc_picard_66@hotmail.com> writes: >I have a simple home network in which two computer are connected >through a dhcp router. The router is connected to a cable modem. >One computer is running SUSE-LINUX and the other WinXP. >I can use cygwin on the XP machine to open up a remote desktop with the >command >$ X -query IP_address >Where IP_address is the IP address. >I would like instead to use the name of the linux computer instead of >the IP_address. >Some other information. >On the LINUX box the command line is >user_name@linux:~> >I take it then that the computer name is "linux". Is this correct? >On the LINUX machine I then type >user@linux:~> nslookup linux >The message indicates the the server can't find a computer named linux. >Enough of the preamble: >Can somebody give me some hints to what I have to do so that I can use >the computer name rather than IP address to identify my linux box? >thanks!! a) set up your router to give the two machines static, not dynamic ip addresses based on the MAC of their ethernet cards. b) make up a name for your linux machine and put the name and the ip into the windows computers hosts file (Not sure where Windows hides the hosts file). If you want your linux machine to think it has the same name, put that into an appropriate place on the Linux box. Since I do not run SUSE I am not sure where it is. On Mandrake/Redhat it is in /etc/sysconfig/network, but I do not know if SUSe uses the same file. |
| ||||
| On 18 Jan 2006, in the Usenet newsgroup comp.os.linux.setup, in article <1137606024.833003.137450@z14g2000cwz.googlegroups .com>, jeanluc wrote: >I have a simple home network in which two computer are connected >through a dhcp router. The router is connected to a cable modem. Are the addresses that the two computers get "public" (something in the 70.160.0.0 - 70.191.255.255 range as you appear to be using Cox), or are they in the RFC1918 range (such as 192.168.x.y)? >I would like instead to use the name of the linux computer instead of >the IP_address. You'd have to get the DHCP router to hand out fixed addresses (based on the MAC address), or have it act as a name server. >On the LINUX box the command line is > >user_name@linux:~> > >I take it then that the computer name is "linux". Is this correct? Probably. What does '/bin/hostname' tell you? [compton ~]$ /bin/hostname compton.phx.az.us [compton ~]$ >On the LINUX machine I then type > >user@linux:~> nslookup linux > >The message indicates the the server can't find a computer named linux. [compton ~]$ whatis dig dnsquery host nslookup dig (1) - send domain name query packets to name servers dnsquery (1) - query domain name servers using resolver host (1) - look up host names using domain server nslookup (8) - query Internet name servers interactively [compton ~]$ Notice that these tools all query a name server - possibly that of your router, cable modem, or ISP - look at the contents of /etc/resolv.conf to find which. Your problem is much the same as you asking to talk to 'jean' or even 'jeanluc'. jean WHO? There are hundreds of thousands of people named 'jean', just as there are probably thousands of computers named 'linux'. >Can somebody give me some hints to what I have to do so that I can use >the computer name rather than IP address to identify my linux box? A lot depends on how you are setting up the network. Unruh suggests setting the router to provide static addresses, and putting hostnames in the host files (/etc/hosts on Linux, on XP, it is PROBABLY in C:\\WINDOWS\SYSTEM32\DRIVERS\HOSTS (not HOSTS.SAM). In both cases, you want the IP address, followed by the FULL name and optionally the short name (192.168.1.1 jeanluc.picard jeanluc). Your DHCP server may be defining the name (as opposed to the system defining it). In SuSE, the name is set from the /etc/rc.conf file. You _may_ be able to set the DHCP server to act as a DNS server. Old guy |