Just tried this on my 2013 MBP with 10.8.5:
The external keyboard still works fine, and I was able to disable, then reenable my internal keyboard.
To disable the internal keyboard of a portable Mac:
sudo kextunload /System/Library/Extensions/AppleUSBTopCase.kext/Contents/PlugIns/AppleUSBTCKeyboard.kext/
The internal keyboard is then disabled, external keyboards will still work.
To re-enable the internal keyboard of a portable Mac:
sudo kextload /System/Library/Extensions/AppleUSBTopCase.kext/Contents/PlugIns/AppleUSBTCKeyboard.kext/
When I initially disable the internal keyboard, terminal notifies me that:
(kernel) Can't unload kext com.apple.driver.AppleUSBTCKeyboard; classes have instances:
(kernel) Kext com.apple.driver.AppleUSBTCKeyboard class AppleUSBTCKeyboard has 11 instances.
Failed to unload com.apple.driver.AppleUSBTCKeyboard - (libkern/kext) kext is in use or retained (cannot unload).
Nevertheless, the command works, no ill effects.
Thanks to: macrumours