Hey, I need to boot a linux OS off a USB, and all i want to be presented with is a linux shell. Where i can do ./file.sh Then that's it - in the script i wrote it'll auto reboot. Everything needs to be complete in about 30 seconds.
Puppy linux will probably do what you want. It and DSL are both around the 50mb mark. Here's a list of various small distros in case any are more suitable for you http://www.linuxlinks.com/Distributions/Mini_Distributions/ Alternatively you can probably install a minimal version of Debian from the netboot disk, or FreeBSD from its netboot disk, onto your USB stick, for no more than 200 - 300 mb. On modern hardware my FreeBSD 8 servers are at CLI ready for login within I'd guess around 30 or 40 seconds from boot loader.
I couldn't find just a link to the .iso of DSL, so i opted for puppy linux. I don't want this GUI though, all i need is a CLI so i can type one line of code.
A basic install of Archlinux will give you nothing more than a CLI that will boot up quit fast indeed.
Okay well stop puppy automatically loading X and it'll dump you to CLI instead! Check out /etc/inittab and read what it says. Generally you'll find a line that says: Runlevel 5 being X11, it initiates this by default. Change to: Then reboot. Let me know how it goes.
Get the ubuntu mini iso and install to a pendrive with grub on the pen as well, when asked what software to install, just skip, it'll install an Ubuntu even more minimal than Ubuntu Server, pretty much kernel and apt/aptitude, nothing more.
Well you'll need a pretty full distro for the driver support in that case I guess. If your flash disk is several gig, then you won't have a huge problem with the Ubuntu Live distro installed on a USB disk. Using the same method as above, you can prevent it from booting into a GUI. There may be specific instructions available for Ubuntu on how to do that - google is your friend.
Or go for something minimal with instructions for how to put it on a USB stick? http://www.sysresccd.org/