安装和升级 > 安装和配置指南 > 使用 PTC 解决方案安装程序 > 安装 Windchill 解决方案 > 可选产品设置 > Windchill Index Search 安装 > Windchill Index Search 安装后配置 > 在云模式下安装索引搜索服务器 > 配置 Solr 的基本验证 (云模式)
  
配置 Solr 的基本验证 (云模式)
系统会使用安装时提供的用户名和密码自动配置基本验证。本节介绍如何根据需要手动配置基本验证。
1. 打开命令提示符,然后导航至 <INDEX_SEARCH_HOME>/solr/server/scripts/cloud-scripts
2. 执行以下命令将 security.json 加载到 Zookeeper 节点集合:
Windows:
zkcli.bat -cmd putfile /security.json <INDEX_SEARCH_HOME>/config/solr/security.json -z <以逗号分隔的 Zookeeper 主机名列表:端口条目>
Unix:
sh zkcli.sh -cmd putfile /security.json <INDEX_SEARCH_HOME>/config/solr/security.json -z <以逗号分隔的 Zookeeper 主机名列表:端口条目>
* 
每当执行 xconfmanger 以设置索引搜索服务器的特性时,它均会以指定用户名和密码生成 <INDEX_SEARCH_HOME>/config/solr/security.json。此文件可加载到 Zookeeper 节点集合中,以设置或更改 Solr 云的验证信息。
3. 打开 Solr 管理器界面,并验证系统是否会提示您输入用户名和密码:
http://<SOLR_HOSTNAME>:<SOLR_PORT>/solr
更改 Solr 用户或密码
更改 Solr 用户或密码时,您必须更新 Windchill Index Search 客户端和服务器。
1. 打开 Windchill shell 并执行以下命令,以更改 Windchill Index Search 客户端的密码或用户:
xconfmanager -s wt.index.solrAdminUser=<New_User> -t codebase/WEB-INF/conf/index.solrAuth.properties -p
xconfmanager -s wt.index.solrAdminPassword=<New_Password> -t codebase/WEB-INF/conf/index.solrAuth.properties -p
2. 重新启动 Windchill
3. 在命令提示符中,导航至 <INDEX_SEARCH_HOME>/bin 并执行以下命令,以更改 Windchill Index Search 服务器的密码或用户:
Windows:
xconfmanager -s wt.index.server.solrAdminUser=<New_User> -t config/solrserver.properties -p
xconfmanager -s wt.index.server.solrAdminPassword=<New_Password> -t config/solrserver.properties -p
Unix:
sh xconfmanager -s wt.index.server.solrAdminUser=<New_User> -t config/solrserver.properties -p
sh xconfmanager -s wt.index.server.solrAdminPassword=<New_Password> -t config/solrserver.properties -p
4. 按照上述步骤将 <INDEX_SEARCH_HOME>/config/solr/security.json 加载到 Zookeeper 节点集合。
5. 重新启动 Solr 和 Zookeeper 节点。