LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   howto create LiveUSB with free space to use (https://www.linuxquestions.org/questions/linux-newbie-8/howto-create-liveusb-with-free-space-to-use-934105/)

lleb 03-12-2012 03:25 PM

howto create LiveUSB with free space to use
 
I would like to setup a LiveUSB device with dedicated free space to use as backup. I have followed http://fedoraproject.org/wiki/How_to...your_USB_stick

to finally create a LiveUSB Fedora16 that works. In order to get it to work first I tried the windows graphical, this failed as it could not download the iso.

then i tried the GUI in my Fedora 15 box. this failed to boot once it was created.

So I tried the dd if=foo.iso of=/dev/sdX1 this did nothing.

next i tried the livecd-iso-to-disk /path/to/ISO /dev/USBPARTITIONNAME

this failed to create anything so I did the livecd-iso-to-disk --format --reset-mbr /path/to/ISO /dev/USBPARTITIONNAME

success. have a bootable flash drive.

Goal is to setup a liveUSB device that I can then setup lvm for backups. As MS Windows has no means of accessing the LVM the LiveUSB will deal with that for gaining access to the data.

Use the usb device as a backup media with LVM configured so as not to deal with /dev/sdX drive letter assigning issues.

If need to recover on a MS Windows system, we do often sadly as they will have 1 linux server and n number of MS Windows workstations we can turn into a temp server on the fly when hardware crashes. Thus the need for the liveUSB that can read the LVM and mount NTFS partitions rw so we can copy the data over from the USB device to the internal HDDs of the windows computer, uncompress the tarball, and decrypt if needed.

Then we can just reboot the system, remove the USB Device, and poof there is the data we need access to in order to get the client up and running again.

Thanks for the help.


oh and yes I tried and failed at setting up the persistent data for the liveUSB on the link above.

lleb 03-13-2012 07:25 AM

was successful at getting a flash drive to boot with Fedora 16 yesterday, but when i used gparted to resize the partitions to free up space on the device to use for storage (was successfully able to create my LVM and access that this morning) it no longer boots.

so gparted did some nasties to the flash drive. going to try to recreate the bootable section this morning.

lleb 03-13-2012 10:06 AM

I think I have it solved. I will know later when I can boot with the device again. Hard to bring a computer down in the middle of the workday.

Steps to solve issue:

Code:

# dd if=/dev/zero of=/dev/sdX
This cleared the system of all the junk I had put on there after messing up so many times.

Then I ran fdisk on it and created partition 1 with option 4 FAT16 <32M, then I made that partition the boot partition and set it size to 1GB. made the 2nd partition with 8e Linux LVM and used the rest of the device.

Then after fdisk i did the following:

Code:

# mkdosfs -F 32 -n usbdisk /dev/sdc1
# livecd-iso-to-disk /path/to/ISO /dev/sdc1

I was then able to create my LVM on the /dev/sdc2. I have tested the LVM on a couple of Linux computers (CentOS 5.4 and Fedora 15), just waiting for a computer to bring down to boot from the flash drive to see if the LiveUSB portion still works.

lleb 03-13-2012 04:26 PM

the above is 100% successful. Please mark this as <Solved>

I was able to boot with the LiveUSB Fedora 16, mount the LVM, decrypt the tarball, uncompress it and save it to the NTFS drive. reboot the computer and have access to the data.

If for nothing else, hope this helps others.


All times are GMT -5. The time now is 02:47 PM.