mongodump is a command-line utility and it's supposed to be run from the system command prompt, not the mongo javascript shell.
./mongodump --db local --collection lecturer
if successful, this command will create some files under dump directory in the current dir.