2. For a positive integer $n$, let $\varphi(n)$ denote the number of positive integers not exceeding $n$ that are coprime to $n$, and let $f(n)$ denote the smallest positive integer greater than $n$ that is not coprime to $n$. If $f(n)=m$ and $\varphi(m)=n$, then the pair of positive integers $(n, m)$ is called a friendly pair. Find all friendly pairs.
(Liu Kaifeng, problem contributor)