Testdisk übernimmt Geometrie-Änderungen nicht

T

Tblue

Tripel-As
Hallo,

ich wollte meine Partitionstabelle ändern, parted beklagte sich jedoch über ein Dateisystem mit nicht unterstützten Optionen, was mir doch etwas seltsam vorkam, da ja alles funktionierte. Also habe ich testdisk gestartet, und richtig, ein altes Problem war wieder da:
Code:
Warning: the current number of heads per cylinder is 16 but the correct value may be 255.
Also habe ich im Geometrie-Menü die Anzahl der Heads pro Zylinder auf 255 gesetzt und die Analye noch einmal durchlaufen lassen. Alle Partitionen wurde ohne Probleme erkannt und die Partitionstabelle geschrieben. Mein Problem ist nun, dass die Anzahl der Heads pro Zylinder nach dem Beenden von Testdisk immer noch falsch ist; auch nach einem Reboot zeigt Testdisk wieder die Warnung von oben und parted kann die Partitionstabelle nicht anzeigen (fdisk allerdings schon):
Code:
Fehler: Partitionen ausserhalb der Festplatte sind nicht möglich!
Mache ich etwas falsch? Ich habe es früher schon einmal hinbekommen, mit Testdisk die Head-Anzahl zu ändern... Wer weiß, wo der Fehler liegt?

Hier das Log von Testdisk:
Code:
Mon Jun  2 00:03:58 2008
Command line: TestDisk

TestDisk 6.9-WIP, Data Recovery Utility, December 2007
Christophe GRENIER <grenier@cgsecurity.org>
http://www.cgsecurity.org
Linux version (ext2fs lib: 1.40.8, ntfs lib: 10:0:0, reiserfs lib: 0.3.0.5, ewf lib: none)
disk_get_geometry BLKGETSIZE64 /dev/hda number of cylinders 65535 !=  238216 (calculated)
Hard disk list
Disk /dev/hda - 122 GB / 114 GiB - CHS 238216 16 63, sector size=512

Disk /dev/hda - 122 GB / 114 GiB
Partition table type: Intel

Analyse Disk /dev/hda - 122 GB / 114 GiB - CHS 238216 16 63
Geometry from i386 MBR: head=255 sector=63
BAD_RS LBA=192780 12096
BAD_RS LBA=2152710 135072
get_geometry_from_list_part_aux head=16 nbr=1
get_geometry_from_list_part_aux head=8 nbr=1
get_geometry_from_list_part_aux head=16 nbr=1
get_geometry_from_list_part_aux head=32 nbr=1
get_geometry_from_list_part_aux head=64 nbr=1
get_geometry_from_list_part_aux head=128 nbr=1
get_geometry_from_list_part_aux head=240 nbr=1
get_geometry_from_list_part_aux head=255 nbr=10
Current partition structure:
 1 * Linux                    0   1  1   191   3 63     192717

Warning: Bad ending head (CHS and LBA don't match)
 2 P Linux Swap             191   4  1  2135   9 63    1959930

Warning: Bad ending head (CHS and LBA don't match)
 3 P Linux                 2135  10  1 60259  10 63   58589055

Warning: Bad ending head (CHS and LBA don't match)
 4 E extended LBA         60259  11  1 238217  12 63  179381790

Warning: Bad starting head (CHS and LBA don't match)
 5 L Linux                60259  12  1 238201  13 63  179365662

Warning: Bad starting head (CHS and LBA don't match)
Ask the user for vista mode
Allow partial last cylinder : No
search_vista_part: 0

search_part()
Disk /dev/hda - 122 GB / 114 GiB - CHS 238216 16 63

recover_EXT2: s_block_group_nr=0/11, s_mnt_count=100/4294967295, s_blocks_per_group=8192
recover_EXT2: s_blocksize=1024
recover_EXT2: s_blocks_count 96356
recover_EXT2: part_size 192712
   D Linux                    0   1  1   191   3 58     192712
     EXT3 Sparse superblock Recover, 98 MB / 94 MiB
   D Linux Swap             191   4  1  2135   9 45    1959912
     SWAP2 version 1, 1003 MB / 956 MiB

recover_EXT2: s_block_group_nr=0/223, s_mnt_count=99/4294967295, s_blocks_per_group=32768
recover_EXT2: s_blocksize=4096
recover_EXT2: s_blocks_count 7323631
recover_EXT2: part_size 58589048
   D Linux                 2135  10  1 60259  10 56   58589048
     EXT3 Large file Sparse superblock Recover, 29 GB / 27 GiB

recover_EXT2: s_block_group_nr=0/684, s_mnt_count=101/4294967295, s_blocks_per_group=32768
recover_EXT2: s_blocksize=4096
recover_EXT2: s_blocks_count 22420707
recover_EXT2: part_size 179365656
   D Linux                60259  12  1 238201  13 57  179365656
     EXT3 Large file Sparse superblock Recover, 91 GB / 85 GiB
get_geometry_from_list_part_aux head=16 nbr=1
get_geometry_from_list_part_aux head=8 nbr=1
get_geometry_from_list_part_aux head=16 nbr=1
get_geometry_from_list_part_aux head=32 nbr=1
get_geometry_from_list_part_aux head=64 nbr=1
get_geometry_from_list_part_aux head=128 nbr=1
get_geometry_from_list_part_aux head=240 nbr=1
get_geometry_from_list_part_aux head=255 nbr=8
Warning: the current number of heads per cylinder is 16 but the correct value may be 255.

Results
   D Linux                    0   1  1   191  15 63     193473
     EXT3 Sparse superblock Recover, 99 MB / 94 MiB
   D Linux Swap             191   4  1  2135  15 63    1960308
     SWAP2 version 1, 1003 MB / 957 MiB
   D Linux                 2135  10  1 60259  15 63   58589370
     EXT3 Large file Sparse superblock Recover, 29 GB / 27 GiB
   D Linux                60259  12  1 238201  15 63  179365788
     EXT3 Large file Sparse superblock Recover, 91 GB / 85 GiB

interface_write()
 
No partition found or selected for recovery
simulate write!

write_mbr_i386: starting...
write_all_log_i386: starting...
No extended partition
New geometry
Disk /dev/hda - 122 GB / 114 GiB - CHS 14947 255 63 sector_size=512

Analyse Disk /dev/hda - 122 GB / 114 GiB - CHS 14947 255 63
Geometry from i386 MBR: head=255 sector=63
get_geometry_from_list_part_aux head=255 nbr=10
get_geometry_from_list_part_aux head=8 nbr=1
get_geometry_from_list_part_aux head=16 nbr=1
get_geometry_from_list_part_aux head=32 nbr=1
get_geometry_from_list_part_aux head=64 nbr=1
get_geometry_from_list_part_aux head=128 nbr=1
get_geometry_from_list_part_aux head=240 nbr=1
get_geometry_from_list_part_aux head=255 nbr=10
Current partition structure:
 1 * Linux                    0   1  1    11 254 63     192717
 2 P Linux Swap              12   0  1   133 254 63    1959930
 3 P Linux                  134   0  1  3780 254 63   58589055
 4 E extended LBA          3781   0  1 14946 254 63  179381790
 5 L Linux                 3781   1  1 14945 254 63  179365662
Ask the user for vista mode
Allow partial last cylinder : No
search_vista_part: 0

search_part()
Disk /dev/hda - 122 GB / 114 GiB - CHS 14947 255 63

recover_EXT2: s_block_group_nr=0/11, s_mnt_count=100/4294967295, s_blocks_per_group=8192
recover_EXT2: s_blocksize=1024
recover_EXT2: s_blocks_count 96356
recover_EXT2: part_size 192712
   D Linux                    0   1  1    11 254 58     192712
     EXT3 Sparse superblock Recover, 98 MB / 94 MiB
   D Linux Swap              12   0  1   133 254 45    1959912
     SWAP2 version 1, 1003 MB / 956 MiB

recover_EXT2: s_block_group_nr=0/223, s_mnt_count=99/4294967295, s_blocks_per_group=32768
recover_EXT2: s_blocksize=4096
recover_EXT2: s_blocks_count 7323631
recover_EXT2: part_size 58589048
   D Linux                  134   0  1  3780 254 56   58589048
     EXT3 Large file Sparse superblock Recover, 29 GB / 27 GiB

recover_EXT2: s_block_group_nr=0/684, s_mnt_count=101/4294967295, s_blocks_per_group=32768
recover_EXT2: s_blocksize=4096
recover_EXT2: s_blocks_count 22420707
recover_EXT2: part_size 179365656
   D Linux                 3781   1  1 14945 254 57  179365656
     EXT3 Large file Sparse superblock Recover, 91 GB / 85 GiB
get_geometry_from_list_part_aux head=255 nbr=8
get_geometry_from_list_part_aux head=8 nbr=1
get_geometry_from_list_part_aux head=16 nbr=1
get_geometry_from_list_part_aux head=32 nbr=1
get_geometry_from_list_part_aux head=64 nbr=1
get_geometry_from_list_part_aux head=128 nbr=1
get_geometry_from_list_part_aux head=240 nbr=1
get_geometry_from_list_part_aux head=255 nbr=8

Results
   * Linux                    0   1  1    11 254 63     192717
     EXT3 Sparse superblock Recover, 98 MB / 94 MiB
   P Linux Swap              12   0  1   133 254 63    1959930
     SWAP2 version 1, 1003 MB / 956 MiB
   P Linux                  134   0  1  3780 254 63   58589055
     EXT3 Large file Sparse superblock Recover, 29 GB / 27 GiB
   L Linux                 3781   1  1 14945 254 63  179365662
     EXT3 Large file Sparse superblock Recover, 91 GB / 85 GiB

interface_write()
 1 * Linux                    0   1  1    11 254 63     192717
 2 P Linux Swap              12   0  1   133 254 63    1959930
 3 P Linux                  134   0  1  3780 254 63   58589055
 4 E extended LBA          3781   0  1 14946 254 63  179381790
 5 L Linux                 3781   1  1 14945 254 63  179365662
write!

write_mbr_i386: starting...
write_all_log_i386: starting...
write_all_log_i386: CHS: 3781/0/1,lba=60741765
You will have to reboot for the change to take effect.

TestDisk exited normally.

Grüße,

Tblue
 
Zuletzt bearbeitet:
kannst du auf eine ältere version downgraden. diese version von testdisk scheint kaputt zu sein. ich habe damit persönlich auch nur probleme.
 
Danke, habe das Testdisk der Ultimate Boot CD genommen (das ist Version 6.6), nun müsste eigtl. alles funktionieren...

//edit: Hm, nun zeigt parted zwar die Partitionstabelle an, will aber die Partition nicht verkleinern (vielleicht mache ich auch etwas falsch?):
Code:
Script wurde gestartet: Mo 02 Jun 2008 15:33:22 CEST
[root@h2g2-42 ~]# parted
GNU Parted 1.8.8
Verwende /dev/hda
Willkommen zu GNU Parted! Geben Sie 'help' ein, um eine Liste der verfügbaren
Kommados zu erhalten.

                                                                          
(parted) print
Modell: Maxtor 6Y120L0 (ide)
Festplatte  /dev/hda:  123GB
Sektorgröße (logisch/physisch): 512B/512B
Partitionstabelle: msdos

Nummer  Anfang  Ende    Größe   Typ       Dateisystem  Flags
 1      32,3kB  98,7MB  98,7MB  primary   ext3         boot 
 2      98,7MB  1102MB  1003MB  primary   linux-swap        
 3      1102MB  31,1GB  30,0GB  primary   ext3              
 4      31,1GB  123GB   91,8GB  extended               lba  
 5      31,1GB  123GB   91,8GB  logical   ext3              


                                                                          
(parted) resize 5 31,1GB 113GB

                                                                          
Fehler: Das Dateisystem hat eine inkompatible Funktion aktiviert.

                                                                          
(parted) resize 4 31,1GB 113GB

                                                                          
Fehler: Es können nicht alle Anforderungen an die Partition erfüllt werden.

                                                                          
(parted) quit
[root@h2g2-42 ~]# exit
exit

Script beendet: Mo 02 Jun 2008 15:34:21 CEST
 
Zuletzt bearbeitet:
Ah, habe den Thread ganz vergessen... Wen es interessiert: Das Problem habe ich gelöst, indem ich die Kernel command line im GRUB einfach um die richtigen Werte ergänzt habe (im BIOS-Menü stehen die Werte zwar richtig, aber irgendetwas will da wohl nicht so ganz):
Code:
kernel /vmlinuz26 root=/dev/sda3 ro hda=14946,255,63
 
testdisk downgrade?

Hallo liebes Forum, vllt. ist dies die Ursache meines Probs.
kannst du auf eine ältere version downgraden. diese version von testdisk scheint kaputt zu sein.

Ich habe eine externe USB Platte mit einer einzigen ext3 Partition, die ich versehentlich mit ntfs zerformatiert habe. Nun versuche ich mit testdisk die alte Partition wiederherzustellen.
Code:
# testdisk
TestDisk 6.8, Data Recovery Utility, August 2007
 (...)
Select a media (use Arrow keys, then press Enter):
Disk /dev/sda - 1000 GB / 931 GiB
Disk /dev/sdf - 500 GB / 465 GiB   <<

[ Proceed ] ... -> [ Intel ] ... -> [ Analyse ] gibt dann
Code:
Disk /dev/sdf - 500 GB / 465 GiB - CHS 60801 255 63
Current partition structure:
     Partition                  Start        End    Size in sectors

No EXT2, JFS, Reiser, cramfs or XFS marker
 1 P Linux                    0   1  1 60800 254 63  976768002
 1 P Linux                    0   1  1 60800 254 63  976768002
No partition is bootable

[ Proceed ] ...

Disk /dev/sdf - 500 GB / 465 GiB - CHS 60801 255 63
     Partition               Start        End    Size in sectors
* HPFS - NTFS              0   1  1 60800 254 63  976768002

Structure: Ok.  Use Up/Down Arrow keys to select partition.
Use Left/Right Arrow keys to CHANGE partition characteristics:
*=Primary bootable  P=Primary  L=Logical  E=Extended  D=Deleted
Keys A: add partition, L: load backup, T: change type, P: list files,
     Enter: to continue
NTFS, 500 GB / 465 GiB

Das ist mE schon mal komisch, dass TD erst zwei (identische?) Linux Partitionen findet und dann aber doch wieder nur die ntfs-Partition. Also mit Enter die Analyse ausgelöst gibt

Code:
Disk /dev/sdf - 500 GB / 465 GiB - CHS 60801 255 63

     Partition                  Start        End    Size in sectors

 1 * HPFS - NTFS              0   1  1 60800 254 63  976768002

SEARCH findet dann beide Partitionen:
Code:
Disk /dev/sdf - 500 GB / 465 GiB - CHS 60801 255 63
     Partition               Start        End    Size in sectors
D Linux                    0   1  1 60800 254 63  976768002 [extern]
D HPFS - NTFS              0   1  1 60800 254 63  976768002

Structure: Ok.  Use Up/Down Arrow keys to select partition.
Use Left/Right Arrow keys to CHANGE partition characteristics:
*=Primary bootable  P=Primary  L=Logical  E=Extended  D=Deleted
Keys A: add partition, L: load backup, T: change type, P: list files,
     Enter: to continue
EXT3 Large file Sparse superblock Backup superblock, 500 GB / 465 GiB

Mit P kann ich mir schon die alten Daten auf der Linux-Part. ansehen, wenn ich die aber auf P oder * setzte und mit [write] schreiben lasse ist nachher doch wieder alles beim alten. Ob Reboot oder un/mount, Kubuntu 8.04 findet immer wieder nur die ntfs Part.

Was mache ich falsch? Meine Vermutung ist, TD schreibt keine Partitionstabelle, sondern tut nur so. Warum nur? wegen des USB Laufwerks?

Tipps und Ratschläge willkommen ...
 
Hi,

Wie ist denn hier die Story ausgegangen? Ich hab derzeit ein ähnliches Problem.

Danke und Gruß!
 
Die Sache ist die: Die Angaben in Testdisk bzgl. der Festplattengeometrie gelten nur für den aktuellen Lauf des Programms, Änderungen sind also nicht permanent.

Versuch mal, dein BIOS zu aktualisieren oder das Problem so zu umgehen, wie ich oben geschildert habe, also per kernel command line.
 

Ähnliche Themen

Software RAID 1 verkleinern

Neue Partition unter openSUSE 12.2 erstellen

USB Festplatte wird nicht erkannt

mdadm: cannot open device: No such file or directory

mdadm Problem

Zurück
Oben