in-: in, into
spect: derived from Latin "specere", meaning "look"
-or: the person of doing something
So inspector means:
The person of looking into something.
If someone wants to look into something, the first step is to open it. This action is always from an official whose job is to examine that something meets rules. So inspect means "examine". Further, inspector means "examiner".
Evolution of usage
She is a person of looking into luggages.
She is a person of inspecting luggages.
She is an inspector.