Monday, May 13, 2013

IIS 7.0 and 7.5 Not Rendering CSS Files or other static content

During a deployment for a client today of a custom ASP.NET application, IIS 7 refused to render external css files correctly - just spitting out Error 500 or blank content.  This happens because IIS 7 and 7.5 do NOT render static content by default - which is a little surprising but not completely unexpected.
To fix for Windows Server 2008:

  1. Open up Start - Administrative Tools - Server Manager on the Front End web server in question.
  2. Select Web Server (IIS) under Roles
  3. Click on "Add Role Services"

  4. Enable the "Static Content" checkbox.
  5. In IIS 7, Click on the Website and double click Handler Mappings

  6. Right click on "StaticFile" and click "Edit" .

  7. In the Module Field add "StaticFileModule,DefaultDocumentModule" and click OK
  8. DONE - FIXED!
The official support document for this on the MS site can be found here:
http://support.microsoft.com/kb/2196177

Source:

Sunday, May 12, 2013

Some Political Thoughts

I personally believe voters are those stupid whole believe that they can defeat king makers. As usual people were standing in lanes and votes were automatically in ballet boxes. No doubt in Lahore PMLN is the strongest party but this is not the way. Since a student of a geo politics I have a strong opinion that decision are made somewhere else. They need PMLN in Pakistan just to support war on terrorism and they don’t want any hiccups for their exist in Afghanistan. I am writing these lines because things were really depressing we are a nation who is inherently corrupt so honestly we don’t true people. So for new government things will not be so easy because Pakistan is like a car who needs engine level overhauling which requires money so what will happen is that new government will increase the Taxes or in long run and go for IMF in short run. Resulting both a rise in dollar my prediction is that dollar will reach around 108-110 in first year, as usual PMLN government will try to seek help of shah Abdullah for oil to start generation of electricity but for other expense they will highly dependent on new loans. As a prediction Ishaq dar will be the new minister of treasury. In my opinion the new government will not last more than 3 or 3 ½ year because once US will be out of Afghanistan they will leave support of Pakistan and in these 3 years people will be more frustrated due to and they ll be fed-up resulting in change. On the other hand I suspect that khan wouldn’t last till that time. because this nation does not deserve a true leader. I am not a supporter of IK but I believe must give him a chance but again I am just piece of paper which can be thrown out of ballet box.

things will not settle down for this country each passing day thing will become bad to worse because the preferences are not the recovery of sick economy or growth rate and no body has time to do that.

following things will happen as per my calculate.

  1. KPK government will be formed by PMLN, JUI F, Independents and JI
  2. a minor friction will soon arise between Army and PMLN
  3. power generation will be better in the short run as of oil from KSA and no long run solution will be provided all they will do is they will utilized current capacity to generate power of charity of oil
  4. people of Karachi will be real and I do mean real bad shape. a situation like 1994 will come back because Altaf Hussain will not tolerate PMLN influence in decision making of Karachi hence as they indicated they will start a bloodshed. Altaf Hussain exactly did what I expected and he will not stop.
  5. Nawaz Sharif will try to seize MQM resulting a real bad shape of Karachi.
  6. Stock exchanges will flourish for next months then will come back to its original size of 12,13K
  7. khan will remain silent for next 1 years because media will not focus him as per instructions. because its only the media which is a powerful tool of king makers.
  8. Asif Zaradari oh I forgot yes Asif Zaradari will remain Asif Zaradari till 2018….

these are just small calculation I am not an analysis just an observer. but the again strings get motion from the shadows and no doubt voters are those stupid whole believe that they can defeat king makers

 

 

Saturday, August 4, 2012

CRM 2011 Virtualization, Replica and IDF Guide

Recently I have been working to start and activity related to virtualization of a live CRM server and then create its replica to initiate the activity of internet facing deployment. things are still out of my hand I am trying to share as much knowledge I can during the course of activities. First of all I would recommend not to change name of CRM server machine because if you change the name you have to change the SQL server instance Name use Drop Server and Add Server command I share in a pervious post. then you have to reinstall CRM server 2011 and if your machine have traces of previous version of CRM server. it just goofs up. it does not register any of the assembly that is supposed to be registered by installer. so following are some steps I have done so far and by this time I have bee able to see the interface CRM server.

  1. Make a copy of production VM and start working on it for IFD deployment because that the only scenario you can reduce the down time.
  2. Change Machine name because if both machine comes up live same time it will just mess up you production environment. if you have already done that mistake. delete machine account from AD and try to rejoin production machine. do make sure you have already changes the name of new machine.
  3. from this point to onwards all discussion will be focused on new machine. so don’t confuse.
  4. uninstall CRM server because CRM will not work its machine name has been changed.
  5. check SQL server instance name if it has new name or not by using Print @@servername
  6. if it not the new machine run SP_dropServer and SP_server to you SQL server instance name. it will not show up until you restart the machine.
  7. once restarted go to SQL server Reporting services configuration and check it report server name and report manager names are updated if not then you have to change these name otherwise CRM installation will not proceed.
  8. once report server URL is change its better to restart your machine again. once back proceed with installation.
  9. install CRM server 2011 and import the organization, make sure you have install the Rollups which were actually installed previously. if not then your organization will not import.
  10. since you are now going live its better to Rollup till later version which is now 8. I am planning to do that shortly.
  11. however when tried to access the CRM website I realized I may have been made a biggest mistake, because I had no clue what is happening. because it was not working.
  12. finally I concluded that I have to re-register all assemblies with in GAC, because each time I was getting method not found exception. which has the simplest meaning that its calling DLL/assembly is not register. I developed a simple batch to server the purpose. which is mentioned blow.
    FOR %%a IN ("D:\Program Files\Microsoft Dynamics CRM\CRMWeb\bin\*.dll") DO GACUTIL /i "%%a"

now I am going to install Rollups, on the same token I have created a new machine for ADFS deployment, on that machine I have configured IIS and installed SQL Server 2008 R2. I will try to keep updated everyone.

Friday, August 3, 2012

Change SQL Instance name to reinstall CRM 2011

I was in middle of the installation and system was throwing exception that instance name must be same as of machine name. so I had to update the instance name of SQL server. following is a script I found online and it was really helpful.

USE master
GO

---- Fetch the SQL Server instance name - fetch the value of "name" from the output
--sp_helpserver
--GO

-- Drop the old server registration
sp_dropserver 'WIN2K8\SQL2K12','droplogins'
GO

-- Register the new server with the new name
sp_addserver 'CONTOSSSO\SQL2K12',local
GO
 
Source

Windows 7 Professional unable to Connect Remote Desktop

Recently installed new Windows 7.0 professional edition and now whenever I try to remote desktop it’s throws error like following

An authentication error has occurred.

The requested security package does not exist

so I had to search on google an I found that the problem is due to some missing parameters in the Registry.

Apparently one of the sys admins deployed an sms package that removed some settings from this key:

HKLM\system\currentcontrolset\control\lsa\security packages

It should have these values: kerberos msv1_0 schannel wdigest tspkg pku2u

The tskpkg and pku2u values were missing.

After adding them and rebooting and I can RDP to 2008 servers.

Friday, November 18, 2011

BizTalkMgmtDB marked as suspect

today I found that one of our BizTalk Servers are creating problems when access upon investigation I found that BiztalkTalkMdmtDb is in suspect status. to resolve this issue I did following things which are mentioned over the internet.

 

EXEC sp_resetstatus 'BizTalkMgmtDb'
ALTER DATABASE BizTalkMgmtDb SET EMERGENCY
DBCC checkdb(' BizTalkMgmtDb ')
ALTER DATABASE BizTalkMgmtDb SET SINGLE_USER WITH ROLLBACK IMMEDIATE
DBCC CheckDB ('BizTalkMgmtDb', REPAIR_ALLOW_DATA_LOSS)
ALTER DATABASE BizTalkMgmtDb SET MULTI_USER

Source

Monday, October 31, 2011

CREATE FILE encountered operating system error 5 Access is denied

I have an MSSQL 2008 R2 installation and was trying to attach a DB from a non-R2 installation using SQL Server Management Studio (SSMS) and I was getting the following error:

CREATE FILE encountered operating system error 5(Access is denied.) while attempting to open or create the physical file 'C:\Program Files\Microsoft SQL Server\MSSQL10_50.MSSQLSERVER\MSSQL\DATA\MyDataBase.mdf'. (Microsoft SQL Server, Error: 5123)
Found plenty of Google results pointing me to suggestions about SQL Server 2000 and 2005 with instructions on how to add user permissions and which user account needed to be added.

Turned out that all I needed to do was to run SSMS as an administrator and the attach worked.

Source

Wednesday, September 14, 2011

Client Communication Guidelines

1. Verbal communication including how to greet, explain and react to clients on different phase like in analysis, deployment and UAT

2. written Communication, including emails and status reports

3. Identification and escalation of changes and change requests.

4. how to keep live and follow-ups a thread, notification and problem escalation

5. Management involvement or issue escalation techniques, i mean when to induct top layer in a mail loop. I mean no need to include senior management in every email until there is really a need, to provide them bandwidth for other horizons to work upon.

6. How to remain disciplined in front of client, I mean if there is a high priority issue or problem everybody is jumping in to resolve that. Rather let Client Liaison/Project manager to resolve it

7. Escalation of Project variance and deadline to all stakeholders

8. How to be proactive rather reactive in client communication.

9. How to keep your primary contact relax and happy even if project is in trouble.

10. Increase the project’s perceived importance in your and your Client’s field of vision.

11. Reduce the temptation to delay something on that project for the sake of another as you’ll have to report on progress in less than a week, e.g. schedule and budget updates.

12. Allow for a constant flow of review and decision making at regular intervals, hence making planning easier.

13. Rapidly encourage a good working rapport with a client making things easier for both sides.

14. Avoid dealing with ad hoc requests the minute they come in, often they’re not as urgent as they seem.

15. Have a consistent project folder structure and file naming convention.

16. Follow consistent processes, so you get better at estimating how long similar tasks in the future will take: e.g. creating a proposal or functional specifications which are dependent on size of the project.

Thursday, September 8, 2011

working on shop floor, Areas for workplace productivity improvement

1. plan your daily activities, Build a crude time schedule for what you are planning to today, document it somewhere where it remains in focus.

2. document your meetings and publish meeting notes and action items

3. Keep your surrounding quite so that you are not causing disturbance for others, conference room is best place for meeting do not start taking in dev. hall until mandatory. use outside corridor for gossips and chitchats.

4. document and implement your ideas, because innovation is an outcome of creative ideas

5. be consistent, achieve your timelines or share the change of action

6. better to arrive on time, delayed arrival should have reason.

7. distribute your workload when required so that everyone feels himself as part of team.

8. be motivated, share whatever you want with management for catharsis

9. document all non-billable activities to keep a complete picture of your utilization

10. Take responsibility for the direction of your career. Ultimately you are responsible for creating an environment in which you can learn and grow. The longer you stay on a “dead-end” career path, the harder it will be to stay positive. If you are not happy with the current directions of your career, communicate that to your manager if you wish to stay with the company; otherwise, look for another job that you feel is a better match.

11. avoid distractions, noisy and congested work environment make it impossible to communicate with clients and concentrate on work, if you feel your surrounding are not bearable kindly inform HR.

12. Block websites, If you find yourself to be one of those people who can easily get distracted and spend lots of time on the web looking at anything but your work, then you may need some restraint. Getting a child website blocker or even some post-it reminders might help you stay focused and save those sites for your coffee break. Look online for some good, free open-source website blockers if you think it’ll help you get stuff done.

13. draw a simple road map before doing a code or QA, including what is to be done and how, I still do that and it helps me remembering reusability.

14. do not dive in and lost in code, try to reach on surface often to have a holistic view of the problem space.

15. and at last but not least work smartly, remember what you have done previously and how it can be utilized again and again.

Wednesday, September 7, 2011

CRM 2011 Email templates Flickering

Recently many of our users were reporting that when they modify or change any of CRM email template it start flickering or Internet explorer Crashes. upon investigation I observed that it is happening to only those templates where we have mentioned company’s phone number. upon further drilldown of problem  I concluded that it is happening due to Microsoft Lync Add-on of internet explorer, lynch add-on somehow injecting some HTML which is causing template to flicker horizontally and vertically. because when I disabled this Add-on everything started working as expected.

Thursday, August 11, 2011

Tactical Management and Strategic Requirements

In my previous post I tried to shed some light on the issues which are very much required by top management level, in my current post I will try to highlight areas which are missing by second layer of management or we can say the engine part of the an organization, often neglected or always considered as working properly. However an issue at this level result in low productivity and often work stress and low commitment and dedication level.

Define yourself:

Organization evolving from scratch to mid-level always has this phenomenon especially if technically skilled people are elevated from lower level or organization foundations are built by techiest. The problem is people with highest paid amount of salary and benefits’ always jump in to technical problem and in client support. It’s always good to be part of team but if you really don’t know who will carries the ball to the goal post then ultimately team will suffer. For mid-level manager it is very important that they always focus on Ariel view of the company and surroundings, this will help them to not only equip with latest trends but they will help to get more business which is the ultimate job of these people. Ordinary things can be done by the ordinary people and but if highly position people will start client support and analysis and design part then who will search for new venues and business. So ideally people should act what they are asked to do like VPs should focus on business developments, technical directors should focus on overall growth and project scopes overall performance, work environments and productivity measurements, Architects should focus of project design and performances. Because we will not do what we have to do then we all will mess up like those who are not in business now.

 

People are not doing what they have to do rather they are doing what they love to do.

Ready to relocate:

When we start doing something we develop a learning curve human nature always resistant to learn new things because it’s difficult and it required a dedication. So change is an ultimate requirement of any IT organization. However it is always observed that people are reluctant to learn new things or they learn it through the hard way. In progressive organization people working in a team are like fire fighters they do what is required to do but once things are under control they start practicing their job descriptions.

Analyze and document:

One of major problem in growing IT organizations where there are lack of documented processes that people are not ready to document about requirements. A non-documented project can have a huge variance because the changing requirements from the client. To reduce rework and enhance profitability is must that each client requirement and change should be documented and approved the client to keep all stakeholders at same page.

Work Planning and WBS:

Make sure that each team and its member have a clear set of requirements and work break down structure. Vague WBS and lack of planning at work level can take effort to 60% above the required level.

Quantitative Estimates:

do not perform guesstimates on any project or even on a single functional points, define objectively the complexity, effort, time to spend by dev, QA and project management. search google for such templates.

Rework and information Gathering:

People doing multiple things at the same time or multi-tasking of senior members of organization is one of the major problem areas. Human mind can work on many things simultaneously but can focus on one at a time. It is always better that team which is supposedly working on project have direction communication with client and they gather it properly. Once signed and approved it will help to reduce rework effort.

Micro management and extended meetings:

People at any level of organization do not like baby sitting or micro management. For organization of IT, it has more serious impact on productivity due to intuitive nature of work. People often get frustrated and their working abilities may reduce if they are continuously monitored or managed. Ideally a project team should be autonomous in its decision because they are responsible for it. Similarly it’s always good to discussed serious issues but long and extended meetings always have serious negative impact on overall productivity. If a company is paying 100$ per hour to a group of senior managers, and a meeting of 5 people for 60 minutes will cost 500$. So ideally project meetings and status reviews should be concise and should not be more than 30 minutes.

Client communications:

Organization often prefers to save their technical staff from client shocks and realities shocks. This has a serious negative impact on overall team productivity and organization profitability. Due to this reason technical people never realize the criticality of situation. Furthermore this phenomenon takes a lot of time of top management which could be more productive if spent on business development. It’s always better to assign some client liaison who is responsible for project and client handling who can be offshore or onshore.

Dare to delegate:

Phenomenon is similar to above mentioned situation, that we have to trust on our team member and we have to dare to delegate task to those who are responsible for it, rather doing everything by ourselves.

Keep an eye on holes of your ship:

Being a senior member of crew it is one of my basic responsible to observe where we are bleeding. Organizations have small pockets or cavities from where the money is bleeding and we never consider that. Major areas for these bleeding pockets are resource intensive support projects, infrastructure requirements and infrastructure backups. Ideally it’s the responsibility of finance and operations to highlight these areas and decision should be made on these on quarterly basis.

In my next post I will focus on lower management where issues are with project managers and team leads. then I will suggest tool and techniques to resolve these problems.

Tuesday, August 2, 2011

Areas of Improvement in IT Organization

Every company strives for profitability and every organization try their best to make money with minimum efforts but only few make it possible, I think there some areas which were not discussed today or maybe we are not pondering a very serious attention to this matter. To me business Administration, understanding of people management is one of my favorite subjects and I have done a lot of researches in this area. Although we are missing with development standards we are lacking in PMO however I have seen many companies making good profit with minimum resource set. For example a company is getting more 250 million out of 35 resources with a single product best seller for black berry phones. Similarly people making huge money with minimum resources just because they have right set of tools and techniques with proper business projection. To me for any organization, following things are most important in profitability,

Business Direction and Dimension:

Every organization must know why they are in business, are there here for money or not, if they are in business for money then they should try to conceive and develop those products and services which are a business need, developing complex solution with labor intensive efforts ultimately result in failure until is not sold reasonably. A properly working paper pin is more profitable than a luxury weekend ride.

This phenomenon sometimes become product myopia, we develop what we love to develop but we never care if it has  customer, so develop something which is a need of customer.

Project and Organization profitability index:

We should be able to forecast what will we get by the end of project and what will be the net worth of any task that we are doing. Usually projects with high variance, due to lack of analysis and change control often fell in this problem. we put our best effort to make project happen but without profit or at breakeven levels.

This is happening in many projects around but nobody is willing to perform any project cost to profit ratio. These profitability ratios are also important at the end of fiscal years when we had a time for organization growth; each organization must maintain its cash inflow to facilitate its requirements. Ideally project profitability index should be calculated on monthly basis in IT projects and for organization it should be performed on quarterly basis, which can be a simple balance sheet or a detailed analysis of profit to cost ratio.

Effort vs. profitability ratio:

In any organization most of the people spend their time in working and mostly they put their best however some companies make really good business while others don’t. to me that is simply because when people don’t know if their work will really make a good business or not. To put this in example I would say if a developer is working for 5 hours on a php project will make far less amount of $ than a developer working for SharePoint project. So we should focus on the line of business for projects.

Furthermore if a task is billed for 3 hours actually takes 10 hours of developer then we are doing nothing. So we should either communicate that to client or we should make sure that these hours are ultimately sellable. This is also called as Cost / Benefit Analysis, an economic decision-making approach, used particularly in business for assessment of whether a proposed project is worth doing, or to choose between several alternative ones. It involves comparing the total expected costs of each option against the total expected benefits, to see whether the benefits outweigh the costs, and by how much.

Project to Resource ratio analysis:

Ongoing project Can Be divided in to two types of projects, project which are not delivered and project which are delivered and in support mode. For any project in support mode we need to make sure that we are putting minimum resources, rather increase in timelines. An increase in project resource will exceed the cost of support however a slow delivering support makes more money and client relationships. We need to perform some sort of analysis to make sure we are putting minimum amount of effort to make good money from support requests.

Role of QA to productivity:

QA plays a vital role in any organization however QA is the only department with maximum leisure if not utilized properly. QA team should be a part of project management developing project plan, QA team should be a part of analysis and requirement gathering and QA team must be a part of post deployment supports. That’s the only way to get maximum out of it. Otherwise QA should not me 20% or 1:5 ratio in any project.

Hiring hiccups:

Organizations confused in hiring spend a reasonable amount of money and resource in this process. Hiring a single person requires hours and hours of senior resources in interviewing and shortlisting of employees. To me there is should be an analysis of resource requirement and forecast. If we have clear forecast that we need a resource for at least a year then we should jump in to hiring otherwise resource relocation is best option in such conditions.

Financial projection:

Every organization must have projection of its finances for at least 2 quarters, because if we don’t have that, then we should be ready for surprises. Simple project could be total number of current cash inflow + estimate cash inflow minus current cash outflow + expected cash outflow.

Forecasting the company's cash and financing needs is necessary to develop the company at the pace desired by the entrepreneurs and investors. One of the main issues confronting entrepreneurs almost daily is the issue of financing the company's activities. Correct forecasting of the company's financial needs in the short-, intermediate- and long-term involves an understanding of the management of transactions and a basic understanding of the concepts of revenues, expenses, and cash paid or received within them. Even for early stage companies, for which full-blown business plans may not even exist, no financial model and hence no forecasting regarding required capital can be prepared without making various assumptions with respect to the customer credit policy, the compensation policy, and other costs.

reason for this projection/financial plans.

First, the financial plan translates your company's goals into specific targets. It clearly defines what a successfully outcome entails. The plan isn't merely a prediction; it implies a commitment to making the targeted results happen and establishes milestones for gauging progress.

Second, the plan provides you with a vital feedback-and-control tool. Variances from projections provide early warning of problems. And when variances occur, the plan can provide a framework for determining the financial impact and the effects of various corrective actions.

Third, the plan can anticipate problems. If rapid growth creates a cash shortage due to investment in receivables and inventory, the forecast should show this. If next year's projections depend on certain milestones this year, the assumptions should spell this out.

Marketing and business developments

Many organization does not have a specialized marketing department/individuals which ultimately result in low business activity, marketing is a must part of any business, but many companies and top management thinks it’s as overhead rather growth.

Analysis and Estimations:

Everything which is done in any organization must be billable to make an organization growing. Usually organization does not consider estimated properly, a low estimated or wrong estimated project always ends up in variance, either in time or defiantly in budget. This is what happening we are not estimating properly or we are not capable enough to sell it. Estimations depend on analysis which means we are lacking in analysis of every project.

Client Perception Management:

Client perception management is a key to success in business. no comments because people already know what’s wrong with it.

Wednesday, July 13, 2011

SharePoint 2010 dispform.aspx now showing values

recently imported many lists from a SharePoint 2007 to SharePoint 2010 instance, apparently things seems to be working fine however when click view or edit it does not comes up with values.  after some research I found that there is a checkbox in list properties when you open it in SPD 2010 with text “Display new folder command on new menu” when I unchecked this option things starting working as expected. writing it here some it may be helpful to others.

Thursday, May 26, 2011

CRM 2011 email Router load Data Error

I've been over and over the steps outlined in the CRM 2011 Email Router Installation Guide and cannot identify the reason the email router configuration is failing on "Users, Queues and Forward Mailboxes"/Load Data."

Error: Cannot retrieve user and queue information from CRM Server. May indicate ... server is busy. Verify URL is correct.... this problem can occur if specified login credentials are insufficient...

We have a CRM 2011 deployment which is accessible and working through browser http://crm2k11.OrganizationName.com. It is authenticating against a Win2003 Active Directory.
We have also installed crm 2011 email router on the same machine.The problem is that when we try to load the user data and queue we are getting the attached error.
Can you please inform us of the points we can check in order to get this working.

these were issues so we open a support incident for this situation and here what we did to resolve the issue.

  1. We reviewed the trace information that was captured and checked both your and an administrator user.
  2. We attempted to access the organization.svc page within Internet Explorer.  We were able to see that it was looking for a physical pathing of D:\Program Files\Microsoft Dynamics CRM\CRMWeb\XRMServcies\2011\Organization.svc.
  3. We discussed that you had previously installed CRM on the D:\ on this machine but were getting issues with that so had uninstalled and then installed on the C:\.
  4. We then created a new organization and were able to both access the organization as well as the Organization.svc page.
  5. We then attempted to remove and reimport the organization and that did not work.
  6. We did a search through the registry for references to the organization service and found several in the HkeyCU\Software\Microsoft\Windows\CurrentVersion\Explorer\RunMRU that were pointing to D:\Program Files\Microsoft Dynamics CRM instead of C:\Program Files\Microsoft Dynamics CRM.  We corrected these references but were still unable to access the Organization.svc page.
  7. We then removed the organization and modified the name on it.  With the new organization name we were able to access the Organization.svc page.
  8. When attempting to load data we were then seeing the message below.
  9. The decryption key could not be obtained because HTTPS protocol is enforced but not enabled.  Enable HTTPS protocol and try again.
  10. We were able to get past that message by using the steps below.
      1. If the SSL is not in use, a new regkey has to be added:
        1.  Click Start , click Run , type regedit , and then click OK .
        2.  Locate and then click the following registry key:
        HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\MSCRM
        3.  On the Edit menu, click New , and then click DWORD Value .
        4.  Set the name of the subkey to DisableSecureDecryptionKey .
        5.  Right-click DisableSecureDecryptionKey , and then click Modify .
        6.  In the Value data box, type 1 in the Value data field, and then click OK .
        7.  On the File menu, click Exit.
        10) We then got a message saying that the user needed to be PrivUserGroup.
        11) We added your user to the PrivUserGroup and were able to get the load data to complete.
        12) We then discussed the setup of the forward mailbox that you are using in your current production environment.
        13) We also discussed setting up IFD for CRM 2011.  I have the document on the setup linked below for you.  Any questions on that would need to be in a new case.
        http://www.microsoft.com/downloads/en/details.aspx?FamilyID=9886ab96-3571-420f-83ad-246899482fb4
        14) We discussed that you were going to do a switch over from your production to this environment in the near future.
        You will want to make sure you check all of the items below for the scenario we discussed.
        1) You will want to make sure that you are importing the database instead of just restoring over the top of the organization.  This is for several reasons, the biggest being the name change that we put into place.
        2) You will want to be sure that when you switch the binding on the website to utilize the host header that it is changed in the following locations:
        Deployment Manager – Right click on Microsoft Dynamics CRM and select Properties and the web address tab.
        IIS
        E-mail router – This will need to be done after the Deployment Manger modification.
        If you do run into issues with the organization during the migration of your production and the binding changes you will need to open a new case as that would be outside of the scope of this case which was to get the Router Configuration Manager to load user and queue data.
      2. one last thing make sure that you have approved email from setting
      3. As we are running CRM 2011 as dogfood, I found an interesting new feature of CRM 2011. When adding a new user, you have to approve their email for it to work properly, for instance in Outlook where you otherwise will get an error saying that the sending user does not have an email address.
        So, if you get this error, just add an email address and press the "Approve Email" button in the ribbon.

Approve Email link Source

at last there was dash(-) in our organization Name which we removed now everything is working perfectly.

What's new SharePoint Server 2010

it’s a presentation for Microsoft I am not sure if it is right to publish it or not but I couldn’t find any.

Slide1

Slide2

Slide3

Slide4

Slide5

Slide6

Slide7

Slide8

Slide9

Slide10

Slide11

Slide12

Slide13

Slide14

Slide15

Slide16

Slide17

Slide18

Slide19

Slide20

Slide21

Slide22

Slide23

Slide24

Slide25

Slide26

Slide27

Slide28

Slide29

Slide30

Slide31

Slide32

Slide33

Slide34

Enable Tracing in CRM 2011

Register the cmdlets

  1. Log into the administrator account on your Microsoft Dynamics CRM server.
  2. In a Windows PowerShell window, type the following command:

    Add-PSSnapin Microsoft.Crm.PowerShell



This command adds the Microsoft Dynamics CRM Windows PowerShell snap-in to the current session. The snap-in is registered during installation and setup of the Microsoft Dynamics CRM server.


Get a list of the current settings. Type the following command:



Get-CrmSetting TraceSettings


The output will resemble the following:

CallStack : True



Categories    : *:Error



Directory     : c:\crmdrop\logs



Enabled       : False



FileSize      : 10



ExtensionData : System.Runtime.Serialization.ExtensionDataObject






Set the Trace Settings





  1. Type the following command:



    $setting = Get-CrmSetting TraceSettings



  2. Type the following command to enable tracing:



    $setting.Enabled="True"



  3. Type the following command to set the trace settings:



    Set-CrmSetting $setting



  4. Type the following command to get a current list of the trace settings:



    Get-CrmSetting TraceSettings




The output will resemble the following:

CallStack : True



Categories    : *:Error



Directory     : c:\crmdrop\logs



Enabled       : True



FileSize      : 10



ExtensionData : System.Runtime.Serialization.ExtensionDataObject



make sure you have created the directory CRM server will not bother itself to create a directory for you rather it will throw internal exception in deployment manager.



 





 

Wednesday, May 25, 2011

CRM 2011 CRMservice.asmx 401 unauthorized

recently updated from 4.0 to 2011 found a link stating that don’t have to write whole chunk of code rather I can use this url for backward compatibility.

http://msdn.microsoft.com/en-us/library/gg334316.aspx

so become more than happy however code was not working as required and throwing 401 upon creating lead and cases. so I had to to following things

 

1) I had to remove existing web reference and had to update it with

http://<servername[:port]>/mscrmservices/2007/crmservice.asmx?WSDL&uniquename=organizationName


details here


http://msdn.microsoft.com/en-us/library/cc151015.aspx


then I had to add this code segment on 


CrmAuthenticationToken token = new CrmAuthenticationToken();



token.OrganizationName = "OrganizationName";



_crmService = new CrmService();



_crmService.Credentials = System.Net.CredentialCache.DefaultCredentials;



_crmService.CrmAuthenticationTokenValue = token;



_crmService.PreAuthenticate = true;



_crmService.Credentials = new System.Net.NetworkCredential(testdomainlogin", "testdomainpassword", "EA");



 



source http://social.microsoft.com/Forums/en/crmdevelopment/thread/fd97215a-454f-4875-b7c9-9b2fbefa0f10



and eureka its working man.. took my 3 hours

Thursday, April 28, 2011

CRM 2011 – Sample data

CRM 2011 makes importing the sample data quick and easy.  Importing the Sample Data isn’t difficult but it is frustrating when you are not sure where to look

You log in with Administrator rights

go to

Settings

Systems/Data Management

Sample Data

it then asks if you want to install it, press Install Sample Data button.

now you can look around CRM, the dashboards have sprung into life and your organization has enough data for you to do some customer demo’s or practice development.

The feature provides the following sample data:

Entity
Records

Accounts
14

Campaigns
8

Cases
14

Contacts
14

Leads
10

Opportunities
15

Phone Calls
10

Subjects
2

Tasks
14

Goals
4

Sources

http://www.avanadeblog.com/xrm/2010/09/crm-2011-feature-of-the-week-9202010-sample-data.html

and

http://crmbusiness.wordpress.com/2011/02/03/crm-2011-how-to-quickly-add-sample-data/

Monday, April 25, 2011

Sharepoint 2010 and CRM 2011 Out of the Box Integration

CRM can be integrated with SharePoint easily with this new tool called as CRM list component. Once that is done CRM can be configured using the Setting menu to enable the entities for the sharpening collaboration. In addition one needs to specify the Url for the site that is configured for integration (where the component was installed). Once this is done the integration is complete and on addition of documents in CRM a new library is created in SharePoint. Existing libraries can also be added to the entities. Each entity with documents would have a library association with the address in format “siteaddress/Acocunts/Account Name/Entity Name/ account/”. This is pretty much it as far as this integration is concerned. Integration is pretty neat however there are a few minor glitches that are still there so it’s better to do demo on the machine where both are installed. For demo I have done this part however another type of integration can be done where CRM data can be shown in SharePoint home page which requires some additional coding and development.

clip_image001

clip_image002

clip_image003

clip_image004

http://raotayyabali.wordpress.com/2010/11/09/crm-2011-integration-with-sharepoint-foundation-2010/

Wednesday, March 16, 2011

Database development considerations

Many of us intentionally or unintentionally do not plan application Background for high availability website or application. This create frustration at both end, I mean it exhausts developers that they are unable to develop a robust application on the same token it frustrates the client who is not getting optimum performance from the application. Purpose of following note is to create a check list that should be complied before delivering any product for quality assurances. I coloring the points, red mean critical, blue means important and green means supportive.

1. Do plan database for its purpose, if it is for online transaction processing it should be normalized and should not violate normalization rules. No matter how much it boosts the database processing. Please consider following notes for OLTP databases.

i. Create multiple file groups for multiple set of tables like a file group for indexes, file group for lookup items and a file group for transaction. It’s better to create multiple groups to optimize disk IO.

ii. Make sure that your transactions are precise and they are short enough to avoid deadlocks. These transactions should be developed in a way that single stored procedure is handling a complete set of insertion or update.

iii. Database backups should be configured at minimum usage hours, although SQL server supports transactions while taking backups however the client responses become slower during backup.

iv. Make sure that you are using table partitioning if there is a large amount of data, because a huge table size has a worse impact on tables’ insertions and updates.

v. When trying to develop OLTP part of any application make sure that you are using minimum number of indexes, it has a negative impact on performance.

vi. Optimum hardware configuration to handle the large numbers of concurrent users and quick response times required by an OLTP system.

vii. Try to configure server to support max degree of parallelism, by default this attribute is disabled and SQL server does not perform parallelism for queries, so server performance can be enhanced by enabling this feature.

viii. increase the 'min memory per query' option to improve the performance of queries that use hashing or sorting operations, if your SQL Server has a lot of memory available and there are many queries running concurrently on the server.

ix. You can increase the 'max async IO' option if your SQL Server works on a high performance server with high-speed intelligent disk subsystem.

x. With usage of table indexes become really slow, it’s better to run dbcc dbreindex with a proper fill factor regularly to optimize performance.

xi. You are using database with full recover option and mirroring is configure then it’s better to increase the recovery interval. This will have a positive impact on database performance.

xii. If database requires a lot number concurrent request try to increase max number of work thread and you can also use the priority boost to 1. Make sure to increase priority only if the server is dedicated for SQL server operations otherwise it will have negative impact on application due to sql server priority.

xiii. Too many table joins for frequent queries. Overuse of joins in an OLTP application results in longer running queries & wasted system resources. Generally, frequent operations requiring 5 or more table joins should be avoided by redesigning the database.

xiv. Too many indexes on frequently updated (inclusive of inserts, updates and deletes) tables incur extra index maintenance overhead. Generally, OLTP database designs should keep the number of indexes to a functional minimum, again due to the high volumes of similar transactions combined with the cost of index maintenance.

xv. Big IOs such as table and range scans due to missing indexes. By definition, OLTP transactions should not require big IOs and should be examined.

xvi. Unused indexes incur the cost of index maintenance for inserts, updates, and deletes without benefiting any users. Unused indexes should be eliminated. Any index that has been used (by select, update or delete operations) will appear in sys.dm_db_index_usage_stats. Thus, any defined index not included in this DMV has not been used since the last re-start of SQL Server.

xvii. Signal waits > 25% of total waits. See sys.dm_os_wait_stats for Signal waits and Total waits. Signal waits measure the time spent in the runnable queue waiting for CPU. High signal waits indicate a CPU bottleneck.

xviii. Plan re-use < 90% . A query plan is used to execute a query. Plan re-use is desirable for OLTP workloads because re-creating the same plan (for similar or identical transactions) is a waste of CPU resources. Compare SQL Server SQL Statistics: batch requests/sec to SQL compilations/sec. Compute plan re-use as follows: Plan re-use = (Batch requests - SQL compilations) / Batch requests. Special exception to the plan re-use rule: Zero cost plans will not be cached (not re-used) in SQL 2005 SP2. Applications that use zero cost plans will have a lower plan re-use but this is not a performance issue.

xix. Parallel wait type cxpacket > 10% of total waits. Parallelism sacrifices CPU resources for speed of execution. Given the high volumes of OLTP, parallel queries usually reduce OLTP throughput and should be avoided. See sys.dm_os_wait_stats for wait statistics.

xx. Consistently low average page life expectancy. See Average Page Life Expectancy Counter which is in the Perfmon object SQL Server Buffer Manager (this represents is the average number of seconds a page stays in cache). For OLTP, an average page life expectancy of 300 is 5 minutes. Anything less could indicate memory pressure, missing indexes, or a cache flush.

xxi. Sudden big drop in page life expectancy. OLTP applications (e.g. small transactions) should have a steady (or slowly increasing) page life expectancy. See Perfmon object SQL Server Buffer Manager. Small OLTP transactions should not require a large memory grant.

xxii. Sudden drops or consistenty low SQL Cache hit ratio. OLTP applications (e.g. small transactions) should have a high cache hit ratio. Since OLTP transactions are small, there should not be, big drops in SQL Cache hit rates or consistently low cache hit rates < 90%. Drops or low cache hit may indicate memory pressure or missing indexes.

xxiii. Normally it takes 4-8ms to complete a read when there is no IO pressure. When the IO subsystem is under pressure due to high IO requests, the average time to complete a read increases, showing the effect of disk queues. Periodic higher values for disk seconds/read may be acceptable for many applications. For high performance OLTP applications, sophisticated SAN subsystems provide greater IO scalability and resiliency in handling spikes of IO activity. Sustained high values for disk seconds/read (>15ms) does indicate a disk bottleneck.

xxiv. High average disk seconds per write. The throughput for high volume OLTP applications is dependent on fast sequential transaction log writes. A transaction log write can be as fast as 1ms (or less) for high performance SAN environments. For many applications, a periodic spike in average disk seconds per write is acceptable considering the high cost of sophisticated SAN subsystems. However, sustained high values for average disk seconds/write is a reliable indicator of a disk bottleneck.

xxv. Big IOs such as table and range scans due to missing indexes.

xxvi. Index contention. Look for lock and latch waits in sys.dm_db_index_operational_stats. Compare with lock and latch requests.

xxvii. High average row lock or latch waits. The average row lock or latch waits are computed by dividing lock and latch wait milliseconds (ms) by lock and latch waits. The average lock wait ms computed from sys.dm_db_index_operational_stats represents the average time for each block.

xxviii. Block process report shows long blocks. See sp_configure “blocked process threshold” and Profiler “Blocked process Report” under the Errors and Warnings event.

xxix. High number of deadlocks. See Profiler “Graphical Deadlock” under Locks event to identify the statements involved in the deadlock.

xxx. High network latency coupled with an application that incurs many round trips to the database.

xxxi. Network bandwidth is used up. See counters packets/sec and current bandwidth counters in the network interface object of Performance Monitor. For TCP/IP frames actual bandwidth is computed as packets/sec * 1500 * 8 /1000000 Mbps.

a. Excessive fragmentation is problematic for big IO operations. The Dynamic Management table valued function sys.dm_db_index_physical_stats returns the fragmentation percentage in the column avg_fragmentation_in_percent. Fragmentation should not exceed 25%. Reducing index fragmentation can benefit big range scans, common in data warehouse and Reporting scenarios

2. If you are developing a database for decision support system or for analytical processing please follow following general rules and guidelines.

a. Better to develop data marts based on database trend analysis requirements.

b. Merge non key attributes with key attribute using views and tables for optimum retrieval.

c. Use of a star or snowflake schema to organize the data within the database.

d. Estimate the sizes of clustered and non-clustered indexes.

3. Now i am trying to list down general guidelines for database optimization.

a. If database size is less than 200mb then it’s better to use file growth in megabytes. However if it increase better to define in percentages.

b. Do not insert heavy object in the database if they are not required in transactions because they increase database size and it really hurts the performance.

c. If you have really a lengthy operation in the stored procedure better to use SQL query short circuiting, this enhance the query performance by avoiding unnecessary joins and where clauses.

d. Must use where clause to otherwise it will slow down the performance. Even if there is an option that say search all do not fetch all rows from database.

e. Try to implement paging in stored procedure level for large amount of data; if this is to be done on front end it will cause timeout operations.

f. Do not use char, varchar fields’ for comparison operations and joins, it better to use integers always. Use isnull function for parameters to avoid unwanted comparisons in the database.

g. Always prefer to mention fields names rather than * operations, because wildcards are negative for performances.

h. Use views and stored procedure instead of heavy queries. Do not use cursors, try to avoid count (*).

i. Since triggers are heavy for operations better to use constraints, this helps to validate data prior to insert.

j. It is preferred to use table variables rather than temp tables but it better to check either you are in a transaction or not and if this transaction is handle by MSDTC. You may face invalid data operations with usage of variables because they not terminated properly.

k. Do not use having or distinct in your queries because require reprocessing of result set.

l. Prefer to use locking hints with queries, as in a previous document I mentioned to use nolock or rowlock or updlock.

m. Use select statements with the TOP keyword or the SET ROWCOUNT statement if you need to return only the first n rows. OR Use the FAST number_rows table hint if you need to quickly return 'number_rows' rows.

n. Prefer to use union all instead of union in queries.

o. Do not guide SQL for query optimization hints if you are now sure about them, better to leave this part with SQL server to decide.

p. Don’t use top 100 percent with in your sql statements this switch guides the sql server to fetch a count of 100 rows based on the data sampling. This clause have really negative effect on the query.

q. Try to use latest feature of SQL server cross apply rather using cursors.