Skip to main content

Thread: I screwed up a hard drive partition with ms-sys, how can I fix it?


so - windows xp crapped out on me few days ago. unable fix or enter windows in way installed ubuntu try , plug @ it. news is, , think i'm going keep using it.

bad news is, i'm inexperienced , did stupid.

i fiddling program ms-sys try , harddrive windows on boot started again. read in forums how set partition.

did (i renamed folder ms-sys "ham" make easier type):

j@j-desktop:~/desktop/ham$ sudo ms-sys --mbr /dev/sdb2
/dev/sdb2 seems disk partition device,
use switch -f force writing of master boot record
j@j-desktop:~/desktop/ham$ sudo ms-sys -f --mbr /dev/sdb2
windows 2000/xp/2003 master boot record written /dev/sdb2
j@j-desktop:~/desktop/ham$
sdb2 partition of big hard drive had windows on it. has lot of files don't want lose, , worried might have.

think in doing force write on drive - screwed partition because can't mount in ubuntu.

first tried mount :

j@j-desktop:~$ sudo mount /dev/sdb2
mount: can't find /dev/sdb2 in /etc/fstab or /etc/mtab

sudo mount /dev/sdb2 mnt/sdb2
mount: mount point mnt/sdb2 not exist

started gnome partition editor see looked , said :

/dev/sdb2 : size 462.40 gb, flags: boot status: not mounted
first sector : 96390, last sector : 969827984
total sectors: 969731595
warning: unable detect file system! possible reasons : -the file system damaged, file system unknown gparted, there no file system available
i did : sudo fdisk -l, says this:

disk /dev/sdb: 500.1 gb, 500107862016 bytes
255 heads, 63 sectors/track, 60801 cylinders
units = cylinders of 16065 * 512 = 8225280 bytes
disk identifier: 0x41ab2316

device boot start end blocks id system
/dev/sdb1 1 6 48163+ de dell utility
/dev/sdb2 * 7 60369 484865797+ 7 hpfs/ntfs
/dev/sdb3 60371 60801 3462007+ db cp/m / ctos / ...

did : sudo fdisk /dev/sdb2

says:
number of cylinders disk set 60363.
there nothing wrong that, larger 1024,
, in setups cause problems with:
1) software runs @ boot time (e.g., old versions of lilo)
2) booting , partitioning software other oss
(e.g., dos fdisk, os/2 fdisk)
i went expert command , typed v (verify partition table)

expert command (m help): v
partition 1 not end on cylinder boundary.
partition 2 not end on cylinder boundary.
warning: partition 1 overlaps partition 2.
partition 3 not end on cylinder boundary.
total allocated sectors 1701990412 greater maximum 969731595
then did expert command : p (print partition table)

expert command (m help): p

disk /dev/sdb2: 255 heads, 63 sectors, 60363 cylinders

nr af hd sec cyl hd sec cyl start size id
1 63 111 45 368 101 51 371 218129509 1701990410 72
partition 1 not end on cylinder boundary.
2 73 115 32 67 114 44 299 729050177 543974724 74
partition 2 not end on cylinder boundary.
3 74 111 32 114 115 52 353 168653938 0 65
partition 3 not end on cylinder boundary.
4 00 0 0 0 0 0 0 2692939776 51635 00

is there can give me fix partition? booted fine ubuntu until screwed , ms-sys. i'd grateful got lot of things on don't want lose.

lot!

one thing add: in viewing gparted file : there unallocated part hd of 7.84 mib

first sector : 969827985
second sector : 969844049

i'm thinking might starting ms-sys.


Forum The Ubuntu Forum Community Ubuntu Official Flavours Support General Help [ubuntu] I screwed up a hard drive partition with ms-sys, how can I fix it?


Ubuntu

Comments