LinuxQuestions.org
Register a domain and help support LQ
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Mandriva
User Name
Password
Mandriva This Forum is for the discussion of Mandriva (Mandrake) Linux.

Notices

Reply
 
Search this Thread
Old 08-01-2012, 06:18 PM   #1
irajjs
Member
 
Registered: Jan 2010
Location: Tehran , Iran
Distribution: Mandriva 2012
Posts: 161
Blog Entries: 1

Rep: Reputation: 15
Unhappy what should be done in emergency mode? and why...?


Recently i noticed that a misconfiguration of my flash memory which is a removable device and pulling out the mounted device without unmounting that causes falling into emergency mode at next boot time or causes a system crash while working!this made me to reinstall the OS at first but then when i discovered the reason and inserted the device problem was solved after rebooting!
My question is that why is that so? and what should be done when unexpectedly system crashes without any explanation or warning!? and what are the maintenance steps?
Thank you
 
Old 08-01-2012, 07:48 PM   #2
frankbell
Guru
 
Registered: Jan 2006
Location: Virginia, USA
Distribution: Slackware, Mageia, Mint
Posts: 7,965

Rep: Reputation: 1507Reputation: 1507Reputation: 1507Reputation: 1507Reputation: 1507Reputation: 1507Reputation: 1507Reputation: 1507Reputation: 1507Reputation: 1507Reputation: 1507
Many questions, no answers.

What distro/version of Linux and what type of flash device? What error messages, if any, did you see on the screen? How was the memory of the flash device "misconfigured" and how did that manifest itself?

You could check the logs. The most likely place you'd find something is /var/log/messages, but, if the crash was sudden, there's a chance the system didn't get the opportunity to log anything.
 
Old 08-02-2012, 08:18 PM   #3
irajjs
Member
 
Registered: Jan 2010
Location: Tehran , Iran
Distribution: Mandriva 2012
Posts: 161
Blog Entries: 1

Original Poster
Rep: Reputation: 15
Unhappy answers

Quote:
Originally Posted by frankbell View Post
Many questions, no answers.

What distro/version of Linux and what type of flash device? What error messages, if any, did you see on the screen? How was the memory of the flash device "misconfigured" and how did that manifest itself?

You could check the logs. The most likely place you'd find something is /var/log/messages, but, if the crash was sudden, there's a chance the system didn't get the opportunity to log anything.
Hi
1-Recently i was using Mandriva2011 and now i am using Mandriva2012.
2-Flash device's name is:
"Kingston DataTraveler 2.0"
3-The error messages have a long story! now i have to ...
some years ago i bought this flash memory to be able to transfer the Cafe-Net downloaded files to my computer because at that time i had no access to internet at home...
another reason for using flash memory was my cdrom problems....http://www.linuxquestions.org/questi...ml#post4732392
at that time i was using both Windows and Linux on my PC
after some time one of my operating systems(i do not remember which one!) informed me that this device shows some suspicious activity! then recommended to make a new entry for that..and i did and changed the original name to kinge ...it was working until next errors and disorders that prevented the mounting of device...then i formatted that device several times during the next months using other public computers which in some cases the result was a success ..
then i decided to not to use Windows anymore but because of my modem problem(my other post!) and no internet access at home i had to use this device again more and more..
Recently while upgrading to Mandriva2011 and Mandriva2012 afterwards , this device caused more problems:
-I could not mount that easily!
-the kinge entry was not mountable and the default name was returned again automatically! also a partition made automatically and labelled automatically
-system notification showed two names for one device! one of which was not mountable(did not exist message)
-sometimes the device could not be unmounted ..an error message saying that: ...can not unmount because one or more files are open in an application!!...i could not find that application...and in some cases there was no files in that!
so . i had to pull out the device without unmounting that!!
after restart system crashed and entered to emergency state..the first time i had to reinstall the OS but the next time i did a lot and found that pulling the device out had caused that so inserted the device again and restarted this time boot succeeded!
At last i could unmount the device and now i do not dare to attach that device to PC anymore!
This was the emergency state messages:
Quote:
...........
recovering journal ok
...
home started...
...
Dependency failed.Aborted start of /media/sdc1
Dependency failed.Aborted start of setup links in /boot for running kernel
Dependency failed.Aborted start of relabel all file systems if necessary
Welcome to emergency mode......
give root password..type "systemctl Default"or ^D.....type ctrl+D to continue
Regards

Last edited by irajjs; 08-02-2012 at 08:34 PM. Reason: correcting the link insertion
 
Old 08-02-2012, 08:59 PM   #4
frankbell
Guru
 
Registered: Jan 2006
Location: Virginia, USA
Distribution: Slackware, Mageia, Mint
Posts: 7,965

Rep: Reputation: 1507Reputation: 1507Reputation: 1507Reputation: 1507Reputation: 1507Reputation: 1507Reputation: 1507Reputation: 1507Reputation: 1507Reputation: 1507Reputation: 1507
So, if I understand your post correctly, it looks as if something on that flash device is hooked into the OS, causing the problem when you remove the drive, but you are not aware having any files on the flash drive open, say in a media player or text editor. Am I summarizing this accurately?

Can you shutdown the computer, remove the device, then restart the computer without the flash drive connected?

If so, you can use the ps command (ps -A, -A for list all) to display a list of processes.

Do this before you insert the drive, then again after you mount it.

When you go to unmount the drive, if you get the same error, that same command can help you figure out what process is hooked into the flash drive. I fear you'll have to do a bit of detective work to finger the culprit.

There are ways to manipulate the output of ps to make it easier to use and to save it in text files. This article describes them better than I can.

I particularly recommend the part about how to save the output to a file, since you can do that and then consult and compare the files later.

You might also run an fsck on the drive before mounting it. Can't hurt, might help.

I hope this helps.

I think there might be more going on here, but one step at a time.
 
Old 08-06-2012, 06:18 PM   #5
irajjs
Member
 
Registered: Jan 2010
Location: Tehran , Iran
Distribution: Mandriva 2012
Posts: 161
Blog Entries: 1

Original Poster
Rep: Reputation: 15
The device is successfully unmounted and removed

Quote:
Originally Posted by frankbell View Post
So, if I understand your post correctly, it looks as if something on that flash device is hooked into the OS, causing the problem when you remove the drive, but you are not aware having any files on the flash drive open, say in a media player or text editor. Am I summarizing this accurately?

Can you shutdown the computer, remove the device, then restart the computer without the flash drive connected?

If so, you can use the ps command (ps -A, -A for list all) to display a list of processes.

Do this before you insert the drive, then again after you mount it.

When you go to unmount the drive, if you get the same error, that same command can help you figure out what process is hooked into the flash drive. I fear you'll have to do a bit of detective work to finger the culprit.

There are ways to manipulate the output of ps to make it easier to use and to save it in text files. This article describes them better than I can.

I particularly recommend the part about how to save the output to a file, since you can do that and then consult and compare the files later.

You might also run an fsck on the drive before mounting it. Can't hurt, might help.

I hope this helps.

I think there might be more going on here, but one step at a time.
Hi
As i said in my previous post the device was unmounted i could do that because there was a chance when there was no file open in any application!!
I did the
Code:
# ps -A
command as you see in my other post about "unknown process" ...and i will do the procedure as you said later
Right now i wanted to say that the device is successfully removed and there is no problem about that...just i do not dare to insert that again! specially because my system now is working better than ever in the past and a lot of new installed applications which i am afraid to lose them
I will post the final results later
Regards
 
Old 08-06-2012, 08:32 PM   #6
frankbell
Guru
 
Registered: Jan 2006
Location: Virginia, USA
Distribution: Slackware, Mageia, Mint
Posts: 7,965

Rep: Reputation: 1507Reputation: 1507Reputation: 1507Reputation: 1507Reputation: 1507Reputation: 1507Reputation: 1507Reputation: 1507Reputation: 1507Reputation: 1507Reputation: 1507
If you are hesitant to test it with your working system, why not try testing it with a Live CD?
 
Old 08-07-2012, 10:19 AM   #7
irajjs
Member
 
Registered: Jan 2010
Location: Tehran , Iran
Distribution: Mandriva 2012
Posts: 161
Blog Entries: 1

Original Poster
Rep: Reputation: 15
Smile Live CD worked very slow...near to stop!

Quote:
Originally Posted by frankbell View Post
If you are hesitant to test it with your working system, why not try testing it with a Live CD?
Hi
I used live CD few times when i had installed Mandriva2011 but that worked very slow and as progressed more it became slower! maybe because i had set permissions for home folder and especially sub-folders
That live CD was inside the downloaded OS package from Mandriva site.
thank you
 
  


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
Booting into Emergency mode manyrootsofallevil Red Hat 12 07-10-2013 06:46 PM
Unable to Access to Single User Mode or Emergency Mode Pinglu Linux - Newbie 3 10-17-2011 01:25 PM
[SOLVED] boot emergency mode trucall Red Hat 1 03-10-2011 04:08 PM
Emergency mode can mount the HDD with FS error but not in rescue or single user-mode kayod_jj Linux - Newbie 3 12-01-2010 07:03 PM
why password in emergency mode? linuxguy99 Red Hat 8 02-18-2007 01:18 PM


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

Main Menu
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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration