473,383 Members | 1,795 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,383 software developers and data experts.

I have 100 servers which need a new backup server added to a text file,

This seems easy but I have been asking tcl and python IRC chat all day
and no one gave an answer.
I have 100 servers which need a new backup server added to a text file,

and then the backup agent restarted.
If I have a list of the servers, all with same root password, and the
connection is ssh.
How do I connect to the server, cat the line to the config file, stop
adn start the agent, and then do same to next server in list and
iterate through the 100 servers.
What script would allow this?

Jul 1 '06 #1
4 1444
gavino wrote:
This seems easy but I have been asking tcl and python IRC chat all day
and no one gave an answer.
I have 100 servers which need a new backup server added to a text file,

and then the backup agent restarted.
If I have a list of the servers, all with same root password, and the
connection is ssh.
How do I connect to the server, cat the line to the config file, stop
adn start the agent, and then do same to next server in list and
iterate through the 100 servers.
What script would allow this?

Curl will let you do this.

-david-

Jul 1 '06 #2
list of servers L.txt
#cat L.txt
config file is /var/bkupexec/agent.cfg need to add "tell epobackup" to
bottom of file
# cat "tell epobackup" >> /var/bkupexec/agent.cfg
agent is /etc/init.d/agent.ini stop (and then start)
# /etc/init.d/agent.init stop
# /etc/init.d/agent.init start
os=redhat ent 4ES
I intend to use root password which is same for all 100 servers.
#now I'm stuck

David Haynes wrote:
gavino wrote:
This seems easy but I have been asking tcl and python IRC chat all day
and no one gave an answer.
I have 100 servers which need a new backup server added to a text file,

and then the backup agent restarted.
If I have a list of the servers, all with same root password, and the
connection is ssh.
How do I connect to the server, cat the line to the config file, stop
adn start the agent, and then do same to next server in list and
iterate through the 100 servers.
What script would allow this?

Curl will let you do this.

-david-


Jul 1 '06 #3
gavino wrote:
This seems easy but I have been asking tcl and python IRC chat all day
and no one gave an answer.
I have 100 servers which need a new backup server added to a text file,

and then the backup agent restarted.
If I have a list of the servers, all with same root password, and the
connection is ssh.
How do I connect to the server, cat the line to the config file, stop
adn start the agent, and then do same to next server in list and
iterate through the 100 servers.
What script would allow this?
If I understand you correctly, I believe Mussh might do the trick:

http://sourceforge.net/projects/mussh

I've never used it myself though.

Tim
Jul 2 '06 #4
gavino wrote:
This seems easy but I have been asking tcl and python IRC chat all day
and no one gave an answer.
I have 100 servers which need a new backup server added to a text file,

and then the backup agent restarted.
If I have a list of the servers, all with same root password, and the
connection is ssh.
How do I connect to the server, cat the line to the config file, stop
adn start the agent, and then do same to next server in list and
iterate through the 100 servers.
What script would allow this?
Kind of OT.

I used rsync for maintaining config files on my servers with shared keys -
but its not a good idea to do this as the root user.

I can just tell that this is one of things where 'only doing it once' it
just wishful thinking. Try asking on one of the admin (e.g.
comp.os.unix)lists as they might have better suggestions than I.

Since you're using root to ssh into these boxes (it's generally considered
BAD practice to allow root to ssh in directly) you'll need to use expect or
PHP's popen to feed the password to the ssh session. That'll get it done
this time - but really you should be setting up some cluster management
system where the nodes poll config from a central location and deal with it
sensibly.

C.
Jul 3 '06 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

6
by: Paul Winkler | last post by:
This is driving me up the wall... any help would be MUCH appreciated. I have a module that I've whittled down into a 65-line script in an attempt to isolate the cause of the problem. (Real...
1
by: Ben M. | last post by:
Greetings all, This should be an easy task, and Im sure it is, but as many times as I have tried, I cant seem to get this to work properly. We changed ISPs recently from a shared host to a...
1
by: Dave Crypto | last post by:
Hi there, SUMMARY: 1) When I use phpadmin to export a large database, the file created on my local PC never containes all the tables and information. It seems to max out at about 10mb. 2)...
5
by: HSP | last post by:
hi. i need to restore an old database. The db was backed up using a DLT drive, using 2 volumes. The content for the tapes was copied to file onto Solaris machine using rsh and dd (for backup...
2
by: happyjenny52 | last post by:
Hi, I work as an IT Administrator and part of my job role is to use Enterprise Manager and Query Analyzer to backup the logins and permissions for each database on our SQL Servers. This...
13
by: gavino | last post by:
This seems easy but I have been asking tcl and python IRC chat all day and no one gave an answer. I have 100 servers which need a new backup server added to a text file, and then the backup agent...
1
by: Screenbert | last post by:
After finding nothing anywhere in google I am posting this so everyone can benefit by it. The formating is not pretty since I copied it from my word document, but you should benefit by it. ...
2
by: garther | last post by:
Hi I'm trying to get something like this to work: Application calculates data and stores them in local SQL server. Once a week this data needs to copied to DVD. Then I need second application...
3
by: sqldba | last post by:
Hi, I have two servers, one is a production server and other is a testing server. Both these servers must be in sync. Please can anyone let me know how to synchronize these two...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.