Define the sequence $A_n=\{|f|\geq n\}$ (the set of all the points in which the value of $|f|$ is greater or equal than $n$). Since $f$ is integrable, clearly $|f|$ is measurable and therefore $A_n$ is measurable for any $n$. $A_n$ is defined a.e. (as $f$ is); should it sound odd to you, since everything holds up to a.e. equivalence, you could replace $f$ with any representative of its equivalence class.
Obviously $A_n$ is decreasing ($A_n\supseteq A_{n+1}$ for any $n$), therefore there exists the limit
$$
A_\infty\dot=\lim_{n\to\infty}A_n=\bigcap_{n=1}^\infty A_n
$$
and $A_\infty$ is measurable. From the integrability of $f$ it follows that $\mu(A_\infty)=0$ (if $\mu(A_\infty)>0$ then $\int_X |f|{\rm d}\mu \geq \int_{A_\infty}|f|{\rm d}\mu = \infty \cdot \mu(A_\infty) = \infty$, so $f$ would not be integrable).
Therefore the sequence
$$
f_n ~\dot=~ f\chi_{A_n}
$$
converges to $0$ a.e. ($\chi_{A_n}$ is the indicator function of the set $A_n$). It is not difficult to argue that $f_n$ is measurable for any $n$.
Now apply Lebesgue's dominated convergence theorem to $f_n$ which is pointwise less or equal than $|f|$, which is integrable.
Therefore
$$
\int_{A_n}f_n{\rm d}\mu ~\stackrel{n\to\infty}{\longrightarrow} 0
$$
It should be easy from here... :)