- fix DPI (if needed) 300 DPI is minimum
- fix text size (e.g. 12 pt should be ok)
- try to fix text lines (deskew and dewarp text)
- try to fix illumination of image (e.g. no dark part of image)
- binarize and de-noise image
There is no universal command line that would fit to all cases (sometimes you need to blur and sharpen image). But you can give a try to TEXTCLEANER from Fred’s ImageMagick Scripts.
If you are not fan of command line, maybe you can try to use opensource scantailor.sourceforge.net or commercial bookrestorer.