According to the MSDS for lithium ion batteries, fires involving them can be extinguished with a typical ABC fire extinguisher.
Lithium batteries (not the rechargeable kind) are the ones that need a class D extinguisher.
Edit:
> CO extinguishers, halon or copious quantities of water or water-based foam can be used to cool down burning Li- ion cells and batteries. Do not use for this purpose sand, dry powder or soda ash, graphite powder or fire blankets.
> Extinguishing media Use water or CO2 on burning Li-ion cells or batteries
Obviously there should be a physically separate circuit for cutting off power in the event of catastrophe. That's pretty much rule-of-thumb for large li-ion battery banks.
I thought fire is by definition a combustion reaction, meaning some kind of material reacting with oxygen. What's fire, then? (I feel like a little kid, having to ask that...)
Lithium fires do not require oxygen, so your typical Class ABC fire extinguishers won't actually work on it. You need a class D (dry powder) extinguisher, which is very rare and expensive.