Microsoft Knowledge Base Article 308029 contains the following INTRODUCTION:

This article refers to resources that you can use to troubleshoot shutdown problems in Windows XP. After you follow the steps in each article in a section, determine if you have resolved the problem by either shutting down or restarting your computer. If you still cannot shut down or restart your computer, continue to the next section in order. Try to shut down or restart your computer at the end of each section.