Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place. |
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
 |
|
09-01-2005, 12:15 AM
|
#1
|
Member
Registered: Sep 2004
Location: Malaysia
Distribution: FC6, Solaris
Posts: 340
Rep:
|
Copy file problem
I copy some files from the folder /var/named which contains some DNS/Bind files. After i copied them to another directory, each source file icon has a green reverse arrow on right top and when i right click properties on it, it disappeared. Even the target directory copied files also like this. Any idea why ? Thanks
Rgds
Daniel
|
|
|
09-01-2005, 01:38 AM
|
#2
|
LQ Newbie
Registered: Sep 2004
Location: Philippines
Distribution: CentOS, Gentoo, Ubuntu, Redhat, Fedora. FreeBSD
Posts: 13
Rep:
|
whenever you copy a file or directory the original context will not be preserved. The method of copying you should use should have preserved parameter.
|
|
|
09-01-2005, 03:13 AM
|
#3
|
Member
Registered: Sep 2004
Location: Malaysia
Distribution: FC6, Solaris
Posts: 340
Original Poster
Rep:
|
How ?
Quote:
Originally posted by kaverong
whenever you copy a file or directory the original context will not be preserved. The method of copying you should use should have preserved parameter.
|
|
|
|
09-01-2005, 03:43 AM
|
#4
|
LQ Newbie
Registered: Sep 2004
Location: Philippines
Distribution: CentOS, Gentoo, Ubuntu, Redhat, Fedora. FreeBSD
Posts: 13
Rep:
|
cp -p [source] [destination]
cp --help
|
|
|
09-01-2005, 10:57 PM
|
#5
|
Member
Registered: Sep 2004
Location: Malaysia
Distribution: FC6, Solaris
Posts: 340
Original Poster
Rep:
|
how to use mouse right click copy and paste ? Btw do you know abt Bind/dns in linux Fc3?
Quote:
Originally posted by kaverong
cp -p [source] [destination]
cp --help
|
|
|
|
09-14-2005, 07:26 PM
|
#6
|
Member
Registered: Sep 2004
Location: Malaysia
Distribution: FC6, Solaris
Posts: 340
Original Poster
Rep:
|
Hi, if the target directory already got same file, how to overwrite them ?
Regards
Daniel
Quote:
Originally posted by kaverong
cp -p [source] [destination]
cp --help
|
|
|
|
09-14-2005, 09:49 PM
|
#7
|
Senior Member
Registered: Nov 2002
Location: CA
Distribution: redhat 7.3
Posts: 1,440
Rep:
|
It's the same 'cp' command. Try it and you'll see what I mean.
-twantrd
|
|
|
09-15-2005, 12:56 AM
|
#8
|
LQ Newbie
Registered: Sep 2004
Location: Philippines
Distribution: CentOS, Gentoo, Ubuntu, Redhat, Fedora. FreeBSD
Posts: 13
Rep:
|
to overwrite existing file
cp -f
-f is force parameter
for other parameter options
cp --help
|
|
|
09-16-2005, 10:36 AM
|
#9
|
Member
Registered: Sep 2004
Location: Malaysia
Distribution: FC6, Solaris
Posts: 340
Original Poster
Rep:
|
Previously i copied some files from /var/named/ to /var/named/chroot/var/named/ with copy and paste. Those files are now linked (have a green turn around arrow) on each copied file. Now i can't copy them to the target directory althought target directory file is deleted. Whenever i use "cp -p -f /xxx/xxx/filename /xxx/xxx/" it will say no such file or directory. Any idea ?
Regards
Daniel
Quote:
Originally posted by kaverong
to overwrite existing file
cp -f
-f is force parameter
for other parameter options
cp --help
|
|
|
|
09-17-2005, 12:16 PM
|
#10
|
Senior Member
Registered: Nov 2002
Location: CA
Distribution: redhat 7.3
Posts: 1,440
Rep:
|
Quote:
Those files are now linked (have a green turn around arrow) on each copied file. Now i can't copy them to the target directory althought target directory file is deleted.
|
You mean they are symlinked now? It's a bit hard to debug your problem since we don't know what happened. Let's check your files. Do this:
1. ls -al /xxx/xxx/filename
2. ls -ald /xxx/xxx
-twantrd
|
|
|
09-18-2005, 06:55 AM
|
#11
|
Member
Registered: May 2005
Posts: 378
Rep:
|
Re: Copy file problem
Quote:
Originally posted by DanielTan
I copy some files from the folder /var/named which contains some DNS/Bind files. After i copied them to another directory, each source file icon has a green reverse arrow on right top and when i right click properties on it, it disappeared. Even the target directory copied files also like this. Any idea why ? Thanks
Rgds
Daniel
|
How are you viewing these icons? I don't get any icons with ls.
|
|
|
09-21-2005, 06:25 PM
|
#12
|
Member
Registered: Sep 2004
Location: Malaysia
Distribution: FC6, Solaris
Posts: 340
Original Poster
Rep:
|
Hi, when i copy from this folder to the chroot foler, it says destination file is the same file. It is symlink. How to break it the link ?
Rgds
Daniel
Quote:
Originally posted by twantrd
You mean they are symlinked now? It's a bit hard to debug your problem since we don't know what happened. Let's check your files. Do this:
1. ls -al /xxx/xxx/filename
2. ls -ald /xxx/xxx
-twantrd
|
|
|
|
09-21-2005, 06:27 PM
|
#13
|
Member
Registered: Sep 2004
Location: Malaysia
Distribution: FC6, Solaris
Posts: 340
Original Poster
Rep:
|
Re: Re: Copy file problem
I view them in window browser. Previously i just click copy and paste. I think now they are symlink. Anyway to break the link ? i tried cp -f it also wont overwrite them.
Rgds
Daniel
Quote:
Originally posted by eddiebaby1023
How are you viewing these icons? I don't get any icons with ls.
|
|
|
|
09-21-2005, 11:42 PM
|
#14
|
Senior Member
Registered: Nov 2002
Location: CA
Distribution: redhat 7.3
Posts: 1,440
Rep:
|
'rm' the link and copy again.
-twantrd
|
|
|
09-22-2005, 01:09 AM
|
#15
|
Member
Registered: Sep 2004
Location: Malaysia
Distribution: FC6, Solaris
Posts: 340
Original Poster
Rep:
|
change to the destination directory and "rm" the file ?
Rgds
Daniel
Quote:
Originally posted by twantrd
'rm' the link and copy again.
-twantrd
|
|
|
|
All times are GMT -5. The time now is 08:19 AM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|