New hard drive (problems)

Forum rules
Before you post please read this
Post Reply
acorn22
Level 1
Level 1
Posts: 18
Joined: Wed Apr 18, 2007 4:15 pm
Location: Winsconsin

New hard drive (problems)

Post by acorn22 » Wed May 23, 2007 9:55 am

I just found a 40 GB hard drive and I want to use it as my /home. What is the easiest way to do this?

Also, I keeps getting errors when trying to format it to ext3. I think this is because When I was initially formating it (to ext3) my computer crashed during the process. I can format it to fat32 and it seems to work, but I think ext3 is better.

The error has something to do with the thing that lets the computer know where the end of the partition is. I can try to make a new one, but I get some error. (If it helps, whatever it is called, I can choose "msdos, amiga, sun, bsd etc") Is there a way to just nuke the whole thing and pretend like the hard drive is brand new? Or is my hard drive ruined?

Husse
Level 23
Level 23
Posts: 18701
Joined: Sun Feb 11, 2007 7:22 am
Location: Near Borås Sweden

Post by Husse » Wed May 23, 2007 11:20 am

If you can loose everything on it - and it seems so - you can use a debug procedure in DOS to wipe the MBR clean.
I'm sorry but I don't have a Linux version of this. You need a complete MS-DOS start diskette. Bot from it and execute the following commands:
//edit//OOPS! this is how it goes with copy/paste :)
The first command should be debug else nothing happens so I've added that//
debug
a 100

int 13

only enter (i.e press enter once)

rax

0301

rbx

0200

f 200 L 200 0
Enter after every line
Have only one disk attached to the motherboard as this is completely without safety belts :)
When this is done you don't have any accessible data left.
Treat it as a new disk and fdisk it ....
What this does is in fact overwrite the MBR with zeros
Last edited by Husse on Thu May 24, 2007 5:53 am, edited 2 times in total.
Image
Don't fix it if it ain't broken, don't break it if you can't fix it

D1Wayne
Level 3
Level 3
Posts: 198
Joined: Tue Apr 24, 2007 6:11 am
Location: Pacific North West

Post by D1Wayne » Wed May 23, 2007 1:48 pm

sometimes, when partitioning problems

1) delete all partions
2) place swap as 1st partition
3) add root as 2nd partition ext3
4) format
5) re-boot from live-cd
5) repeat above but reverse the partition allocations ext3 the swap as 2nd
6) format again

if above does not work then run drive fitness tests and see if the drive is really a paper-weight waiting to happen :shock:

scorp123
Level 8
Level 8
Posts: 2277
Joined: Sat Dec 02, 2006 4:19 pm
Location: Switzerland

Post by scorp123 » Wed May 23, 2007 2:48 pm

D1Wayne wrote: sometimes, when partitioning problems
1) delete all partions
So far so good ... :wink:
D1Wayne wrote: 2) place swap as 1st partition
3) add root as 2nd partition ext3
I disagree here :? /boot should be the first partition. Putting the swap partition first is a waste. The disk sectors at the front of the disk are particularly fast for read operations, making them ideal for booting quickly. Putting your swap there is a waste.
D1Wayne wrote: 4) format
5) re-boot from live-cd
5) repeat above but reverse the partition allocations ext3 the swap as 2nd
6) format again
I disagree here. Waste of time and needless exercise IMHO. :?

If the disk's partitions are corrupted then removing all partitions and re-partitioning the disk again the way you need / you want should fix the errors. If they're still not fixed after that then the disk is probably physically damaged and there is nothing you can do against that anyway.
D1Wayne wrote: see if the drive is really a paper-weight
40 GB disks are really old I guess; I haven't seen such small disks in ages. So if the disk is 5+ years old and it was laying around collecting dust chances are it is paper-weight. :?

Husse
Level 23
Level 23
Posts: 18701
Joined: Sun Feb 11, 2007 7:22 am
Location: Near Borås Sweden

Post by Husse » Wed May 23, 2007 4:47 pm

Well, this was in my Windows times, but I had really good use of the debug described above when a hard drive got completely messed up after a failed overclocking experiment. Whatever we did didn't help, but the debug operation + fdisk and all as new....
And even then I had complete backup (but not disk images as now) so I was back on the track in 15 minutes once the disk was fixed :)
Oh - 40GB don't use it as home Lowell - use it as a container for things not frequently used :)
Image
Don't fix it if it ain't broken, don't break it if you can't fix it

D1Wayne
Level 3
Level 3
Posts: 198
Joined: Tue Apr 24, 2007 6:11 am
Location: Pacific North West

Post by D1Wayne » Wed May 23, 2007 5:24 pm

scorp123 wrote
I disagree here. Waste of time
I have used this several times in the past

after formating ntfs drive with mythKnoppix live_cd, switching back to ntfs and XP was totally messed up. went to Ubuntu 4.10 it tried but died in the formating 3 times straight, the deleted all partitions and then re-allocatted them in a different order, problem went away

scorp123
Level 8
Level 8
Posts: 2277
Joined: Sat Dec 02, 2006 4:19 pm
Location: Switzerland

Post by scorp123 » Wed May 23, 2007 5:37 pm

Husse wrote: Oh - 40GB don't use it as home Lowell - use it as a container for things not frequently used :)
Yes, I second that. Putting your /home on that potentially broken disk is not such a good idea. If it really breaks you lose all your mails, your MP3 collection, your photos, pictures, and all the things that you put there.

I'd use that 40 GB disk as "testing ground" or "playground", e.g. either use the space to try out new and exotic Linux distributions or install an old and lean Windows (e.g. Windows 98 is still good for gaming purposes ... especially on older machines) there for playing games ... :wink:

scorp123
Level 8
Level 8
Posts: 2277
Joined: Sat Dec 02, 2006 4:19 pm
Location: Switzerland

Post by scorp123 » Wed May 23, 2007 5:41 pm

D1Wayne wrote: after formating ntfs drive with mythKnoppix live_cd
The NTFS formatter is totally broken and not working reliably as Microsoft never released the specifications. You can use Linux to read NTFS data, but before the "NTFS-3G" project there was absolutely nothing to write NTFS data in a reliable way.

That your disk got messed up has nothing to do with partitioning. You just should not have used that flaky NTFS formatter in Knoppix and Ubuntu. If you want to format a disk reliably with NTFS you have to use Windows. You could have saved yourself a lot of time and troubles there ... :wink:

Google for "Bart PE": That's a project that will allow you to create a "Windows XP Live CD". I use it too from time to time if I have to mess around with NTFS volumes. As much as I hate using any form of Windows, but if you have important data on a NTFS formatted disk I strongly suggest using Microsoft's original stuff in Windows and not those incomplete and unfortunately still quite experimental and reverse-engineered NTFS drivers and NTFS formatters currently in Linux.

Maybe the situation will improve but for as long as Microsoft refuses to explain how exactly NTFS data gets written properly without breaking anything, I'd not touch NTFS disks with any Linux.

D1Wayne
Level 3
Level 3
Posts: 198
Joined: Tue Apr 24, 2007 6:11 am
Location: Pacific North West

Post by D1Wayne » Thu May 24, 2007 2:06 am

you have totally missed the point
this has nothing to do with knoppix, ubuntu or ntfs

I have been using bart_pe and ucbwin for several years, but not everybody out there has such tools or even dos at their reach when this type of problem occurs.

it was about getting a disk to format as ext3, using a live-cd, which if they are installing they already have in their drive.

using the method i described below
I have just done that again since last post, using Cassandra beta014 on a drive that would not format as ext3.

I dug out a old 40gb drive with a funky mbr, maxtor's maxblast
could only see 18gb on the drive.

stuck it in an old 256mb Dell Dimension 8100 1.3ghz, with a old Nvidia geforce2 mx400 video card. could not run install 3 times failed to partion drive.

used gpart deleted the partition, put swap at the beginning, then ext3
repeated a second time and put the ext3 partition top the top of the drive and swap on bottom, rebooted

installed Cassandra, then spent the rest of the time to get nvidia, Beryl and compiz running on this old dog with only 256mb (rdram too expensive to upgrade memory :) )

all tough this configuration runs nicely at 1280x1024, with Beryl to flakey at resolutions higher than 1024x768

scorp123
Level 8
Level 8
Posts: 2277
Joined: Sat Dec 02, 2006 4:19 pm
Location: Switzerland

Post by scorp123 » Thu May 24, 2007 3:26 am

D1Wayne wrote:you have totally missed the point
.... ah OK :D Oh well, it was late :roll:

Thanks for the details 8)

Husse
Level 23
Level 23
Posts: 18701
Joined: Sun Feb 11, 2007 7:22 am
Location: Near Borås Sweden

Post by Husse » Thu May 24, 2007 5:52 am

It probably does not matter what you do or in which order as long as you create and delete a bunch of partitions. It probably "shakes up" the MBR enough for it to be OK
Image
Don't fix it if it ain't broken, don't break it if you can't fix it

scorp123
Level 8
Level 8
Posts: 2277
Joined: Sat Dec 02, 2006 4:19 pm
Location: Switzerland

Post by scorp123 » Thu May 24, 2007 6:57 am

Husse wrote: It probably "shakes up" the MBR enough for it to be OK
Well, if you only want to delete the MBR + partition table then dd would be waaaay faster !! dd if=/dev/null of= ... (not posting the rest here as someone might be so unlucky and actually try this out ... on the wrong drive :? )

The problem I see is not so much with the MBR and the partition table there but rather with the partition boundary markers ... I can imagine that for some silly reason those markers might get not properly written (e.g. power failure while a tool such as "Partition Magic" is moving partitions around? ... always very funny when that happens!! :evil: ) and mess things up, e.g. the partition table was properly written and claims that partition 1 ends on block X, and partition 2 starts on block X+1, but block X+1 claims "Nope, I still belong to partition 1, not 2 ... " and the boundary marker is in fact e.g. on block X+1000 ... This happened to me once and it seriously messed things up :?

Maybe this is what happened e.g. in D1Wayne's case. Hence why deleting partitions, creating new partitions of different sizes than the previous ones and of different types than the previous ones (e.g. Linux swap partitions and Linux data partitions have different partition ID's ...) helped to fix this, e.g. MBR, partition table and boundary markers had to be written again which then corrected the previous problem ... :?:

acorn22
Level 1
Level 1
Posts: 18
Joined: Wed Apr 18, 2007 4:15 pm
Location: Winsconsin

Post by acorn22 » Thu May 24, 2007 9:51 am

Sadly I get the feeling as it is paper weight. It makes this incredibly high pitched noise from time to time that drives me mad anyways.

This is really a bummer as all my hard drives I have now are about 10 gigs. I need a new computer :P

Husse
Level 23
Level 23
Posts: 18701
Joined: Sun Feb 11, 2007 7:22 am
Location: Near Borås Sweden

Post by Husse » Thu May 24, 2007 10:10 am

about 10 gigs
Even lappy - was that a crappy? :)
Image
Don't fix it if it ain't broken, don't break it if you can't fix it

acorn22
Level 1
Level 1
Posts: 18
Joined: Wed Apr 18, 2007 4:15 pm
Location: Winsconsin

Post by acorn22 » Thu May 24, 2007 10:16 am

no that's on my pc (the 800mhz)

My lappy has a 30 gig, but I swear OS X takes up 15 gigs :/ with absolutely no movies/music/information on it I have about 10 gigs available :(

scorp123
Level 8
Level 8
Posts: 2277
Joined: Sat Dec 02, 2006 4:19 pm
Location: Switzerland

Post by scorp123 » Thu May 24, 2007 10:20 am

acorn22 wrote: makes this incredibly high pitched noise from time to time that drives me mad anyways.
Sounds like the ball bearing (or whatever you call that in English!? German: "Kugellager") in the disk's center is busted and what you hear is what one guy here once called "Screech of Death", e.g. one of the balls is scratching the surface, metal on metal, and that screeching is what you get then ... :?

D1Wayne
Level 3
Level 3
Posts: 198
Joined: Tue Apr 24, 2007 6:11 am
Location: Pacific North West

Post by D1Wayne » Thu May 24, 2007 10:24 am

scorp123 wrote:This happened to me once and it seriously messed things up :?

Maybe this is what happened e.g. in D1Wayne's case.
I can not say for the a couple of these (they were not in my possession when they failed, and clients swore not to have had power problems, just failure frozen/crashed windows :shock: :o ), but for the last 1 (last night's test), that is what i did powered off the machine while using maxblast to re-partition and try to kiil the mbr :D :D :twisted:

scorp123
Level 8
Level 8
Posts: 2277
Joined: Sat Dec 02, 2006 4:19 pm
Location: Switzerland

Post by scorp123 » Thu May 24, 2007 11:15 am

D1Wayne wrote: try to kiil the mbr
use "dd" :wink: It's very efficient at that ... :twisted:

Husse
Level 23
Level 23
Posts: 18701
Joined: Sun Feb 11, 2007 7:22 am
Location: Near Borås Sweden

Post by Husse » Thu May 24, 2007 6:21 pm

@D1Wayne
More than once I've had disks seriously messed up after failed overclocking - I feel I can take the risk as I generally have an extra pc to play with, and for the important one always backup.
I had to resort to the debug procedure I described above, nothing else worked.
@scorp
Yes, ball bearing - and there's no special connotation here unless you want it :)
Image
Don't fix it if it ain't broken, don't break it if you can't fix it

scorp123
Level 8
Level 8
Posts: 2277
Joined: Sat Dec 02, 2006 4:19 pm
Location: Switzerland

Post by scorp123 » Thu May 24, 2007 6:53 pm

Husse wrote: Yes, ball bearing - and there's no special connotation here unless you want it :)
Why oh why did I somehow expect such a comment? :lol:

Post Reply

Return to “Mounting Partitions”