Download courses and users by role
Allows an administrator to download a list of all the courses or a list of users selected by role to a comma-separated values format (CSV) or Excel 2007 file format.
The plugin creates two entries in Administration: one in Administration > Site administration > Users > Accounts > Download users by role for downloading users, and one in Administration > Site administration > Courses > Download courses for downloading courses. From there you can access the full functionality of the plugin.
In addition to the web interface there is also a command line tool located in admin/tool/downloaddata/cli/downloaddata.php.
You can discuss this plugin on the Moodle forums.