How can I run Disk Utility in terminal via a comand line?

The application behind "Disk Uitility" changed in newer release versions. Hence the terminal command to call them is as follows:

For >= 12.10

gnome-disks

For earlier versions including 12.04:

palimpsest

Renaming partitions can also be done with a command line tool (no need to install and run gparted):

  • How to rename partitions?

Please note that the device and partition names /sda, resp. /sda1 ... /sdaX and /sdb /sdc .. do not depend on the disk label but are internal device numbers, depending on partition layout, SATA-port attachment, BIOS. To avoid confusion we have a unique UUID for each drive to mount it appropriately. This can be replaced by a label if needed.

  • Constant UUID on USB install

As an alternative from the disk utility you can use Gparted. It is the best tool partitioning and managing of them.

to install gparted in your PC type as

sudo apt-get install gparted

in your terminal.