2. Let the three sides of a triangle be integers $l, m, n$ and $l>m>n$. It is known that $\left\{\frac{3^{l}}{10^{4}}\right\}=\left\{\frac{3^{m}}{10^{4}}\right\}=\left\{\frac{3^{n}}{10^{4}}\right\}$, where $\{x\}=x-[x]$. Find the minimum perimeter of such a triangle.
$$
\left\{\frac{3^{l}}{10^{4}}\right\}=\left\{\frac{3^{m}}{10^{4}}\right\}=\left\{\frac{3^{n}}{10^{4}}\right\} \Leftrightarrow 3^{l} \equiv 3^{m} \equiv 3^{n}\left(\bmod 10^{4}\right),
$$

and $3^{m} \equiv 3^{n}\left(\bmod 10^{4}\right) \Leftrightarrow 3^{m-n} \equiv 1\left(\bmod 10^{4}\right) \Leftrightarrow\left\{\begin{array}{l}3^{m-n} \equiv 1(\bmod 16) \\ 3^{m-n} \equiv 1(\bmod 256)\end{array}\right.$
Since $\delta_{16}(3)=4$, then $3^{x} \equiv 1(\bmod 16) \Rightarrow 4 \mid x$;
Let $\delta_{625}(3)=t$, then $t \mid \varphi(625)=500$. On the other hand,
$$
\begin{array}{l}
3^{50} \equiv(6561 \cdot 9)^{5} \equiv 59049^{5} \equiv(-326)^{5} \equiv(106276)^{2}(-326) \equiv(26)^{2}(-326) \\
\equiv 51(-326) \equiv-16626 \equiv-376 \equiv 249(\bmod 625) \\
3^{250} \equiv 126 \cdot 126 \cdot 249 \equiv 15876 \cdot 249 \equiv 251 \cdot 249 \equiv-1(\bmod 625)
\end{array}
$$

Then $t \nmid 100, t \nmid 250, t \mid 500$, i.e., $t=500$. Therefore, $3^{x} \equiv 1\left(\bmod 10^{4}\right) \Leftrightarrow 500 \mid x$.
Thus, $500|m-n, 500| l-m$, hence $m \geqslant 501, n \geqslant 1001, l \geqslant 1501$.
Therefore, the minimum perimeter of such a triangle is $501+1001+1501=3003$.