Ipconfig error an internal or external error occurred in windows xp

Go to Control Panel, System, Advanced tab, Environment Variables.
Check lines that all paths to system files are correct and not modified (spelling counts).
Do you have that error with any other commands ?
Is ipconfig.exe physically in the directory ?
You may have had it infected and cleaned at one point, replace the file.