LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Programming (https://www.linuxquestions.org/questions/programming-9/)
-   -   boot sector is lost ! (https://www.linuxquestions.org/questions/programming-9/boot-sector-is-lost-4175495876/)

engkemo2002 02-22-2014 03:11 PM

boot sector is lost !
 
Hi All,

I need your help please regarding the following problem :
I was about to install Linux Suse10 on a HP machine, and sombody adviced me to delete the boot sector by running this command : "dd if=/dev/zero of=/dev/cciss/c1d0 bs=1024 count=1000" while beening on rescue system from live DC.
I think it was a big mistake, as just after running this command systel is not booting anymore and just displaying the following error message " no botable drive in table ...".
What I need now is to recrate again this boot sector and enable a normal boot on HDD again. (kowing that hard disk has been repalced just before this problem).

Thank you in advance.
engkemo.

PTrenholme 02-22-2014 07:58 PM

The command you ran overwrote the first 1000 sectors of your disk with zeros. This destroyed more than your boot sector. It also wiped out much, if not all, of your partition table. So, basically, if you had anything on the disk, it's no longer there. (I hope that you can inflict some just retribution on whomever it was that suggested that you do this.)

Hopefully you had nothing you wanted on that drive. :)

Typically, HP systems are shipped with a Windows operating system installed, and a separate "rescue" system. The "rescue" system is, I believe, at the high-address end of the drive, and the NT file system keeps a copy of the file layout in that area. But, without the partition table, it would be difficult to access either of those.)

If you would be satisfied to have only SUSE 10 on the drive, just install it from the DVD and let it use the whole drive. (Note that the current version of SUSE is OpenSUsE 11.1, available for download here.)

If you were intending to set up a dual-boot system with whatever was already on your hard drive, and need to recover that, let us know. But it may not be possible to do a full recovery.

metaschima 02-22-2014 08:13 PM

If you are able to restore the partition table using testdisk, then you can re-install grub or whatever bootloader you use. However, this may not be likely.

Whoever told you to wipe the MBR and also told you to wipe much more than 512 bytes probably did not mean well.

syg00 02-22-2014 08:30 PM

OpenSUSE is actually at 13.1 - see here. Of course the OP may be talking about SLE[SD].

michaelk 02-22-2014 08:33 PM

Welcome to LinuxQuestions

So the question is what are you trying to accomplish. If you knew you were going to erase the master boot record then you would expect it not to boot. Are you trying to install SuSE as the sole operating system or a dual boot?

The MBR and partition table are the first 512 bytes assuming it isn't gpt. The command actually overwrote the first 1Mb of the drive. Without knowing how the drive was partition we can not say what data was lost.

engkemo2002 02-23-2014 10:32 AM

Many Thanks to all of you for your answers.

In fact, All what I need is to only restore the boot secotr (I think it should be "/dev/cciss/c1d0"), in order to enable machine (HP proliant server) to boot normally with future restarts.
no worries about data as this disk is a new one that replaced a faulty one, so it was allready empty.
I have live CD for Suse10 (must install this one).
what do you suggest me just to install the system (with correct boot sector mapping...).
if need to install GRUB or MBR, is doable via the system CD that I have ? how?

Thanks
engkemo

michaelk 02-23-2014 10:46 AM

A new disk is typically blank so it will not be bootable until you actually load an operating system. All you need to to do is install SuSE and select grub to be installed to the MBR.

engkemo2002 02-23-2014 10:55 AM

Have to mention that its not a dual-systems platform, only suse 10 need to beinstalled here...

engkemo2002 02-23-2014 11:04 AM

installation allready done
 
Quote:

Originally Posted by michaelk (Post 5123259)
A new disk is typically blank so it will not be bootable until you actually load an operating system. All you need to to do is install SuSE and select grub to be installed to the MBR.

Thanks ,
But I tried allready a new installation and problem still persisting, when I try to boot from disk after installation
got the error : "no bootable drive found on table ....."

install system it again ?
no need to modify /boot/grub/menu.lst manually via rescue system for exmaple ?

Rgds,
engkemo

metaschima 02-23-2014 11:20 AM

Install the bootloader again.

engkemo2002 02-23-2014 12:37 PM

GRUB Installation
 
1 Attachment(s)
Quote:

Originally Posted by metaschima (Post 5123276)
Install the bootloader again.

Ok Thanks,
Install bootloader you mean "GRUB", could you please tell me how to do it for SuSe10? (I mean please provide detailed procedure)
here are the options that I have from CD : (please see attached snap shot).

Thanks again for your answer.

Rgds,
engkemo.

metaschima 02-23-2014 01:30 PM

See the bootloader section:
http://www.dedoimedo.com/computers/o...e-install.html
Install the bootloader (GRUB) to MBR.

engkemo2002 02-23-2014 01:55 PM

Thanks will try it by tomorrow and keep you informed.

Smokey_justme 02-23-2014 02:10 PM

Hello engkemo,

So, just to clarify, you went somewhere else and described this problem and you we're given a command to wipe the boot sector. If that is the case (and you've mentioned there that your disk is new) then please rest assure that it wasn't a really bad advice. I'm guessing that there we're no errors thrown when you did that, right? If there was one it's important to mention it here.

Now, back to your problem..
First, ensure that when installing Suse you select to install GRUB (the bootloader) on the MBR (Master Boot Record).
If afterwards, this doesn't work then your problem might go deeper. Your computer might actually not be configured to boot from SCSI (/dev/cciss/* is a SCSI that if I'm not mistaken). You should options in BIOS or a special SCSI menu for that.

Smokey_justme 02-23-2014 02:14 PM

Btw, I found this: http://nozell.com/blog/2004/05/08/so...oliant-server/
I think it describes your problem..


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