How to delete the Default SSP in SharePoint 2007

There is no way to delete default SSP from Sharepoint Central Administration site via using this gui.
So stsadm command has help us for removing Default SSP

1) Open a command prompt
2)change your path to drive:\program files\common files\microsoft shared\web server extentions\12\BIN
3) Run fallowing command:
stsadm -o deletessp -title SharedServices1 -force

Have a nice Tips&Tricks

MOSS 2007 – Welcome name is not updated problem.

This is a very well know problem.  Even if you run full profile import on sharepoint 2007 the user’s which is name property has changed in AD , not updated on your site welcome name.
First of all you have to detect that the problem has encounter between Sharepoint and AD connection issues. If you see the updates in Profile Store in SSP correctly but not affecting welcome name this article may help you. If it is not updated correctly in Profile Store , it is another problem that out of scope for this article.

So what you can do :

Here is the command for force the sync operations.

stsadm -o sync -ignoreisactive 1
stsadm -o sync -deleteolddatabases 0
stsadm -o sync -synctiming m:5
stsadm -o sync -sweeptiming m:5
stsadm -o sync

Wait min 5 minutes. and check.

You can get more information about stsadm -o sync operations.
http://technet.microsoft.com/en-us/library/cc263196(office.12).aspx
If this is not solve your problem you can use fallowing tool for a workaround;
http://blog.bugrapostaci.com/2012/01/22/sharepoint-tools-wsscontentdbsync-v1-0-command-line-tool/

 

Quick Tip: Adding content database with stsadm

It is important when the content database need to upgrade the gui interface can not able to complete this operation.you have to use stsadm for doing that.

Command:
stsadm -o addcontentdb -url “<siteURL>” -databasename “<databaseName>” -databaseserver “<SQLServerName>”

Example
stsadm -o addcontentdb -url “http://blog.bugrapostaci.com” -databasename WSS_Content_Blog -databaseserver “postpoint2003″

You can get detail information from MSDN:
http://technet.microsoft.com/en-us/library/cc263422(office.12).aspx

 

 

Sharepoint Deploying resource files to app_globalresources folder using Timer Job.

Hi Everyone ,
in this article i want to explain how to copy your resource files to web application’s app_globalresources folder using by a timer job.

As you know there is four place that the resource files has to be.

\14\Resources\
\14\Template\Features\<Feature Name>\Resources\
\14\Config\Resources\
[Virtual Directory] \App_GlobalResources\

I could not tell about which folder for what,  this is out of concept.But i will explain that

the files which in  \14\Config\Resources can copied to [Virtual Directory] \App_GlobalResources\ folder when a new web.application created. But what about the existing ones.
Friendly stsadm command give us some help.
STSADM -o CopyAppBinContent
But still you can run this command all your sharepoint servers.And this is not an aswer for if you aim to deploy some specific web applications.
You can use
SPWebApplication.ApplyApplicationContentToLocalServer()  fuction for do it with programmatically by creating and using a feature reciever class.

public override void FeatureDeactivating(SPFeatureReceiverProperties properties)
        {
            SPWebApplication webApp = properties.Feature.Parent as SPWebApplication;
            if (webApp != null)
            {
                 ...Somecodes.
                 webApp.Farm.Services.GetValue().ApplyApplicationContentToLocalServer();
            }
        }

I could say that cause a latency when you click to activate button for this feature.and stsadm -o copyappbincontent and ApplyApplicationContentToLocalServer() only copy the resource files on the local server.So
we have  options with Visual Studio 2010 and Sharepoint 2010

First  i will start with the easy way if you are using Sharepoint 2010 and Visual Studio 2010 .
1) Create an Empty Element from vs ide and rename it OurResources.
2) Add a resource file to this element named TestResource.resx
3) Select TestResource.resx and Change property value of  “Build Action”  key to “Resource” from Visual Studio IDE Properties window
4) Change property value of Deployment Type key to “AppGlobalResource”
5) Expand the “Deployment Location” and set the Path is empty .for doing that we can able to copy our resource file root folder of App_GlobalResources.

Second you can use ApplicationResourceFiles element on your Solution xml
<ApplicationResourceFiles> 
    <ApplicationResourceFile Location=”blog.resx”/> 
    <ApplicationResourceFile Location=”blog.en-US.resx”/> 
  </ApplicationResourceFiles>

But what if you are developing a farm scope feature or webapplication scope features that should add extra resource file to selected web applications or you have multiple server farm and you want to deploy resource files accross the farm .This time you may need a TimerJob for deploying your resource files.

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Microsoft.SharePoint.Administration;
using Microsoft.SharePoint;
using Microsoft.SharePoint.Utilities;
using System.IO;

namespace ResourceDeployment
{

    public class DeployResourcesJob : SPJobDefinition {
        public readonly static string DefinitionName = "job-deploy-resources";

        #region Constructors
        public DeployResourcesJob() : base() { }
        public DeployResourcesJob(SPWebApplication webApp) : base(DeployResourcesJob.JobDefinitionName, webApp, null, SPJobLockType.None) {
            this.Title = "Deploy Resource Files";
        }
        #endregion

        public static void ActivateJob(SPWebApplication webApp) {
            // Delete if any existing jobs
            DeployResourcesJob.Delete(webApp.JobDefinitions, JobDefinitionName);

            DeployResourcesJob job = new DeployResourcesJob(webApp);
            job.Schedule = new SPOneTimeSchedule(DateTime.Now.AddHours(-2));
            job.Update();
        }

       public static void RemoveJob(SPJobDefinitionCollection jobDefinitions, string name) {
           DeployResourcesJob existingJob = jobDefinitions.GetValue(DeployResourcesJob.JobDefinitionName);
            while (existingJob != null)
            {
                existingJob.Delete();
                existingJob.Unprovision();
                existingJob = jobDefinitions.GetValue(DeployResourcesJob.JobDefinitionName);
            }
        }

       public override void Execute(Guid targetInstanceId) {

             string source = SPUtility.GetGenericSetupPath("Resources");
            // Copy or remove the resource file for all zones
            if (Directory.Exists(source)) {
                foreach (SPUrlZone zone in this.WebApplication.IisSettings.Keys) {

                    // Get the location of the App_GlobalResources folder under the target Web Application
                    string destination = this.WebApplication.GetIisSettingsWithFallback(zone).Path + "\\App_GlobalResources";

                    if (Directory.Exists(destination)) {
                        string[] resourceFiles = Directory.GetFiles(source, "MyResource*.resx");
                        foreach (string filename in resourceFiles)
                        {
                            string destinationFilename = destination + "\\" + Path.GetFileName(filename);
                            File.Copy(filename, destinationFilename, true);

                        }
                    }

                }
            }
        }

}
}

Here Some Resources:
http://blogs.msdn.com/b/johnwpowell/archive/2009/11/29/sharepoint-2010-localization-with-visual-studio-2010.aspx
http://blogs.msdn.com/b/maximeb/archive/2008/04/26/deploying-resource-files-across-a-farm.aspx
http://cicoria.com/cs1/blogs/cedarlogic/archive/2010/01/31/deployment-of-resource-files-resx-to-app-globalresources-under-sharepoint.aspx

End of Article :-)

How to enable verbose log mode on Moss 2007

First Method: Using Central Administration

1) Open your Central Administration web page and Click “Operations”
2) Click Diagnostic Logging link

3) For enabling verbose mode for all categories:
Select and set “Select a Category” combobox value to “All
Select and set “Least critical event to report to the event log” combobox value to “Warning
Select and set “Least critical event to report to the trace log” combobox value to “Verbose

4) Click OK.Its done.
Important!:Please don’t forget change mode to default after collecting needed verbose mode logging. Because in verbose mode log files grows rapidly and if you are not enough storage your sharepoint server would be crashed

For restoring default values.
Select and set “Select a Category” combobox value to “All
Select and set “Least critical event to report to the event log” combobox value to “Error
Select and set “Least critical event to report to the trace log” combobox value to “Medium
and click OK button.


Second Method: Using stsadm command

 

1) Open a command prompt
2) Redirect to path drive:\Program Files\Common Files\Microsoft Shared\Web Server Extentions\12\Bin
3) Be sure that you have enough hardisk space for collecting verbose mode logging.
4) Run stsadm command: 

Syntax
stsadm.exe -o setlogginglevel
   [-category < [CategoryName | Manager:CategoryName [;...]] >]
   {-default |
   -tracelevel < trace level setting>
   [-windowslogginglevel] <Windows event log level setting>}

For set all categories to verbose use this command:
exp:
stsadm -o setlogginglevel  -tracelevel verbose -windowslogginglevel warning

For set all logs level to default use this command:
exp:
stsadm -o setlogginglevel -default

Important!:Please don’t forget change mode to default after collecting needed verbose mode logging. Because in verbose mode log files grows rapidly and if you are not enough storage your sharepoint server would be crashed.

If you want to learn current logging level run bellowed command:
Exp:
stsadm.exe -o listlogginglevels

for more information.
http://technet.microsoft.com/en-us/library/cc261740(office.12).aspx

You can find Sharepoint logs in folder: (Default folder)
Drive:\Program Files\Common Files\Microsoft Shared\Web Server Extentions\12\LOGS
NOTE: If you need to transfer these files to Microsoft File Services , please compress files in zip file. If zip file size is bigger than  5GB please spearate multiple files that lower than 5GB.

Hhave nice day …

Follow

Get every new post delivered to your Inbox.