Ingrain is the standard spelling of the verb meaning to impress deeply. Engrain is an accepted variant, but it appears only rarely. It does not have any meanings of its own.
The preference for ingrain extends to ingrained, which is actually more common than the uninflected form.
Ingrained is preferred throughout the English-speaking world. Here are a few examples of the word in action:
Long-term education is needed to change historically and culturally ingrained habits and to reduce the fascination that the yellow metal has for the people. [Deccan Herald]
These ideas were deeply ingrained in Whiggism — the prevailing political philosophy of the day. [The Story of the Constitution]
But being so deeply ingrained in the department he now leads has come at a cost, Beck said. [LA Times]
But engrained is not completely absent. Instances of its use seem especially common in American sources:
So engrained in the English psyche have the horrors of the Gabba become in recent years. [Wall Street Journal]
That’s a tough sell, because few things are more deeply engrained in human nature than the impulse to punish enemies. [NY Times]
Still, ingrained is far more common everywhere.