Clearly Knuth's original TeX, TeX82, can produce .dvi files. Of the 'current' engines, pdfTeX and LuaTeX can produce both .dvi and .pdf files directly, while XeTeX produces a extended DVI (.xdv) format. There are also some more specialist engines, for example KerTeX which again produce .dvi files. (I am unsure about pTeX.)
In terms of which commands run a TeX engine in DVI mode, this depends on your TeX distribution and how old it is. pdfTeX has been the standard engine for TeX Live since 2004, as detailed in the release notes:
pdfetex is now the default engine for all formats except (plain) tex
itself. (Of course it generates DVI when run as latex, etc.) This
means, among other things, that the microtypographic features of
pdftex are available in LaTeX, ConTeXt, etc., as well as the e-TeX
features (texmf-dist/doc/etex/base/).
This means that running latex foo, etex foo, etc. uses pdfTeX in DVI mode. For example, on my system running latex gives header information
This is pdfTeX, Version 3.1415926-2.3-1.40.12 (TeX Live 2011)
restricted \write18 enabled.
MiKTeX is similar, although I am unsure of the exact date it switched over to using pdfTeX as the standard engine.
If you want to use pdfTeX for a plain document in DVI mode, then tex foo will not work as that will always use TeX82. So you would need to do pdftex "\pdfoutput=0 \input foo", or similar. (Normally, setting \pdfoutput directly is discouraged as it is done correctly in the format-building procedure.)
When using pdfTeX, it's also important to note that some of the 'new' primitives work in DVI mode, and some do not. The exact details are covered by the pdfTeX manual (texdoc pdftex).
dvifiles orpdffiles. (There's also the original TeX engine, of course, but nowadays when people typetex myfile.tex, they run the pdftex engine.) – Mico Jan 25 '12 at 4:36@syntax. They act as terminators. In this case I got notified instead of MartinSchroeder. It is indeed a waste of space in this case ;-) – Martin Scharrer♦ May 7 '12 at 13:00