I had my system dual-booted with Ubuntu 14.04. However, I found myself not using it enough to warrant the storage space. I deleted the ubuntu partition and the ubuntu swap partition.
However, am now facing two problems that I have struggled to solve.
I have been unable to reclaim the disk space from the deleted partitions. I've tried booting into recovery mode Command+R and repairing the disk. The disk repairs successfully, but still remains the same size, and will not let me increase the partition size.
The system is still trying to use the grub bootloader. In order to boot to OS X I have to hold down the Option key on startup. This issue is more of an annoyance, but I would love to figure out how to solve it.
Is any of this possible without a fresh install of the OS?
Edit: Screenshot of partition table below. Also, using OSX 10.10.3 Yosemite.
Edit: Could this have anything to do with the Recovery HD below by osx's hard drive on the partition list? Is it safe to remove the recovery hd given that CMD + R reboots are now an online process?
Edit: Output of requested commands below:
diskutil list
/dev/disk0
#: TYPE NAME SIZE IDENTIFIER
0: GUID_partition_scheme *320.1 GB disk0
1: EFI EFI 209.7 MB disk0s1
2: Apple_HFS Macintosh HD 245.4 GB disk0s2
3: Apple_HFS Recovery HD 650.0 MB disk0s3
/dev/disk1
#: TYPE NAME SIZE IDENTIFIER
0: Apple_partition_scheme *137.4 MB disk1
1: Apple_partition_map 32.3 KB disk1s1
2: Apple_HFS VirtualBox 137.4 MB disk1s2
sudo gpt -r show /dev/disk0
start size index contents
0 1 PMBR
1 1 Pri GPT header
2 32 Pri GPT table
34 6
40 409600 1 GPT part - C12A7328-F81F-11D2-BA4B-00A0C93EC93B
409640 479330712 2 GPT part - 48465300-0000-11AA-AA11-00306543ECAC
479740352 262144
480002496 1269536 3 GPT part - 48465300-0000-11AA-AA11-00306543ECAC
481272032 143870383
625142415 32 Sec GPT table
625142447 1 Sec GPT header
sudo fdisk /dev/disk0
Disk: /dev/disk0 geometry: 38913/255/63 [625142448 sectors]
Signature: 0xAA55
Starting Ending
#: id cyl hd sec - cyl hd sec [ start - size]
------------------------------------------------------------------------
1: EE 1023 254 63 - 1023 254 63 [ 1 - 625142447] <Unknown ID>
2: 00 0 0 0 - 0 0 0 [ 0 - 0] unused
3: 00 0 0 0 - 0 0 0 [ 0 - 0] unused
4: 00 0 0 0 - 0 0 0 [ 0 - 0] unused