Find the answer to your Linux question:
Results 1 to 10 of 10
I have second hard drive on my desktop that I use to try various Linux distros. After many successful and failed installations the drive is a mess of various partitions. ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Just Joined! OldBob's Avatar
    Join Date
    Jul 2004
    Location
    New Jersey - USA
    Posts
    42

    "Clearing" a Linux Hard Drive


    I have second hard drive on my desktop that I use to try various Linux distros. After many successful and failed installations the drive is a mess of various partitions. Right now I can't even install a Live CD.

    Since this drive has never had a Windows OS installed, my "old standby" a Win98SE boot floppy won't work. Can't find a FAT.

    How can I "erase & format" this drive for a fresh start ???

  2. #2
    oz
    oz is offline
    forum.guy
    Join Date
    May 2004
    Location
    arch linux
    Posts
    18,733
    Code:
    dd if=/dev/zero of=/dev/hda bs=512 count=1
    ...that should wipe the drive giving you a fresh start.

    Change the device to match your own device.
    oz

  3. #3
    Just Joined! OldBob's Avatar
    Join Date
    Jul 2004
    Location
    New Jersey - USA
    Posts
    42
    Ozar,

    As a "newbie", I don't even understand that command ?

  4. $spacer_open
    $spacer_close
  5. #4
    Linux Newbie
    Join Date
    Apr 2005
    Location
    CT --> PA
    Posts
    170
    well, what's the OS on the OTHER HD? Lets see what does boot, if anything at all...

    If it's THAT far gone, i recommend Knoppix..which will boot (pretty sure it boots w/o a HD even in the system)... and then some quick work with cfdisk will put you back in the game...
    Chicks dig giant mechanized war machines

  6. #5
    Just Joined! questio verum's Avatar
    Join Date
    Jun 2007
    Location
    Adrift in an ever-expanding universe, quietly contemplating the wondrous and the inevitable.
    Posts
    82
    Ozar,
    I'm always hungry to learn something new, so I'm going to do some digging & see if I can decipher that command string you posted. In the meantime though, if a system won't boot a LiveCD (not sure why that would happen) what tool would you use to bring up a shell to enter that command?

    Having come from a dos/windows background, in the past I would've been scrambling for a custom configured CD boot floppy or a BartPE bootable CD to give me a command shell where I would use dos-based tools to clean things up.

    But... that was then. This is now. I'm trying to break my reliance on ms & ms commercial software. So if I want to return a sick partition table to health using only open-source tools, what would be my approach?

    THX

    qv

  7. #6
    Linux Guru bigtomrodney's Avatar
    Join Date
    Nov 2004
    Location
    Ireland
    Posts
    6,133
    Is the problem here that you can't boot a livecd or that you can't install?

    If you can't boot that will be a different problem altogether. As an explanation of Oz's command...

    This is an old trick. /dev/zero is a virtual device that produces zeroes and dd is 'disk duplicator' which is used for copying disks, files and streams. Using the command above copies zeroes over master boot record, nulling everything. All partitions and tables are wiped leaving the disk effectively empty.

    A non-functional pseudo command to help understand would be something like :-
    Code:
    diskduplicator inputfile=zeroes outputfile=harddisk bytesize=the_size_of_your_master_boot_record count=1

  8. #7
    oz
    oz is offline
    forum.guy
    Join Date
    May 2004
    Location
    arch linux
    Posts
    18,733
    oz

  9. #8
    Just Joined! questio verum's Avatar
    Join Date
    Jun 2007
    Location
    Adrift in an ever-expanding universe, quietly contemplating the wondrous and the inevitable.
    Posts
    82
    Quote Originally Posted by bigtomrodney View Post
    Is the problem here that you can't boot a livecd or that you can't install?
    No problems here, just trying to learn something. Thanks for breaking that line down, btw.

    Purely by coincidence, I stopped by Distrowatch just before hitting the forum, and I learned of the existence of partedmagic. I had previously downloaded parted, qparted, and was in the process of gathering various filesystem tools to make a similar repair & configuration disc. Now I find it's already been done. cool.

  10. #9
    oz
    oz is offline
    forum.guy
    Join Date
    May 2004
    Location
    arch linux
    Posts
    18,733
    Quote Originally Posted by questio verum View Post
    Purely by coincidence, I stopped by Distrowatch just before hitting the forum, and I learned of the existence of partedmagic.
    The Parted Magic LiveCD is a great tool to keep on hand for working with Linux and/or Windows partitions. I routinely recommend it to others here on the forums.
    oz

  11. #10
    Just Joined! OldBob's Avatar
    Join Date
    Jul 2004
    Location
    New Jersey - USA
    Posts
    42
    Sorry Guys,

    I gave up on clearing HD and replaced it with another spare I had on hand.

    With "new" HD distro installed with no problem.

    Background Info:

    My desktop includes a Romtec Trios hard drive switcher, [this is a push button switch box that allows one of three drives to connect to mobo]

    The present set up is:

    #1 - 40 gig with Win98SE
    #2 - 20 gig [dual boot] backup copy Win98SE & Red Hat 8.0
    #3 - 10 gig with PClinuxOS - 2007

    #3 drive was "problem" trying to remove Xandros and install PClinuxOS. "Old" RH is from CDs in a Linux manual I bought at Waldens. I buy 10 gig HDs at local computer show $10 -$15.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •