fdisk: One that’s not from coreutils

I have fdisk on my list of applications to include, and I suppose it warrants inclusion, even if I have a personal reason for writing about it. This is out of util-linux, not coreutils, which is a change … over the past few days, anyway. :roll:

Or maybe not. fdisk is a tool for “creating and manipulating partition tables,” which means two things — first, it doesn’t belong in coreutils ;) ; and second, it has the potential to completely destroy your system if you use it wrong.

2013-11-06-lv-r1fz6-fdisk

Of course, you could say that about a lot of things. That doesn’t mean fdisk is something you should avoid. Live a little. Don’t be afraid to try something new. If you need a completely sterile, padded and antiseptic existence, I hear Windows 8.1 is a lot like a child’s pull toy. :twisted:

The easiest and probably most popular use for fdisk is checking what hard drives are connected to your computer. As you can see in the screenshot, if you tack on the -l flag, you’ll get a neatly formatted list of drives and partitions, along with sensitive and personal information for each.

fdisk can also manipulate or create partitions, and if you start it and aim it at a device label, you’ll have the option to delete, create, modify or adjust partitions on that device.

I suppose it should go without saying that you’ll need superuser permissions or root account access to do any real damage to your system. And for goodness sake and all that is holy, don’t use fdisk lightly. And don’t complain to me if you destroy your collection of family photos by tinkering with the partitions on your external drive.

There’s more you can do with fdisk, but I should probably admit that when it comes time to arrange partitions, on a new drive or at installation time. I usually rely on cfdisk, which is also part of util-linux.

I know there are hard-core Linux geeks out there who wouldn’t dream of using anything but fdisk to set up a drive, just like they wouldn’t dream of using anything but ed to edit a text file.

I just prefer the arrangement and the dialogs. It’s more intuitive for me.

So what’s my personal reason for including fdisk here? Well, you see, fdisk got something lately — in version 2.24 in Arch — that I really like. And if you looked at the screenshot you probably already know what it is. …

Color! :mrgreen:

P.S., sorry, Debian fans. You’re still stuck at 2.20 in Wheezy. …

About these ads

3 thoughts on “fdisk: One that’s not from coreutils

  1. thisnameisfalse

    I am one of these strange people who prefers fdisk to all other alternative programs (cfdisk, sfdisk, parted, et al).

    Sadly, there are different “fdisk” commands from different suppliers.
    -Traditional fdisk at linux distros is from util-linux or util-linux-ng packages.
    -GNU project implemented a new fdisk (gnu-fdisk) with modular source code:
    http://savannah.gnu.org/forum/forum.php?forum_id=6973

    Different distros use different fdisks

    PS: You are right: fdisk with color!!!

    Reply
    1. K.Mandla Post author

      That’s new, I hadn’t heard about gnu-fdisk before. Not that I am a hub of new information though, either. … :roll:

      Reply
  2. Pingback: parted: The forgotten partition tool | Inconsolation

Leave a reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s