To enable - type:
:set number or :set nu.
To disable - type:
:set nonumber or :set nonu.
To enable enumerating relative to the cursor location - type:
:set relativenumber.
To disable enumerating relative to the cursor location - type:
:set norelativenumber.
Note: To change whether the current line shows the actual line number or 0, use the :set number and :set nonumber commands while the relativenumber attribute is active.