![]() |
|
Register | Forum Rules | Support Ticket System | Members List | Social Groups | Edit System Specs | Search | Today's Posts | Mark Forums Read |
![]() |
|
Thread Tools | Search this Thread |
Rating: ![]() |
Display Modes |
#1
|
|||
|
|||
![]()
I have been trying to align the partitions on my SSD for a dual boot (Linux/Windows 7) configuration, and I keep running into a disk geometry corruption problem. I started with Theodore Ts'o's blog post on aligning SSDs, and I figured if I simply followed Ted's suggestions to start fdisk with the -H 224 -S 56 geometry parameters, (so I can align on 128k boundaries for my Corsair P256 SSD), and then create all of my Linux and Windows partitions, that I would be set. I don't want to use LVM. I just want to partition the drive statically for both OSes, (like I've done in the past). So I created the following partitions;
/dev/sda1 - 32M for /boot /dev/sda2 - 35G for my Windows 7 OS /dev/sda3 - 55G for my Windows 7 Data /dev/sda4 - (rest of drive for extended partition) /dev/sda5 - 4G for my Linux swap partition /dev/sda6 - rest of drive for my Linux root partition Creating the partitions using fdisk works fine, and if I do a fdisk -l right after I'm done, I see the geometry reported correctly as 224 heads, and 56 sectors. I even do all of my mkfs/mkntfs/mkswap steps, from the SystemRescueCD, after partitioning, and fdisk -l still reports the geometry and partitions correctly. My problem is that when I reboot to do my directed Windows 7 install to /dev/sda2, (no partitioning and no formatting), after I reboot to the SystemRescueCD again, to begin my Linux install, I find that the disk geometry has been corrupted by the Windows installation. When I look at the disk again with fdisk -l, it reports that the drive geometry is now the default 255 heads and 63 sectors, and that partitions do not end on cylinder boundaries. Like this; Code:
root@sysresccd /root % fdisk -l Disk /dev/sda: 256.1 GB, 256060514304 bytes 255 heads, 63 sectors/track, 31130 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Disk identifier: 0xf7c8e09a Device Boot Start End Blocks Id System /dev/sda1 1 4 31332 83 Linux Partition 1 does not end on cylinder boundary. /dev/sda2 * 4 4574 36703744 7 HPFS/NTFS /dev/sda3 4574 11754 57677312 7 HPFS/NTFS Partition 3 does not end on cylinder boundary. /dev/sda4 11754 31131 155645952 5 Extended Partition 4 does not end on cylinder boundary. /dev/sda5 11754 12277 4202212 82 Linux swap / Solaris /dev/sda6 12277 31131 151443684 83 Linux Code:
root@sysresccd /root % fdisk -H 224 -S 56 -l Disk /dev/sda: 256.1 GB, 256060514304 bytes 224 heads, 56 sectors/track, 39869 cylinders Units = cylinders of 12544 * 512 = 6422528 bytes Disk identifier: 0xf7c8e09a Device Boot Start End Blocks Id System /dev/sda1 1 5 31332 83 Linux /dev/sda2 * 6 5857 36703744 7 HPFS/NTFS Partition 2 does not end on cylinder boundary. /dev/sda3 5858 15053 57677312 7 HPFS/NTFS /dev/sda4 15054 39869 155645952 5 Extended /dev/sda5 15054 15723 4202212 82 Linux swap / Solaris /dev/sda6 15724 39869 151443684 83 Linux I also tried doing this from Windows. I booted the Windows 7 install disc, and then created all the same partitions as above with the Windows command line disk partition tool, diskpart.exe, (which defaults to a 1024K offset for the first partition). I then installed Windows 7, and then rebooted with the SystemRescueCD to install Linux, and fdisk -l again showed a geometry of 255 heads, 63 sectors, (which may or may not have been correct. I don't know how to check the geometry from diskpart), but also partition 1 not ending on a cylinder boundary. I've read this Microsoft Technet forum post that suggest that some Windows 7 users having problems with formatting floppy disks, because of Windows 7 corrupting the disk geometry. I don't know if this is related to that or not. Has anyone else seen anything like this? BTW, the only way I was able to get through an SSD partition -> installation of Windows 7 -> and then an installation of Linux, without fdisk reporting corrupted disk geometries, was to start all over with fdisk, and partition the SSD with the default disk geometry parameters only, fdisk /dev/sda. In other words, run fdisk without any additional drive parameters. Thanks.. Last edited by jasn; 04-22-2010 at 07:10 PM. |
#2
|
||||
|
||||
![]()
I would use Windows 7 and just let it automatically create and format the drive for you, and the Format allocation should be 32K by default.
If you want to have it boot to Linux I would suggest using a Boot manager
__________________
Support accounts and tickets can be created at https://support.corsair.com. |
#3
|
|||
|
|||
![]()
I already tried using the Windows 7 setup Customized Installation tool to set up my partitions, and it resulted in the same behavior I outlined in my post above. Regardless, I'm not asking for help in setting up my system. I believe that the Windows 7 installer is corrupting "non-standard" partition layouts, and I was curious if anyone has noticed this behavior as well. In my case, the Windows 7 installer clearly changed my custom partition setup of 224 heads and 56 sectors back to the default 255 heads and 63 sectors, which corrupted the existing partitions and the data in those partitions.
As I stated, the only way I could set up my dual boot system correctly was to boot with my SystemRescueCD and use Linux fdisk, to setup the partitions, and then install Windows 7 on its partition, followed by installing Linux on its partition. I could only do this by running fdisk without customized geometry thereby NOT aligning the partitions. Finally, what I mean by "setup correctly" is that when I run a partition tool like fdisk now, it doesn't burp out any warnings, and more importantly, I don't have any corrupted data in any partition. If anyone has noticed these kinds of irregularities, or even successfully aligned their SSD partitions for a dual boot Linux/Windows setup, please feel free to share your experience. Thanks.. |
#4
|
||||
|
||||
![]()
Yes and in the Windows 7 Documentation they sent to me with my copy they stated that Windows 7 would not support booting to multiple O.S. as previous versions of Windows had and suggested using a Boot manager
__________________
Support accounts and tickets can be created at https://support.corsair.com. |
#5
|
|||
|
|||
![]()
In case anyone searching, finds this thread..
I was finally able to solve this issue, with information provided by the author, "Chuckula", at the blog posting here. My goal was to install both Gentoo Linux (64bit), as well as Windows 7 Pro, on a single SSD in my laptop, in a dual boot configuration, with the following partition layout; /dev/sda1 - 32M for /boot /dev/sda2 - 100G for my Windows 7 OS and Data /dev/sda3 - (rest of drive for extended partition) /dev/sda5 - 4G for my Linux swap partition /dev/sda6 - rest of drive for my Linux root partition Since I was upgrading my SSD, I decided to revisit this issue, and see if I could again figure out how to align the partitions correctly. So after reading the blog post, I started fdisk with; Code:
fdisk -uc /dev/sda Code:
fdisk -ucl /dev/sda Code:
Disk /dev/sda: 512.1 GB, 512110190592 bytes 255 heads, 63 sectors/track, 62260 cylinders, total 1000215216 sectors Units = sectors of 1 * 512 = 512 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disk identifier: 0x20139a42 Device Boot Start End Blocks Id System /dev/sda1 2048 67583 32768 83 Linux /dev/sda2 * 67584 209782783 104857600 7 HPFS/NTFS /dev/sda3 209782784 1000215215 395216216 5 Extended /dev/sda5 209784832 218173439 4194304 82 Linux swap / Solaris /dev/sda6 218175488 1000215215 391019864 83 Linux Code:
Disk /dev/sda: 512.1 GB, 512110190592 bytes 255 heads, 63 sectors/track, 62260 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disk identifier: 0x20139a42 Device Boot Start End Blocks Id System /dev/sda1 1 5 32768 83 Linux Partition 1 does not end on cylinder boundary. /dev/sda2 * 5 13059 104857600 7 HPFS/NTFS /dev/sda3 13059 62261 395216216 5 Extended Partition 3 does not end on cylinder boundary. /dev/sda5 13059 13581 4194304 82 Linux swap / Solaris /dev/sda6 13581 62261 391019864 83 Linux Finally, something interesting is that when I went back and tried to use the Windows utility, diskpart, to partition the drive, the first partition also started at sector 2048. I'm currently using fdisk version 2.17.2 from the SystemRescue CD 1.5.2 now, and I think that what may have been happening here was more to do with fdisk, than the Windows OS. Maybe Windows was trying to align the partitions, but corrupting thingsand getting hung up with the fact that there was no more partition/space on the drive. "Chuckula" seemed to have some suggestions for Linux devs, towards the end of the blog, along the lines of making the Linux tools for SSD partition alignment friendly, so we'll see. BTW, I did verify that my original dual boot SSD installation used unaligned partitions, which worked fine, except I was curious what kind of performance penalty I might be incurring. So I performed some benchmark testing on both aligned and unaligned NTFS partitions, on the same SSD, under Windows 7, with the AS SSD Benchmark utility, and although the aligned partition performed better, the differences in scores between aligned and unaligned partitions, were small. Here's an example; Code:
Aligned Partition AS SSD Benchmark 1.5.3753.27631 ------------------------------ Name: CORSAIR CMFSSD-256GBG2D ATA Device Firmware: VBM19C1Q Controller: msahci Offset: 1024 K - OK Size: 238.47 GB Date: 4/21/2010 9:33:43 PM ------------------------------ Sequential: ------------------------------ Read: 222.71 MB/s Write: 164.00 MB/s ------------------------------ 4K: ------------------------------ Read: 14.76 MB/s Write: 5.81 MB/s ------------------------------ 4K-64Threads: ------------------------------ Read: 28.73 MB/s Write: 2.98 MB/s ------------------------------ Access Times: ------------------------------ Read: 0.370 ms Write: 0.668 ms ------------------------------ Score: ------------------------------ Read: 66 Write: 25 Total: 128 ------------------------------ Code:
Unaligned Partition AS SSD Benchmark 1.5.3753.27631 ------------------------------ Name: CORSAIR CMFSSD-256GBG2D ATA Device Firmware: VBM19C1Q Controller: msahci Offset: 40162 K - BAD Size: 238.47 GB Date: 4/21/2010 10:00:53 PM ------------------------------ Sequential: ------------------------------ Read: 205.43 MB/s Write: 107.90 MB/s ------------------------------ 4K: ------------------------------ Read: 13.48 MB/s Write: 5.01 MB/s ------------------------------ 4K-64Threads: ------------------------------ Read: 24.51 MB/s Write: 3.45 MB/s ------------------------------ Access Times: ------------------------------ Read: 0.278 ms Write: 0.778 ms ------------------------------ Score: ------------------------------ Read: 59 Write: 19 Total: 109 ------------------------------ Good Luck.. |
![]() |
Thread Tools | Search this Thread |
Display Modes | Rate This Thread |
|
|