Koozali.org: home of the SME Server

Changing External IP [SOLVED]

Offline .solo

  • 7
  • +0/-0
Changing External IP [SOLVED]
« on: February 09, 2008, 05:46:17 PM »
My external IP address changed recently and I am having a lot of trouble trying to get my sme server connected. I ran the command  /sbin/e-smith/signal-event ip-change {new ip address} ; however, my server still can't connect. I'm in the habit of watching my messages log and i notice that dhclient constantly resets my IP address to the address I used previously. I've explored the /var/lib/dhcp/ folder and tried to stop dhclient from rebinding my old IP, but I still can't get my server to connect.


PLEASE, any help would be much appreciated.


Another odd thing is that, after changing my ip in the /var/lib/dhcp/dhclient-eth1.leases file I don't know where dhclient is mysteriously pulling my old IP from. I read the man pages and can't think of anywhere else it would keep it.
« Last Edit: February 13, 2008, 05:43:32 AM by .solo »

Offline arne

  • ****
  • 1,116
  • +0/-4
Re: Changing External IP
« Reply #1 on: February 09, 2008, 10:24:46 PM »
How can you know it is not only your isp that just give you the old adress back ?
The sme box is running in gateway mode, and it gets the external ip direct into the eth1 ?
There is no other router in front of it ?
What is the ip that returns back (When you anonymize it by xx'ing out the two last digits) ?
......

Offline byte

  • *
  • 2,183
  • +2/-0
Re: Changing External IP
« Reply #2 on: February 09, 2008, 11:34:18 PM »
My external IP address changed recently and I am having a lot of trouble trying to get my sme server connected. I ran the command  /sbin/e-smith/signal-event ip-change {new ip address} ; however, my server still can't connect. I'm in the habit of watching my messages log and i notice that dhclient constantly resets my IP address to the address I used previously. I've explored the /var/lib/dhcp/ folder and tried to stop dhclient from rebinding my old IP, but I still can't get my server to connect.

Please report bugs and potential bugs in the bug tracker. Thanks.
--[byte]--

Have you filled in a Bug Report over @ http://bugs.contribs.org ? Please don't wait to be told this way you help us to help you/others - Thanks!

Offline raem

  • *
  • 3,972
  • +4/-0
Re: Changing External IP
« Reply #3 on: February 10, 2008, 08:24:15 AM »
solo

Not sure if that command will do it for you.

To see what is in the config db file do
config show ExternalIP

If still set to your old IP, then that's why.

To change it
Login to the console as admin
Select Configure this server
step through the screens and change your external IP
Reboot and it should come up correctly now.

If not, then do lodge a bug report.
...

Offline .solo

  • 7
  • +0/-0
Re: Changing External IP
« Reply #4 on: February 10, 2008, 08:02:31 PM »
I wasn't sure this was a bug. I thought it was my own incompetence.

How can you know it is not only your isp that just give you the old adress back ?
The sme box is running in gateway mode, and it gets the external ip direct into the eth1 ?
There is no other router in front of it ?
What is the ip that returns back (When you anonymize it by xx'ing out the two last digits) ?


The cable modem is connected directly to the sme server which is acting as a gateway/server. I am confident that the isp isn't giving me back my old ip address because my internet won't work.

Offline raem

  • *
  • 3,972
  • +4/-0
Re: Changing External IP
« Reply #5 on: February 10, 2008, 09:19:35 PM »
solo

Turn your modem off for 30 minutes, then power it back on and see if you get issued a new IP.
...

Offline william_syd

  • ****
  • 1,608
  • +0/-0
  • Nothing to see here.
    • http://www.magicwilly.info
Re: Changing External IP
« Reply #6 on: February 11, 2008, 04:27:27 AM »
Are you alternating PC/SME with your cable modem to post here?

Remember to power off the modem when going from one to the other. Usually, once a cable modem 'learns' a MAC address, it's in there till the unit does a reset or reboot.

If the cable modem has a 'standby' button, that's usually not good enough. You have to pull the plug and wait a minute or two.
« Last Edit: February 11, 2008, 04:31:03 AM by william_syd »
Regards,
William

IF I give advise.. It's only if it was me....

Offline arne

  • ****
  • 1,116
  • +0/-4
Re: Changing External IP
« Reply #7 on: February 11, 2008, 05:13:34 AM »
Don't know to much about cable modems, but adsl modems often contain a router pluss a dhcp server. In such a case it will be quite normal to receive the same old ip also when the external ip has changed.

That's the reason that I thought it wa an idea to post the ip, or some part of it (the first digits), to see if it was an external or an internal ip.
......

Offline .solo

  • 7
  • +0/-0
Re: Changing External IP
« Reply #8 on: February 11, 2008, 08:55:57 PM »
First, Thanks for all the responses.

After running '/sbin/e-smith/signal-event' I checked '/sbin/e-smith/configure get ExternalIP' and it returned the IP I changed it to, however it still rebinds the old IP address because it doesn't get a dhcp response. I have tried unplugging the router and plugging it in but it still won't acquire an ip address via dhcp.

When I bypass the sme server and plug the modem directly into the my linksys router the internet will work. I watch the router and it is first assigned a 192.168.100.x ip (I assume thats the modem) and then is quickly assigned a 67.177.xxx.xxx ip address from my isp. This leads me to believe that my sme server isn't configured correctly. It won't acquire an IP.

I'm going to try to unplug the cable modem for a longer period of time then if that doesn't resolve the issue I'm going to change the MAC address of my external NIC. If I still don't have the issue fixed by midnight, I'm going to do a fresh install.

I have also looked for a way to stop the dhclient or at least get it to issue another dhcp request; however, I can't run /sbin/dhclient because it is already running in daemon mode (ps aux |grep dhclient), and every time I kill the process it restarts and changes my ip back to the old ip (when i check /sbin/ifconfig).

Should I file this as a bug, or do you think its just an issue with the ISP and cable modem?

Offline arne

  • ****
  • 1,116
  • +0/-4
Re: Changing External IP
« Reply #9 on: February 12, 2008, 12:50:49 AM »
Quote
When I bypass the sme server and plug the modem directly into the my linksys router the internet will work. I watch the router and it is first assigned a 192.168.100.x ip (I assume thats the modem) and then is quickly assigned a 67.177.xxx.xxx ip address from my isp. This leads me to believe that my sme server isn't configured correctly. It won't acquire an IP.

When I run my ADSL modem in semi bridge mode, it has the same behaviour I think. I think that the comunication is first sat set up via local adresses and then the externnal address is handled ocer to the sme external gateway. (while the modem is still available on its local adress, so it it possible to log into it, changing parameters, etc.)

When I connect the SME server/gateway to such a connection, it works, but it does not work completely like normal. It use quite much longer time than normal, but if I give it an hour or two, it will do it. (Possibly strange, but this it how it works here.)

So my only advice it to sleep on it, give it the night and see what happens.
« Last Edit: February 12, 2008, 12:52:44 AM by arne »
......

Offline CharlieBrady

  • *
  • 6,918
  • +3/-0
Re: Changing External IP
« Reply #10 on: February 12, 2008, 01:51:58 AM »
Should I file this as a bug, or do you think its just an issue with the ISP and cable modem?

You should file a bug for anything which doesn't "just work" as documented.

Offline william_syd

  • ****
  • 1,608
  • +0/-0
  • Nothing to see here.
    • http://www.magicwilly.info
Re: Changing External IP
« Reply #11 on: February 12, 2008, 02:03:11 AM »
Don't know to much about cable modems, but adsl modems often contain a router pluss a dhcp server.

Probably dependant on modem model but my Surfboard does not route and the DHCP server for the LAN operates a little differently than most.

Pubic page with some info....

http://homepage.ntlworld.com/robin.d.h.walker/cmtips/surfboard.html



Regards,
William

IF I give advise.. It's only if it was me....

Offline .solo

  • 7
  • +0/-0
Re: Changing External IP
« Reply #12 on: February 13, 2008, 05:18:56 AM »
I have "fixed" the original problem by following RayMitchell's advice and leaving the cable modem unplugged for a Long time. Seemed to good to be true ... and it was. Now, I can't access my webservers externally.

I can't even ping my external ip address externally or from my local network.

Do you think it is my ISP cracking down on my webservers or do you think it's my server!?

Offline .solo

  • 7
  • +0/-0
Re: Changing External IP
« Reply #13 on: February 13, 2008, 05:42:55 AM »
Ok, now everything seems to work correctly.

I checked /sbin/e-smith/config get ExternalIP    and it was set incorrectly, so I ran another signal-event and it resolved the issue.

THANKS FOR THE RESPONSES.

ISSUE RESOLVED.