  As a special class of linear codes, minimal linear codes have important
applications in secret sharing and secure two-party computation. Constructing
minimal linear codes with new and desirable parameters has been an interesting
research topic in coding theory and cryptography. Ashikhmin and Barg showed
that $w_{\min}/w_{\max}> (q-1)/q$ is a sufficient condition for a linear code
over the finite field $\gf(q)$ to be minimal, where $q$ is a prime power,
$w_{\min}$ and $w_{\max}$ denote the minimum and maximum nonzero weights in the
code, respectively. The first objective of this paper is to present a
sufficient and necessary condition for linear codes over finite fields to be
minimal. The second objective of this paper is to construct an infinite family
of ternary minimal linear codes satisfying $w_{\min}/w_{\max}\leq 2/3$. To the
best of our knowledge, this is the first infinite family of nonbinary minimal
linear codes violating Ashikhmin and Barg's condition.
