Exercise with localization and minimal primes 
Let $A$ be a ring and $p\subset A$ be a prime ideal. Call $f$ the canonical map $A\to A_p$, and set $I:=\operatorname {ker }f$. Show that $I\subseteq p$ and that $\sqrt I=p$ if and only if $p$ is minimal among the prime ideals of $A$.

$I\subseteq p$ is easy: $x\in I $ iff exists $t\in A\setminus p$ such that $tx=0$; since $0\in p$ and $t\notin p$, be $p$ prime $x\in p$.
Now I try to show that, if $p$ is a minimal prime, $\sqrt I=p$. Since $I\subseteq \sqrt I\subseteq p$, we can look at what happens in $A_p$. Here we have that the radical of $IA_p=0$ is $pA_p$, being the only prime containing it. Am I finished?
Now suppose that $\sqrt I=p$. Again, passing to $A_p$, we are in the situation that there is only a prime ideal, namely $\sqrt 0=pA_p$. Since any prime contained in $p$ would survive in $A_p$, can I conclude that $p$ is minimal?
These arguments actually seem defective to me, but I have not clear why. It seems to me that sometimes I reasoned like if the prime ideals of $A_p$ were in bijection with the primes of $A$ contained in $p$, other times like if the bijection was with the prime ideals contained in $p$ and containing $I$ (for example in saying that $\sqrt I A_p$ is the nilradical of $A_p$). Could you clear my ideas? Thanks
 A: Here is a better way to prove this. The containment $\sqrt{I} \subseteq p$ is trivial once you have $I \subseteq p$ (by taking radical on both sides). By definition, $\sqrt{I} \supseteq p$ if an only if for all $x \in p$ there is $n>0$ and $t \in A \setminus p$ such that $tx^n=0$ if and only if $x/1 \in \mathfrak{N}(A_p)$ (for all $x \in p$). Recall that $\mathfrak{N}(A_p)$ is the intersection of all prime ideals of $A_p$.
If $p$ is minimal, then $x/1 \in pA_p = \mathfrak{N}(A_p)$ (there is only one prime ideal of $A_p$). Conversely, suppose $p$ is not minimal. Then we can find a minimal prime $q \subset p$. Assume, in contrary, that $x/1 \in \mathfrak{N}(A_p)$. In particular, $x/1 \in qA_p$. Thus, there exists $y \in q$, $t \in A \setminus q$ such that $x/1 = y/t$. Hence, for some $u \in A \setminus p$, $utx = uy \in q$ and so $x \in q$ by primality (since $u,t \not\in q$). Since $x \in p$ is arbitrary, we have $p \subseteq q$, a contradiction.
A: Here is an equivalent statement and proof, which do not involve localisation.  Thus you get a different perspective, and can see what is happening in the ring $A$ more explicitly.

Let $A$ be a commutative unital ring and let $P$ be a prime ideal.  Let $I$ be the ideal of $i\in A$ such that $ix=0$ for some $x\notin P$.
Then $\sqrt I\subseteq P$ as $a^nx=0$ with $x\notin P$ implies $a\in P$.  Similarly, for any prime ideal $P'\subsetneq P$, we have $a^nx=0$ with $x\notin P$ implies $x\notin P'$, so $a\in P'$.  Thus $\sqrt I \subseteq P'\subsetneq P$ and $\sqrt I\neq P$.
Conversely, suppose $\sqrt I \neq P$.  Pick $a\in P \backslash \sqrt I$.  Then $a$ and $A\backslash P$ generate a multiplicatively closed set $M$, disjoint from $\sqrt I$ (if $a^nx\in \sqrt I$ with $x\notin P$, then $(a^nx)^ky=0$, with $y\notin P$, which implies $a\in \sqrt I$ - a contradiction).  By Zorn's lemma, one may find an ideal $J\supseteq \sqrt I$, maximal amongst ideals disjoint from $M$.  Then $J$ is a prime ideal and $J\subsetneq P$, as it is disjoint from $M$.

Note the following lemma is used explicitly at the end of the above argument, and implicitly in the corresponding argument by @Ray (as it is the key ingredient of the proof that only nilpotent elements lie in the intersection of all primes):
Lemma Let $A$ be a commutative unital ring, let $M\subseteq A$ be a multiplicatively closed subset, and let $J$ be maximal among ideals disjoint from $M$.  Then $J$ is prime.
Proof: If $u,v\notin J$ then by the maximality property we have: $$\lambda u=j_1+m_1, \qquad \mu v=j_2+m_2,$$
with $\lambda,\mu\in A$, and $j_1,j_2\in J$, and $m_1,m_2\in M$.  However in that case: $$\lambda\mu uv=(j_1j_2+j_1m_2+j_2m_1)+m_1m_2,$$
so $uv\notin J$ (otherwise $m_1m_2\in J \cap M$ - a contradiction). $\qquad\qquad\qquad\Box$
