Posts in category ubuntu

GPT Booting with Ubuntu

So if you buy a 3 TB drive (or anything bigger than 2TB) and want to use it as the primary drive for your machine you will need to use a GPT paritioning system instead of the classic MBR.

Here's a couple of tricks/tips which should help:

  • You need to be using an OS that has GRUB2
  • When partitioning, the 1st partition should be a 1 MB section with the bios_grub flag (recent versions of the Ubuntu installer, at least 11.04 has this option, 10.04 I had to set if with a Live disc and parted)
  • When you get to the install GRUB question, if you happen to be installing to something other than /dev/sda say no, and then it will ask you which drive or partition to install to.

Un-doing the partition mess from a dual boot

More and more, when I make a dual boot system it turns out that 6 months to a year down the line the windows partition just isn't needed anymore. But now you've got 10GB+ of disk just sitting out at the front of the drive.

Over the holiday I tackled a shuffling of partitions and here's the important tips I picked up.

  1. Copy your important data to another drive (an external usb is great)
  2. Using the Ubuntu disk tools like gparted blank the space where you want to move stuff to.
  3. Using the  Clonezilla live disc (and either partimage or  partclone [the new variant that handles ext4]) clone your / partition over to the new space.
  4. Relabel the UUID of this new partition, otherwise it will be identical to the UUID of the original and the bootloader will quasi load both
      uuidgen
      tune2fs /dev/hdaX -U numbergeneratedbyuuidgen
    

5.Edit your grub config to boot the new drive. If you reboot into Ubuntu running the update-grub will find it.

  1. Once you're sure you can boot the relocated / you can add the empty space onto your /home (I always recommend separate / and /home partitions)

Things I also recommend:

  1. Converting ext3 to ext4
  2. Creating a Private directory for storing encrypted stuff.

Installing Sqlite 3.6.x on Ubuntu Intrepid

I needed sqlite 3.6 or newer for an application I'm working on but Ubuntu Intrepid has 3.5.9, specifically for Rtree spatial indexes. (In order to build and use  Spatialite.

After weighing my options and doing a little research I noticed that the Jaunty packages barely have any dependencies and they are already met by Intrepid.

So I downloaded:

Steps to follow:

  1. Uninstall libsqlite3-dev 3.5.9
  2. Install libsqlite3 3.6.10
  3. Install libsqlite3-dev 3.6.10
  4. Install sqlite3 3.6.10

To test with python(happens to be what I'm developing with)

from pysqlite2 import dpapi2 as sqlite3
print sqlite3.sqlite_version