Q&A with Stuart Langridge and Bryan Lunduke

Slashdot it! Delicious Share on Facebook Tweet! Digg!




Hi, I would like to know how to put the /home folder on a separate partition, so that I can do a clean upgrade or fresh install without wiping my data. Years ago, when I ran Windoze, I did the same thing, I created another partition, a D drive and put my data on that, so when I had to reinstall Windows (much too frequently for my liking) at least my data was safe.


STUART: OK, putting /home on a separate partition is like deep-fried Mars bars, trickle-down economics, and Honey I Shrunk The Kids : It seemed like a good idea years ago, but time has moved on. A long way on.

Ubuntu has supported doing a reinstall while keeping your /home folder around since version 8.04 in 2008. Simply run the Ubuntu installer as normal by booting from a prepared USB stick or CD and then choose Reinstall Ubuntu 13.10 (or Upgrade Ubuntu 13.04 to 13.10 if you're upgrading rather than reinstalling). That will do a fresh reinstall, or upgrade, of Ubuntu without disturbing your /home folder, and it doesn't need a separate partition at all. There's really not a lot of need for separate partitions on a single-disk system, despite what greybeard relics of the 1990s may tell you.

BRYAN: You have just read "things that Stuart is profoundly wrong about" number 742. Placing your /home on a separate partition is both handy and reasonable – not to mention a great way to boost your overall system performance. Plus, it earns you at least one Nerd Cred point. Here's how you do it (in a nutshell).

First, create your new /home partition on some free space or a second drive (I recommend using ext3 for maximum compatibility with as many distros as possible). Copy over any files you want to keep in your new /home . Then, simply install Ubuntu with your /home mounted. Wham. Done.

Now, if your existing disk partitions fill up the entire disks, you'll need to shrink one or more of them first to get some free space. To do this, boot from the Ubuntu Live CD and then, when you're in the live environment, run GParted Partition Editor from the Dash. GParted knows how to resize existing partitions and create new ones: Right-click a too-big partition, choose Resize/Move to show details of a particular partition, and then drag the bar in the window or enter a new size in digits. You can then continue using GParted to create a new partition in the free space; make it ext3 or ext4 as the filesystem (Figure 1).

Figure 1: GParted knows how to create and resize partitions.

Still in the Live environment, look in the file manager under Devices to see your newly created partition and your previously existing one. You can then copy all your home folder's contents to the new partition. Make sure you copy your whole home folder, not just the contents of your home folder (so copy the folder named yourusername , not just all the stuff in that folder).

The new partition's UUID , which is a long meaningless-looking string like bf42ad83-d38a9-d3a89-3903-a3930d , will be shown in Location in the file manager: Remember this. (You can also get it by starting a terminal, either before or after restarting, and entering sudo blkid . After you enter your password, it'll list your partitions.)

You may also want to create a file in the new home folder called something like ThisIsTheNewHome , so you can tell the difference. Restart the computer into your normal environment (not the Live CD) and log in (to your old home folder). Then, in a terminal, do gksu gedit /etc/fstab and enter your password. You're adding a new line to this file, which looks like this:

UUID=xxxxxxxxxxxxxxxx   </home>   ext4 nodev,nosuid 0 2

where xxxxxxxx is the uuid you remembered from above (or got from sudo blkid in another terminal).

There will likely be at least one more line beginning UUID=… in that file; that's fine.) This line tells the machine: When you start up, mount my new partition (identified by the UUID) as /home . Once you've told the machine that, you can restart, and after logging into your home folder, you should have your ThisIsTheNewHome file in it, meaning that it all worked!

And, more importantly, you can feel superior to Stuart.


How can I work with HDR photos in Ubuntu? Gerald

BRYAN: Ah, HDR photography! The golden, flying unicorn of taking pretty pictures!

HDR photography, for the uninitiated, is a pretty simple concept. You set up your camera to take a bunch of pictures, super-duper quickly, at different exposure levels. You're left with, in theory, multiple versions of the same picture at different light levels. Those different versions can then be combined together to make one mega pretty picture. Neat, right?

Here's the thing. It's kinda dumb. HDR photography really only works well if you have a completely still scene and you're using a tripod (because you really need multiple photos that you can combine together… and if there's any real variance in the photos you end up with a blurry picture). This means that 99.99999999% of all photos taken (give or take) should not be done this way.

My advice: Take a picture. Save it as a big, giant JPEG and enjoy the fact that you can view (and edit) it with GIMP… or any other piece of software on the entire planet.

STUART: Pay no attention to the nay-sayer here. HDR can result in some amazing photos, and working with them on an Ubuntu workstation is delightfully simple.

To begin, take your photo. Specifically, you'll need to be able to take that photo in RAW format, and that single shot will need to have multiple versions of the photo taken at multiple light levels as Bryan says.

Most DSLRs provide this functionality; most compact cameras or mobile phones don't, so this is a technique for people with a Proper Camera. I agree with Bryan here (owing to a rare moment of Lunduke accuracy): You'll probably want to invest in a tripod to keep your shot steady.

Once you've done that, copy your photos over to your Ubuntu workstation and let the magic of open source go to work.

Install Luminance HDR (search for Luminance in the Dash, or from the Ubuntu Software Center [1]) and launch it (Figure 2). Click the "New HDR Image" button and add all of the pictures that you want to have blended together into one bold, beautiful HDR image. Basically, you're done. Hooray for Luminance! Everything from here is just tweaking.

Figure 2: After you install Luminance HDR, the rest is cake.

You have a bunch of different tweaking options, including the ability for Luminance to attempt to auto-align the images in case you skipped that "use a tripod" suggestion above. You can also tone-map the images, tweak various histogram things, and so on. For a first run, you can probably just hit the next button until Finish appears.

What you'll be left with is an honest-to-goodness HDR image. You can adjust the image further using the tools on the left side of the Luminance window. And, of course, you always have the option of saving it from Luminance and further tweaking it in your favorite photo-editing suite (GIMP, probably) to blow the doors off a non-HDR image.

You can find more tips about both the initial photography (f-stop ratings and so forth) and HDR color profiles in a tutorial from Ian Hex [2].

Or, you know, you can ignore this amazing photography technology and just take "big, giant JPEGs" like my compatriot across the pond. Also, cheeseburgers instead of steak. Enjoy.

Buy this article as PDF

Express-Checkout as PDF

Pages: 2

Price $0.99
(incl. VAT)

Buy Ubuntu User

Get it on Google Play

US / Canada

Get it on Google Play

UK / Australia

Related content