In this tutorial I will try to tell how to install debian on a USB stick shortly. This section does not include copying live linux ISO's to USB but this section helps you. You can freely carry your usb stick with you and run it on any computer. BUT, after your installation do not expect a good performance from OS because even if you use a USB 3.0, limited simultaneous read/write performance prevents you from having a good performance.
Since this was my first installation on USB, I had some problems.
First problem was I selected LVM during partitioning. I do not know why but with LVM, USB does not boot. If anybody knows and share it with me I will be glad.
Second problem was I forgot to put a boot flag on the primary partition of the USB. You can do this with “gparted” installed any other linux.
You can use vmware player for all operations so you can deal with other things during installation.
Important pictures of the installation is below including gparted.
Do not choose LVM
Select your target usb for GRUB installation correctly. You will probably have more than one disk here, so do not damage your existing OS.
Click on boot flag if missing.
Now it is ready to use. Just boot your pc with your new USB by changing settings from BIOS. Have fun.
When you download ISO images of Debian or any other Linux distribution you most probably write it to a USB to install it to another computer. Since USBs took the place of CD and DVDs, you need a tool to copy ISO image to USB. For Windows systems, there are many softwares out there but I like to use Rufus. It is small, open sourced, no installation required and very stable. I have not had any problems so far. I found a nice youtube video showing how to use Rufus;
For Linux users, you do not need to install any software you have it in your system that is
After downloading iso and plugging your usb in, identify usb's device path then run
dd if=<your_iso_file>.iso of=<device> sync
If you cannot find the device path, you can use the following commands
ls -l /dev/disk/by-id/
umount /dev/sdb1 dd if=<your_iso_file>.iso of=/dev/sdb sync
Make sure you unmount the usb before
dd command, because if any activity occurs on usb while
dd is running, your partition may be broken.
dd command does not inform you about progress, sit and wait till it finishes.
bs=4M argument can make the progress faster for