Re: removing large file

From: Mac Mason <mac@cs.hmc.edu>
Date: Wed Mar 22 2006 - 17:36:38 AKST

On Wed, Mar 22, 2006 at 05:35:14PM -0800, Kurt Brendgard wrote:
> It almost sounds as if the system needs more ram to
> keep track of what sectors need to be dealt with,
> maybe try add a stick long enough to delete it? Or
> maybe if you have a real memory hog of an app running,
> try turning ot off while deleting. Linux is better
> than Windows with using smaller amounts of ram, but
> there is only so much that can be expected.
I'm no filesystems guru, but I really doubt it takes much ram at all
to delete a file. It's just a tree traversal, right? Even with a
collossal filesystem (=> large tree elements), that shouldn't be too
hard. Shouldn't be any more memory-intensive than writing the file to
disk the first time, and that worked, right?

In the worst case, you'll just hit swap space; if you're truly out of
ram, that's a kernel panic, not a segfault (unless rm was written by
morons, but it wasn't).

If you feel like it, it could be fun to figure out where rm is
segfaulting; attach a debugger and go to town.

> If the box has enough ram, it's also possible that the
> memory and/or mb are getting flakey, trying to access
> ram in a spot where it's starting to flake out. Might
> try swapping out with some new ram stick to see if
> that works.

Better yet, run memtest86. My favorite way to do this is to download a
Knoppix CD and use that. It'll also provide an easy way to fsck your
filesystems. Bad ram could easily cause your problem.
 
> If you can't get it deleted any other way, there is a
> last resort trick to try. Try copying a much smaller
> file over the top of it, or opening it up to write,
> overwriting whats there, and write very little. makes
> the memory requirments smaller in deleting it. Last
> resort though, if something goes wrong, it could make
> it much worse.

Or, mount the filesystem from Knoppix and delete the file from there.

Or (last last ditch) back up everything else, burn it down, and
restore from backups. But there's no way this is necessary.

    --Mac

-- 
Julian "Mac" Mason                            mac@cs.hmc.edu
Computer Science '06                          (310)-882-8068
Harvey Mudd College
-- Attached file included as plaintext by Ecartis --
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.2.2 (FreeBSD)
iD8DBQFEIgmz1AphoTGXiN0RAiPpAJ48mycOSZ17fBwxYQWj7xyRterHwgCdGHh2
oB8xfmZtWvBopAqJ6zVlWic=
=Q3Y4
-----END PGP SIGNATURE-----
---------
To unsubscribe, send email to <aklug-request@aklug.org>
with 'unsubscribe' in the message body.
Received on Wed Mar 22 17:36:46 2006

This archive was generated by hypermail 2.1.8 : Wed Mar 22 2006 - 17:36:46 AKST