To shake is to move back and forth or up and down quickly.
When people shake hands, it usually means they agree.
Example picture