Running any DB2 command in Windows Vista, Windows 7 and Windows 2008 causes the following error:
C:\Program Files\IBM\SQLLIB\BIN>db2 list db directory
SQL5005C System Error.
The cause of this error is because you may not have picked "Run as Administrator" when installing DB2. If you right click on any icon you will have an option to "Run as Administrator". You can either do this every time you want to open a DB2 Command Window or you can uninstall and reinstall DB2. Before installing DB2 right click on db2setup.exe and select "Run as Administrator",
This is also covered by the technical article 1430172, http://www.ibm.com/support/docview.wss?uid=swg21430172