  While ultra-thin layers of the LaNiO$_3$ film exhibit a remarkable
metal-insulator transition as the film thickness becomes smaller than a few
unit cell (u.c.), the formation of oxygen vacancies and their effects on the
correlated electronic structure have been rarely studied. Here, we investigate
the effects of the surface termination and the oxygen vacancy position on the
electronic properties and vacancy energetics of LaNiO$_3$ ultra-thin films
using density functional theory plus U (DFT+U). We find that oxygen vacancies
can be easily formed in the Ni layers with the NiO$_2$ terminated surface (0.5
u.c. and 1.5 u.c. thickness) compared to the structures with the LaO terminated
surface and the in-plane vacancy is energetically favored than the out-of-plane
vacancy. When two vacancy sites are allowed, the Ni square plane geometry is
energetically more stable in most cases as two oxygen vacancies tend to stay
near a Ni ion. The in-plane vacancy of the NiO$_2$ terminated structure is
favored since the released charge due to the oxygen vacancy can be easily
accommodated in the $d_{x^2-y^2}$ orbital, which is less occupied than the
$d_{z^2}$ orbital. Remarkably, the oxygen vacancy structure containing the Ni
square-plane geometry becomes an insulating state in DFT+U with a sizable band
gap of 1.2eV because the large crystal field splitting between $d_{z^2}$ and
$d_{x^2-y^2}$ orbitals in the square-plane favors an insulating state and the
Mott insulating state is induced in other Ni sites due to strong electronic
correlations.
