Ubuntu boot slow after resizing partition

I recently resized my Ubuntu partition to move some space from a Windows partition and I noticed that, upon rebooting, the Ubuntu startup was much slower. It turns out, in the process of resizing my root partition, I had also moved my swap partition. My /etc/fstab file still had the UUID for the old swap partition (I had done the partition resizing with gparted on the Ubuntu live usb, so it did not update the fstab file). The solution was to do the following:

  1. Get the UUID for your new swap partition using sudo blkid
  2. Update the UUID for the swap partition in the /etc/fstab file (you can edit in a terminal using sudo nano /etc/fstab)
  3. Reboot and check if that solved the slow boot problem