2. Represent the integer 2016 as
$$
2016=\frac{\left(a_{1}!\right)\left(a_{2}!\right) \cdots\left(a_{m}!\right)}{\left(b_{1}!\right)\left(b_{2}!\right) \cdots\left(b_{n}!\right)} \text {, }
$$

where, $a_{1} \geqslant a_{2} \geqslant \cdots \geqslant a_{m}, b_{1} \geqslant b_{2} \geqslant \cdots \geqslant b_{n}, a_{i} 、 b_{j}$ $(i=1,2, \cdots, m ; j=1,2, \cdots, n)$ are all positive integers. Then, when $a_{1}+b_{1}$ takes the minimum value, the minimum value of $m+n$ is ( ).
(A) 3
(B) 4
(C) 5
(D) 6
2. B.

Given $2016=2^{5} \times 7 \times 3^{2}, 7>3>2$, and 7 is in the numerator, we know $a_{1}=7$.

There does not exist a prime $p$ such that $p$ is a prime factor of 2016, then $b_{1}<p<7$.

The largest prime less than 7 must be in the numerator, so $b_{1}=5$.
$$
\text { Therefore, } 2016=\frac{(7!)(4!)(2!)}{5!} \text {. }
$$

Thus, the minimum value of $m+n$ is 4.