Showing posts with label stsadm. Show all posts
Showing posts with label stsadm. Show all posts

Wednesday, December 19, 2012

Adding and Deploying Solutions in SharePoint 2010

Adding and Deploying Solutions in SharePoint 2010
How we can add solutions in SharePoint 2010 ?
We can add solution via common line using either STSADM or PowerShell command while solution deployment can be done either via Central Admin or using STSADM or PowerShell

Command line:
Using STSADM:
stsadm.exe -o addsolution -filename yoursolutionpackage.wsp
Using PowerShell:
Add-SPSolution -LiteralPath <SolutionPath>

Now here comes deployment part
  • Deploy Solution using Central Administration
  • Open Central Administration
  • Go to System Settings
  • Click on Manage farm solutions
  • Select the solution from the list
  • Select Deploy Solution and select the web application where you want to deploy it
  • Click OK when you are done.
  • Click Deploy Solution
  • That’s all, we are done with deployment

Command line:
Using STSADM:
stsadm -o deploysolution -name yoursolutionpackagename.wsp -url http://sp-mach/ -local  -force
Using PowerShell:
Install-SPSolution -Identity <SolutionName> -WebApplication <URLname>

Uninstallation and Retraction of a Solution in SharePoint 2010

Uninstallation and Retraction of a Solution in SharePoint 2010

Using STSADM:
stsadm -o retractsolution -name solutionName.wsp -immediate
stsadm -o deletesolution -name solutionName.wsp

Using PowerShell:
Uninstall-SPSolution -identity solutionName.wsp
Remove-SPSolution -identity solutionName.wsp

Wednesday, May 30, 2012

User can still access Allitem.aspx via Mobile site after Lockdown Mode

Issue:
One of my user requested to block Allitems.aspx page to be blocked for internet users and I blocked it using following command
stsadm -o activatefeature -url <site collection url> -filename ViewFormPagesLockDown\feature.xml) it works and user get 401 Unauthorized.
However, when user browse into a mobile page they are able to see all the items in the AllItem.aspx page.
Resolution:
  • To turn off site access from mobile device we need to edit the “compat.browser” file for our SharePoint site.
  • To find this file, look in your IIS directory for your SharePoint site and look for the App_Browsersfolder.
C:\inetpub\wwwroot\wss\VirtualDirectories\<Site Folder>\App_Browsers
Edit the file as guided in http://blog.drisgill.com/2009/11/sp2010-branding-tip-6-mobile-browsers.html

Tuesday, May 22, 2012

SharePoint site templates codes


Each Site Template that is installed on SharePoint 2007 has a unique name and number to allow for referencing when coding applications or using STSADM for site deployment (when using the -sitetemplate parameter, e.g. -sitetemplate STS#0 would apply a team site template)


WSS Templates

Team Site: STS#0

Blank Site: STS#1

Document Workspace: STS#2

Wiki Site: WIKI#0

Blog Site: BLOG#0

Basic Meeting Workspace: MPS#0

Blank Meeting Workspace: MPS#1

Decision Meeting Workspace: MPS#2

Social Meeting Workspace: MPS#3

Multiple Meeting Workspace: MPS#4

MOSS Templates

Document Center: BDR#0

Site Directory: SPSSITE#0

Report Center: SPSREPORTCENTER#0

Search Center with Tabs: SRCHCEN#0

My Site Host: SPSMSITEHOST#0

Search Center: SRCHCENTERLITE#0

Personalisation Site: SPSMSITE#0

Collaboration Portal: SPSPORTAL#0

Publishing Portal: BLANKINTERNETCONTAINER#0

Publishing Site: CMSPUBLISHING#0

Publishing Site with Workflow: BLANKINTERNET#2

News Site: SPSNHOME#0

Thursday, April 9, 2009

STSADM by default in My Command prompt





SharePoint has a lot of programs to be performed on the command prompt as in the GUI in fact after so much interaction with SharePoint product I believe that stsadm is more reliable and faster then the UI, so when ever you have to perform an action on the SharePoint site you open the command prompt and type the command that world knows about

c:\Program Files\common files\Microsoft shared\web server extensions\12\bin

and then you proceed with you list of stsadm commands, but is there an easier way to do it ????.

well of course there is we can add the stsadm path to the hive for command prompt so you can just hit command prompt and run the stsadm commands

>> Copy the path for 12\bin

>> On the SharePoint server(s), go to my computer > Properties and the Advanced Tab

>> Here hit on the button Environment Variables > here you see two frames user variables and system variables, go to system variables

>> Here go to the “PATH” variables and say Edit

>> Here paste the copied url which is c:\Program Files\common files\Microsoft shared\web server extensions\12\bin

>> Say OK and Apply and close

>> Now open command prompt and run stsadm –o help

>> you should be able to see a list of stsadm commands

>> Congrats you just made your life a little easier with SharePoint which is as unusual as pigs got wings ….