setting dynamic IP as main domain name
How can I set my ppp0 address as the main host name "e1000.gotdns.com", cause my current /etc/hosts lists my ethernet adress as darkstar, but I want my real domain to work even when im not on the net and connected to the dyndns.com DNS server.
here is my current /etc/hosts 127.0.0.1 localhost 192.167.0.4 darkstar.example.net darkstar <-- my ethernet adress 192.167.0.3 node3 |
Not sure I understand your question completely, but if I do all you need to do is run
Code:
netconfig |
First of all you are using the wrong "private" addresses
TCP/IP addresses reserved for 'private' networks are: 10.0.0.0 to 10.255.255.255 172.16.0.0 to 172.31.255.255 192.168.0.0 to 192.168.255.255 and as of July 2001 169.254.0.0 to 169.254.255.255 rfc If you are seting these addys yourself they must be in the range above. To set your host name $>hostname myhostname for more info $> man hostname As suggested you should run netconfig to set your network connection up correctly.. |
I'm talking about a modem, not a ethernet adress. the trick here is that I may have many different IP's in one day because it changes each time I log on and off. but dyndns assigns my host name to the new IP every time.
is there any way to change what IP my host name is bound to each time I connect to the net? |
First if your host file is setting your hostname to "darkstar" (default slack hostname if a hostname is not set) you have not configured a hostname for your machine;
`hostname e1000.gotdns.com` Then if you want to set your local machines IP addresses that are assigned to devices it is done via rc.inet1.conf located in /etc/rc.d once you have set the machine hostname and device IP addys you edit them into your hosts file. example: 192.168.50.5 mymachine.mydomain.myinitials mymachine mybox computer the mymachine.mydomain.myinitials are for the hostname your assigned to your macine. The namea after including mymachine are aliases you use for your machine. As for as getting the same IP from your ISP via DCHP the HOWTOs on DCHP and the DCHPD explains how to "request" the same address everytime if available. Now trying this with a dial-up may be quick ineffective as you may not even dial into the same modem pool or comm server. If this is a cable modem see the setup section for it. Most have the ability to set idle disconnect and/or keep alive timeouts to the tune of 5 digits in minutes/seconds. Better yet if BellSouth ADSL is available where in the "state of disorder" get yourself the Ultra package with a static IP ($14.00 per month) and then you will not need a dyndns service. As for use here we have the Extreme package x2 (fiberoptic, PPoE, 3.9mbps down, 500kbps up, bridged, 2 bell assigned statics) (speed averages 4.3-8.7mbps down, 500-2,400kbps up):) |
first off, thanks for the heads up; I will change my IP for the private network.
second, if there was even a remote chance that I could have some form of broadband, I would have bought it years ago. as for now Im stuck with 56k wether I like it or not. my ONLY other option is satelite internet service which isnt all that fast and its upward of 100$ per month, not an option on my budget. back to what I was asking, thanks for the suggestion but does anybody have any Idea on how to assign a domain name (locally) to my dynamic not always existant modem IP. I already have a remote domain name from dyndns. |
As I stated above IF you assign your own hostname and domain name via the hostname command it WILL be mapped to the dchp assigned IP
man hostname also see /etc/HOSTNAME mostly will say darkstar until you set your own |
I have used hostname <myhostname> and it never would stay. It still uses darkstar.
|
did you "man hostname"?
Have you checked the /etc/host.conf? How about the /etc/HOSTNAME??? |
Seeing as how "man hostname" didn't mention the other two, how was I supposed to know? Unless I just missed that. netconfig worked.
|
Maybe you should read it again....
line 84 of man hostname refers to /etc/hostname which is read by /etc/rc.d/rc.net1 at boot. Line 73 of the man hostname refers to the /etc/host.conf as part of hostname configuration. You could also simply <ls host*> the /etc directory and see these files. And yes that is why netconfig is there... So ppl you don't know how to do direct edits of configuration scripts and files don't have to. |
All times are GMT -5. The time now is 12:17 AM. |