How can I detect motion in a long, mostly dull video?

DVR-Scan

DVR-Scan is a cross-platform command-line (CLI) application that automatically detects motion events in video files (e.g. security camera footage). In addition to locating both the time and duration of each motion event, DVR-Scan will save the footage of each motion event to a new, separate video clip. Not only is DVR-Scan free and open-source software (FOSS), written in Python, and based on Numpy and OpenCV, it was built to be extendable and hackable.

Usage:

dvr-scan -i some_video.mp4 -o some_video_motion_only.avi

VLC

VLC has a motion detection filter that you can try by accessing: Tools -> Effects and Filters -> Video Effects -> Advanced -> Motion Detect.

screenshot

You might have more tweaks available running it from the command line with the --video-filter=motiondetect flag; check out this example.