Netgate Discussion Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Search
    • Register
    • Login

    [SOLVED] Installing pfSense 2.2 aligned to 4k blocks on SSD

    Scheduled Pinned Locked Moved 2.2 Snapshot Feedback and Problems - RETIRED
    3 Posts 2 Posters 3.9k Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • J Offline
      josh4trunks
      last edited by

      Hi everyone,
      I'm taking the plunge to upgrade to pfSense 2.2 on my home firewall. I'm trying to get it aligned to 4K, which I gave up on with 2.1 but I figured 2.2 would use GPT by default now.

      I can't seem to get this to work. Installing using the "Easy", blow away your disk, method gave me an un-aligned MBR disk. Then I tried using gpart, setting things up similar to this http://www.wonkity.com/~wblock/docs/html/ssd.html and using the "Advanced" install, skipping what I could but at one point, when you pick your slice, it blows away my GPT partition table.

      Finally, I'm going to try to do some math and trick MBR to get aligned to start at 2048, that's where I'm at now. I'd happy to take suggestions, Thanks!

      SOLVED
      I did the following before using the Advanced install.

      gpart create -s mbr ada0
      gpart add -t freebsd -b 504 ada0
      

      This tricked the installer into using a slice that was alligned to both 63 (fake sector) and 8(x512=4K). 16 blocks of free space preceded the UFS partition, but the partition still ended up being 4K aligned.
      (504+16)x512/4096=65 (a nice whole number =] )

      I think a better solution would be to make the partitioner use the flag '-a 4k'. As seen here https://forums.freebsd.org/threads/mbr-and-alignment-on-4k-disks.42725/

      1 Reply Last reply Reply Quote 0
      • D Offline
        dstroot
        last edited by

        Just curious - are you using the full version or the nano version?

        1 Reply Last reply Reply Quote 0
        • J Offline
          josh4trunks
          last edited by

          @dstroot:

          Just curious - are you using the full version or the nano version?

          full

          if anyone else is installing full on an SSD, make sure to enable trim
          Hit CTRL+c during installer shutdown or boot into single-user mode

          /sbin/tunefs -t enable /dev/ada0s1a
          

          I also added the 'noatime' option to the /etc/fstab entry

          1 Reply Last reply Reply Quote 0
          • First post
            Last post
          Copyright 2025 Rubicon Communications LLC (Netgate). All rights reserved.