ospp.vbs是什么文件?激活过程cscript ospp.vbs命令详解

mahocon 2021-12-08 原文

ospp.vbs是什么文件?激活过程cscript ospp.vbs命令详解

  在Office 2013激活过程中我们经常会用到cscript ospp.vbs这个命令。那么,很有必要来了解一下,ospp.vbs到底是什么文件?Cscript.exe是脚本运行引擎,这里就不多介绍了。ospp全称为:Office Software Protection Platform,vbs大家都知道是脚本文件,所以得出结论,ospp.vbs就是:Office软件保护平台脚本。它是目前Office自身提供的激活管理工具。

ospp.vbs文件在哪里?

该脚本位于%安装目录%\ Program Files文件\微软Office \ Office15文件夹中。如果您运行的是32位Office 2013的64位操作系统,该脚本位于%安装目录%\程序文件(x86)\微软Office \ Office15文件夹中。

ospp.vbs命令介绍

命令有很多,不一一全部介绍了,说说几个激活过程中的常用命令。为了让大家看得更明白,下面我以我虚拟机里的Office 2003 Pro Plus做个演示。

ospp.vbs

cscript ospp.vbs /dstatus

显示当前已安装产品密钥的许可证信息。可以查看到自已安裝的版本有多少个序列号。

ospp.vbs

cscript ospp.vbs /unpkey:xxxxx

卸载已安装的产品密钥。后面的数字是密钥的最后5位数。

此时再执行cscript ospp.vbs /dstatus发现产品密钥已经没有了,我重新进行导入。

ospp.vbs

cscript ospp.vbs /inpkey:xxxxx……
安装、替换现有的产品密钥。和上面的过程刚好相反。

cscript ospp.vbs /sethst:x.x.x.x
设置KMS主机名。一般为IP地址。

cscript ospp.vbs /act
激活当前安装的Office。

cscript ospp.vbs /remhst
删除KMS主机名。

一般来说掌握这么几个就可以了,如果你想要全面了解,我从微软官方网站上找到了全部的命令帮助说明,慢慢学习研究吧!

Global options for ospp.vbs

/act Activates installed Office 2013 product keys.
/inpkey:value Installs a product key (replaces existing key) with user-provided product key. Value option is required.
/unpkey:value Uninstalls an installed product key with the last five digits of the product key to uninstall (as displayed by the /dstatus option). Value parameter is required.
/inslic:value Installs a license with user-provided path of the .xrm-ms license. Value parameter is required.
/dstatus Displays license information for installed product keys.
/dstatusall Displays license information for all installed licenses.
/dhistoryacterr Displays the failure history for MAK/Retail activation.
/dinstid Displays Installation ID for offline activation.
/actcid:value Activates product with user-provided Confirmation ID. Value parameter is required.
/rearm Resets the licensing status for all installed Office 2013 product keys.
/rearm:value Resets the licensing status for an Office 2013 license with a user-provided SKUID value. Value parameter is required.
Use this option with the SKUID value specified by using the /dstatus option if you have run out of rearms and have activated Office through KMS or AD-based activation to gain an additional rearm.
/ddescr:value Displays the description for a user-provided error code. Value parameter is required.

KMS client options for ospp.vbs

/dhistorykms Displays KMS client activation history.
/dcmid Displays KMS client machine ID (CMID).
/sethst:value Sets a KMS host name with a user-provided host name. Value parameter is required.
This sets HKLM\Software\Microsoft\OfficeSoftwareProtectionPlatform\KeyManagementServiceName (REG_SZ).
/setprt:value Sets a KMS port with a user-provided port number. Value parameter is required.
This sets HKLM\Software\Microsoft\OfficeSoftwareProtectionPlatform\KeyManagementServicePort (REG_SZ).
/remhst Removes KMS host name (sets port to default).
/cachst:value Allows or denies KMS host caching. Value parameter is required (TRUE or FALSE).
/actype:value (Windows 8 and newer versions only) Sets volume activation type. Value parameter is required.
Values: 1 (for Active Directory-Based), 2 (for KMS). 0 (for both).
/skms-domain:value (Windows 8 and newer versions only) Sets the specific DNS domain in which all KMS SRV records can be found. This setting has no effect if the specific single KMS host is set by the /sethst option. Value parameter is the Fully Qualified Domain Name (FQDN) and is required.
/ckms-domain (Windows 8 and newer versions only) Clears the specific DNS domain in which all KMS SRV records can be found. The specific KMS host is used if it is set by the /sethst option. Otherwise, auto-discovery of the KMS host is used.

用在线Google翻译如下。机器翻译肯定不会很通顺,不过能大慨看懂。

全局命令

/ ACT 激活安装的Office 2013产品密钥。
/ inpkey:值 用户提供的产品密钥安装产品密钥(替换现有密钥)。值选项是必需的。
/ unpkey:值 卸载已安装的产品密钥的最后5位数字的产品密钥卸载(显示的/ dstatus选项)。Value参数是必需的。
/ inslic:值 安装许可证的。XRM-MS许可证的用户提供的路径。Value参数是必需的。
/ dstatus 显示已安装的产品密钥的许可证信息。
/ dstatusall 显示所有已安装许可证的许可信息。
/ dhistoryacterr 显示的故障历史记录的MAK /零售激活。
/ dinstid 显示安装ID为脱机激活。
/ actcid:值 用户提供的确认ID激活产品。Value参数是必需的。
/重新武装 复位的授权状态,所有已安装的Office 2013产品密钥。
/重整价值 重设许可状态的Office 2013许可证与用户提供SKUID的价值。Value参数是必需的。
使用此选项指定的值通过使用的/ dstatus选项,如果你有用完的重新激活和已激活的Office通过KMS或基于AD-激活的获得额外的重新武装SKUID 。
/ ddescr:值 显示为用户提供的错误代码的描述。Value参数是必需的。

KMS客户端的命令

/ dhistorykms 显示KMS客户端激活历史记录。
/ dcmid 显示KMS客户端计算机ID(CMID)。
/ sethst:值 设置KMS主机名和用户提供的主机名。Value参数是必需的。
此设置HKLM \软件\微软\ OfficeSoftwareProtectionPlatform \ KeyManagementServiceName(REG_SZ)。
/ setprt:值 设置KMS端口与用户提供的端口号。Value参数是必需的。
此设置HKLM \软件\微软\ OfficeSoftwareProtectionPlatform \ KeyManagementServicePort(REG_SZ)。
/ remhst 删除KMS主机名(将端口设置为默认)。
/ cachst:值 允许或拒绝KMS主机缓存。Value参数是必需的(TRUE或FALSE)。
/ actype:值 (Windows 8和较新的版本只)设置批量激活的类型。Value参数是必需的。
值:1(基于Active Directory),2(KMS)。0(两个)。
/ SKMS域值 (Windows 8和较新的版本只)设置特定的DNS域的所有KMS SRV记录可以发现。如果特定的单一KMS主机的/ sethst选项,该设置没有任何影响。Value参数是完全合格的域名称(FQDN)是必需的。
/ CKMS域 (Windows 8和较新的版本只)清除所有KMS SRV记录可以发现特定的DNS域名。使用特定的KMS主机,如果它被设置的/ sethst选项。否则,自动发现使用的KMS主机。

版权声明:本文为mahocon原创文章,遵循 CC 4.0 BY-SA 版权协议,转载请附上原文出处链接和本声明。
本文链接:https://www.cnblogs.com/mahocon/p/8615210.html

ospp.vbs是什么文件?激活过程cscript ospp.vbs命令详解的更多相关文章

随机推荐

  1. Java Web开发和Python Web开发之间的区别

    今天的文章讨论了Java Web开发和Python Web开发之间的区别。我不鼓励我们在这里从Java Web […]...

  2. 项目与产品区别

    项目与产品区别 咨询项目:咨询项目通常会包括二种,一种是只做咨询,像北大纵横他们只提供IT咨询,但不包括实施, […]...

  3. 笨方法学python之读写文件、open函数的用法

    一、python读写文件相关知识点 close:关闭文件 read:读取文件的内容//你可以把结果赋给一个变量 […]...

  4. 微软企业项目管理(EPM)解决方案

      微软企业项目管理(EPM)解决方案,帮助企业统一整合项目管理资源,提高项目管理的工作效率,加强信息共享,降 […]...

  5. 成为百万富翁的四个方法

    重读《小狗钱钱》,发现一个不小的秘密。 今天文章的开头,我想讲一个美国小男孩变成百万富翁的故事。 这个小男孩叫 […]...

  6. 高通电源管理qpnp-vm-bms驱动

    1. compatible节点: qpnp-vm-bms.c使用来控制电池曲线的和BMS功能的,其compat […]...

  7. 如何探测网络设备ACL规则

      探测网络设备ACL规则   背景:在互联网企业的生产网络中,往往在网络入口处的网络设备上会有成千上万条AC […]...

  8. 360全景拍攝技巧 – loveDT

    360全景拍攝技巧 一、全景拍攝的特性 VR需要展示交互式的空间或物体效果。其有两种主要方法:     1)3 […]...

展开目录

目录导航