Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: ChangeIPAddress.command



On Jul 22, 2008, at 11:14 PM, Ian Masters wrote:

Eli

Thanks for the swift reply.

The ChangeIPAddress cli tool is only for MacOS X Server and it fixes up
a bunch of places where MacOS X Server uses the IP address and/or DNS
address.

So even if I only want to change the IP address of the server, it's
better to use this script rather than the System Prefs Network pane?
(The server's only function presently is that of a backup proxy server
on the same subnet as the main proxy server. When the main proxy goes
down, the idea is that we manually change the backup server's IP to that
of the main proxy. However, until recently, we never had to do that.
Changing the server's IP remotely via ssh and 'ifconfig' proved to be a
failure for some reason.)


I'm pretty certain that in the past I have changed the server's IP via
the Network pane, without any drastic consequences.

The System Preference Network pane just updates the network settings, so
all the other places that also use the IP/dns address aren't updated.

Hmm ... as far as I'm aware, I only want to update the network settings.
Are you saying that if I use the Network pane to update the IP address,
there might be problems later?

The services that you happen to be currently using may not need to be updated using the tool, or they may just working well enough in your particular setup that you haven't hit the cases where it fails in an obvious way.


If Apple says 'when using our software, to change X, run tool Y instead of using method Z', I would default to running tool Y instead of using method Z. It would take an unusual circumstance to go against Apple's recommendation [for me at least], and a lot of testing to make sure it still works.

As for doing it remotely, I would imagine that unless you take special
precautions, the network connection you would use to run the command
[ie, ssh to the server] probably would be disconnected as part of
executing the ChangeIPAddress command.

I would expect the ssh session to be disconnected but I wonder if it would affect the script's correct functioning?

Well, this is the kind of significant change, where if it fails, the services that the server is providing no longer work and you have to physically go over to the server to fix the problem. Personally, I would really not like to do this kind of thing unless I really had to, such as the server being at a co-lo or something like that.


At the very least, if I had to do it remotely, I would NOT execute it via a shell spawned from an ssh login. I'd probably write a shell script to do it and then add it to root's cron job [so it executes once, 5 minutes from now], so there is no question of the script possibly being kill'ed prematurely because it's environment [the ssh login] has died.

Maybe also research what Apple has on ip failover, as I recall reading some info on Apple's site about this, as it should no longer take manual intervention [ie, even you logging in remotely to whack the IP settings] to do this with 10.5 Server. And you probably could setup some script to auto-ping and make the backup server take over the primary IP address when the primary server no longer responds to ping's [or whatever else you want].

_______________________________________________
Do not post admin requests to the list. They will be ignored.
Macos-x-server mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/macos-x-server/email@hidden

This email sent to email@hidden
References: 
 >ChangeIPAddress.command (From: Ian Masters <email@hidden>)
 >Re: ChangeIPAddress.command (From: Eli Bach <email@hidden>)
 >Re: ChangeIPAddress.command (From: Ian Masters <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.