Interestingly, byb, under bartleby the primary meaning of barratry is the one which you note is, under MW on-line, merely the tertiary meaning. A related legal term is champerty; for the distinction between the terms see
http://dictionary.law.com

bartleby:
barratry: 1. The offense of persistently instigating lawsuits, typically groundless ones.
champerty: A sharing in the proceeds of a lawsuit by an outside party who has promoted the litigation.

law.dictionary (emphasis added):
champerty: an agreement between the party suing in a lawsuit (plaintiff) and another person, usually an attorney, who agrees to finance and carry the lawsuit in return for a percentage of the recovery (money won and paid). In common law this was illegal on the theory that it encouraged lawsuits. Today it is legal and often part of a "contingent fee" agreement between lawyer and client. It is not the same as barratry, which is active encouragement of lawsuits.
barratry: creating legal business by stirring up disputes and quarrels, generally for the benefit of the lawyer who sees fees in the matter. Barratry is illegal in all states and subject to criminal punishment and/or discipline by the state bar, but there must be a showing that the resulting lawsuit was totally groundless. There is a lot of border-line barratry in which attorneys, in the name of being tough or protecting the client, fail to seek avenues for settlement of disputes or will not tell the client he/she has no legitimate claim.