9. Arrange the $n$ positive integers from $1 \sim n (n>1)$ in a row so that the sum of any two adjacent numbers is a perfect square. What is the minimum value of $n$?
9. The smallest positive integer $n$ is 15.

Since $n>1$, it includes 2. The smallest positive integer that, when added to 2, results in a perfect square is 7, represented as $2+7=9$ (the same notation applies below), so $n \geqslant 7$.

If $n=7$, we can get three non-adjacent segments: $(1,3,6),(2,7),(4,5)$.

Adding 8 can only change the first segment to $(8,1,3,6)$, and adding 9 changes the second segment to $(2,7,9)$. Therefore, $n \geqslant 10$.

Since $8+1=9,9+7=16,10+6=16$, 8, 9, and 10 must all be at the end of the array.
$$
\text { Also, } 8+17=25,9+16=25,10+15=25 \text {, }
$$

Thus, $n \geqslant 15$.
When $n=15$, the 15 numbers can be arranged as:
$8,1,15,10,6,3,13,12,4,5,11,14,2,7,9$.
Therefore, the smallest positive integer $n$ is 15.