FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > Gentoo > Gentoo User

 
 
LinkBack Thread Tools
 
Old 06-07-2010, 07:54 PM
Mick
 
Default /var/tmp/portage not empty?

I am trying to clean up what seems like a remnant of a failed emerge, but I
can delete the directory in question:

# rm -Rf /var/tmp/portage/sys-devel/gcc-4.4.3-
r2/work/gcc-4.4.3/libjava/classpath/resource/gnu/java/locale
rm: cannot remove `/var/tmp/portage/sys-devel/gcc-4.4.3-
r2/work/gcc-4.4.3/libjava/classpath/resource/gnu/java/locale': Directory not
empty

Am I missing something simple here? Why can't I remove it? It seems empty to
me:

# ls -la /var/tmp/portage/sys-devel/gcc-4.4.3-
r2/work/gcc-4.4.3/libjava/classpath/resource/gnu/java/locale
total 1
drwxr-xr-x 2 portage portage 3 May 28 07:48 .
drwxr-xr-x 3 portage portage 3 May 28 07:48 ..
--
Regards,
Mick
 
Old 06-07-2010, 08:08 PM
Neil Bothwick
 
Default /var/tmp/portage not empty?

On Mon, 7 Jun 2010 20:54:36 +0100, Mick wrote:

> # rm -Rf /var/tmp/portage/sys-devel/gcc-4.4.3-
> r2/work/gcc-4.4.3/libjava/classpath/resource/gnu/java/locale
> rm: cannot remove `/var/tmp/portage/sys-devel/gcc-4.4.3-
> r2/work/gcc-4.4.3/libjava/classpath/resource/gnu/java/locale':
> Directory not empty
>
> Am I missing something simple here? Why can't I remove it? It seems
> empty to me:

Filesystem corruption?


--
Neil Bothwick

Three kinds of people: Those who can count, and those who can't.
 
Old 06-07-2010, 08:24 PM
Dale
 
Default /var/tmp/portage not empty?

Mick wrote:

I am trying to clean up what seems like a remnant of a failed emerge, but I
can delete the directory in question:

# rm -Rf /var/tmp/portage/sys-devel/gcc-4.4.3-
r2/work/gcc-4.4.3/libjava/classpath/resource/gnu/java/locale
rm: cannot remove `/var/tmp/portage/sys-devel/gcc-4.4.3-
r2/work/gcc-4.4.3/libjava/classpath/resource/gnu/java/locale': Directory not
empty

Am I missing something simple here? Why can't I remove it? It seems empty to
me:

# ls -la /var/tmp/portage/sys-devel/gcc-4.4.3-
r2/work/gcc-4.4.3/libjava/classpath/resource/gnu/java/locale
total 1
drwxr-xr-x 2 portage portage 3 May 28 07:48 .
drwxr-xr-x 3 portage portage 3 May 28 07:48 ..



I generally use rm -rfv when I delete something and do it as root as
well. It is gone after that. I'm not sure what the difference is
between R and r tho. I need to go check the man page I guess. ;-)


Dale

:-) :-)
 
Old 06-07-2010, 09:45 PM
Mick
 
Default /var/tmp/portage not empty?

On Monday 07 June 2010 21:24:37 Dale wrote:
> Mick wrote:
> > I am trying to clean up what seems like a remnant of a failed emerge, but
> > I can delete the directory in question:
> >
> > # rm -Rf /var/tmp/portage/sys-devel/gcc-4.4.3-
> > r2/work/gcc-4.4.3/libjava/classpath/resource/gnu/java/locale
> > rm: cannot remove `/var/tmp/portage/sys-devel/gcc-4.4.3-
> > r2/work/gcc-4.4.3/libjava/classpath/resource/gnu/java/locale': Directory
> > not empty
> >
> > Am I missing something simple here? Why can't I remove it? It seems
> > empty to me:
> >
> > # ls -la /var/tmp/portage/sys-devel/gcc-4.4.3-
> > r2/work/gcc-4.4.3/libjava/classpath/resource/gnu/java/locale
> > total 1
> > drwxr-xr-x 2 portage portage 3 May 28 07:48 .
> > drwxr-xr-x 3 portage portage 3 May 28 07:48 ..
>
> I generally use rm -rfv when I delete something and do it as root as
> well. It is gone after that. I'm not sure what the difference is
> between R and r tho. I need to go check the man page I guess. ;-)
>
> Dale
>
> :-) :-)
>
-r, -R, --recursive
remove directories and their contents recursively

I am getting worried now about fs corruption. The fs is supposed to be
checked at boot time ....
--
Regards,
Mick
 
Old 06-07-2010, 09:46 PM
Alan McKinnon
 
Default /var/tmp/portage not empty?

On Monday 07 June 2010 22:24:37 Dale wrote:
> Mick wrote:
> > I am trying to clean up what seems like a remnant of a failed emerge, but
> > I can delete the directory in question:
> >
> > # rm -Rf /var/tmp/portage/sys-devel/gcc-4.4.3-
> > r2/work/gcc-4.4.3/libjava/classpath/resource/gnu/java/locale
> > rm: cannot remove `/var/tmp/portage/sys-devel/gcc-4.4.3-
> > r2/work/gcc-4.4.3/libjava/classpath/resource/gnu/java/locale': Directory
> > not empty
> >
> > Am I missing something simple here? Why can't I remove it? It seems
> > empty to me:
> >
> > # ls -la /var/tmp/portage/sys-devel/gcc-4.4.3-
> > r2/work/gcc-4.4.3/libjava/classpath/resource/gnu/java/locale
> > total 1
> > drwxr-xr-x 2 portage portage 3 May 28 07:48 .
> > drwxr-xr-x 3 portage portage 3 May 28 07:48 ..
>
> I generally use rm -rfv when I delete something and do it as root as
> well. It is gone after that. I'm not sure what the difference is
> between R and r tho. I need to go check the man page I guess. ;-)

The "#" in his quoted prompt implies that he is doing it as root.

the -r -R and --recursive switches to rm are all synonymous.

Neil is likely correct - filesystem corruption. A quick easy way to check is
to run ls -al starting with the target then going up on directory in turn. If
you start getting lots of "???" in the output, corruption is almost certain.



--
alan dot mckinnon at gmail dot com
 
Old 06-07-2010, 10:12 PM
Paul Hartman
 
Default /var/tmp/portage not empty?

On Mon, Jun 7, 2010 at 2:54 PM, Mick <michaelkintzios@gmail.com> wrote:
> I am trying to clean up what seems like a remnant of a failed emerge, but I
> can delete the directory in question:

Maybe try lsof to see if anything is using one of those directories
 
Old 06-07-2010, 10:13 PM
Alex Schuster
 
Default /var/tmp/portage not empty?

Mick writes:

> I am getting worried now about fs corruption.

I would be, too.

> The fs is supposed to be checked at boot time ....

But only if it was not shut down correctly. To force a complete fsck on
reboot on a file system that looks sane, issue a 'touch /force_fsck'.

Wonko
 
Old 06-07-2010, 10:31 PM
Neil Bothwick
 
Default /var/tmp/portage not empty?

On Mon, 7 Jun 2010 22:45:57 +0100, Mick wrote:

> I am getting worried now about fs corruption. The fs is supposed to be
> checked at boot time ....

Only if it's marked unclean. extN filesystems are only checked every so
many mounts or days. Run fsck with the --force option to force a proper
check.


--
Neil Bothwick

Picard: 'What do the sensors say Mr Data?'
Data: 'They tell us that we can't say "F*ck" Sir."
Picard: 'I meant the ship's sensors Mr Data'
 
Old 06-07-2010, 10:46 PM
Dale
 
Default /var/tmp/portage not empty?

Mick wrote:

On Monday 07 June 2010 21:24:37 Dale wrote:


Mick wrote:


I am trying to clean up what seems like a remnant of a failed emerge, but
I can delete the directory in question:

# rm -Rf /var/tmp/portage/sys-devel/gcc-4.4.3-
r2/work/gcc-4.4.3/libjava/classpath/resource/gnu/java/locale
rm: cannot remove `/var/tmp/portage/sys-devel/gcc-4.4.3-
r2/work/gcc-4.4.3/libjava/classpath/resource/gnu/java/locale': Directory
not empty

Am I missing something simple here? Why can't I remove it? It seems
empty to me:

# ls -la /var/tmp/portage/sys-devel/gcc-4.4.3-
r2/work/gcc-4.4.3/libjava/classpath/resource/gnu/java/locale
total 1
drwxr-xr-x 2 portage portage 3 May 28 07:48 .
drwxr-xr-x 3 portage portage 3 May 28 07:48 ..


I generally use rm -rfv when I delete something and do it as root as
well. It is gone after that. I'm not sure what the difference is
between R and r tho. I need to go check the man page I guess. ;-)

Dale

:-) :-)



-r, -R, --recursive
remove directories and their contents recursively

I am getting worried now about fs corruption. The fs is supposed to be
checked at boot time ....



Since you were using the -f option, I would be to. Something odd
somewhere. Could there be a lock file in there or something? I would
think the -f option would over ride that to tho.


Try to umount it and see if it complains about something. I would be in
single user to do that tho. Just in case.


Dale

:-) :-)
 
Old 06-08-2010, 09:47 AM
Neil Bothwick
 
Default /var/tmp/portage not empty?

On Mon, 7 Jun 2010 23:46:19 +0200, Alan McKinnon wrote:

> Neil is likely correct - filesystem corruption. A quick easy way to
> check is to run ls -al starting with the target then going up on
> directory in turn. If you start getting lots of "???" in the output,
> corruption is almost certain.

Paul's suggestion of running lsof may be valid too. If a process had a
lock n a file that was then deleted, the file wouldn't show up in ls but
would prevent the directory being deleted until the lock was released.

If you don't want to mess around with lsof and tracking down the process,
a reboot will solve that one.


--
Neil Bothwick

If at first you don't succeed, call in an airstrike.
 

Thread Tools




All times are GMT. The time now is 09:13 PM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright 2007 - 2008, www.linux-archive.org