Create a boot able USB on Linux

By January 1, 2015Hacking Tutorial

On Linux to create a boot able USB follow this step:

  1. Download start up USB disk  creator
  2. Select the .iso source image and the disk to use
  3. Click make start up disk

To create a boot able USB on command line follow this steps:

  • Place the ubuntu.iso file in any one of your hard disk partition.
  • Then mount the ubuntu.iso file.For this run the below commands in terminal,
    sudo mkdir /media/iso
    sudo mount -o loop /path/to/ubuntu.iso /media/iso
    
  • Then copy all the files from /media/iso to your mounted usb flash drive folder in /media.
    Insert your usb flash drive.My usb flashdrive partition screenshot.
    

    enter image description here

    It will automatically mounted,whenever you insert it.Your usb partition must be mounted inside /media.Let us assume your usb drive mounted inside /media/xxxx folder.Then run the below command,

    cp -a /media/iso/. /media/xxx
    
  • Then paste the ldlinux.sys file inside your USB flash drive partition(In my case /dev/sdd1) to make the usb bootable .For this run the below commands,
    sudo apt-get install syslinux mtools
    sudo syslinux -s /dev/sdd1
    
  • Open the /media/xxx and rename the isolinux directory to syslinux.Then go into the renamed syslinux folder and rename the file isolinux.cfg to syslinux.cfg.
  • Reboot your pc and change the boot-order in bios to USB.Now your ubuntu usb flash drive will booted up and you can install it.