LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   file copy manager (https://www.linuxquestions.org/questions/linux-newbie-8/file-copy-manager-879123/)

sumeet inani 05-06-2011 01:42 AM

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?

Sjonnie48 05-06-2011 04:10 AM

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.

sumeet inani 05-06-2011 08:58 AM

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.

MTK358 05-06-2011 09:00 AM

Quote:

Originally Posted by sumeet inani (Post 4348392)
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 (Post 4348392)
Also such a file copy manager should replace default if needed.

What does that mean?

sumeet inani 05-06-2011 09:06 AM

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.

Sjonnie48 05-06-2011 09:16 AM

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".

MTK358 05-06-2011 09:24 AM

Quote:

Originally Posted by sumeet inani (Post 4348400)
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.

mericet 05-06-2011 09:49 AM

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.

sumeet inani 05-06-2011 10:22 AM

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 ?

sumeet inani 05-06-2011 10:43 AM

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 ?

Sjonnie48 05-06-2011 10:46 PM

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.

jschiwal 05-06-2011 11:21 PM

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.

sumeet inani 05-07-2011 03:47 AM

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 ?


All times are GMT -5. The time now is 03:52 PM.