Visit Our UNIX and Linux User Community


Script information needed


 
Thread Tools Search this Thread
Top Forums UNIX for Dummies Questions & Answers Script information needed
# 1  
Old 12-17-2007
Script information needed

Transferring files from one unix server to another one was easy for me. I used a relative path which worked for me. thanks to porter.

My question now is that:-

1)Say for instance i have one unix server with name(ABC). PATH: /home/web/props . I have bunch of different users folders in that props directory. for eg dia/downloads or alex/downloads.. etc..

2) I have another unix server (XYZ). URL: /home/webapps/users

What i wanted to do is copy whatever is inside /home/web/props from ABC unix server to XYZ unix server under /home/web/webapps. If its a new user then create a directory by the same name under XYZ.

Hope you all can understand. Is it possible? how any clues? any links i can read

Bottom Line: I would like to copy each and every folder under props directory from ABC unix server to XYZ unix server. If directory exist then just do a simple secure transfer copy if not then create a directory.
Thanks
# 2  
Old 12-17-2007
use recurcive rcp

you can use recursive rcp or tar the directory you want to transfer and then extract it in the desired directory Smilie
# 3  
Old 12-17-2007
Thanks rakesh. Can you give me an example or may be a link which i can read?
# 4  
Old 12-17-2007
thanks rakesh. well the script is not different from the secure directory copy command. anyways thanks for your effor and i will try to do more research on it to see if i can accomplish that goal.

Thanks
 

Previous Thread | Next Thread
Test Your Knowledge in Computers #873
Difficulty: Medium
Self-modifying code is easier to read and maintain because the instructions in the source program listing are always the instructions that will be executed.
True or False?

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

script for RAC information required

Hello, is it possible for someone to generate a shell script that will do the following, please. UNIX Shell script novice who is after a script to look at a few things within an Oracle RAC environment Hopefully if this works, I can schedule this via cron Many thanks I can execute these... (3 Replies)
Discussion started by: jnrpeardba
3 Replies

2. Shell Programming and Scripting

Expect script help needed- script failing if router unavailable

Hey all. Sometimes I'm tasked to change some router configs for the entire network (over 3,000 Cisco routers). Most of the time its a global config parameter so its done with a loop and an IP list as its the same configuration change for all routers. This is working OK. However, sometimes an... (3 Replies)
Discussion started by: mrkz1974
3 Replies

3. UNIX for Dummies Questions & Answers

Write a script to extract information from a db

Hi I need to put together a script that will search certain tables in a db and send that data to a csv file. Basically I am importing data to a db and I want to write a script to check that all information was imported correctly. Thank you (1 Reply)
Discussion started by: ladyAnne
1 Replies

4. Shell Programming and Scripting

Script to compact information !

Hello Group, Could you please help me with a shell script that condense in this case each 12 rows of hour information in only one row per day as following: Final Fields in each row 1.Ticker Name 2. D (Daily) 3. Date 4. Open Price (The open price of the first record of the day) 5. High... (13 Replies)
Discussion started by: csierra
13 Replies

5. Shell Programming and Scripting

script to collect all db information

hi all I am looking for shell script ,by which i need to gather all the DB information in Sybase server . Thanks in advance :) (3 Replies)
Discussion started by: mvsramarao
3 Replies

6. UNIX for Dummies Questions & Answers

User information script

Hi Guys, I just started learning unix and was wondering if anyone can assist me with my User info script.The script file lets the user input their personal information (Their name, address, phone number etc...). The script will then ask the user to input the info again if the input is incorrect... (2 Replies)
Discussion started by: rc1138
2 Replies

7. UNIX for Dummies Questions & Answers

Help regarding saving information within a script!

I have 2 files. File 1 exports variables globally, File 2 pulls in the information into itself and displays it. I need to know how to then save the information into the bottom of File 2, allowing for more information to be added at a later date. The scripts i've written are below. File 1:... (8 Replies)
Discussion started by: phproxy
8 Replies

8. UNIX for Dummies Questions & Answers

Information needed

As part of a school project I'm supposed to make a webpage on operating systems (Other than windows) and the three I was told to do were Linux, Unix, and Mac. I got Linux and Mac done pretty easily because I use them a lot but Unix is showing some problems. Could anyone give me some information on... (2 Replies)
Discussion started by: Shinjin
2 Replies

9. Shell Programming and Scripting

Script execution information

I want to catch the execution information of a script by calling it from another script.... script_main: #! /bin/ksh ksh -x script2.ksh >> tmplog .... but this doesn't give me anything but the error msgs of script in tmplog. can anyone pls suggest which is the right method? The... (12 Replies)
Discussion started by: manthasirisha
12 Replies

10. UNIX for Dummies Questions & Answers

Sun Solaris information needed

Hello everyone. I wont waste anytime and I will get right to the point. I've been working with Linux for about 7 months and started using OpenBSD and FreeBSD for about 2 months. I have a very strong background in Microsoft (MCSE). I plan to continue working with Microsoft as it's one entity... (10 Replies)
Discussion started by: tarballed
10 Replies

Featured Tech Videos