LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Red Hat
User Name
Password
Red Hat This forum is for the discussion of Red Hat Linux.

Notices



Reply
 
Search this Thread
Old 08-04-2009, 10:35 AM   #1
farooqnasim
Member
 
Registered: May 2009
Posts: 30

Rep: Reputation: 15
how to rescue linux with rescue cd


i had a linux RHEL 4.4 box running on a local network. i had to shutdown the system forcefully coz it hanged. when i started it again it gave me the error
/dev/sdd unexpected inconsistency run fsck manually (i.e without -a or -p)
i run the following after giving root password
file#1 fsck /dev/sdd
the mesg i got was
fsck.ext3:attempt to read block from filesystem resulted in short while trying to open /dev/sdd

when i ran it again it gave the same mesg

any how system is not booting

is there any solution to make the system running? if i use installation cd and go to rescue mode, are there any files which i can correct to get the system as i have other systems running on the local network with almost same configuration
any help or suggested link would be appriciated
 
Old 08-04-2009, 01:47 PM   #2
unSpawn
Moderator
 
Registered: May 2001
Posts: 27,743
Blog Entries: 54

Rep: Reputation: 2972Reputation: 2972Reputation: 2972Reputation: 2972Reputation: 2972Reputation: 2972Reputation: 2972Reputation: 2972Reputation: 2972Reputation: 2972Reputation: 2972
Quote:
Originally Posted by farooqnasim View Post
i had a linux RHEL 4.4 box running on a local network. i had to shutdown the system forcefully coz it hanged.
Hanged how? With what errors logged/shown? Shutdown how?


Quote:
Originally Posted by farooqnasim View Post
fsck /dev/sdd
You run fsck on a partition, not a whole disk. List partitions by running 'fdisk -l /dev/sdd' then run fsck on each of them. If they still give "short read" errors try using one of the backup superblocks. Find those by running 'dumpe2fs /dev/partitionname|grep super' or 'mke2fs -vnSF /dev/partitionname'.
 
Old 08-05-2009, 01:58 AM   #3
farooqnasim
Member
 
Registered: May 2009
Posts: 30

Original Poster
Rep: Reputation: 15
when i tried "fdisk -l /dev/sdd" it gives me the following mesg

disk /dev/sdd:500.1 GB 500107862016 bytes 255 heads, 63 sectors/track 60801 cylinders
units=cylinders of 16065*512=8225280 bytes
/dev/sdd doesn't contain a valid parition table

after that i tried
'dumpe2fs /dev/sdd|grep super' i got the this mesg

dumpe2fs 1.35 (date)
dumpe2fs: attempts to read block from filesystem resulted in short read while trying to open /dev/sdd
could not find valid filesystem superblock

and on this
'mke2fs -vnSF /dev/sdd' the mesg was

mke2fs 1.35(date)
Filesystem label=
OS type=Linux
Block size=4096 (log=2)
61063168 inodes, 122096646 blocks
6104832 blocks (5.00%) srserved for super user
First data block=0
Maximum filesystem blocks=125829120
3727 block groups
32768 blocks per group, 32768 fragments per group
16384 inodes per group
superblock backups stored on blocks
32768,98304,163840,229376,294912,819200,
884736,1605632,2654208,4096000,7962624,11239424,
20480000,23887872,71663616,78675968,102400000

------------------
what to do now??????
 
Old 08-05-2009, 06:18 AM   #4
unSpawn
Moderator
 
Registered: May 2001
Posts: 27,743
Blog Entries: 54

Rep: Reputation: 2972Reputation: 2972Reputation: 2972Reputation: 2972Reputation: 2972Reputation: 2972Reputation: 2972Reputation: 2972Reputation: 2972Reputation: 2972Reputation: 2972
I don't know if this is due to any language barrier, if you just read over it or you don't want to, but you didn't answer the shutdown questions. I also told you that you should not run 'fsck' on a disk but on a partition. The same goes for 'dumpe2fs' and 'mke2fs'. If you do not know what a command does then please look it up before you execute it. Do not execute commands blindly: if reading doesn't help answer your questions then ask before executing it. Anyway. Since the partition table is gone you'll have to recover or rewrite it. If you do not have a backup of the drive then it is advisable to make a ('dd') copy before proceeding. Boot the KNOPPIX LiveCD and run 'testdisk /debug /log' on your drive to recover the partition table. Testdisk may indicate a certain partition table layout but you should know how many partitions are on the disk and what filesystem they are formatted with for this to work.
 
Old 08-05-2009, 07:36 AM   #5
farooqnasim
Member
 
Registered: May 2009
Posts: 30

Original Poster
Rep: Reputation: 15
i had read your question about how the system was shutdown but immidiately after that you instructed to run fsck on partitions. basically im jave programmer trying to learn linux so plz dont mind if i ask any silly questins. let me try the way you have told to recover parition table otherwise let you know the situation. i shutdown the system by pressing restart button and it took me to the stage" give root password for maintenance"
 
Old 08-05-2009, 07:52 AM   #6
unSpawn
Moderator
 
Registered: May 2001
Posts: 27,743
Blog Entries: 54

Rep: Reputation: 2972Reputation: 2972Reputation: 2972Reputation: 2972Reputation: 2972Reputation: 2972Reputation: 2972Reputation: 2972Reputation: 2972Reputation: 2972Reputation: 2972
I just put emphasis on things you should not read over lightly. You're not asking "silly" questions, it's just that you are not complete in answering but you can fix that. Note the 'testdisk /debug /log' will leave a log in the current directory so you can read it back and post from (or attach) it if necessary.
 
Old 08-06-2009, 09:07 AM   #7
farooqnasim
Member
 
Registered: May 2009
Posts: 30

Original Poster
Rep: Reputation: 15
I downloaded KNOPPIX and try to boot the system but it didn't work, I had another CD (SysRescureCD) and booted the system with that. Once the system was up, i used fdisk -l, it showed me

/dev/sda doesn't contain valid parition table and didn't show any other disks
i tried fdisk -l /dev/sdb and so on up to d, it gave me the mesage, device is not available
at this point i didn't know where to backup using dd as none of other disks were available(plz note i have 4 disks on the system 3 disks are 500GB SATA, and 1 is 1000GB)

again after restarting the computer and booting from the disk not cd , it took me to the same "root password for maintenance"
there when i try fdisk -l
/dev/sda is ok and showed parition table
for rest (sdb,sdc,sdd) same mesage('doesn't contain valid partition table)
plz advise what to do, i dont want to loose data of the disks

Last edited by farooqnasim; 08-06-2009 at 10:28 AM.
 
Old 08-06-2009, 05:33 PM   #8
unSpawn
Moderator
 
Registered: May 2001
Posts: 27,743
Blog Entries: 54

Rep: Reputation: 2972Reputation: 2972Reputation: 2972Reputation: 2972Reputation: 2972Reputation: 2972Reputation: 2972Reputation: 2972Reputation: 2972Reputation: 2972Reputation: 2972
SysRescueCD comes with testdisk. Is there a reason why you could not run it? And since you have said that you have similar machines it would be good to state how the hardware is configured. Are these 4 separate SATA drives or does it use RAID? If so, is it hardware or software RAID? Does the machine use LVM? Anything else you think would be worth knowing? And rebooting the machine without making changes will not get you past the dreaded "root password for maintenance", however it would allow you to mount one of the other drives and 'dd' a copy of /dev/sda to a file on a partition with enough space on it.
 
Old 08-09-2009, 06:51 AM   #9
farooqnasim
Member
 
Registered: May 2009
Posts: 30

Original Poster
Rep: Reputation: 15
its not raid, all 4 are separate disks, and there is no LVM, what i am doing now is attaching a new disk 1000GB with this system and backup /dev/sda on that new disk, after that i will try to run 'testdisk /debug /log' . one thing is confusing me! when i boot the system with sysrescuecd and use fdisk -l, it shows me
/dev/sda doesn't contain valid parition table and didn't show any other disks
but when i go to "give root password for maintenance" without "sysrescurecd" and do fdisk -l it shows all the disks as i had pointed out earlier. my question is while using "sysrescuecd" why it is not showing all the disks
 
Old 08-09-2009, 07:11 AM   #10
linus72
Guru
 
Registered: Jan 2009
Location: Gordonsville-AKA Mayberry-Virginia
Distribution: PocketWriter/MinimalX
Posts: 5,084

Rep: Reputation: 336Reputation: 336Reputation: 336Reputation: 336
Not sure about that
you got newest sysrescue cd?

Another good choice(s) are GRML full
http://grml.org/

and PMagic 4.4. (testing) has testdisk, dd rescue and more too
http://beefdrapes.partedmagic.com/

the mini pm there is cool too
 
Old 08-10-2009, 08:04 PM   #11
unSpawn
Moderator
 
Registered: May 2001
Posts: 27,743
Blog Entries: 54

Rep: Reputation: 2972Reputation: 2972Reputation: 2972Reputation: 2972Reputation: 2972Reputation: 2972Reputation: 2972Reputation: 2972Reputation: 2972Reputation: 2972Reputation: 2972
Quote:
Originally Posted by farooqnasim View Post
what i am doing now is attaching a new disk 1000GB with this system and backup /dev/sda on that new disk, after that i will try to run 'testdisk /debug /log'
Any progress?
 
Old 08-11-2009, 07:07 AM   #12
farooqnasim
Member
 
Registered: May 2009
Posts: 30

Original Poster
Rep: Reputation: 15
i had to face another problem which needed more attention, could you plz have a look at that and suggest something

http://www.linuxquestions.org/questi...3/#post3637639
 
Old 08-11-2009, 07:24 AM   #13
unSpawn
Moderator
 
Registered: May 2001
Posts: 27,743
Blog Entries: 54

Rep: Reputation: 2972Reputation: 2972Reputation: 2972Reputation: 2972Reputation: 2972Reputation: 2972Reputation: 2972Reputation: 2972Reputation: 2972Reputation: 2972Reputation: 2972
That thread is being dealt with there so you have to be patient for those helping you to return.
 
  


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
Linux Rescue script question, in rescue mode vijay_aras Linux - General 1 01-09-2008 06:03 PM
linux rescue scbops Red Hat 1 04-21-2006 08:26 AM
how to rescue linux vijaysh Linux - Hardware 2 07-05-2004 11:38 PM
linux rescue crcheek Linux - Newbie 1 09-20-2003 11:03 PM
linux rescue and vi shanenin Linux - Software 1 09-13-2003 04:06 PM


All times are GMT -5. The time now is 03:07 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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration