LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 05-06-2011, 01:42 AM   #1
sumeet inani
Member
 
Registered: Oct 2008
Posts: 908
Blog Entries: 26

Rep: Reputation: 49
file copy manager


hi, I am currently using debian 6.0 .
While moving the file , electricity vanished. It happened that the file being moved wasn't at source neither destination folder.
Is there a file copy program which works atomically (like teracopy in windows) .
Yeah , common sense would be to manually copy then delete file from source . Can't this be integrated into GUI by a program?
 
Old 05-06-2011, 04:10 AM   #2
Sjonnie48
Member
 
Registered: Jun 2005
Location: Earth
Distribution: Ubuntu10.04
Posts: 308

Rep: Reputation: 43
Quote:
While moving the file , electricity vanished.
That's a lesson to remember! You can move documents and other small files as much as you like, but for larger files it is safer to copy, as you did experience.
When working in a shell use the cp command.
Nautilus automatically copies files when you drag & drop from one partition to another. If you wish to copy a file within the same partition you can use copy & paste.
 
Old 05-06-2011, 08:58 AM   #3
sumeet inani
Member
 
Registered: Oct 2008
Posts: 908

Original Poster
Blog Entries: 26

Rep: Reputation: 49
isn't there any software that safely moves file i.e remove source only after transfer is 100% i.e what I meant by atomic operation?
teracopy is one of those in windows .
Also such a file copy manager should replace default if needed.
 
Old 05-06-2011, 09:00 AM   #4
MTK358
LQ 5k Club
 
Registered: Sep 2009
Posts: 6,443
Blog Entries: 3

Rep: Reputation: 723Reputation: 723Reputation: 723Reputation: 723Reputation: 723Reputation: 723Reputation: 723
Quote:
Originally Posted by sumeet inani View Post
isn't there any software that safely moves file i.e remove source only after transfer is 100% i.e what I meant by atomic operation?
Yes.

Code:
man cp
man rm
If you don't want to enter the commands separately, it shouldn't be too hard to write a script that combines them both.

Quote:
Originally Posted by sumeet inani View Post
Also such a file copy manager should replace default if needed.
What does that mean?
 
Old 05-06-2011, 09:06 AM   #5
sumeet inani
Member
 
Registered: Oct 2008
Posts: 908

Original Poster
Blog Entries: 26

Rep: Reputation: 49
Actually people mostly use GUI not terminal , otherwise cp & rm is fine.
For instance :- in windows tera copy integrates into explorer so ctrl+x & ctrl+v (as usual) does cut & paste via teracopy so that in case of power failure the file remains safe at either source or destination unlike explorer.
I believe :- in linux , there must be a GUI alternative of teracopy.
 
Old 05-06-2011, 09:16 AM   #6
Sjonnie48
Member
 
Registered: Jun 2005
Location: Earth
Distribution: Ubuntu10.04
Posts: 308

Rep: Reputation: 43
Linux is not Windows.
As said before moving large files is a risky thing to do.

So, better learn to overcome this terrible limitation in Linux and copy as much as you desire.
Or develop a plugin for the file manager that does "teracopy".
 
Old 05-06-2011, 09:24 AM   #7
MTK358
LQ 5k Club
 
Registered: Sep 2009
Posts: 6,443
Blog Entries: 3

Rep: Reputation: 723Reputation: 723Reputation: 723Reputation: 723Reputation: 723Reputation: 723Reputation: 723
Quote:
Originally Posted by sumeet inani View Post
Actually people mostly use GUI not terminal
There are "people" that prefer CLI to GUI. So your statement is false.

You never specifically requested that it has to be GUI. Also, use of the command line in Linux typically isn't considered a bad thing or something to be avoided.

Quote:
For instance :- in windows tera copy integrates into explorer so ctrl+x & ctrl+v (as usual) does cut & paste via teracopy so that in case of power failure the file remains safe at either source or destination unlike explorer.
I believe :- in linux , there must be a GUI alternative of teracopy.
Does it have to integrate into an existing file manager?

I guess it has to, becasue if there was a GUI application that has two entries for source and destination files and a "Copy" button, it would be much less practical and not any easier to use than the command line.

Last edited by MTK358; 05-06-2011 at 09:26 AM.
 
Old 05-06-2011, 09:49 AM   #8
mericet
Member
 
Registered: Jul 2009
Posts: 50

Rep: Reputation: 8
What I think happens when moving files is this:
The actual data on disk is not moved from one physical place to another, merely the index pointing to it is re-written. So in your case it looks like the power failed between deleting the old index and writing the new one. Your file is probably sitting there intact but inaccessible, but for how much longer I can't say, it's probably at risk of being over-written as more file operations take place.
But I'm not an expert on this, don't quote me.
 
Old 05-06-2011, 10:22 AM   #9
sumeet inani
Member
 
Registered: Oct 2008
Posts: 908

Original Poster
Blog Entries: 26

Rep: Reputation: 49
Actually file was transferred from USB to hard disk so it was data transfer unlike inode change had both files been on same partition. i know recovery software named testdisk .
Question remains as it was : is there any alternative file copy manager in linux ?
 
Old 05-06-2011, 10:43 AM   #10
sumeet inani
Member
 
Registered: Oct 2008
Posts: 908

Original Poster
Blog Entries: 26

Rep: Reputation: 49
I found this 'ultracopier' but it does not become system default .
That sums up the situation --> http://mail.gnome.org/archives/nauti.../msg00029.html

How can I add Ultracopier custom menu items to the context menu ?

Last edited by sumeet inani; 05-06-2011 at 10:48 AM.
 
Old 05-06-2011, 10:46 PM   #11
Sjonnie48
Member
 
Registered: Jun 2005
Location: Earth
Distribution: Ubuntu10.04
Posts: 308

Rep: Reputation: 43
Quote:
How can I add Ultracopier custom menu items to the context menu ?
If you have read the news on the Ultracopier website, you also could have read that they are still working on integrating it into Gnome and KDE.
 
Old 05-06-2011, 11:21 PM   #12
jschiwal
LQ Guru
 
Registered: Aug 2001
Location: Fargo, ND
Distribution: SuSE AMD64
Posts: 15,733

Rep: Reputation: 682Reputation: 682Reputation: 682Reputation: 682Reputation: 682Reputation: 682
Move first copies the file and then deletes it when moving files between filesystems.
If the file is being moved to the same filesystem it changes directory entries, and the file on the disk itself doesn't move.

From the mv info manual:
Quote:
It first uses some of the same code that's used by `cp -a'
to copy the requested directories and files, then (assuming the copy
succeeded) it removes the originals. If the copy fails, then the part
that was copied to the destination partition is removed.
What probably happened is that the file was successfully moved, but the filesystem journal wasn't updated, reflecting all the changes.

Last edited by jschiwal; 05-06-2011 at 11:23 PM.
 
Old 05-07-2011, 03:47 AM   #13
sumeet inani
Member
 
Registered: Oct 2008
Posts: 908

Original Poster
Blog Entries: 26

Rep: Reputation: 49
jschiwal , did you mean that file was moved to ntfs partition though it was not updated in file allocation table of hard disk yet file was removed from USB stick.

Quote:
What you could do, with an extension, is adding
Ultracopier custom menu items to the context menu, but you can't assign
keyboard shortcuts to them (see [1]).
That means we can have ultracopier in context menu but not assign keyboard shortcut.
So the question is How do we add item to file context menu & associated command ?
 
  


Reply



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 Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Script to copy paste text from one file to another (overwriting part of the file) freet Programming 4 04-19-2011 03:23 PM
copy last 10000+ lines of large text file to a temporary file emilyg Linux - Newbie 3 06-24-2009 02:43 PM
Clipboard Manager for quickly copy paste saurya_s Linux - Software 1 09-22-2005 09:33 AM
Is arrangement of file systems will differ if we copy a file from FAT 32 to ext 3 ? anindyanuri Linux - Software 2 02-20-2005 11:39 AM
[Gentoo file manager] Install RPM from the file manager? Coume Linux - Software 2 12-10-2003 02:21 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 02:20 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration