LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 10-27-2014, 04:39 PM   #1
camorri
LQ 5k Club
 
Registered: Nov 2002
Location: Somewhere inside 9.9 million sq. km. Canada
Distribution: Slackware 15.0, current, slackware-arm-currnet
Posts: 6,233

Rep: Reputation: 860Reputation: 860Reputation: 860Reputation: 860Reputation: 860Reputation: 860Reputation: 860
Can't remove huge directory in /home/user or run fsck


Slackware 14.1, 32 bit system on a netbook.

I have a directory in my /home/user that shows a dir size of 166,780,928. If I try and do anything with it, the disk light goes solid on, and the system becomes unresponsive.

I was doing some updates from Sbopkg when the system locked up. I suspect some junk got written to home.

I went to init 1 and tried to umount /dev/sda6 which is /home/user. The system reports it as busy. I can not figure out what has it busy.

Managed to boot the system off a slack install usb stick. Ran fsck /dev/sda6 -t ext4, and the system reports the file system is good.

I want to run fsck on sda6.

How can I either find out why its busy?

Is there some way I can run fsck? This system does not have a CD or DVD drive, so I can not boot a live system from there.

Suggestions on how to check sda6? FWIW the HD has sda1 as /, sda5 is swap, and sda6 is /home. No other disks in the system.

I booted the system with a slack install USB stick. Got a root command prompt.

I mounted /dev/sda6, was able to change into the directory in question. Did a ls -l, and it lists a ton of files with obscure file names. Between each file name are lines of '\ \ \ \ \ \ '

I ran rm * and rm *.* . Did another ls -l, and still file names appear separated by the back slashes.

Your thoughts?

Last edited by camorri; 10-27-2014 at 06:16 PM. Reason: Added info
 
Old 10-27-2014, 04:47 PM   #2
moisespedro
Senior Member
 
Registered: Nov 2013
Location: Brazil
Distribution: Slackware
Posts: 1,223

Rep: Reputation: 195Reputation: 195
Have you tried lsof? To see what is keeping the device busy

Something like:

Code:
lsof /home/user
Or maybe

Code:
lsof +D /home/user
 
Old 10-27-2014, 04:50 PM   #3
Didier Spaier
LQ Addict
 
Registered: Nov 2008
Location: Paris, France
Distribution: Slint64-15.0
Posts: 11,063

Rep: Reputation: Disabled
If you can reboot, comment the line with /dev/sda6 in /etc/fstab, then reboot at runlevel 3, login as root, run fsck on /dev/sda6.
 
Old 10-27-2014, 06:29 PM   #4
Richard Cranium
Senior Member
 
Registered: Apr 2009
Location: McKinney, Texas
Distribution: Slackware64 15.0
Posts: 3,858

Rep: Reputation: 2225Reputation: 2225Reputation: 2225Reputation: 2225Reputation: 2225Reputation: 2225Reputation: 2225Reputation: 2225Reputation: 2225Reputation: 2225Reputation: 2225
Did you login originally as a non-root user and then "su - root" or similar? If you had, that original login was the thing keeping the partition busy.
 
Old 10-27-2014, 07:07 PM   #5
camorri
LQ 5k Club
 
Registered: Nov 2002
Location: Somewhere inside 9.9 million sq. km. Canada
Distribution: Slackware 15.0, current, slackware-arm-currnet
Posts: 6,233

Original Poster
Rep: Reputation: 860Reputation: 860Reputation: 860Reputation: 860Reputation: 860Reputation: 860Reputation: 860
OK. Since my first post and update, I have made progress.

Quote:
Have you tried lsof?
I did, but not with the /home/user or +D. Got a large list mt limited ability could not make sense of.

Quote:
If you can reboot, comment the line with /dev/sda6 in /etc/fstab, then reboot at runlevel 3, login as root, run fsck on /dev/sda6.
Great idea, never thought of that. After I booted with the USB stick I did run fsck on sda6. It reported no problems.

Quote:
Did you login originally as a non-root user and then "su - root" or similar?
Yes I had, I was trying to update some packages from Sbo when the system locked up.

So, after booting from USB, as root I mounted /dev/sda6 and changed to the directory in question. As I posted on my first post, I saw I had files starting with random numbers and letters. I did a long series of 'rm 1*' to 9*, then A* to Z* and finally a* to z*. The files were removed, what ever they were. I was then able to rmdir the dir in question.

On reboot off the hdd, the system complained the date and time were wrong. They were way off in the bios. I set them correctly. I adding this post from the netbook. I'll do some more testing tomorrow. All seems well now.

Thank-you to those who responded.
 
  


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
Unable to run another command from within shell script, when run from home directory blackray1 Linux - Newbie 7 07-01-2013 09:42 AM
issues with fsck at boot - remove user response requirements natosaichek Linux - Server 5 04-04-2012 05:11 AM
User does int getting home directory in root home in ubuntu 10.04 lucid lynx sunrised24 Linux - Server 2 03-07-2012 09:21 AM
[SOLVED] unable to remove user home directory daisychick Linux - Newbie 8 11-15-2011 11:13 PM
fsck or equivalent for my encrypted home directory cantab Ubuntu 2 09-20-2010 01:41 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 01:44 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