I have a 32 GB USB pendrive which I'd like to use as both a startup/installation disk for Ubuntu, and for regular file storage/transfer purposes. Since the Ubuntu installation stuff only needs a little under 3 GB, I thought this would be no problem, but it has turned out to be harder than I thought.
My plan was to create two partitions on the drive - one 4GB that I can wipe at any time and use for installation media, and one with the rest of the space that I can use for data (and won't have to wipe when I create a new installation disk). Creating the partitions posed no problems - gparted did that without complaining - but installing the Ubuntu installation stuff has turned out to be harder than I thought.
In the "Startup Disc Creator" program, I can't select the USB drive's partiions individually - just the entire drive. And if I don't press "Erase disk", I'm not allowed to start the installation. I've tried setting the "boot" flag on the partition I want to use, but it didn't matter. It seems the startup disc creator program isn't "partition aware" - is it? Or do I need to do this with another program?
Is there a way that I can create a bootable USB drive where just one partition is used for the installation media? How?
I had the same problem. I had a USB Hard drive that had some data on it but was about 80% free that I wanted to use to test out Live CDs on. But the “Startup Disk Creator” would only recognise the disk as a whole and wanted me to erase it, despite it having three partitions (two of which were empty and Ext file systems).
I found a way around this however. I used GParted to delete and recreate the two empty partitions but this time making them FAT32 partitions (the same as the first partition) and also making them both Primary partitions. Once this was done the Startup Disk Creator recognised all three partitions and I was able to use one of them to create a Startup Disk, whilst keeping my content on the first partition. I am not sure why this worked, but it did.
I hope this is of help to people.
Use Ubuntu's Disks program. Startup Disk Creator freezes from time to time.
Create your partitions using Disks/Gparted, then click on the partition and click on the 'two gears' icon to the right of the '-' then click 'Restore Partition Image'
Restoring Partition Image is what you want.
Restoring Disk Image from the main menu formats the whole drive.
Once upon a time, I was experimenting with ArchLinux and read about this issue.
The information is on https://wiki.archlinux.org/index.php/USB_Installation_Media
There is a section 'without overwriting the USB device'. But it's talking about the Syslinux-bootloader, not GRUB2-bootloader. So maybe this information is not relevant.
Good luck!
I don't know how to choose the partition before installing, but what I normally do is to install Ubuntu onto the whole pendrive, and then resize it and add the other partitions.
This will remove the data already on your drive, though - you'll have to back it up somewhere and copy it back when your done.
I use MultiSystem for my LiveUSB drive to try out several Linux distros without installing them, but I think this software might fit your use case.
You can keep the live ISOs and your data on the same partition when using MultiSystem, because they do not affect each other and live alongside without concern. That is because MultiSystem install GRUB2 on your drive, managing the ISOs and a couple of tools but not caring about whatever else is on the drive.
Therefore, instead of managing two partitions, you could create a folder in the root directory of your only partition called "Data" (or whatever suits you) and use that folder just like you would have used your data partition.
Alternatively, you could just drop your data directly into the root directory of your drive, though that would require you to be careful about not touching the files MultiSystem requires to boot your live ISO.
I never used the Startup Disk Creator, so maybe you can actually just use that tool and create a Data folder on your drive.
I was able to make it work with Ubuntu.
Steps:
i. Create two primary partitions on your usb drive.
ii. Use Unetbootin to create startup disk on first partition
iii. Boot from pendrive, select 'Try Ubuntu without installing'
iv. Now start Installation Wizard from desktop
v. Select language and other options
vi. Select second partition on Pen Drive as root (/) partition
vii. Select /dev/sdb (not /dev/sdb2) to install boot loader
viii. Before hitting Install Now, open a terminal and type:
sudo umount -l -r -f /cdrom
ix. Hit 'Install Now', installation should complete successfully
I used NetBootin to install to the partition I wanted. My Data partition was NTFS and my Ubuntu partition was ext2, but you could probably use ext4. UnetBootin didn't even acknowkledge the NTFS partition, and instead automatically selected the ext2 partition, and install went well. The Boot Disc Creator didnt work for me either.