2. If $n$ positive real numbers $x_{1}, x_{2}, \cdots, x_{n}$ satisfy the equation
$$
\sum_{k=1}^{n}\left|\lg x_{k}\right|+\sum_{k=1}^{n}\left|\lg \frac{1}{x_{k}}\right|=\left|\sum_{k=1}^{n} \lg x_{k}\right|
$$

then the values of $x_{1}, x_{2}, \cdots, x_{n}$ are $\qquad$
2. $x_{1}=x_{2}=\cdots=x_{n}=1$.

The original equation is
$$
\begin{array}{l}
2 \sum_{k=1}^{n}\left|\lg x_{k}\right|=1 \sum_{k=1}^{n} \lg x_{k} \mid \\
\Rightarrow 2 \sum_{k=1}^{n}\left|\lg x_{k}\right| \leqslant \sum_{k=1}^{n}\left|\lg x_{k}\right| \\
\Rightarrow \sum_{k=1}^{n}\left|\lg x_{k}\right| \leqslant 0 .
\end{array}
$$

Thus $\left|\lg x_{k}\right|=0(1 \leqslant k \leqslant n), x_{1}=x_{2}=\cdots=x_{n}=1$.
Conversely, when $x_{1}=x_{2}=\cdots=x_{n}=1$, the given equation clearly holds.