LinuxQuestions.org
Latest LQ Deal: Complete CCNA, CCNP & Red Hat Certification Training Bundle
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 07-20-2005, 12:41 PM   #1
Xyem
Member
 
Registered: Apr 2005
Distribution: Fedora Core 4
Posts: 100

Rep: Reputation: 15
dd usage - "Resetting Hard Drives"


I have 2 hard drives and I intend of doing a completely fresh install of both Windows and Linux (Fedora Core 4) as I want the Linux install on the 160Gb (which will be the Primary Master) and Windows on the 120GB (Secondary Master).

Unfortunately, PartitionMagic v8 refuses to delete any partitions on the 120GB (which both Windows and Linux are installed) return a #510 error. According to a google search I have to disable dir_index on the hard drive (which Linux put on) but the command doesn't exist.

Quote:
tunefs -O^dir_index /dev/hdb
Closest is 'tune2fs' but that returns an error.

However I have come across the following command:
Quote:
dd if=/dev/zero of=/dev/hda bs=1024 count=10240
which it is said (on the site) to erase the Paritition Table and any information regarding the disk causing it to be "brand new".

A simple yes or no answer is welcome, will this achieve my goal of having "clean" (as far as it is concerned nothing exists) hard disks?
 
Old 07-20-2005, 01:06 PM   #2
traene
Member
 
Registered: Jan 2005
Distribution: Archlinux, Debian, grml
Posts: 210

Rep: Reputation: 33
I just had a really short internet serach for reintalling the MBR on a hard disk. You
may have a look here:
http://www.faqs.org/docs/win_bsd/trouble.htm

Anyways with the DOS utility

Code:
fdisk /mbr
You can write a clean dos MBR to your hardisk. When this is done,
new partions can be created and you should have a good starting point.

However this dd command with writing zeros to the harddisk can cause some
problems i guess. Have a look at the link above.
 
Old 07-20-2005, 01:15 PM   #3
Xyem
Member
 
Registered: Apr 2005
Distribution: Fedora Core 4
Posts: 100

Original Poster
Rep: Reputation: 15
According to that site
Code:
dd if=/dev/zero of=/dev/hda
Wipes the hard disk completely, presumably bringing it back to a "factory" type state. This is more of what I am looking for.

I have used 'fdisk /mbr' before and it's never touched partition data.

EDIT: I just read the site a little further and it seems I can do the above and then use 'fdisk /mbr' to reset the MBR into a working order.

Thanks for the site, I would have shot myself in the foot pretty seriously there!

Last edited by Xyem; 07-20-2005 at 01:21 PM.
 
  


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
new pci ide - now hard drives are re "labeled" Mailman42 Debian 2 09-04-2005 03:27 PM
Gaim idle time reporting: "x usage" option disappeared DiscoStoo Linux - Software 2 12-23-2004 03:32 PM
"No Hard Disk Drives detected" error when installing Woody as guest OS in VMware Thomas Anderson Debian 1 01-25-2004 05:41 AM
Module usage :Global symbol "$ref" requires explicit package name rajatgarg Programming 2 12-17-2003 02:55 AM
Mandrake 9.0 & 9.1 "detecting hard drives" installation hang Dr Tom Danger Mandriva 3 11-07-2003 04:34 PM


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