To search a file in the vi editor, use /. First, use escape to enter any mode that you’re in. Then, type the forward slash before the text that you’re searching for, and hit enter. This will bring you the the appearance of the string you’re looking for.

Using the keyboard shortcut Cntrl+B allows you to go back when doing a string search with /.