In a triangle, the variables $a, b, c$ are typically reserved for the side lengths. To avoid confusion, I will use $r_a, r_b, r_c$ to denote the distances of a point $P$ from corresponding sides. Let $\Delta$ be the area of the triangle. For any point $P$ on or inside the triangle, we have
$$\sum_{cyc} a r_a = a r_a + b r_b + c r_c = 2\Delta\tag{*1}$$
Furthermore, if any triplets of non-negative numbers $x_a, x_b, x_c$ satisfies $(*1)$, there is a point $P$ on or inside the triangle with $(r_a, r_b, r_c) = (x_a, x_b, x_c)$.
Let $\displaystyle\;k = \frac{2\Delta}{\sum_{cyc} a^2} = \frac{2\Delta}{a^2+b^2+c^2}\;$, the sum of squared distances can be rewritten as
$$\begin{align}\sum_{cyc} r_a^2
&= \sum_{cyc} \left( (r_a - k a)^2 + 2k a r_a - k^2 a^2 \right)\\
&= \sum_{cyc} (r_a - k a)^2 + 2\left(\frac{2\Delta}{\sum_{cyc} a^2}\right)\left(\sum_{cyc} a r_a\right)
- \left(\frac{2\Delta}{\sum_{cyc} a^2}\right)^2
\left( \sum_{cyc} a^2\right)\\
&= \sum_{cyc} (r_a - k a)^2 + \frac{4\Delta^2}{\sum_{cyc} a^2}
\end{align}\tag{*2}
$$
Since $\sum_{cyc} a (ka) = 2\Delta$, there is a point on or inside the triangle with $(r_a, r_b, r_c) = (ka, kb, kc)$.
The minimum of sum of squared distances is achieved at this point with value
$\displaystyle\;\frac{4\Delta^2}{a^2+b^2+c^2}$.
Update
Please note that this particular point is known as
symmedian point (or alternatively the Lemoine point or Grebe point).
After I finished this answer, a search indicate this particular property has been
asked before.
Look at this question for more answers.