Solved

how to copy folder and paste in another directory

Posted on 2006-10-19
6
225 Views
Last Modified: 2012-05-05
some sub directories r there in the applications folder c:/oc4j/j2ee/home/applications;

i wanted to copy applications folder and pasted in home directory  and rename to node1.how to do it?
0
Comment
Question by:chaitu chaitu
  • 3
  • 2
6 Comments
 
LVL 45

Accepted Solution

by:
sunnycoder earned 500 total points
ID: 17763769
Hi chaituu,

cp -R /oc4j/j2ee/home/applications ~/node1

I presumed that C: was typo - since this is Linux TA
Cheers!
sunnycoder
0
 
LVL 20

Author Comment

by:chaitu chaitu
ID: 17763777
"I presumed that C: was typo - since this is Linux TA"

yes

to run the above command i have to come upto this directory /oc4j/j2ee/home
0
 
LVL 45

Expert Comment

by:sunnycoder
ID: 17763787
Hi chaituu,

You do not have to change directories to execute this command
cp -R /oc4j/j2ee/home/applications ~/node1

Absolute path for source and destination have been specified ... ~/ refers to home directory.
Cheers!
sunnycoder
0
Windows Server 2016: All you need to know

Learn about Hyper-V features that increase functionality and usability of Microsoft Windows Server 2016. Also, throughout this eBook, you’ll find some basic PowerShell examples that will help you leverage the scripts in your environments!

 
LVL 20

Author Comment

by:chaitu chaitu
ID: 17764486
i am using SSH ;can i run this command like this.

[usernamexxx@servernamexxx /]# cp -R /oc4j/j2ee/home/applications ~/node1
0
 
LVL 45

Expert Comment

by:sunnycoder
ID: 17764499
Yes you can
0
 
LVL 14

Expert Comment

by:ygoutham
ID: 17764585
hi if you want to copy from a remote server then you need to use "scp" than cp.

if it is from a remote machine to your local machine then use

scp -r x.x.x.:/oc4j/j2ee/home/applications     /path/to/local/directory

where x.x.x.x is the ip address of the server FROM which you want to copy.

if it is from within the server then you need to do only a cp.

goutham
0

Featured Post

Enterprise Mobility and BYOD For Dummies

Like “For Dummies” books, you can read this in whatever order you choose and learn about mobility and BYOD; and how to put a competitive mobile infrastructure in place. Developed for SMBs and large enterprises alike, you will find helpful use cases, planning, and implementation.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Network Interface Card (NIC) bonding, also known as link aggregation, NIC teaming and trunking, is an important concept to understand and implement in any environment where high availability is of concern. Using this feature, a server administrator …
rdate is a Linux command and the network time protocol for immediate date and time setup from another machine. The clocks are synchronized by entering rdate with the -s switch (command without switch just checks the time but does not set anything). …
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.

830 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question