The UNIX and Linux Forums  
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.

Go Back   The UNIX and Linux Forums > Top Forums > Shell Programming and Scripting
.
google unix.com



Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts and shell scripting languages here.

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
script to change passwords for the same user on multiple servers stolz Shell Programming and Scripting 7 02-17-2009 03:49 PM
User add on multiple servers sandeep_pan Shell Programming and Scripting 6 06-10-2005 06:04 PM
Apache Config> One IP, Multiple Servers l008com UNIX for Advanced & Expert Users 7 09-15-2003 10:54 AM
moving files across multiple servers kymberm UNIX for Advanced & Expert Users 2 10-23-2002 01:04 PM
ftp to multiple servers kristy Shell Programming and Scripting 2 12-03-2001 03:49 PM

Closed Thread
English Japanese Spanish French German Portuguese Italian Dutch Swedish Russian Norwegian Hungarian Hebrew Danish Bulgarian Greek Powered by Powered by Google
 
LinkBack Thread Tools Search this Thread Rate Thread Display Modes
  #1 (permalink)  
Old 02-17-2008
kenshinhimura kenshinhimura is offline
Registered User
  
 

Join Date: Feb 2008
Posts: 65
rsh to change multiple ip in multiple servers?

good day. i jsut wanted to know what is the best script or the best way changing a lot of Ip's in all servers. Do you have any idea? im using awk to change IP,what if, you have lots of servers. You need to change it one by one? It will take time to change it manually.
  #2 (permalink)  
Old 02-17-2008
Smiling Dragon's Avatar
Smiling Dragon Smiling Dragon is offline Forum Advisor  
Disorganised User
  
 

Join Date: Nov 2007
Location: New Zealand
Posts: 922
Depends on the OS of the servers to be changed but generally speaking, you can write a script to log onto each server and update the files (have a big table mapping each IP to the new one and just do a search and replace of all of them on each server), then restart the network stack (if required).

Unless you are using DHCP, in which case it would be pretty easy, just do a big search and replace on your dhcptab file and refresh each server.
  #3 (permalink)  
Old 02-18-2008
invinzin21 invinzin21 is offline
Registered User
  
 

Join Date: Dec 2007
Location: Philippines, Cebu City
Posts: 75
in linux,try to edit ifcfg-eth0 for linux servers, and /etc/rc.config.d/netconf in HP-UX, well i dont know in AIX. Maybe someone had an idea.

For automation, you can use awk and sed, that will change your IP or your subnet etc.. I have some machines too, that i made script to changed the IP.

all servers 10.131.3.xx i changed it to 10.121.3.xx but that servers were linux and hpux. i do manually running the scripts, but havent tried ssh
maybe someone knows how to change ip not using smitty
Closed Thread

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On




All times are GMT -4. The time now is 02:23 AM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited. Language Translations Powered by .
vBCredits v1.4 Copyright ©2007 - 2008, PixelFX Studios
The UNIX and Linux Forums Content Copyright ©1993-2009. All Rights Reserved.Ad Management by RedTyger

Content Relevant URLs by vBSEO 3.2.0