LinuxQuestions.org
Review your favorite Linux distribution.
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 02-10-2008, 06:59 PM   #1
kwikness
Member
 
Registered: Apr 2006
Location: MA
Distribution: Slackware 13
Posts: 67

Rep: Reputation: 15
hda2 not being unmounted properly


Hi I just set up my nix box and i'm having trouble with fsck running on every boot. I get the error message, " /dev/hda2 was not cleanly unmounted..<blah blah blah>"

I'd imagine I could resolve this by sticking in a umount /dev/hda2 into some script file or whatever, but I don't know which one to mess with.
Thanks for any help.

I also tried giving a umount command before I used the shutdown command but it gave me an error message saying that it was busy or something.

Last edited by kwikness; 02-10-2008 at 07:02 PM.
 
Old 02-10-2008, 07:44 PM   #2
snowman81
Member
 
Registered: Aug 2006
Location: Michigan
Distribution: Ubuntu
Posts: 237

Rep: Reputation: 30
Before you shutdown, are you running any applications that are relying upon hda2? Like if you have a music playing app, is it connecting to that drive for the music or anything like that?
 
Old 02-10-2008, 07:58 PM   #3
kwikness
Member
 
Registered: Apr 2006
Location: MA
Distribution: Slackware 13
Posts: 67

Original Poster
Rep: Reputation: 15
Nah i'm not even in X anymore when I shutdown. I log out of x, then at the command prompt, I try unmounting and I get the busy error.
 
Old 02-10-2008, 08:27 PM   #4
gilead
Senior Member
 
Registered: Dec 2005
Location: Brisbane, Australia
Distribution: Slackware64 14.0
Posts: 4,125

Rep: Reputation: 164Reputation: 164
Can you try running lsof /dev/hda2 just prior to shutting down the box to see what is still open?
 
Old 02-10-2008, 08:49 PM   #5
jailbait
LQ Guru
 
Registered: Feb 2003
Location: Blue Ridge Mountain
Distribution: Debian Jessie, Linux Mint 17
Posts: 7,750

Rep: Reputation: 271Reputation: 271Reputation: 271
Could you post the contents of your fstab file, /etc/fstab?

What distribution are you using?

-----------------------
Steve Stites
 
Old 02-12-2008, 02:49 AM   #6
kwikness
Member
 
Registered: Apr 2006
Location: MA
Distribution: Slackware 13
Posts: 67

Original Poster
Rep: Reputation: 15
Contents of Fstab:
/dev/hda2 / auto defaults 1 1
aufs / aufs defaults 0 0 # AutoUpdate
devpts /dev/pts devpts gid=5,mode=620 0 0 # AutoUpdate
proc /proc proc defaults 0 0 # AutoUpdate
sysfs /sys sysfs defaults 0 0 # AutoUpdate
/dev/hdb /mnt/hdb iso9660 noauto,users,exec 0 0 # AutoUpdate
/dev/hda1 /mnt/hda1 ntfs-3g auto,noatime,users,suid,dev,exec,locale= 0 0 # AutoUpdate
/dev/hda3 /mnt/hda3 swap auto,defaults 0 0 # AutoUpdate
/dev/fd0 /mnt/floppy vfat noauto,noatime,users,suid,dev,exec 0 0 # AutoUpdate


When I try typing lsof /dev/hda2 before shutting down, the cursor blinks down but nothing prints out.

During shutdown it looks like its trying to auto unmount hda2, but it gets a busy error.

Last edited by kwikness; 02-12-2008 at 02:52 AM.
 
Old 02-12-2008, 11:32 PM   #7
kwikness
Member
 
Registered: Apr 2006
Location: MA
Distribution: Slackware 13
Posts: 67

Original Poster
Rep: Reputation: 15
*bump* Anyone?
 
Old 02-12-2008, 11:55 PM   #8
gilead
Senior Member
 
Registered: Dec 2005
Location: Brisbane, Australia
Distribution: Slackware64 14.0
Posts: 4,125

Rep: Reputation: 164Reputation: 164
There's nothing obviously wrong with what is shown there. Have you tried manually shutting down daemons and seeing if any of them hang? Can you use telinit 1 to change to single user mode successfully? If that works does the shutdown from there work properly?
 
Old 02-13-2008, 04:05 AM   #9
roy_lt_69
Member
 
Registered: Aug 2006
Location: Vancouver, BC, Canada
Distribution: Slackware, Bodhi, Mint-xfce
Posts: 182

Rep: Reputation: 21
I don't think you can manually unmount /dev/hda2 as it is your root partition (according to your fstab)!

That error message:
Quote:
/dev/hda2 was not cleanly unmounted..<blah blah blah>"
indicates that your previous Linux boot was not properly shutdown, and that the system will run a fsck on it to check for errors/corruptions in its file structure.
Some distro's prompt for a Y/N to run the fsck!
If the fsck is not run, Linux may or may not prompt again on the next boot.

You should probably let the fsck run as it is a check for corruption in the fs stucture.

If the system is repeatedly displaying the error message even after running the fsck, then you may have to boot from a Live-CD and run fsck on /dev/hda2 (easiest path), else try to fix the boot script that run fsck (more work).
You cannot run fsck on the root partition when it is in use (which will be the case if you boot from the hard drive) as it cannot run against a mounted partition (or r/w one anyways)!
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
C: is /mnt/hda2 Where is D: ? pppaaarrrkkk Linux - Newbie 1 08-28-2007 07:56 AM
hda2 went to hdb2 aral SUSE / openSUSE 21 08-13-2005 10:34 AM
System won't boot properly knoppix doesn't initialize properly rodewan Linux - Software 0 01-23-2005 04:35 PM
Can't mount hda2 thundersnows Slackware 7 09-09-2003 11:50 PM
Installation, hda2 digiview65 Linux - Software 1 06-24-2001 02:15 AM


All times are GMT -5. The time now is 06:37 PM.

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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration