2023年11月27日发(作者:)

No.1

Problem

When trying to install or uninstall SQL Server, the setup process fails with the

following message:

Rule "Restart Computer" failed.

This happens because there are pending restart operations on the machine and the

setup needs a reboot before continuing. The problem is, that sometimes, even if the

computer is restarted, the setup process can fail at exactly the same step.

Solution

Check if there are pending rename file operations that needs to be done after the

computer is restarted.

To do this open a registry editor (Start -> Run -> Regedit) and navigate to the

following path:

HKEY_LOCAL_MACHINESYSTEMCurrentControlSetControlSession Manager

Right click on the PendingFileRenameOperations registry key from the right pane, to

see the files that will be renamed after the restart.

These entries are added to the registry when a program needs to rename a file that is being used.

PendingFileRenameOperations registry key or add the containing entries to the

newly created PendingFileRenameOperations key (if this is the case).

Sometimes the PendingFileRenameOperations registry key is not present in the

above path. In this situation, a solution will be to avoid the pending restart by

installing / uninstalling SQL from the command line. To do this go to the SQL

installation folder and from the cmd prompt execute the following:

/SkipRules=RebootRequiredCheck /ACTION=install

or

/SkipRules=RebootRequiredCheck /ACTION=uninstall

By doing this, the setup will skip the rule that verifies if there are any restart pending

operations.

No.2

安装SQL server 2008 R2时遇到如下问题,在安装到Setup Support

Files 后,系统一闪而过下图错误信息后安装中断。

报错:preparing SQL server 2008 R2 setup error detailsplease

wait。如下图:

由于此次安装的系统为英文版,所以要求安装的SQL server 为英文,但是在安

装文件中的

X:Installationsql server 2008 R21033_enu_lpx86 目录中缺少相关文件,

所以意外中断。

解决方法:

X:Installationsql server 2008 R22052_chs_lpx86目录中的setup

文件夹复制到其下,然后重新安装。