设为首页 收藏本站
查看: 765|回复: 0

[经验分享] stsadm功能之sharepoint service

[复制链接]
累计签到:1 天
连续签到:1 天
发表于 2015-9-26 09:22:19 | 显示全部楼层 |阅读模式
2010年02月23日 星期二 14:59

  常用的stsadm命令行参数有:
  1、installfeature、uninstallfeature:
  feature部署和卸载; 安装feature:stsadm -o installfeature -filename [feature文件夹下]\feature.xml
  激活feature:stsadm -o activatefeature -filename [feature路径]\feature.xml -url http://[主机标头]:[端口]/sites/portol -force
  特别注意的地方 -url     
  还有就是:“主机标头”可以不是计算机名,但是有时创建Web Application时会出错,所以还是用计算机名比较好。也不知到为什么会出错。
  2、addwppack、deletewppack:webpart和*.cab部署和卸载;
  安装:stsadm -o addwppack -filename [*.cab文件路径]\*.cab
  卸载:stsadm -o deletewppack -name *.cab
  一般情况下,webpart不要直接部署到网站里,用feature部署要好一些。
  3、addtemplate、deleteremplate:template(模板)的部署和卸载;
  安装:stsadm.exe -o addtemplate -filename [*.stp文件路径]\*.stp -title [template名称]
  4、addsolution、deletesolution:
  solution部署和卸载;
  安装:stsadm -o addsolution -filename [*.wsp文件路径]\*.wsp;
  部署:stsadm -o deploysolution -name *.wsp -allowgacdeployment -immediate
  删除:stsadm.exe -o deletesolution -name *.wsp
  Feature功能很强大,很多东西都可以通过feature部署到MOSS里,但是根据自己的使用情况,
  个人感觉母板页(MasterPage)和模板(template)还是通过“母板页库”和“模板库”上传上去比较好用。
  5、getlock、setlock:
  用于在备份backup site collection时访问限制;
  


  •   At a command prompt on the drive on which SharePoint Products and Technologies is installed, change to the following directory: %COMMONPROGRAMFILES%\Microsoft shared\Web server extensions\12\Bin.
  •   To determine the current access level of the site, type the following command, and then press ENTER:
      stsadm -o getsitelock -url <URL name>
      where URL name is the URL of the site collection that you want to back up. For more information, see Getsitelock: Stsadm operation (Office SharePoint Server).
  •   If the current access level allows changes to the site content, change it to read-only by typing the following command, and then pressing ENTER:
      stsadm -o setsitelock -url <URL name> -lock readonly
      where URL name is the URL of the site collection that you want to back up. For more information, see Setsitelock: Stsadm operation (Office SharePoint Server).
  •   When the backup is complete, use this procedure to return access to the site collection to the original setting determined in step 1.
  Use this procedure to back up a site collection by using the Stsadm command-line tool.
  
  
  Examples

  A common situation where the getsitelock and setsitelock operations are useful is when a site is backed up. Typically, before you back up a site collection, the site should be locked and no users should have access to it.
  To determine the lock status of the site, you can use the following getsitelock syntax:
  stsadm -o getsitelock -url http://server_name
  Once the lock status of the site collection is determined, you can use the noaccess parameter of the setsitelock operation to lock out all users to the site:
  stsadm -o setsitelock -url http://server_name -lock noaccess
  You can use the Backup operation to create a backup of the site collection:
  stsadm -o backup -url http://server_name -filename "filename.bak" -overwrite
  After the site has been backed up, you can use the none parameter of the setsitelock operation to remove all locks to the site:
  stsadm -o setsitelock -url http://server_name -lock none

运维网声明 1、欢迎大家加入本站运维交流群:群②:261659950 群⑤:202807635 群⑦870801961 群⑧679858003
2、本站所有主题由该帖子作者发表,该帖子作者与运维网享有帖子相关版权
3、所有作品的著作权均归原作者享有,请您和我们一样尊重他人的著作权等合法权益。如果您对作品感到满意,请购买正版
4、禁止制作、复制、发布和传播具有反动、淫秽、色情、暴力、凶杀等内容的信息,一经发现立即删除。若您因此触犯法律,一切后果自负,我们对此不承担任何责任
5、所有资源均系网友上传或者通过网络收集,我们仅提供一个展示、介绍、观摩学习的平台,我们不对其内容的准确性、可靠性、正当性、安全性、合法性等负责,亦不承担任何法律责任
6、所有作品仅供您个人学习、研究或欣赏,不得用于商业或者其他用途,否则,一切后果均由您自己承担,我们对此不承担任何法律责任
7、如涉及侵犯版权等问题,请您及时通知我们,我们将立即采取措施予以解决
8、联系人Email:admin@iyunv.com 网址:www.yunweiku.com

所有资源均系网友上传或者通过网络收集,我们仅提供一个展示、介绍、观摩学习的平台,我们不对其承担任何法律责任,如涉及侵犯版权等问题,请您及时通知我们,我们将立即处理,联系人Email:kefu@iyunv.com,QQ:1061981298 本贴地址:https://www.yunweiku.com/thread-118932-1-1.html 上篇帖子: [SharePoint]HTTP 500 下篇帖子: 推荐 SharePoint 2010 视频资料
您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

扫码加入运维网微信交流群X

扫码加入运维网微信交流群

扫描二维码加入运维网微信交流群,最新一手资源尽在官方微信交流群!快快加入我们吧...

扫描微信二维码查看详情

客服E-mail:kefu@iyunv.com 客服QQ:1061981298


QQ群⑦:运维网交流群⑦ QQ群⑧:运维网交流群⑧ k8s群:运维网kubernetes交流群


提醒:禁止发布任何违反国家法律、法规的言论与图片等内容;本站内容均来自个人观点与网络等信息,非本站认同之观点.


本站大部分资源是网友从网上搜集分享而来,其版权均归原作者及其网站所有,我们尊重他人的合法权益,如有内容侵犯您的合法权益,请及时与我们联系进行核实删除!



合作伙伴: 青云cloud

快速回复 返回顶部 返回列表