Tuesday, May 25, 2010

Need a technical speaker for U-SPUG.com June meeting

We need a technical SharePoint speaker for our Utah SharePoint Users Group meeting local or remote speaker on Thursday June 24 3-5pm. Please email me if you can be a speaker. LindaChapman  @  Live.com

Sunday, May 16, 2010

SharePoint Designer – how to redirect the OK button on NewForm.aspx

If you have created your own custom Item New form or NewForm.aspx page and want to redirect the page you go to after clicking the OK button…you can accomplish this by adding ?source= then the URL you want it to redirect to.

For example if your custom New Item page is:

http://LindaLeeChapman.spaces.live.com/NewForm.aspx

Change it to:

http://LindaLeeChapman.space.live.com/NewForm.aspx?source=http://LindaLeeChapman.space.live.com/Confirmation.aspx

Technorati Tags: sharepoint designer,redirect OK

del.icio.us Tags: sharepoint designer,redirect OK

SharePoint how to hide view all site content and other page elements

This is one example of hiding several page elements by using the following style code in the Source Code of the CEWP

This is good to apply when you want to create report pages where they simply right click and select Print Preview, then remove Headers and Footers, then print.

  1. Add a Content Editor Web Part to the page you want to hide the elements on,
  2. then Modify the CEWP as you want it (Title, Border, visibility, etc)
  3. then click on the Source Code button and paste to the very top of the code the elements below you want to hide.

<style>
#ct100_PlaceHolderLeftNavBar_idNavLinkViewAll
{
   Visibility:hidden;
}
#ctl00_PlaceHolderLeftNavBar_idNavLinkRecycleBin
{
       Visibility:hidden;
}
.ms-searchform
{
    display: none
}
.ms-bannerContainer
{
    Display:none
}
.ms-bannerframe
{
    Display:none
}
.ms-bodyareaframe
{
    Border:0
}
.ms-bodyareapagemargin
{
    Display:none
}
.ms-globalbreadcrumb
{
    Display:none
}
.ms-globalleft
{
    Display:none
}
.ms-globallinks
{
    Display:none
}
.ms-globalright
{
    Display:none
}
.ms-globalTitleArea
{
    Display:none
}
.ms-navframe
{
    Display:none
}

.ms-pagetitle
{
    Display:none
}
</style>

Sunday, May 9, 2010

SharePoint File Not Found error after creating new site

Occasionally I will create a new site based off a custom site template and when it is completed I get the following error.

          File Not Found

It drives me crazy because I always forget what my fix was! Anyways, at least for me, my problem is always that I am creating a new site off of a custom template that was originally created on a different site collection then the one I am creating this site in.

Thus my problem is always that it cannot find one of the following items that are unique to each Site Collection.

    • Master Page
    • Feature Activated
    • Web Part
    • List Template
    • Custom Column or Content Types

Now you might think, I copied or uploaded the same Master Page, or List Template etc. to this site collection before creating the site. Well, that may be so but it can still cause this error.

First you need to get to your Site Actions Site Settings by adding /_layouts/settings.aspx to your URL. Then I usually start with my Master Page and even if it already says Default.aspx is selected, I re-select the default master page again and click OK and that usually solves my problem.

Then I make sure all the same Features are selected, and Content Types, etc. The hardest is if I do all the above and it is still there, then it is usually a custom List. In that case I go to View All Site Content /_layouts/viewlsts.aspx  and delete the list and create another one.

Technorati Tags: file not found,sharepoint

del.icio.us Tags: file not found,sharepoint

SharePoint Server STSadm.exe error

Sometimes I get the following error when trying to run different STSadm.exe commands on SharePoint Server 2007.

The server administration programs and the Windows SharePoint Services Web applications on this Web server are not compatible. Ensure that the administration program is the same version as the Web application.

Where as this error could truly mean what it says…you could be running a 32bit STSadm.exe command on a 64bit deployment, or vise versa.

More commonly, with me, the problem is that the –url path I am entering does not match up exactly with what is defined in the Central Administration – Application Management – Web Application List URL or meaning the Default Managed Path defined in the Operations tab.  These must match exactly.

Example:  If my Web Application is "Chapman” over port 6000 and my Operations – Managed Path – Default = http://Chapman-SSP:6000/

Then I must enter that exact Default Managed Path in all STSadm.exe  -URL commands.

WRONG -url  http://Chapman-SSP

RIGHT  -url http://Chapman-SSP:6000

del.icio.us Tags: SharePoint Server STSadm error not compatible

Technorati Tags: SharePoint Server STSadm error not compatible

How to add a Link to a Document external to SharePoint

You can add links to external file shares or/and file server documents to your document library very easily. Why would you want to do this? Primarily so all your MetaData to all your documents are searchable in the same place.

First a Farm Administrator will need to modify a core file on the front end server.  Then you must create a custom Content Type. If you use the built in content type you will not be able to link to a Folder directly.
Edit the NewLink.aspx page to allow the Document Library to accept a File:// entry.
  1. Go to the Front End Web Server \12\template\layouts directory.
  2. Open the file NewLink.aspx using NotePad. If I have to tell you to take a backup of this file first then you have no business editing this file (really).
  3. Go to the end of the script section near top of page and add:
    function HasValidUrlPrefix_UNC(url)
    {
    var urlLower=url.toLowerCase();
    if (-1==urlLower.search(”^http://”) &&
    -1==urlLower.search(”^https://”) && -1==urlLower.search(”^file://”))
    return false;
    return true;
    }
  4. Use Edit Find to search for HasValidURLPrefix and replace it with HasValidURLPrefix_UNC (you should find it two times).
  5. File – Save.
  6. Open command prompt and enter IISreset /noforce.
Important: To link to Folders correctly you must create your own content type exactly as below and not use the built in URL or Link to Document at all.

Create custom Content Type
  1. Go to your Site Collection logged in as a Site Collection Administrator.
  2. Site actions – Site Settings – Modify All Site Settings.
  3. Content Types
  4. Create
  5. Name = URL or UNC
  6. Description = Use this content type to add a Link column that allows you to put a hyperlink or UNC path to external files, pages or folders. Format is File://\\ServerName\Folder , or http://
  7. Parent Content Type,
    1. Select parent content type from = Document Content Types
    2. Parent Content Type = Link to a Document
  8. Put this site content type into = Existing Group:  Company Custom
    1. image
  9. OK
  10. At the Site Content Type: URL or UNC page click on the URL hyperlink column and change it to Optional so that multiple documents being uploaded will not remain checked out.
  11. OK
    1. image
Add Custom Content Type to Document Library
  1. Go to a Document Library
  2. Settings – Library Settings
  3. Advanced Settings
  4. Allow Management Content Types = Yes
  5. OK
  6. Content Types – Add from existing site content types
  7. Select site content types from: Company Custom
  8. URL or UNC – Add – OK
  9. Click on URL or UNC hyperlink
  10. Click on Add from existing site
  11. Add all your Available Columns – OK
  12. Column Order – change the order to be consistant with the Document content type orders.
  13. Click on your Document Library breadcrumb to test.
  14. View – Modify your view to add the new URL or UNC column to your view next to your Name column.
Create Link to Document
  1. Go to the Document Library
  2. New – URL or UNC
  3. Document Name: This must equal the exact file or folder name less the extension.
    1. Example: My Resume 
    2. Example: Folder2
    3. Example: Doc1
  4. Document URL: This must be the UNC path to the folder or file.
    1. Example: http://LindaChapman.BlogSpot.com/Folder1/Folder2/My Resume.doc
    2. Example: http://LindaChapman.BlogSpot.com/Folder1/Folder2
    3. Example: File://\\ServerName\FolderName\FolderName2\Doc1.doc
You might see other blogs that say you can't connect to a folder and must create a shortcut first. They are wrong. You can by the method above.

The biggest mistakes I see are:
  1. People click on the NAME field instead of the URL field. They are not the same. You MUST click on the URL field to access the Folder properly.
  2. People use the built in Link to Document content type thinking it is the same or will save them a step. It is not the same.
  3. People type the document extension in the Name field. You can not type the extension in the name field. It will see it is a UNC path and ignore the .aspx extension.
  4. People enter their slashes the wrong direction for UNC paths.

Saturday, May 8, 2010

TechNet vs. MSDN

Stumbled across this Microsoft link that has a nice table explaining the differences of when you can use TechNet subscriptions vs. when you should be using MSDN. I thought I knew, but I had a few of them wrong.
You should review them to ensure you are using the correct software.
http://msdn.microsoft.com/en-us/subscriptions/dd362338.aspx

HTTP Error 503. The service is unavailable. after deploying a SharePoint solution

Well this one threw me off, for a few minutes.


I deployed a custom .wsp solution.

Normal…local deployment, not a GAC deployment…

stsadm.exe –o addsolution –filename CustomSolutionFile.wsp

stsadm.exe –o deploysolutions –name CustomSolutionFile.wsp –local –url http://WebApplicationName


IISreset /noforce

Then the web application browser gave me the following error:

HTTP Error 503. The service is unavailable.

It seems every time I deploy this custom solution (I did not write it), I get this error because the Application Pool to the Web Application I deployed it to is not starting back up. So far all I have had to do it start the application pool and all is well.

Technorati Tags: SharePoint http error 503del.icio.us Tags: SharePoint http error 503

SharePoint in the Cloud?

For a SharePoint Cloud solution, a requirement is the ability to host multiple clients and departments in an isolated way, providing isolation to their workloads and administration while still providing all the platform features required. Some clients will need their own work areas, and the ability to host applications which will not hinder other sites deployed within the same farm.

This principal of isolation is referred to as Multi-tenancy. This is referring to the isolation of data, operation services, and management. In our current version, 2007, you can obtain this type of isolation at the Site Collection Level or the Web Application Level.  Each has their pros and cons and have to be planned very carefully to be scalable.  Many Site Collections are much more scalable and manageable than several Web Applications. However, Site Collections currently only provide limited isolation, while several Web Applications can be an administrative nightmare.

SharePoint 2010

SharePoint 2010 is already providing great improvements to Multi-tenancy.  A new feature has been introduced called Site Subscriptions.  They are a way to group sets of Site Collections based on their clients (or tenants) requirements of data, features, security and administration.  

It allows you to partition data based on their subscription, and also allows you to divvy out administration based on their subscription. To go even further, there is another new feature called Feature Packs, that group together site features that you then can associate to subscriptions.  This allows you to take Site Collections and manage them in an even more granular isolated way as currently.  You can define these Feature Packs and Subscriptions to match clients Service Levels, or security requirements, organizational structure, etc.

So picture this, you have one SharePoint web page, where your client (tenant) goes to subscribe to the SharePoint services they need to meet their needs.  Based on what the client selects for their requirements through that page (service levels, security, organizational, features) it then auto subscribes them to an existing subscription and feature pack, or builds them a new subscription and feature pack and they are within minutes taken to their new area. 

Thinking, ya right, that would be heaven...well close...just SharePoint 2010 in the Cloud :)

Want to read more?  Here you go...these are great articles!

  1. http://blogs.technet.com/speschka/archive/2009/11/30/enabling-multi-tenant-support-in-sharepoint-2010.aspx

  2. http://blogs.technet.com/speschka/archive/2009/12/30/multi-tenancy-in-sharepoint-2010-part-2.aspx

  3. http://blogs.technet.com/speschka/archive/2010/01/16/multi-tenancy-in-sharepoint-2010-part-3.aspx

Embed a video in a SharePoint Blog Post

So we all know we can embed Widgets, Gadgets, Videos, and other content by adding our HTML code into a Content Editor Web Part’s Source Code button on any SharePoint web page.

Well today I needed to embed a YouTube video for someone into a SharePoint Blog Post.

I usually use Microsoft Windows Live Writer to write all of my posts, so this isn’t an issue.  However this user did not use WLW.

So in researching why you can’t copy the same HTML code in a blog post like you can a CEWP, I found this published work around.  I will not take the time to explain how to implement it or how it works as the links below go into that detail.  But I implemented it quickly to all Site Collections with no problems so far.

Thanks to the people that wrote this work around!

http://erte.codeplex.com/

http://boris.gomiunik.net/erte/

Technorati Tags: embed video in SharePoint blog post

del.icio.us Tags: embed video in SharePoint blog post

How to create a custom Folder Content Type

Why would you want to create a custom Folder Content Type? If you need to have the same data entry fields (columns) that you have for your Documents or Items attached to the Folder and available during New and Edit Forms.

  1. Go to your Site – Site Settings – Modify Settings
  2. Under Galleries click Site content types
  3. Click Create
  4. I like to keep my Names short,
    1. so this example is FolderWithMetaData – you could use spaces I prefer not to, to remind users to keep names short.
  5. Under Description this is what will appear in the NEW area under the Folder Icon so keep it short
    1. Add a new Folder to this Document Library that includes a TITLE field in the data entry form."
  6. Under Parent Content Type select Folder Content Types
  7. At Parent Content Types select Folder if this is for a Document Library.
  8. At “Put this site content type into:”
    1. I prefer to create one custom group called “Company Name Custom Content Types” and put all custom ones I create there.
  9. Then select OK
  10. At the List Content Type: FolderWithMetaData page, go to the Columns and click on the columns such as Title that you want to appear in the data entry page and select Required or at least not hidden.
  11. Select Update all content types inheriting from this type and OK
  12. Go to your List or Library – Settings – Advanced Settings
  13. Select Allow management of content type = Yes and OK
  14. Under Content Type section click on the Add From Existing Content Types.
  15. Select your new Custom Content Type Group you created
  16. Then click your new Folder content type you created and click Add
  17. Then OK
  18. Then under the Content Types section again, select Change new button order and default content type
  19. Reorder if you want, I prefer to have all new custom content types appear on top or first.
  20. Then if you go to your List or Library under the NEW option you will now see your new Folder type and when they click New FolderWithMetaData the data entry form with have the

Now some will say, but if you put it in DataSheet Mode you can edit the Title. True, but you can not always edit all fields to a Folder in Datasheet Mode depending on the settings. Thus a custom content type can be a good easy solution.

And as you know, you can create Workflows to Content Types that may alert users when a new folder is created or some other type of workflow.

del.icio.us Tags: SharePoint custom Folder Content Type

Technorati Tags: SharePoint custom Folder Content Type

What is the admin page for Save Site As Template

If you are trying to save your site as a template but you are not seeing the option under Look and Feel, and you are sure permissions is not the issue, then you can simply append the following to the end of your site URL to access the page.

          _layouts/savetmpl.aspx

Example: http://YourWebApplication.com/sites/SiteName/_layouts/savetmpl.aspx

Technorati Tags: SharePoint admin page for

Cannot see saved Site Template that is in the Gallery

Problem:

You save a site as a Site Template, and you see it listed in the Site Collection Gallery but you cannot see it as an option in a site under the Site Collection.

Cause:

If you create a Site off a built-in or custom template, then you create a sub-site based off a different built-in or custom template, then save that sub-site as a Site Template, you will not see this new Site Template as an option to create from under any sub-sites that are not built off the same template as the saved template site was.

Resolution:

Basically there is no workaround for this issue. You must create both sites from the same template to be able to see the Custom-CustomSiteTemplateName . You will either need to re-create a new top site based of the same original template the saved sub-site was…or re-create your sub-site to be based off the same original template the top site was, then re-customize it and re-save it back up to the Gallery again.

I did NOT find a Microsoft KB article on this exact problem, but did find a similar one on this same issue with a saved List Template, then tested this and found Site Templates have the same problem.

del.icio.us Tags: SharePoint site template in gallery not seen

Technorati Tags: SharePoint site template in gallery not seen

Export List Data To Excel and keep it in sync with List changes

There is built-in functionality in SharePoint that allows you to export your Site List data into an Excel Spreadsheet.  There is also a built-in Data Connection and Refresh option in Excel that allows you to keep your offline spreadsheet in sync with the Site List changes.

Please note this is a one way synchronization only from Site List data to Excel. Any changes that are made to your Excel file are overwritten the next time you select to Refresh your data.

Many use this feature in three main ways;

  1. To view their List data while offline.

  2. To produce Excel Charting or PivotChart reports in Excel.

  3. To use Excel Services to display charts and graphs that are actually created in the Excel Spreadsheet they are exporting data to. In this way you would upload your Excel Spreadsheet to your Reports Library and Convert it. So both the List data and Excel spreadsheet are stored in your SharePoint site, but users are not accessing or updating that Excel spreadsheet. It is only being used as the graphing mechanism.

Instructions how:

  1. Go to the SharePoint Site Directory.

  2. Select your Site.

  3. Go to the List you want to export data from.

  4. Go to the Actions toolbar

  5. Select Actions - Export to Spreadsheet

  6. Select Open

  7. In Excel Save As Office 2003 format (required)

  8. It will create two extra columns; Item Type and Path, this is for sorting purposes primarily.

When you want to update the Excel spreadsheet with the Site's List data again:

  1. Open the Excel Spreadsheet.

  2. Click in the table area of the data.

  3. Go to the Design tab.

  4. In the External Table Data group click Refresh.

For small lists this will update very fast and you may not even notice it. Remember, when you click Refresh it will replace all Excel table contents with your current Site List data. And this is not a two way synchronization solution. Try Microsoft Access or VBA if you need some form of two way synchronization.

Technorati Tags: SharePoint export list data to excel,Excel data connection file

del.icio.us Tags: SharePoint export list data to excel,Excel data connection file

How to earn Medals on Microsoft Forums

I just pointed someone at my work to the Microsoft Forums and told them they should start reading through those for their answer to their problem or post a new question if not found. They had never signed up for it before. Then after signing up they asked “ …how do I earn those medals ? ”

Well it is not quite a fair system at all in my option, and many of the moderators are too quick to mark their own answers as the answer, when they don’t allow you the contributor to mark yours as the answer…but they do. (I will get allot of heat from them for saying that, many don't, but many do)

Anyways you earn POINTS that tally up for Medals.  WHY? Most are trying to build up to the MVP (Most Valued Professional) status on a subject. So unfortunately many reply with bogus non-helping non-related answers just trying to add to their points.  I myself am very frustrated with many of those trying to build up their points, as they are going about it wrong.

If you REPLY to a question not started by you = 2 points

If your REPLY is marked as the answer = 10 points

If your REPLY is voted as helpful = 5 x # of votes

Points            Medals

  • 0                   0
  • 1-750             1
  • 751-2000        2
  • 2001-7500      3
  • 7501 – 15000  4
  • 15001+          5

http://social.answers.microsoft.com/Forums/en-US/help#310

del.icio.us Tags: Microsoft Forum Medal

Technorati Tags: Microsoft Forum Medal

How to remove the comma from a Number column field ?

Gee, you sure think it wouldn’t be too much for Microsoft SharePoint developers to add an option in the Column settings for the Number field to select to not show a comma.  This is a complaint I get from users all the time…HIDE THE COMMA!

So one of the workarounds we have to do is to create a second field…a calculated field that removes the comma:

=TEXT([NumberColumnName],”0”)

Then make sure you select the data type as Number for the calculated field.

Keep in mind that if you need to have a decimal place then the above won’t work for you. To retain a decimal place use the following:

=text([NumberColumnName],”0.00”)

Change the number of zero’s behind the decimal to equal how many you allow in your original Numeric Field. With this formula if you entered 23,546.41 the calculated field will display it as 23546.41.  If you entered 23,546 the calculated field will show it as 23,546.00   .

How to add a linked List to your DispForm.aspx

Today I was modifying the DispForm.aspx (view page) to one of my Lists to link a second list below the first. This is so easy to do, and I do it allot just for convenience, but I don’t think I have ever taken the time to document it, so here it is.

If you have two lists that are linked by a common field using a Data Lookup field, then adding the second list to the first’s view and edit pages is something you may want to do.

        My disclaimer: The way I am showing this will customize or un-ghost the DispForm.aspx page.

My first List is called Inventory and all the fields are static fields, meaning they are not really expected to change their values, thus just one unique record for each item in inventory is expected.

My second List is called Inventory Updates and consists of all of the fields that are dynamic or that are expected to change periodically. This List will have multiple entries that link to one item in the Inventory List. The Inventory Updates List has a Data Lookup field that points to the Inventory ID built in field.

First I edited the default page (AllItems.aspx) to my Inventory List and added the Inventory Updates List Web Part on bottom and the Form Web Part on top. Then I made a Connection on the Form Web Part to Provide Values to the Inventory Updates web part. This is not required for the editing of the DispForm.aspx page we are about to do, but I do it just for consistency so both Lists are always linked in all views.

Moving on…now I open SharePoint Designer and open the individual site.

  1. Navigate to the LISTS container and expand my Inventory List and double click on the DispForm.aspx.
  2. Click on the Inventory Main area so the WebPartPages:ListFormWebPart is highlighted.
  3. Then click the Right Arrow just once. This will move your cursor to the open space underneath the web part.
  4. Now from the menu select INSERT SHAREPOINT CONTROLSDATA VIEW.
  5. It will insert the area for the Data View, now click on the hyperlink to add new Data Source Library in the box.
  6. On the right under Data Source Library click on the second List, for us it is Inventory Updates.
  7. From the item drop down select SHOW DATA.
  8. Then press Ctrl Click on the fields you want to display.
  9. Then click the button above the fields called INSERT SELECTED FIELDS AS…MULTIPLE ITEM VIEW.
  10. Click on the new WebPartPages:DataFormWebPart and you will see a right arrow appear, click on that to see your Common Data View Task options.
  11. Click on Filter:
  12. In the Filter Criteria box select the Data Lookup Field, mine is Field Name = InventoryID, Comparison = Equals.
  13. On the Value field arrow to the bottom and select CREATE A NEW PARAMETER.
  14. Click NEW PARAMETER button, in the NAME field enter the name of this parameter, mine is InventoryID.
  15. In the PARAMETER SOURCE select Query String.
  16. In the Query String Variable field enter ID .
  17. In the Default Value field enter 1 .
  18. Then select OK.
  19. Now your VALUE field back in the Filter Criteria box should show your new parameter name, mine is [InventoryID].
  20. Now just select OK to complete the filter.
  21. You can then go through the other formatting tasks such as Sorting, etc. as you wish, but the actions above are all that are needed to link the two lists on this one page.
  22. Then select to SAVE this PAGE.

Now you can go to your Inventory List DispForm.aspx page and see that when you select an item from the first list, all linked records from the second list will appear underneath.

Technorati Tags: SharePoint Linked List,DispForm.aspx,SharePoint Designer

How to add a copyright notice to bottom of pages

You can add a copyright notice or other text to the bottom of all pages by modifying the Default.Master, MWSdefault.master, and any other custom master pages or publishing masters you have.

To modify the default.master and MWSdefault.master go to your front end web server c:\Program Files\Common files\Microsoft Shared\Web Server Extensions\12\Template\Global\  and open default.master using NOTEPAD. Then scroll down to the very bottom and right above the closing </BODY> modify your statement below and paste it above that line.

Paste

<table style="width: 100%" align="center">
<tr>
     <td colspan="2" class="style1">Company, Inc.&nbsp; |&nbsp;
     <a href="Company, Inc.";</a> |&nbsp; <a href="CompanyExtranet;</a> |&nbsp;<a target="_blank" href="Other URLs">Other URLs;</a> |&nbsp;&nbsp; ©2006-2010 Company, Inc.. All rights reserved. </td>

</tr>
</table>

Then the </BODY> and </HTML> closing tags would be the last two lines.

To add your own style as referenced above then edit and paste the style information below to the top of the master page right before (above) the opening <HTML> tag.  Otherwise you can reference an existing style class from one of the default css files instead.

<style type="text/css">
.style1 {
font-family: Verdana;
color: #000000;
text-align: center;
font-size: 8pt;

</style>

Making this change the exact way listed above does not un-ghost or customize those pages. Typically by default opening them in SPD or similar tools such as Visual Studio will.

Now remember if you modify the default.master and MWSdefault.master then you will need to copy these files over before any upgrades like Services Packs or Infrastructure Update patches just incase Microsoft overwrites them. Or you can copy them and create your own custom master file which is what I do...however, for simple modifications like this I do choose to modify the built in ones and just make the modifications to the defaults again if they get overwritten.

Appended column stores by Version Control settings

OK, I feel really stupid with this one.  I use the Appended Column setting as a Log Column all over the place.

A user was wondering why they were only seeing the last 6 appended entries and not all of them. The appended column setting only stores as many Versions as you have set in your List Version Control settings. DUH, I knew that of course but had completely forgotten about it.

Can not delete a master page " This item cannot be deleted because it is still referenced by other pages "

I came across this bug the other day.  When creating a custom master page, I then wanted to delete it. When trying to delete the page I got the following error

"This item cannot be deleted because it is still referenced by other pages. This item cannot be deleted because it is still referenced by other pages " 

but I knew my page was not attached to any other pages. I finally found this KB from Microsoft http://support.microsoft.com/?kbid=926812 stating this is a known bug.

Rather than "hiding" the page as they suggest, I chose to create a Folder called "DeleteMe" in the MasterPage Gallery, then I had to turn my Version Control off completely and Content Approval off too. Then I opened the gallery using SPD and was able to drag the master pages into the DeleteMe Folder, then I went back to the Master Gallery web page and deleted the Folder.

Technorati Tags: SharePoint Master Page,can not delete

Site Owner can not Create a Page (Publishing Page)

This occurs more on architectures where the majority of sites are NOT a Site Collection but merely a Site under a Site Collection. While the Site Owners group has Full Control of their site they still are not able to Create a Page from the publishing pages library in their site.

This is because they must also have Read access to the Master Page Gallery at the Site Collection level.

Site Actions - Site Settings - Modify All Site Settings - Master Pages and Page Layouts - Settings - Permissions - New - add all users with Read only permissions.

SharePoint BlueGlassBand.master template

If you are working with the BlueGlassBand.master file, there are many items different than the default.master since this is a publishing template.  Here are some of my notes from working with it.

  • MaximumDynamicDisplayLevels="1"
    • will add a right arrow in the right side of the banner area that when you hover over it will show your 1st level of items in your Global Navigation (top menu bar)
    • Why would I want this?  If you want to remove your Global Navigation (top menu bar) from the area below to save space.
  • StaticDisplayLevels="2"
    • will add the 1st level Global Navigation plus the banner directly underneath resulting in a column
    • Why would I want this?  Only if you want it to display in a column format...not likely.
  • No Global Breadcrumb because the datasource is different
  • Different Local Breadcrumb because the datasource is different (here I just edited it and replaced with one from default.master)
  • Site Title next to logo/banner will be the Site Collection if in Global Navigation you choose to inherit the menu from above rather than the local Site Title (I hate this one!)

Although the layout is nice and clean and you may be tempted to want to use it for sites, just remember it was intended for Internet facing sites, so many items are different and will be confusing for the users if they are use to the default.master.

I would recommend copying the default.master and changing that copy to look how you want.

Change the NEW! item display

I have posted this before, but I just needed to do it the other day again.  If you want to change the number of days SharePoint displays that NEW! icon here is the command.

Enter 0 to hide it all together, or enter 2-6 for the days.  If you enter 0...say to upload some bulk items that you don't want it to show the NEW! on...but you want to turn it back on say to 3 days later...you can, but make sure you wait until the 4th day from your upload to issue the new command otherwise your documents will show the NEW! for how ever many days are left. It goes by the Created On date field.

cd /d %programfiles%\Common Files\Microsoft Shared\Web Server Extensions\12\BIN

stsadm.exe -o setproperty -pn days-to-show-new-icon -pv 0 -url http://WebApplicationDefaultManagedPath

cd /d %programfiles%\Common Files\Microsoft Shared\Web Server Extensions\12\BIN

stsadm.exe -o setproperty -pn days-to-show-new-icon -pv 5 -url http://WebApplicationDefaultManagedPath

Reference Material:  http://support.microsoft.com/kb/825510

Performance Monitor - Base Objects to Monitor

Again this is an old article that did not get migrated over to this new site.

I am always surprised at how many senior engineers do not understand how to use the Windows Server built-in Performance Monitor to determine hardware, software, network bottlenecks...or that have never even used it.  

First thing to remember, is that while you are running Performance Monitor that will cause a performance hit to your server too.  Now, obviously you do need to run it to create a good baseline to compare against, and to troubleshoot...but you should just perform short captures of less than 30 minutes if possible, during times not used, then average use, then peak times or with forced hits. 

Below is the baseline object counters that I always start with, then I eliminate different Performance Objects one by one, by their results, until I have just 2 or three that I have narrowed it down to.  I suggest you create a baseline like this and save it locally so the next time you need to capture you can do so very quickly by just opening and starting it.  I have had this baseline for literally years, I am sure I probably got it from a Microsoft white paper, but can't remember where.

Start - Run - type Perfmon   or

Start  - Administrative Tools - Performance - System Monitor. You have 3 display formats; graph, histogram and text report.

Adding Performance Counters

  • Right click the counter pane and select Add Counter
  • Select whether you are monitoring the local computer counters by selecting Use local computer counter option or another remote computer by selecting Select counter from computer option by providing the UNC path
  • Select from the Performance object drop down list
  • Select the counter, these are different according to the selected performance object
  • Click Add to add it in the System monitor
  • Click Explain button if you need more details about the counter

Performance Object

Count

Threshold

Description

Processor

Percent processor time_total

80 to 85 percent averaged over three intervals

The total percentage of processor usage for a server.

Network Interface

Bytes total per second_network interface

50 percent of the available network interface bandwidth -- for example, a 100-MB network interface running at 50,000 KB per second

The rate at which bytes are sent and received over each network adapter.

Logical Disk

Percent idle time_ (drives C:,D:, and so on)

20 percent over idle time_.

Reports the percentage of time during the sample interval that the disk was idle. If this value is very low, the logical disk is very busy.

Paging File

Percent usage

Above 70 percent

Review this value in conjunction with memory -- available megabytes and page faults per second -- to understand paging activity on the server.

Memory

Available MBs

128 MB -- assuming 2 GB of RAM as prescribed on servers

The amount of physical memory, in MBs, immediately available for allocation to a process or for system use on the server.

Memory

Page faults per second

20

A high rate of page faults indicates a lack of physical memory.

System

Processor queue length

The number of CPUs + 1

Exceeding the threshold indicates that the processors are not fast.

ASP.NET Applications

Requests per second_total

Through ongoing monitoring, trends begin to emerge that equate requests per second with CPU consumption

The number of requests executed per second; this roughly equates to the number of HTTP pages per second.

Disk

Physical Disk\% Free Space

15%

Disk

Logical Disk\% Free Space

15%

Disk

Physical Disk\% Disk Time

90%

Disk

Logical Disk\% Disk Time

90%

Disk

Physical Disk\Disk Reads/sec, Physical Disk\Disk Writes/sec

Depends on manufacturer's specifications;15,000 RPM vs 10,000 RPM, etc.

Check the specified transfer rate for your disks to verify that this rate does not exceed the specifications. In general, Ultra Wide SCSI disks can handle 50 to 70 I/O operations per second. Note that whether or not the I/O is sequential or random can have a strong impact on values for disk reads/sec and disk writes/sec.

Disk

Physical Disk\Current Disk Queue Length

Number of spindles plus 2

This is an instantaneous counter; observe its value over several intervals. For an average over time, use Physical Disk\Avg. Disk Queue Length.

Memory

Memory\Available Bytes

For larger memory computers, greater than 4 MB

Research memory usage and add memory if needed.

Memory

Memory\Pages/sec

n pages/sec per pagefile

Research paging activity. Note the amount of I/O going to the disks with pagefiles.

Paging File

Paging File\% Usage

Above 70%

Review this value in conjunction with Available Bytes and Pages/sec to understand paging activity on your computer.

Processor

Processor\% Processor Time

85%

Find the process that is using a high percentage of processor time. Upgrade to a faster processor or install an additional processor.

Processor

Processor\Interrupts/sec

Depends on processor; 1,000 interrupts per second is a good starting point

A dramatic increase in this counter value without a corresponding increase in system activity indicates a hardware problem. Identify the network adapter, disk, or other hardware causing the interrupts.

Server

Server\Bytes Total/sec

If the sum of Bytes Total/sec for all servers is roughly equal to the maximum transfer rates of your network, you may need to segment the network.

Server

Server\Work Item Shortages

3
If the value reaches this threshold, consider
adding the DWORD entries InitWorkItems
(the number of work items allocated to a
processor during startup) or MaxWorkItems
(the maximum number of receive buffers that
a server can allocate) to the registry (under
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\
Services\LanmanServer\Parameters). The entry
InitWorkItems can range from 1 to 512 while
MaxWorkItems can range from 1 to 65,535.
Start with any value for InitWorkItems and a
value of 4,096 for MaxWorkItems and keep
doubling these values until the Server\Work
Item Shortages threshold stays below 3.

Server

Server\Pool Paged Peak

Amount of physical RAM

This value is an indicator of the maximum paging file size and the amount of physical memory.

Server

Server Work Queues\Queue Length

4

If the value reaches this threshold, there may be a processor bottleneck. This is an instantaneous counter; observe its value over several intervals.

Multiple Processors

System\Processor Queue Length

SharePoint Performance Limits

I wrote this article over a year ago, but many of my old posts are missing from this new blog location.

Below are all of the SharePoint 2007 performance guidelines post SP1 summarized.  Note not all of these are "limits" but many are just suggested thresholds by Microsoft. Referenced Material: http://technet.microsoft.com/en-us/library/cc262787.aspx

  • SSP Shared Service Providers   · 3 per Farm sugg, 20 max
  • Zone   · 5 per Farm
  • Web Application   · 99 per SSP
  • IIS Application Pool  · 8 per Web Server
  • Site Collection   · 50,000 per Web Application
  • Site Collection   · 50,000 per Content Database
  • Site Collection   · 150,000 per Web Application * if spread across multiple Content DB
  • Content Database   · 100 CDB per Web Application
  • Index Servers   · 1 per SSP
  • Excel Calculation Services/Apps   · No Limit
  • Query Servers   · No Limit
  • Web Server/Database Server Ratio   · 8 Web Servers per Database server
  • Web Server/Domain Controller ratio   · 3 Web Servers per Domain Controller
    • however Microsoft is ASSUMING that your current DC are following their Guidelines for DC Capacity Planning recommendations according to those best practices of aproximately 1 DC per 10,000+ users.  Most customers have MANY more DCs than they should have, because they don't do proper DC capacity planning.
  • Web Site   · 250,000 per site collection
  • Subsite   · 2,000 per Web Site
  • Documents   · 5 million per library (sugg < 2,000 per Folder, Folders not nested too deep)
  • Document file size   · 2 GB  * the limit is NOT 50MB that is simply the "default" setting, most customers change this to 2GB
  • Item   · 2,000 per View
  • List   · 2,000 per Web Site
  • Field Type   · 256 per list
  • Column   · 2,000 per Document Library
  • Column   · 4,096 per list
  • Web Part   · 50 per page
  • Content Query,Cross List Web Parts
  • limit of 1,000 cross lists to query however, this IS over-ridable at the command level
  • Managed Paths   · 20 per Web Application
  • User in groups   · 2 million per Web Site
  • User Profile   · 5 million per farm
  • Security Principals   · 2,000 per ACL on any object
  • Search Indexes   · 1 per SSP
  • Search Indexes   · 20 per Farm
  • SSPs   · 20 SSPs per Farm
  • Indexed Documents   · 50,000,000 per Content Index
  • Content Sources   · 500 per SSP
  • Start Addresses   · 500 per content source
  • Alerts   · 1,000,000 per SSP
  • Scopes   · 200 per site
  • Display groups   · 25 per site
  • Crawl rules   · 10,000 per SSP
  • Keywords   · 15,000 per Site
  • Crawled Properties   · 500,000 per SSP
  • Managed Properties   · 100,000 per SSP
  • Authoritative Pages   · 200 per relevance level
  • Results removal · 100 during one operation
  • Crawl Logs   · 50,000,000 individual log entries

Microsoft Best Practices:

  • Separate NICS to handle inbound and outbound traffic. 
  • Use Gigabit NICs with sefl-switching cards set to over-ride to use 1 Gigabit. 
  • If using a Gigabit switch ensure the same number of inbound/outbound channels.
  • All front end servers should have LAN bandwidth and latency to the SQL back end server up to 1 millisecond latency. 
  • Custom Coding: No more than 2-3 SQL round trips. 
  • Consider moving the SSP databases onto a different physical database server.
  • Always use 15,000 RPM disks where possible.
  • Segregate the configuration database and content databases into different SCSI disks in a RAID 5.
  • Segregate search databases, temporary databases, and temporary database logs onto different high-speed SCSI disks in a RAID 10.  Add additional drives to the disk array to increase total I/O.
  • Defrag databases and drives on a regular basis.    
  • Build a temp data file for each processor core on the server.
  • WSS & MOSS are CPU intensive. Use 64bit 4 multi-core processors
  • · Implement a caching strategy, or distribute databases across multiple physical servers. 
  • · TTL issues: Keep Page download size small.
  • · Use 64bit OS and 8-16 GB RAM
  • · Exclude SQL databases files from antivirus software scans.

1/17/2009 8:03 PM

Failure decompressing data from a cabinet file error

Recently I got the following error when trying to save a site as a template with Content.  This site's size was well under the supported 25-50MB.  So I really should not have gotten the error.  However, this site did have much custom work and third party content types, etc.  So I think we sometimes get this error for other reasons than the KB article says.

Error:  Failure decompressing data from a cabinet file.

Resolution: none really, you can try increasing your template size by running on the front end servers:  Stsadm.exe -o setproperty -pn max-template-document-size -pv 524288000   However, in my case it didn't fix my error.  I ended up having to backup the site using SPD and restore it to a new location and work on my Lists from there.

Microsoft KB Article:  http://support.microsoft.com/kb/960969

Published: 6/1/2009 11:05 PM

How to add columns to Folders

Well as you probably know, you can add fields/columns to your document library lists, and populate those same field on the Folders themselves by going into Datasheet Mode.  The problem with this is that not all fields can be edited in Datasheet Mode. For example using this method you cannot edit a Data Lookup column to a Folder, or People Picker field, or Multi-line Text field while in Datasheet Mode.

Another way is to create your own Folder Content Type.

  1. On your site with the document library
  2. Site Actions - Site Settings -Galleries - Site content types
  3. Create
  4. Name = whatever you want, mine is "FolderPlus"
  5. Parent Content Type = Folder Content Types
  6. Parent Content Type = Folder
  7. Then either add it to an existing group or create a new group.
  8. Click OK
  9. Then in Columns select to Add from existing site columns or create new depending on your needs.
  10. Click OK
  11. At your document library select Settings - Library Settings 
  12. Select Advanced and select Yes to Allow management of content types - OK 
  13. In the Content Types section click Add from existing site content types - select the new FolderPlus 
  14. Now at your Document Library if you select NEW you will see the content type.
  15. Upon creating a new FolderPlus folder it should show you your columns you added to enter data in.

Whether you create this new Content Type at the Site Collection or Site level will depend on whether your additional columns are standard ones or unique.

Published 2/1/2007 9:01 PM

Know a little CSS do ya?

WELL, then have fun with this! As you know with SharePoint to get corporate branding looks you can create Custom Themes, Master Pages, etc.  Well what about those users that are not server admins, just a site owner?  If you know CSS (Styles) even just a little you can change the colors and fonts on your home page or any other pages you are the Site Owner to. 

All you have to do is add a Content Editor Web Part to the bottom of your page. Then hide the Title and Border, then select Source Code and enter <style> then your CSS custom styles </style> that's it.

What's the catch?  Well you do need to know what the SharePoint Controls Styles are called, that part is hard. But you can right click on a page select View Source, and you can see most of the controls there. Also Heather Solomon has a chart of course. Also this will only apply this style on this one page.  Also it will be slower this way because  it will actually apply this CSS control last, meaning after it loads the styles from Site Definition, Themes, etc.

But this is excellent to show regular Site Owners.  Have fun with it.

Published: 11/1/2007 8:29 PM

Good SharePoint Services 3.0 Power User Level Book

Too many books try to combine MOSS 2007 (Portal Server) in the same book as WSS 3.0 and therefore much ends up not being relevant to a pure WSS configuration. 

So I just looked over mine, and I think that the following one is best for users, power users and Site Owners.  I have a copy in my document library. Careful if you choose to open it or download it, it is 44MB in size, a PDF file. But for those preferring to order the book the information is below.

  • Microsoft Windows SharePoint Services 3.0 Step by Step
  • ISBN-13: 978-0-7356-2363-7
  • ISBN-10: 0-7356-2363-5
  • $24.99

Published: 3/3/2008 10:51 PM

Free SQL 2008 eLearning!

Check out these free SQL 2008 eLearning courses from Microsoft Learning site. I went through them this weekend and they are okay beginner courses to get you up to speed with what is new in 2008...and did I mention its free? Clinic 6188, 6189, and 6190 Here is a link to all their current FREE online courses:  http://learning.microsoft.com/Manager/Catalog.aspx?view=free

Published: 11/5/2007 10:19 AM

System Center Operations Manager 2007 presentation

This week I presented System Center Operations Manager 2007 and its differences from its predecessor MOM 2005 and the migration path, for Microsoft at the Utah IT Pro Users Group.  It was a 2 hour presentation. I am posting the presentation for any of you interested in Operations Manager. There is allot of content in my Speaker Notes so look there.

It is in my document library here. Beware it is 3MB and in PowerPoint 2007 SCOM 2007 Presentation

Org Published: 10/9/2007 10:06 PM

Book of Choice - sorry but its...Microsoft Press

People always ask me what books I recommend for SQL, AD, SharePoint, etc.  It always seems to be a disappointment to them when I say the Microsoft Press books are by far my favorite.  I don't deny that I am partial, I used to sit on their review/editing board for the MOC training classes and the MS Press publishing.  I liked their process for how they decided what content they left in did away with, by polling experts from different lines of business.

This newest set, the blue books, I find are very logical and easy to follow. I think I have everyone they've published so far!  I especially like the Administrator's Pocket Consultant series; SQL 2005, Exchange 2007, IIS 6.0.

But it is easier for me to say what books I have bought and read that were not worth the money or time spent; Syngress "How to cheat at Managing Microsoft Operations Manager 2005", horrible, they somehow just took the Installation ReadMe Text file that comes with MOM and reworded it to fill up 467 pages!  Don't waste your money!

Published: 1/5/2008 8:19 PM

Troubleshooting Forest Trusts Batch Output

This is one of the batch files I put together to troubleshoot forest trust relationship problems.  It was based off a Microsoft Port Query template batch file.

@echo off
Goto START

************************************************************************
* Created By:  Linda Chapman
* CMD File to facilitate PortQry test for Domain Controllers
* INPUT SYNTAX: OpenPorts.cmd <DC NetBIOS name>
* OUTPUT: This will generate a <DC NetBIOS name>TrustedDomainResults.txt file.
* DEPENDENCY: PortQry.exe
*
************************************************************************

:START
echo.
echo Testing with PortQry against %%s
echo AD/DC specific ports
echo.
echo.

:ERRORCHECK

echo Press any key to continue the test...
pause

:PINGTEST
echo Pinging %%s
Echo    ************* > TrustedDomainResults.txt
Echo    * Ping Test * >> TrustedDomainResults.txt
Echo    ************* >> TrustedDomainResults.txt

for /f "eol=; tokens=1 delims=," %%s in (TrustedDomainServerList.txt) do ping %%s >>TrustedDomainResults.txt
pause
Echo. >> TrustedDomainResults.txt
Echo. >> TrustedDomainResults.txt
echo.
echo.

:PORTWORK
echo Testing DNS
Echo    ************************ >> TrustedDomainResults.txt
Echo    * DNS (53) UDP and TCP * >> TrustedDomainResults.txt
Echo    ************************ >> TrustedDomainResults.txt
Echo    Performing    Portqry -n %%s -p both -e 53
for /f "eol=; tokens=1 delims=," %%s in (TrustedDomainServerList.txt) do Portqry -n %%s -p both -e 53 >>TrustedDomainResults.txt
echo.
echo.
pause
echo Testing Kerberos
Echo    ***************************** >> TrustedDomainResults.txt
Echo    * Kerberos (88) UDP and TCP * >> TrustedDomainResults.txt
Echo    ***************************** >> TrustedDomainResults.txt
Echo     Performing  portqry -n %%s -p both -e 88 >> TrustedDomainResults.txt
for /f "eol=; tokens=1 delims=," %%s in (TrustedDomainServerList.txt) do portqry -n %%s -p both -e 88 >>TrustedDomainResults.txt
echo.
echo.

echo Testing RPC End Point Mapper Service
Echo    ********************************** >> TrustedDomainResults.txt
Echo    * RPC End Point Mapper (135) TCP * >> TrustedDomainResults.txt
Echo    ********************************** >> TrustedDomainResults.txt
echo    performing portqry -n %%s -p TCP -e 135 >> TrustedDomainResults.txt
for /f "eol=; tokens=1 delims=," %%s in (TrustedDomainServerList.txt) do Portqry -n %%s -p TCP -e 135 >>TrustedDomainResults.txt
Echo.   >> TrustedDomainResults.txt
Echo.   >> TrustedDomainResults.txt
echo.
echo.

echo Testing NetBIOS Name Service
Echo    ********************* >> TrustedDomainResults.txt
Echo    * NetBIOS (137) UDP * >> TrustedDomainResults.txt
Echo    ********************* >> TrustedDomainResults.txt
echo   performing portqry -n %%s -p UDP -e 137 >> TrustedDomainResults.txt
for /f "eol=; tokens=1 delims=," %%s in (TrustedDomainServerList.txt) do Portqry -n %%s -p udp -e 137 >>TrustedDomainResults.txt
Echo. >> TrustedDomainResults.txt
Echo. >> TrustedDomainResults.txt
echo.
echo.

echo Testing NetBIOS Datagram Service
Echo    ********************* >> TrustedDomainResults.txt
Echo    * NetBIOS (138) UDP * >> TrustedDomainResults.txt
Echo    ********************* >> TrustedDomainResults.txt
echo    performing portqry -n %%s -p udp -e 138 >> TrustedDomainResults.txt
for /f "eol=; tokens=1 delims=," %%s in (TrustedDomainServerList.txt) do Portqry -n %%s -p udp -e 138 >>TrustedDomainResults.txt
Echo. >> TrustedDomainResults.txt
Echo. >> TrustedDomainResults.txt
echo.
echo.

echo Testing NetBIOS Session Service
echo    ********************* >> TrustedDomainResults.txt
Echo    * NetBIOS (139) TCP * >> TrustedDomainResults.txt
Echo    ********************* >> TrustedDomainResults.txt
echo    performingportqry -n %%s -p tcp -e 139 >> TrustedDomainResults.txt
for /f "eol=; tokens=1 delims=," %%s in (TrustedDomainServerList.txt) do Portqry -n %%s -p tcp -e 139 >>TrustedDomainResults.txt
Echo. >> TrustedDomainResults.txt
Echo. >> TrustedDomainResults.txt
echo.
echo.

echo Testing LDAP
Echo    ************************** >> TrustedDomainResults.txt
Echo    * LDAP (389) UDP and TCP * >> TrustedDomainResults.txt
Echo    ************************** >> TrustedDomainResults.txt
echo    performing portqry -n %%s -p both -e 389 >> TrustedDomainResults.txt
for /f "eol=; tokens=1 delims=," %%s in (TrustedDomainServerList.txt) do Portqry -n %%s -p both -e 389 >>TrustedDomainResults.txt
Echo. >> TrustedDomainResults.txt
Echo. >> TrustedDomainResults.txt
echo.
echo.

echo Testing SMB Direct Hosting
Echo    ***************** >> TrustedDomainResults.txt
Echo    * SMB (445) TCP * >> TrustedDomainResults.txt
Echo    ***************** >> TrustedDomainResults.txt
echo    performing portqry -n %%s -p tcp -e 445 >> TrustedDomainResults.txt
for /f "eol=; tokens=1 delims=," %%s in (TrustedDomainServerList.txt) do Portqry -n %%s -p tcp -e 445 >>TrustedDomainResults.txt
Echo. >> TrustedDomainResults.txt
Echo. >> TrustedDomainResults.txt
echo.
echo.

echo Testing Secure LDAP
Echo    ******************* >> TrustedDomainResults.txt
Echo    * LDAPS (636) TCP * >> TrustedDomainResults.txt
Echo    ******************* >> TrustedDomainResults.txt
echo    portqry -n %%s -p tcp -e 636 >> TrustedDomainResults.txt
for /f "eol=; tokens=1 delims=," %%s in (TrustedDomainServerList.txt) do Portqry -n %%s -p tcp -e 636 >>TrustedDomainResults.txt
Echo. >> TrustedDomainResults.txt
Echo. >> TrustedDomainResults.txt
echo.
echo.

echo Testing GC LDAP
Echo    ******************* >> TrustedDomainResults.txt
Echo    * LDAP (3268) TCP * >> TrustedDomainResults.txt
Echo    ******************* >> TrustedDomainResults.txt
echo    performing portqry -n %%s -p TCP -e 3268 >> TrustedDomainResults.txt
for /f "eol=; tokens=1 delims=," %%s in (TrustedDomainServerList.txt) do Portqry -n %%s -p tcp -e 3268 >>TrustedDomainResults.txt
Echo. >> TrustedDomainResults.txt
Echo. >> TrustedDomainResults.txt
echo.
echo.

echo Testing GC Secure LDAP
Echo    ******************** >> TrustedDomainResults.txt
Echo    * LDAPS (3269) TCP * >> TrustedDomainResults.txt
Echo    ******************** >> TrustedDomainResults.txt
Echo    Test GC SSL (3269) TCP >> TrustedDomainResults.txt
echo    performing portqry -n %%s -p tcp -e 3269 >> TrustedDomainResults.txt
for /f "eol=; tokens=1 delims=," %%s in (TrustedDomainServerList.txt) do Portqry -n %%s -p tcp -e 3269 >>TrustedDomainResults.txt
Echo. >> TrustedDomainResults.txt
Echo. >> TrustedDomainResults.txt
echo.
echo.
echo End of Script
echo pause
Goto END

:END

Published: 4/30/2008 11:39 PM

Charting for SharePoint

I like Dundas Charts and Gauges for SharePoint. Aproximately $1999 or $2999 for both Charts and Gauges. http://dundas.com/Technologies/Sharepoint/DashBundle.aspx

I would have liked AnyChart.com's product better, but they need to integrate into SharePoint more. They need to figure out to how point to a Sharepoint List and have their tool automatically generate the XML file and modify it so that the user doesn't have to try to figure this out.  They also had TERRIBLE SUPPORT!  No one would ever answer the emails.  They tried to say they were caught up in their spam filter.  I am sorry, but when your site says your primary means of support is over EMAIL, then you better make sure you can get all the emails.

Published: 1/1/2009 1:38 PM

Blog vs Discussion Threads

Okay I have been blogging for over 3 years now, before it was even well know of, and I have to say, I happen to like Discussion Threads better than Blogs.

I really like how Discussion Threads make it so easy to see the "tree" of the discussion.  With Blogs, regardless of what tool you are using, they are all the same in that you do not easily see the entire threaded discussion back and forth.

So there it is my vote is for Discussion Threads...I rarely express my opinion about stuff like this, but I am really just not getting the Blog over a Discussion Thread.  If Microsoft would modify Windows Live Writer to post to Discussion Forums then I would switch to a Discussion Forum in a heart beat.  But I do like the convenience that Windows Live Writer provides when documenting, so I use it for almost everything, which in turn means I have to use Blogs for almost everything!  Just do me a favor and modify Live Writer to post to Microsoft Discussion Forums so I can use those.

Published: 12/26/2008 1:36 PM

SQL 2005 Express Edition Backups

If you are using or have an application that is using the free version of SQL 2005 (Express), then you should install the free utility to manage it, Microsoft SQL Server Management Studio Express.  It provides a simple interface to manage instances of SSDE.  You can download this from Microsoft here.

It is very light weight, not taking up much space.  You can still use SQLcmd to script and schedule it through Scheduled Tasks if you prefer.  It can be found in C:\Program Files\Microsoft SQL Server\90\Tools\binn  or  C:\Program Files\Windows Resource Kits\Tools  .

First create a TSQL file.  You can create this using SQL Server 2005 Express Studio to get the proper syntax.  First create a backup, then while in the backup, go to the top bar and select Script - Script Action to File, and it will create the .sql file for you :

You will notice that Express defaults to a Simple Recovery.  If you need to perform a Full Recovery you will need to right click on your database, select New Query, paste the code below changing [Linda] for your database name, then select Execute.  Then you will notice you will now have the Transaction Log as an option under Backup Method.

USE [master]
GO
/****** Object:  Database [Linda]    Script Date: 09/04/2008 12:57:52 ******/
ALTER DATABASE [Linda] SET RECOVERY FULL
GO

Example of Backup of a Database:

BACKUP DATABASE [Linda] TO  DISK = N'c:\Program Files\Microsoft SQL Server\MSSQL.1\MSSQL\Backup\Linda.bak' WITH NOFORMAT, NOINIT,  NAME = N'Linda-Full Database Backup', SKIP, NOREWIND, NOUNLOAD,  STATS = 10
GO

Example of Backup of a Database with FULL, Append to Existing and Verify:

BACKUP DATABASE [Linda] TO  DISK = N'c:\Program Files\Microsoft SQL Server\MSSQL.1\MSSQL\Backup\Linda.bak' WITH NOFORMAT, NOINIT,  NAME = N'Linda-Full Database Backup', SKIP, NOREWIND, NOUNLOAD,  STATS = 10
GO
declare @backupSetId as int
select @backupSetId = position from msdb..backupset where database_name=N'Linda' and backup_set_id=(select max(backup_set_id) from msdb..backupset where database_name=N'Linda' )
if @backupSetId is null begin raiserror(N'Verify failed. Backup information for database ''Linda'' not found.', 16, 1) end
RESTORE VERIFYONLY FROM  DISK = N'c:\Program Files\Microsoft SQL Server\MSSQL.1\MSSQL\Backup\Linda.bak' WITH  FILE = @backupSetId,  NOUNLOAD,  NOREWIND
GO

Example of Shrink of a Transaction Log:

USE [Linda]
GO
DBCC SHRINKFILE (N'Linda_log' , 1)
GO

You should always backup the Transaction Log before Shrinking it.  Example:

BACKUP LOG [Linda] TO  DISK = N'c:\Program Files\Microsoft SQL Server\MSSQL.1\MSSQL\Backup\Linda.bak' WITH NOFORMAT, NOINIT,  NAME = N'Linda-Transaction Log  Backup', SKIP, NOREWIND, NOUNLOAD,  STATS = 10
GO
declare @backupSetId as int
select @backupSetId = position from msdb..backupset where database_name=N'Linda' and backup_set_id=(select max(backup_set_id) from msdb..backupset where database_name=N'Linda' )
if @backupSetId is null begin raiserror(N'Verify failed. Backup information for database ''Linda'' not found.', 16, 1) end
RESTORE VERIFYONLY FROM  DISK = N'c:\Program Files\Microsoft SQL Server\MSSQL.1\MSSQL\Backup\Linda.bak' WITH  FILE = @backupSetId,  NOUNLOAD,  NOREWIND
GO

Then create your command for the Scheduled Task:

Example:  SQLcmd -S ComputerName\Instance -E -i "LocationOfINPUTfile\Backup.sql"

4/6/2009 11:13 PM

SharePoint Services 3.0 - SQL Database Moves

This is a list of good MS articles to reference in respect to your WSS SQL server and databases.

Published: 12/1/2008 9:24 PM

On Vista or Windows 7 you get "This file is read-only" when editing a SharePoint Services 3.0 document

Problem:
Using Vista, Office 2007 and Internet Explorer 7, or Windows 7 Office 2007 and IE8, you get any of the following errors when trying to edit and save a document from a SharePoint Document Library, or any other WebDAV based service.

  • This file is read-only.

  • Unknown error trying to lock file.

  • This document was checked out to your local drafts folder but the local copy could not be checked in to the site. Close any application that is editing the document and try to check in again, or discard the checkout.
Cause:
This problem is caused from a Vista and Windows 7 WebDAV problem when you do not have a Proxy Server defined.
Refer to Microsoft KB Article 943280.  Please note if Service Pack 1 for Vista is already applied then you only have to perform the  Registry change shown below.
Resolution:
Please follow the steps in the KB article above.
Step Summary

  1. Start - Run - RegEdit

  2. HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\WebClient\Parameters

  3. From top menu select Edit

  4. New - Multi-String Value

  5. Enter:   AuthForwardServerList

  6. Press ENTER

  7. From top menu select Modify

  8. In the Value Data box type:
http://YourSharePointApplicationURLs
Then reboot.
Published: 2/15/2008 9:21 PM

Issue tracking list data is not saved when you save a site as a template

Problem:

Issue tracking list data is not saved when you save a site as a template.

Cause:

This is due to using the built-in Issue Tracking List as the original template.

Resolution:

Microsoft has confirmed this to be a problem, and there is currently no fix.

Microsoft Knowledge Base: http://support.microsoft.com/kb/948141/en-us

Your only options are to re-create the list and copy the data over.

Published: 12/4/2008 9:20 PM

SharePoint - Cannot see custom site template in subsite

Problem:

You save a site as a Site Template, and you see it listed in the Site Collection Gallery but you cannot see it as an option in a site under the Site Collection.

Cause:

If you create a Site off a built-in or custom template, then you create a sub-site based off a different built-in or custom template, then save that sub-site as a Site Template, you will not see this new Site Template as an option to create from under any sub-sites that are not built off the same template as the saved template site was.

Resolution:

Basically there is no workaround for this issue. You must create both sites from the same template to be able to see the Custom-CustomSiteTemplateName . You will either need to re-create a new top site based of the same original template the saved sub-site was…or re-create your sub-site to be based off the same original template the top site was, then re-customize it and re-save it back up to the Gallery again.

I did NOT find a Microsoft KB article on this exact problem, but did find a similar one on this same issue with a saved List Template, then tested this and found Site Templates have the same problem.

Published: 12/20/2008 9:17 PM

SharePoint Services 3.0 scheduled tasks backup

How to perform Full Farm Backups through Scheduled Tasks.

Go to Start - Control Panel - Scheduled Tasks - Open - Add Scheduled Task

At the Task tab:

  • Run:  "C:\Program Files\Common Files\Microsoft Shared\web server extensions\12\BIN\STSADM.EXE" -o backup -directory \\SQLServerName\backupShare\FolderNameWSSbackups -backupmethod full
  • Start in:  "C:\Program Files\Common Files\Microsoft Shared\web server extensions\12\BIN"
  • Run as:  Domain\WSSserviceAdminAccount
  • Enabled Checked
  • Then fill out the Schedule, Settings, and Security tabs as needed.

Do not forget to write or schedule another routine that goes and deletes old Farm Backups out of the backup directory listed above, otherwise you can fill up that server quite quickly.

Published: 12/21/2006 9:15 PM

How to view the current Operations Master role holders

Referenced Material

"www.microsoft.com/technet/solutionaccelerators/cits/mo/

winsrvmg/adpog/adpog5.mspx#EOBBG"

To view the current operations master role holders, use Ntdsutil.exe with the roles option. This option displays a list of all current role holders.

Procedure Requirements

  • Credentials: User or Administrator
  • Tool: Ntdsutil.exe (System Tools)

Procedure Steps

To view the current operations master role holder

  1. In the Run text box, type ntdsutil and press ENTER.
  2. At the ntdsutil: prompt, type roles and press ENTER.
  3. At the fsmo maintenance: prompt, type connections and press ENTER.
  4. At the server connections: prompt, type connect to server servername (where servername is the name of the domain controller that belongs to the domain containing the operations masters).
  5. After receiving confirmation of the connection, type quit and press ENTER to exit this menu.
  6. At the fsmo maintenance: prompt, type select operation target and press ENTER.
  7. At the select operations target: prompt, type list roles for connected server and press ENTER.
  8. The system responds with a list of the current roles and the Lightweight Directory Access Protocol (LDAP) name of the domain controllers currently assigned to host each role.
  9. Type quit and press ENTER to exit each prompt in Ntdsutil.exe. Type quit and press ENTER at the ntdsutil: prompt to close the window.

Published: 7/1/2008 9:14 PM

Migrations - IntraForest Domain Migration and Collapse

As a consultant, I have specialized in large enterprise migrations for 13 years.  Over that time I have lead the migration effort for over 10 large global enterprises all from complex mixed environments (MS, Unix, Novell, etc).  Below is the methodology I have developed over the years trying to follow all best practices.  This is my first article in a series of "Migration" topics.

The focus of this article is: Performing a IntraForest Domain Migration and Collapse using the free tool ADMT v3 (Active Directory Migration Tool).  This article does not take into consideration Exchange, SharePoint or any other application specifically.  It is a high level migration planning approach to get you started.

Important Concepts

  • The domain you are migrating or collapsing should be operating at Windows Server 2003 Functional Level.
  • Objects are migrated and no longer exist in the Source location.
  • SID history is required.  Using ADMT it will create a new SID but it will use the SID History or SID Walker old tool method to retain the original SID as an Attribute of the object, therefore AD is aware of the old SID.
  • Passwords are retained.
  • Local Profile Migration
    • Migrating user profiles is a completely separate step from migrating the user account.
    • Be prepared with the manual steps to migrate user profiles manually for ones that didn't work.
    • Users computer must be powered on and accessible on the network prior to the account, profile, and computer migration.
    • For workstations that run the Microsoft Windows 2000 Server operating system and later, local profiles are migrated automatically because the user’s GUID is preserved.
    • For Windows NT 4.0 and earlier you must use ADMT to migrate local profiles.
  • You must migrate accounts in closed sets. This means that all users in all groups you are migrating are only in your source domain, and all users that are in a group you are migrating are also being migrated, and all groups a user is in that is being migrated are being migrated. This is the only way the Global Group will be migrated to another Global Group.  If it is an "open set" then ADMT will migrate the Global Group to a Universal Group.  Remember, you don't want to have any more Universal Groups than necessary as they are replicated throughout the entire Trusted Forest structure from Global Catalog Server to Global Catalog Server causing un-necessary traffic over the network.
    • You migrate User Accounts, Global Groups together, and Resources (computers, servers, printers) and Local Groups together. The order you migrate objects is extremely important.  You will migrate Groups right before Users, not after.
    • When you migrate a Global Group it creates a Universal Group in the target domain to migrate the users into until all members of that Global Group have been migrated, and then it changes the Universal Group to a Global Group.  This is another reason it is important to migrate "closed sets".
  • Users must decrypt encrypted files before their account migration.

Active Directory Migration Tool

You must use ADMT to perform a domain migration or collapse properly. You can script it, use command prompt or use the Wizard.  Many things can go wrong in a migration using ADMT, especially if you have never performed a domain migration before.  Therefore, for this migration I highly suggest using the Wizard rather than scripting.

You will need to create at least one Migration Service Account that ADMT will use to perform the migration functions.

Object Migration Order

Remember you migrate 2 sets; 1) Groups and Users, and 2) Resources and Local Groups

  1. Run the Service Account Migration Wizard to identify all Service Accounts (it does not migrate them)
  2. Universal Groups
  3. Global Groups (exclude built-in groups)
  4. User Accounts that are members of the Global Groups migrated
    1. If you have any NT 4.0 computers then you need to Translate Local User Profiles next.
    2. This is not necessary for workstations > NT 4.0 because SID to GUID mapping will preserve in the registry the profile of the user and then re-associate it to the new SID.
  5. Service Accounts
  6. Resources - migrated users computers - you must reboot computer immediately afterwards
  7. Run Security Translation Wizard on any Software Distribution Points
  8. Resources - Printers
  9. Resources - File Servers - you must reboot immediately afterwards
  10. Resources - Member Servers (and Application Servers) - you must reboot immediately afterwards
  11. Resources - Infrastructure Servers (DHCP, DNS, all DCs except FMSO roles) and Domain Local Groups (exclude built-in groups) - you must reboot  immediately afterwards
  12. Resources - Infrastructure Server FSMO roles, leave the Root DC for last - you must reboot immediately afterwards

Migration Steps - high level

A domain migration and collapse is no minor task, and if not done in the proper order can orphan objects and lose their ACLs.  If you know me at all, you would know that I like to follow a phased approach for my migrations, as I was taught from my years work with Microsoft Consulting and EDS.

  1. Phase I - Preparation
    1. Clean up AD, remove all old user accounts, groups, OUs, computer accounts. 
    2. If you need to rename any accounts, groups or OUs you should do this prior to the migration, not during so that you do not experience naming conflicts.
    3. Identify all Login Scripts in the NTTL domain, track in a List recording what actions it takes.
    4. Identify all Service Accounts in the NTTL domain, track in a List recording; what permissions it requires, groups groups it is in, what GPOs are applied, and what applications and users use it.
    5. Identify all Domain Local Groups and ensure that the Domain Local Groups are NOT used ANYWHERE in the ACLs. 
      1. IMPORTANT:  Most companies do NOT leave enough time for this.  They "assume" that they don't have any or many ACLs using Domain Local Groups...and I have NEVER been to a company where they didn't under estimate this and ended up spending weeks re-ACLing at the last minute because they didn't address it properly.
    6. Identify all applications, scripts and batch files on all servers and workstations to ensure they do not have the fully qualified domain name hard coded anywhere.
      1. Again, I have stressed this to every customer and every customer insists they don't have any hard coded references to the domain names.  And again I have never had a customer that didn't have them.  I have had migrations come to a halt because of many domain references found at the last minute, that needed to be re-worked. 
      2. I suggest you purchase tool that can search the inside of batch files and other script files to search for your domain names.
    7. If there is currently only a one way trust, then create a two-way trust for the migration process as it just makes the steps easier.
    8. Identify all data, and printers on source domain controllers and migrate that data and objects over to other Member Servers if possible.
    9. Create a Service Account for ADMT that has Domain Administrator permissions in both domains.  It must also have delegated permission on the user, group, computer, OUs and the extended right to migrate SID history.
      1. In the TRI domain, delegate permissions on OUs that are targets for resource migration to the ADMT Service Account.
    10. OU Preparation - If you have a different OU structure then you will need to modify TRI to account for all computer, user, and application OUs.  You will need to map out which target OUs the computers and users will be migrated into.
  2. Phase II - Closed Set 1 Migration
    1. Use ADMT to migrate the following:
      1. Run the Service Account Migration Wizard to identify all Service Accounts (it does not migrate them)
      2. Universal Groups
      3. Global Groups (exclude built-in groups)
      4. User Accounts that are members of the Global Groups migrated
        1. If you have any NT 4.0 computers then you need to Translate Local User Profiles next.
        2. This is not necessary for workstations > NT 4.0 because SID to GUID mapping will preserve in the registry the profile of the user and then re-associate it to the new SID.
      5. Service Accounts
      6. Resources - migrated users computers - you must reboot computer immediately afterwards
    2. After each number verify migration logs for errors and verify the group types.
  3. Phase III - Closed Set 2 Migration
    1. Use ADMT to migrate the following:
      1. Run Security Translation Wizard on any Software Distribution Points
      2. Resources - Printers
      3. Resources - File Servers - you must reboot immediately afterwards
      4. Resources - Member Servers (and Application Servers) - you must reboot immediately afterwards
    2. After each number verify migration logs for errors and verify the group types.
  4. Phase IV - Collapse
    1. Use ADMT to migrate the following:
      1. Resources - Infrastructure Servers (DHCP, DNS, all DCs except FMSO roles) and Domain Local Groups (exclude built-in groups) - you must reboot  immediately afterwards
      2. Resources - Infrastructure Server FSMO roles, leave the Root DC for last - you must reboot immediately afterwards
      3. Perform ADMT Security Translation Wizard on Member Servers to clean up ACLs, and to remove the source domain SIDs from the ACLs..
    2. Only after ALL OBJECTS are migrated out of the child domain can you perform the DCPROMO back to a member server.
    3. Ensure all entries for the domain name and domain controllers are cleaned out of DNS, WINS, and Sites and Services properly.

Referenced Material:  Chapter 12 Restructuring Active directory Domains Within a Forest.doc

del.icio.us Tags: Migration Specialists,Active Directory migration,Active Directory Collapse,ADMT

Category: Active Directory;Migration

Published: 6/1/2008 9:11 PM