If you would like to display line numbers in Vi/Vim you have to type following line in editor:
:set number
If you want to set that VI always display line numbers while you edit your file, you have to add following line to you ~/.vimrc file:
set number