What is the mechanism of action of anaesthetics?
This answer is a general answer, based on some research.

The mechanisms behind anaesthetics is not entirely understood, according to the article Mechanisms of Anesthesia: Towards Integrating Network, Cellular, and Molecular Level Modeling (Arhem et al. 2003), primarily due to, as you alluded to in your question, the fact that anaesthetics come from a very diverse group of chemicals.

In the fragmentary data presented in the article, the conclusions the authors made were that


  general anesthetics modulate the activity of ion channels, the main targets being GABAA and NMDA channels and possibly voltage-gated and background channels, thereby directly or indirectly hyperpolarizing neurons in thalamocortical loops, and thereby disrupting coherent oscillatory activity in the cortex. In our view, it does not seem unreasonable that the ultimate target is NMDA channels.


There is also a suggestion that the unconsciousness that results is in a way like sleep, an adaptive response to the chemical input.

Interesting perspectives are provided in the article Why anesthetic mechanism research 
has failed, and what to do about it (Hammeroff), where the author suggests, research is needed in investigating anaesthetic mechanisms by


  Look closely at the quantum nature of anesthetic binding by van der Waals 
  London forces.


In terms of local anaesthetics, the slides included in the presentation Local Anesthetics: Overview state that the mechanism here is due to


  Ionized form of weak base 
  blocks $\ce{Na^+}$
  channels
  by binding to an internal 
  sequence involved in channel inactivation