tag:blogger.com,1999:blog-62145874506445320512024-03-14T06:13:11.577+01:00AX 2009 Technical JournalThis blog is all about technical subjects related to Microsoft Dynamics AX. By sharing some of my experiences and opinions, my ambition is to contribute to the AX community.Hans-Petter Lundhttp://www.blogger.com/profile/02781240948020780728noreply@blogger.comBlogger43125tag:blogger.com,1999:blog-6214587450644532051.post-21090219740699127332014-06-26T12:19:00.000+02:002014-06-26T12:21:12.850+02:00AX 2009 SP1, Parameter Sniffing finally addressed by MicrosoftMost of you have probably struggeled with Parameter Sniffing issues in AX solutions and it finally seems like Microsoft has been able to address this design issue also for AX 2009 SP1! The fix introduced in AX 2012 R2 CU6 has been backported to AX 2012 R0/R1 and now also AX 2009 SP1.Please see <a href="http://ax2012tech.blogspot.se/2014/04/ax-2012-r2-cu6-feature-to-reduce-effect.html" target="_blank">AX 2012 R2 CU6, Feature to reduce the effect of Parameter Sniffing</a>.<br />
<br />
Please have a look at <a href="http://blogs.msdn.com/b/axinthefield/archive/2014/01/09/sql-server-parameter-sniffing-with-dynamics-ax-just-plain-evil.aspx?PageIndex=2&wa=wsignin1.0#comments" target="_blank">SQL Server Parameter Sniffing with Dynamics AX, just plain evil. (Redux 5-19-2014)</a> and note that kernel builds after 5.0.1600.2553 (KB2934938) will include a fix that changes the way SQL statements are generated from the AOS by always sending the value for the column DATAAREAID as a literal instead of a parameter (the x-factor).<br />
<br />
<i>Also please not</i>e that the instructions for updating the value in the table SQLSYSTEMVARIABLES <u>are wrong</u> - the value for the column PARM in the row added to SQLSYSTEMVARIABLES as part of implementing this kernel build, is <b>DATAAREALITERAL</b> (NOT DATAAREA<u>ID</u>LITERAL).<br />
<br />
The correct SQL Update Statement to enable literals for DATAAREAID is<br />
<br />
<span style="font-family: arial, helvetica, sans-serif; font-size: x-small;">UPDATE SQLSYSTEMVARIABLES SET VALUE = '1' WHERE PARM = 'DATAAREALITERAL'</span><br />
<br />
<div class="separator" style="clear: both; text-align: center;">
<a href="http://2.bp.blogspot.com/-5q_5U5wNYfU/U6vzc9H4nHI/AAAAAAAAAIo/y0pIVlrAOU8/s1600/2.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="http://2.bp.blogspot.com/-5q_5U5wNYfU/U6vzc9H4nHI/AAAAAAAAAIo/y0pIVlrAOU8/s1600/2.jpg" height="94" width="320" /></a></div>
<br />
<br />
It took me a couple of minutes to realize this when first enabling the DATAAREALITERAL in an AX 2009 SP1 solution for the first time, but a quick SELECT aginst SQLSYSTEMVARIABLES, returned a row containing the value DATAAREALITERAL.<br />
<br />
<div class="separator" style="clear: both; text-align: center;">
<a href="http://2.bp.blogspot.com/-UrAnwcL6F7w/U6vzXWY9KrI/AAAAAAAAAIg/uMHNi24RBY4/s1600/1.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="http://2.bp.blogspot.com/-UrAnwcL6F7w/U6vzXWY9KrI/AAAAAAAAAIg/uMHNi24RBY4/s1600/1.jpg" height="182" width="320" /></a></div>
<br />
<br />
This fix should be evaluated and implemented in every AX 2009 SP1 solution having one company contributing to most rows in shared tables to avoid "Plain Evil", frustration and ad hoc work.<br />
<br />
Verification:<br />
<br />
Actual value for DATAAREAID is replaced by 'xxx'.<br />
<br />
<div class="MsoNormal">
<span lang="EN-GB" style="color: blue; font-family: "Courier New"; font-size: 10.0pt; mso-ansi-language: EN-GB;">SELECT</span><span lang="EN-GB" style="font-family: "Courier New"; font-size: 10.0pt; mso-ansi-language: EN-GB;"> <span style="color: magenta;">SUM</span><span style="color: grey;">(</span>A<span style="color: grey;">.</span>QTY<span style="color: grey;">)</span> <span style="color: blue;">FROM</span> PROJINVOICEITEM A<span style="color: grey;">,</span>PROJITEMTRANS
B <span style="color: blue;">WHERE </span><span style="color: grey;">(</span><span style="background: yellow; mso-highlight: yellow;">A<span style="color: grey;">.</span>DATAAREAID<span style="color: grey;">=</span><span style="color: red;">N'xxx'</span></span><span style="color: grey;">)</span> <span style="color: grey;">AND</span><span style="color: blue;"> </span><span style="color: grey;">((</span><span style="background: yellow; mso-highlight: yellow;">B<span style="color: grey;">.</span>DATAAREAID<span style="color: grey;">=</span><span style="color: red;">N'xxx'</span></span><span style="color: grey;">)</span> <span style="color: grey;">AND</span><span style="color: blue;"> </span><span style="color: grey;">((</span>B<span style="color: grey;">.</span>PROJTRANSID<span style="color: grey;">=</span>A<span style="color: grey;">.</span>PROJTRANSID<span style="color: grey;">)</span> <span style="color: grey;">AND</span><span style="color: blue;"> </span><span style="color: grey;">(</span><a href="mailto:B.PROJTRANSIDREF=@P1))">B.PROJTRANSIDREF=@P1))</a><span style="color: grey;">)<o:p></o:p></span></span></div>
<div class="MsoNormal">
<br /></div>
<br />
<div class="MsoNormal">
<span lang="EN-GB" style="color: blue; font-family: "Courier New"; font-size: 10.0pt; mso-ansi-language: EN-GB;">SELECT</span><span lang="EN-GB" style="font-family: "Courier New"; font-size: 10.0pt; mso-ansi-language: EN-GB;"> A<span style="color: grey;">.</span>AGREEMENT<span style="color: grey;">,</span>A<span style="color: grey;">.</span>ITEMCODE<span style="color: grey;">,</span>A<span style="color: grey;">.</span>ACCOUNTCODE<span style="color: grey;">,</span>A<span style="color: grey;">.</span>ITEMRELATION<span style="color: grey;">,</span>A<span style="color: grey;">.</span>ACCOUNTRELATION<span style="color: grey;">,</span>A<span style="color: grey;">.</span>QUANTITYAMOUNT<span style="color: grey;">,</span>A<span style="color: grey;">.</span>FROMDATE<span style="color: grey;">,</span>A<span style="color: grey;">.</span>TODATE<span style="color: grey;">,</span>A<span style="color: grey;">.</span>AMOUNT<span style="color: grey;">,</span>A<span style="color: grey;">.</span>CURRENCY<span style="color: grey;">,</span>A<span style="color: grey;">.</span>PERCENT1<span style="color: grey;">,</span>A<span style="color: grey;">.</span>PERCENT2<span style="color: grey;">,</span>A<span style="color: grey;">.</span>DELIVERYTIME<span style="color: grey;">,</span>A<span style="color: grey;">.</span>SEARCHAGAIN<span style="color: grey;">,</span>A<span style="color: grey;">.</span>PRICEUNIT<span style="color: grey;">,</span>A<span style="color: grey;">.</span>RELATION<span style="color: grey;">,</span>A<span style="color: grey;">.</span>UNITID<span style="color: grey;">,</span>A<span style="color: grey;">.</span>MARKUP<span style="color: grey;">,</span>A<span style="color: grey;">.</span>ALLOCATEMARKUP<span style="color: grey;">,</span>A<span style="color: grey;">.</span>MODULE<span style="color: grey;">,</span>A<span style="color: grey;">.</span>INVENTDIMID<span style="color: grey;">,</span>A<span style="color: grey;">.</span>CALENDARDAYS<span style="color: grey;">,</span>A<span style="color: grey;">.</span>CIT_AGREEMENT<span style="color: grey;">,</span>A<span style="color: grey;">.</span>RECVERSION<span style="color: grey;">,</span>A<span style="color: grey;">.</span>RECID <span style="color: blue;">FROM</span> PRICEDISCTABLE A <span style="color: blue;">WHERE </span><span style="color: grey;">((</span><span style="background: yellow; mso-highlight: yellow;">DATAAREAID<span style="color: grey;">=</span><span style="color: red;">N'xxx'</span></span><span style="color: grey;">)</span> <span style="color: grey;">AND</span><span style="color: blue;"> </span><span style="color: grey;">((((((((((</span>RELATION<span style="color: grey;">=</span>@P1<span style="color: grey;">)</span> <span style="color: grey;">AND</span><span style="color: blue;"> </span><span style="color: grey;">(</span>ITEMCODE<span style="color: grey;">=</span>@P2<span style="color: grey;">))</span> <span style="color: grey;">AND</span><span style="color: blue;"> </span><span style="color: grey;">(</span>ITEMRELATION<span style="color: grey;">=</span>@P3<span style="color: grey;">))</span> <span style="color: grey;">AND</span><span style="color: blue;"> </span><span style="color: grey;">(</span>ACCOUNTCODE<span style="color: grey;">=</span>@P4<span style="color: grey;">))</span> <span style="color: grey;">AND</span><span style="color: blue;"> </span><span style="color: grey;">(</span>ACCOUNTRELATION<span style="color: grey;">=</span>@P5<span style="color: grey;">))</span> <span style="color: grey;">AND</span><span style="color: blue;"> </span><span style="color: grey;">(</span>UNITID<span style="color: grey;">=</span>@P6<span style="color: grey;">))</span> <span style="color: grey;">AND</span><span style="color: blue;"> </span><span style="color: grey;">(</span>CURRENCY<span style="color: grey;">=</span>@P7<span style="color: grey;">))</span> <span style="color: grey;">AND</span><span style="color: blue;"> </span><span style="color: grey;">(</span>INVENTDIMID<span style="color: grey;">=</span>@P8<span style="color: grey;">))</span> <span style="color: grey;">AND</span><span style="color: blue;"> </span><span style="color: grey;">((</span>@P9<span style="color: grey;">>=</span>FROMDATE<span style="color: grey;">)</span> <span style="color: grey;">OR</span><span style="color: blue;"> </span><span style="color: grey;">((</span>FROMDATE<span style="color: grey;">=</span>@P10<span style="color: grey;">))))</span> <span style="color: grey;">AND</span><span style="color: blue;"> </span><span style="color: grey;">((</span>@P11<span style="color: grey;"><=</span>TODATE<span style="color: grey;">)</span> <span style="color: grey;">OR</span><span style="color: blue;"> </span><span style="color: grey;">((</span>TODATE<span style="color: grey;">=</span>@P12<span style="color: grey;">)))))</span> <span style="color: blue;">ORDER</span> <span style="color: blue;">BY</span> A<span style="color: grey;">.</span>DATAAREAID<span style="color: grey;">,</span>A<span style="color: grey;">.</span>RELATION<span style="color: grey;">,</span>A<span style="color: grey;">.</span>ITEMCODE<span style="color: grey;">,</span>A<span style="color: grey;">.</span>ITEMRELATION<span style="color: grey;">,</span>A<span style="color: grey;">.</span>ACCOUNTCODE<span style="color: grey;">,</span>A<span style="color: grey;">.</span>ACCOUNTRELATION<span style="color: grey;">,</span>A<span style="color: grey;">.</span>CURRENCY<span style="color: grey;">,</span>A<span style="color: grey;">.</span>INVENTDIMID<span style="color: grey;">,</span>A<span style="color: grey;">.</span>UNITID<span style="color: grey;">,</span>A<span style="color: grey;">.</span>QUANTITYAMOUNT<span style="color: grey;">,</span>A<span style="color: grey;">.</span>RECID<span style="color: grey;">,</span>A<span style="color: grey;">.</span>FROMDATE<o:p></o:p></span></div>
Hans-Petter Lundhttp://www.blogger.com/profile/02781240948020780728noreply@blogger.com0tag:blogger.com,1999:blog-6214587450644532051.post-21450233070466261312011-11-03T10:08:00.006+01:002011-11-03T10:09:00.935+01:00AX 2012 Technical JournalJust a short message - future entries regarding AX 2012 will be published in a separate blog titled <a href="http://ax2012tech.blogspot.com/" target="_blank">AX 2012 Technical Journal</a>.<br />
<br />
Stay tuned for new updates.Hans-Petter Lundhttp://www.blogger.com/profile/02781240948020780728noreply@blogger.com1tag:blogger.com,1999:blog-6214587450644532051.post-89926373993356438152011-02-17T15:16:00.000+01:002011-02-17T15:16:16.918+01:00AX2009 SP1 secret statisticsI while ago (<a href="http://ax2009tech.blogspot.com/2010/09/question.html">September 2010</a>) I asked a question based on a simple graph. I thought it was time for an update leaving the question open.<br />
<br />
<div class="separator" style="clear: both; text-align: center;"><a href="http://1.bp.blogspot.com/-m9HHLz0E_YY/TV0tAmH1j7I/AAAAAAAAAD8/g6rt2NyDOIw/s1600/AX2009sp1fixes_feb2011.JPG" imageanchor="1" style="clear: left; cssfloat: left; float: left; margin-bottom: 1em; margin-right: 1em;"><img border="0" height="170" j6="true" src="http://1.bp.blogspot.com/-m9HHLz0E_YY/TV0tAmH1j7I/AAAAAAAAAD8/g6rt2NyDOIw/s320/AX2009sp1fixes_feb2011.JPG" width="320" /></a></div>Hans-Petter Lundhttp://www.blogger.com/profile/02781240948020780728noreply@blogger.com2tag:blogger.com,1999:blog-6214587450644532051.post-79092739158907433402011-02-09T10:56:00.000+01:002011-02-09T10:56:11.952+01:00Looking forward (read: AX 2012)Back in November 2008 I blogged about AX 2009 after attending the Convergence conference in Copenhagen and I was pretty excited about the possibilities. After working with AX 2009 since it was released in 2008, I'm still excited but also more realistic about several aspects of implementing and operating AX. After gaining hands on experience, you discover all the rough edges and you get a feel for the quality of the software with regards to things not woring as expected for instance measured as the number of hotfixes released. All in all it seems like AX 2009 has succeeded in the market.<br />
<br />
So whats next? AX 2012 was officially published as the name of the next version of AX (aka AX 6) at the Microsoft Dynamics Technical Conference taking place in Redmund in January. I wasn't able to participate, but based on the information published after the conference, it certainly seems like a huge (giant?) shift both with regards to added and extended functionalty, and technical with some architectural changes as well (like the possibility to replace the classic AOD files in the file system with storage in the database). <br />
<br />
The <a href="http://axaptasource.com/2011/01/whats-new-in-dynamics-ax-2012-a-brief-extract-from-the-recently-held-tech-conf/">post</a> by Jake at AxaptaSource gives a good summary of what was presented at the conference and it should be pretty clear to everyone that we are talking about the biggest shift in the history of AX and a shift that will have an impact on everyone involved in the value chain. This is of cource in the category of un official information, but still quite trustworthy as far as I can understand. <br />
<br />
<strong>Modelling</strong> is one example that will influence developers and people involved in deploying changes. Much tighter integration to <strong>Visual Studio</strong> is another. The <strong>security system</strong> is re designed with roles becoming a real part of the security system (a role in AX 2009 is the same as the Role Center assigned to a user at least within AX) and the requirement of defining a user in Active Directory, seems not to be a requirement anymore (replaced by Claims based security in SharePoint for non AD users). <strong>Setup</strong> is made easier and system management is prioritzed with a new add in for <strong>System Center Operation Manager</strong>. The <strong>BizTalk</strong> adapter is gone and replaced by the WCF adapter (Web Services). The (data) <strong>caching</strong> machanisms are re designed (much needed in my mind). <strong>Include columns</strong> are finally supported for SQL Server 2008 togheter with support for<strong> full text indexes</strong>. Huge performance improvements mainly in the area of <strong>CIL execution</strong> (<a href="http://en.wikipedia.org/wiki/Common_Intermediate_Language">Common Intermediate Language</a>). Drag and drop transformation of <strong>forms</strong> to web pages in Enterprise Portal (indicates big changes in the area of forms in general). <strong>Workflow</strong> executing as part of the AOS service and shared <strong>workflow editor</strong> (designer) withVisual Studio 2010. <strong>Management</strong> through PowerShell. <strong>AIF</strong> service contracts have changed (possibly influencing the upgrade effort) and less complexity (hey, that sounds like a step in the right direction). Very thigh integration to <strong>Excel</strong> supporting data entry and synchronization from Excel (big time mental change for a lot of people I think). Big improvements in the area of <strong>debugging</strong> and <strong>batch</strong> execution in addition to AOS beeing able to host WCF processes (a real enabler).<br />
<br />
Add a module for Public Sector (be aware Agresso and Visma :-)) and 1200 new features in addition to some major rewrites (rumors), and you probably start to see the big picture. I think the AX Community must start preparing for AX 2012 on the mental level since this release will require a shift in most of the ways we have been used to treat new releases of AX.Hans-Petter Lundhttp://www.blogger.com/profile/02781240948020780728noreply@blogger.com0tag:blogger.com,1999:blog-6214587450644532051.post-81666494789440872572011-02-01T14:58:00.001+01:002011-02-02T07:59:26.832+01:00Virtualization of AOS - VMWare versus Hyper-VA very interesting <a href="https://community.dynamics.com/product/ax/f/33/p/47756/88055.aspx">thread</a> on the Dynamics AX Community forum regarding virtualization of AOS.<br />
<br />
As stated, the only important information missing right now, is a description of the differences in the underlying infrastructure between the VMWare and Hyper-V implementations.<br />
<br />
<em><u>Update:</u></em><br />
Te original poster has published information regarding the infrastructure and this information only increases the value of this subject - he has managed to test virtualization of the AOS role under VMWare and Hyper-V on the same (identical) infrastructure! This makes his findings extremely interesting (at least to me) partly because it leaves room for possible reasons/explanations/theories and maybe the biggest paradox - if his findings are true in general, a lot of customers running AOS under VMWare are possibly influenced by decreased performance caused by differences in how the AOS behaves on VMWare. Since most customers most likely are using VMWare, the scope of this subject with regards to the number of customers possibly affected, makes it one of the most interesting subjects in a long time.<br />
<br />
It could of course be tightly coupled to the OS and how the OS performs under the two hypervisors (as mentioned as a possible reason in the thread) and I will be light on this until some more research has been done.<br />
<br />
Comments are welcome as usual.Hans-Petter Lundhttp://www.blogger.com/profile/02781240948020780728noreply@blogger.com0tag:blogger.com,1999:blog-6214587450644532051.post-78423034054696519012011-01-28T18:20:00.000+01:002011-01-28T18:20:36.925+01:00AX 2009 and edition of SQL Server Analysis ServicesI recently came across an issue when trying to build a SSAS project containing modifications to the standard AX Cubes.<br />
<br />
When building or rebuilding the project, I got 1 047 (!) errors with the description "<em>Dimension [x] : Only dimension attributes and attribute relationships can have translations in Standard Edition</em>."<br />
<br />
The only solution to this is to (try to) modify the SSAS database in SQL Server Management Studio by some heavy scripting. Or of course upgrade SSAS to Enterprise Edition which I really don't know is legal without licensing Enterprise Edition (I'm trying to clarify this). Anyway it's a valid upgrade path regarding to the information given by Microsoft for SQL Server 2008 R2 (<a href="http://msdn.microsoft.com/en-us/library/ms143393.aspx">Version and Edition Upgrades</a>) on MSDN.<br />
<br />
The <a href="http://www.microsoft.com/en-us/dynamics/using/ax-system-requirements-2009.aspx">system requirements</a> for AX 2009 doesn't contain any information saying SSAS Enterprise Edition is needed and neither does the general SQL Server reqiurements.Until further noticed and official information is given from Microsoft, it's worth having this in mind when deciding which edition of SQL Server to use together with AX 2009.<br />
<br />
The only information from Microsoft I have found on this issue, is in a draft document titled "How to add financial dimension to Dynamics AX default cubes" (<a href="http://blogs.msdn.com/cfs-file.ashx/__key/CommunityServer-Components-PostAttachments/00-10-11-52-14/How-to-add-Financial-Dimensions-to-Default-cubes_5F00_v1.1.pdf">PDF</a>) from the <a href="http://blogs.msdn.com/b/emeadaxsupport/archive/2011/01/13/how-to-add-financial-dimension-to-dynamics-ax-default-cubes.aspx">EMEA Dynamics Support blog on MSDN</a>. On the bottom of page 3 and the beginning of page 4, the following information is given:<br />
<br />
<div class="separator" style="clear: both; text-align: center;"><a href="http://2.bp.blogspot.com/_LvOWIBLIb0Q/TUL4QSa-kdI/AAAAAAAAAD0/U2QF0XYFdws/s1600/ax2009ssas.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="72" s5="true" src="http://2.bp.blogspot.com/_LvOWIBLIb0Q/TUL4QSa-kdI/AAAAAAAAAD0/U2QF0XYFdws/s400/ax2009ssas.jpg" width="400" /></a></div>This is the only information from Microsoft I have found and despite this beeing a draft document, it clearly states that the system requirements should be updated alternatively that another soultion is provided. From this I understand that you have to backup the OLAP database and restore it to an instance of SQL Server 200x Developer Edition (equals Enterprise Edition in functionality), create a project in BIDS, build and deploy the changes to Developer Edition, and finish doing a final backup - restore sequence back to the production instance of SSAS.<br />
<br />
In general, I think most customers will end up designing their own cubes and modifying the needed Role Centers accordingly, to avoid all the struggle with the default cubes.Hans-Petter Lundhttp://www.blogger.com/profile/02781240948020780728noreply@blogger.com0tag:blogger.com,1999:blog-6214587450644532051.post-41761200394494201002011-01-18T09:48:00.000+01:002011-01-18T09:48:38.438+01:00Experience doing an AX 2009 Complete InstallA short update on my experience from doing a complete install of AX 2009 with dedicated servers for each server role.<br />
<br />
First of all, the process went quite well and the only struggle was to get all the Service Principal Names (SPNs) correct including named instances and the SQL Server Browser service on the SSAS server. <br />
<br />
Main take aways:<br />
<ul><li>Spend time on planning and account for some issues related to Kerberos authentication (hard to estimate)</li>
<li>Follow the latest version of the AX Installation Guide</li>
<li>Make sure you deploy the latest Cumulative Rollup package for AX (and other services)</li>
<li>Bookmark the AX EMEA Support Team Blog (very valuable source of information)</li>
<li>Make sure each component work as expected before you proceed the install and configuration sequence</li>
</ul>After installing SharePoint 2010 for the first time, I also have a suggestion for Microsoft regarding AX setup - please have a look at the SharePoint 2010 Products Preparation Tool (shown below) and incorporate this idea into the next release of AX.<br />
<br />
<div class="separator" style="clear: both; text-align: center;"><a href="http://3.bp.blogspot.com/_LvOWIBLIb0Q/TTVTDbu4z9I/AAAAAAAAADw/mftoP3yvfv8/s1600/SP2010PPT.JPG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="298" n4="true" src="http://3.bp.blogspot.com/_LvOWIBLIb0Q/TTVTDbu4z9I/AAAAAAAAADw/mftoP3yvfv8/s400/SP2010PPT.JPG" width="400" /></a></div>Hans-Petter Lundhttp://www.blogger.com/profile/02781240948020780728noreply@blogger.com4tag:blogger.com,1999:blog-6214587450644532051.post-87920023148700042672010-12-22T15:52:00.001+01:002010-12-22T15:52:34.424+01:00AX 2009 Rollup 6 and KB 2278963 (SharePoint 2010)Finally I'm doing a complete install of Dynamics AX 2009 on a new plattform for a customer! While performing the installation of the core solution, my verified plan (verified by Microsoft) was to install in this sequence:<br />
<ol><li>AX 2009 RTM patched with binaries from the KB</li>
<li>AX 2009 SP1</li>
<li>AX 2009 SP1 RU6</li>
<li>Initialize</li>
<li>Apply application fix for the KB</li>
</ol>Everything went according to plan until step 5. This step failed with the following message:<br />
<blockquote>This update is not applicable to your installation of Microsoft Dynamics AX because wrong version of application files is installed. This update is applicable to version 5.0.1000.52-5.0.1500.3560 of application files. <br />
<br />
Setup could not complete the installation.</blockquote>After checking my sources and discussing with Microsoft without any progress, I decided to install a second application in this sequence:<br />
<ol><li>AX 2009 RTM</li>
<li>AX 2009 SP1</li>
<li>Initialize</li>
<li>KB 2278963</li>
<li>AX 2009 SP1 RU6</li>
</ol>This time everything went according to plan and based on my experience, one of the following are true for this issue:<br />
<br />
<ul><li>KB2278963 application hotfix is forgotten with regards to RU6</li>
</ul><br />
or<br />
<ul><li>KB2278963 is included but not documented as part of RU6 (or RU5)</li>
</ul><br />
or<br />
<br />
<ul><li>Wrong version is used when the axupdate process verifies the application version (max is 5.0.1500.3760 - RU6 gives 3761)</li>
</ul>The worst thing is that I had to spend extra time and effort doing a new install and 2 compilations in addition to installing a separate AOS and a Client to work on the same versionlevel.Hans-Petter Lundhttp://www.blogger.com/profile/02781240948020780728noreply@blogger.com2tag:blogger.com,1999:blog-6214587450644532051.post-58476095271028554682010-10-29T12:01:00.001+02:002010-10-29T12:02:03.655+02:00AX 2009 64-bit AOS instance memory usageI have seen some people asking if the 64-bit "edition" of the AOS kernel is capable of utilizing memory above 2 Gb (search microsoft.public.axapta which by the way is or is going to be retired). The snapshot below is taken from a customer site.<br />
<br />
<div class="separator" style="clear: both; text-align: center;"><a href="http://2.bp.blogspot.com/_LvOWIBLIb0Q/TMqalRppplI/AAAAAAAAADo/TNDKqyY0rjo/s1600/AOSmemusage.png" imageanchor="1" style="clear: left; cssfloat: left; float: left; margin-bottom: 1em; margin-right: 1em;"><img border="0" height="71" nx="true" src="http://2.bp.blogspot.com/_LvOWIBLIb0Q/TMqalRppplI/AAAAAAAAADo/TNDKqyY0rjo/s400/AOSmemusage.png" width="400" /></a></div>Working Set equal to 2 Gb and Peak Working Set equal to 4,1 Gb - say no more.Hans-Petter Lundhttp://www.blogger.com/profile/02781240948020780728noreply@blogger.com0tag:blogger.com,1999:blog-6214587450644532051.post-22496998358267006772010-09-21T14:53:00.000+02:002010-09-21T14:53:38.042+02:00QuestionA little challenge to my readers:<br />
<br />
Can You tell me what I'm trying to illustrate in the graph below?<br />
<br />
<br />
<div class="separator" style="clear: both; text-align: center;"><a href="http://3.bp.blogspot.com/_LvOWIBLIb0Q/TJipiHDcq7I/AAAAAAAAADg/OdoBikYeNWg/s1600/Capturex.JPG" imageanchor="1" style="clear: left; cssfloat: left; float: left; margin-bottom: 1em; margin-right: 1em;"><img border="0" height="211" qx="true" src="http://3.bp.blogspot.com/_LvOWIBLIb0Q/TJipiHDcq7I/AAAAAAAAADg/OdoBikYeNWg/s400/Capturex.JPG" width="400" /></a></div><br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
A couple of tips along the way <br />
<ul><li>it's closely related to Microsoft and Dynamics AX 2009 SP1...</li>
<li>the average is almost 69...</li>
</ul>Please leave your answer as a comment.Hans-Petter Lundhttp://www.blogger.com/profile/02781240948020780728noreply@blogger.com1tag:blogger.com,1999:blog-6214587450644532051.post-27583874380711729952010-09-15T11:24:00.000+02:002010-09-15T11:24:50.208+02:00Follow Up on Event ID 110 and 117 (annoying database error)I wrote about this a while ago and since this still is what I call an annoying database error (noice) and something very common to AX 4.0/AX 2009 solutions, I would like to call on my readers to vote for a change in the AOS kernels (x32/x64) to filter out this information to prevent bombing the event log with errors not beeing errors at all. The voting can be done at <a href="https://connect.microsoft.com/dynamicssuggestions/feedback/details/541171/filtering-database-errors-event-id-110-and-117">Microsoft Connect</a>.<br />
<br />
Finally I would like to quote a paragraph in <a href="http://support.microsoft.com/kb/143339">Microsoft KB article 143339</a>:<br />
<blockquote>Applications need to code their error handling routines for SQL Server connections to call SQLError() until it returns SQL_NO_DATA_FOUND, and act on any messages other than the ones that return a pfNative code of 5701 or 5703. </blockquote>Maybe it's impossible to change this behaviour, but as long as Microsoft don't state this in their feedback on Connect, it's still an issue that I find hard to accept...Hans-Petter Lundhttp://www.blogger.com/profile/02781240948020780728noreply@blogger.com0tag:blogger.com,1999:blog-6214587450644532051.post-20671455631294783502010-09-07T14:39:00.000+02:002010-09-07T14:39:44.914+02:00AX 2009 - deadlocksI recently conducted a system review at a customer site and discovered a message totally new to me beeing logged in on all AOS: <em>"Object Server xx: Dialog issued for client-less session 1: Cannot edit a record in LastValue (SysLastValue). User ID: ,AdminUserSetup. Deadlock where one or more users have simultaneously locked the hole table or part of it."</em><br />
<br />
The database at hand was not configured to use Read Committed Snapshot Isolation (RCSI) as recommended by the AX Performance Team. Enabling RCSI on the database solved the issue.<br />
<br />
<div class="separator" style="clear: both; text-align: center;"><a href="http://1.bp.blogspot.com/_LvOWIBLIb0Q/TIYwDNHYXGI/AAAAAAAAADY/X-Ggh4snoiM/s1600/Deadlock+on+SysLastValue.jpg" imageanchor="1" style="clear: left; cssfloat: left; float: left; margin-bottom: 1em; margin-right: 1em;"><img border="0" height="278" ox="true" src="http://1.bp.blogspot.com/_LvOWIBLIb0Q/TIYwDNHYXGI/AAAAAAAAADY/X-Ggh4snoiM/s400/Deadlock+on+SysLastValue.jpg" width="400" /></a></div>Hans-Petter Lundhttp://www.blogger.com/profile/02781240948020780728noreply@blogger.com3tag:blogger.com,1999:blog-6214587450644532051.post-71856863788237094852010-08-27T10:58:00.000+02:002010-08-27T10:58:34.665+02:00Missing informationI recently was asked about the difference between the 4 alternative values for "Cache Settings" found on the tab labeled "Performance" in the AX Configuration Utility (client) - se example below.<br />
<br />
<div class="separator" style="clear: both; text-align: center;"><a href="http://4.bp.blogspot.com/_LvOWIBLIb0Q/THd7lpwc7OI/AAAAAAAAADI/FzGTtA22ESo/s1600/ClientConfigPerfTab.JPG" imageanchor="1" style="clear: left; cssfloat: left; float: left; margin-bottom: 1em; margin-right: 1em;"><img border="0" height="331" ox="true" src="http://4.bp.blogspot.com/_LvOWIBLIb0Q/THd7lpwc7OI/AAAAAAAAADI/FzGTtA22ESo/s400/ClientConfigPerfTab.JPG" width="400" /></a></div>The different options are explained directly in the GUI, but I would like to know how this mechanism is implemented (technically). I have searched all possible sources (formal and informal) without finding any information at all. It's not unusual to hit "blind spots" like this regarding formal documentation around Dynamics AX, but it should not be necessary to open a support case every time this happens.<br />
<br />
Anyone having a reference or are willing to share some experience regarding the effect of this setting?Hans-Petter Lundhttp://www.blogger.com/profile/02781240948020780728noreply@blogger.com0tag:blogger.com,1999:blog-6214587450644532051.post-56429523123265802642010-06-24T11:39:00.001+02:002010-06-24T11:41:08.995+02:00CommentsI have changed the possibility to post comments from anonymous (all) to Registered Users. Reason: loads of spam comments in my mailbox.Hans-Petter Lundhttp://www.blogger.com/profile/02781240948020780728noreply@blogger.com0tag:blogger.com,1999:blog-6214587450644532051.post-11328297349272474692010-03-08T13:09:00.006+01:002010-05-11T14:54:19.348+02:00Event ID 110 and 117 (annoying database error)I observe the issue described below in both AX 4.0.x and AX 2009 SP1 x solutions running SQL Server 2005 and 2008 (the version of SQL Server Native Client is the same). This is also reported by others in several Communities like microsoft.public.axapta (last one beeing a post by Mike titled "AOS errors" from February 25 2010 where one suggestion is to syncronize the SYSLASTVALUE table).<br />
<br />
Eventlog, application<br />
<br />
#1 Event ID 110<br />
<br />
<span style="font-family: "Courier New", Courier, monospace;">Object Server 01: Dialog issued for client-less session 1: Cannot edit a record in LastValue (SysLastValue). User ID: , AdminUserSetup.</span><br />
<span style="font-family: "Courier New", Courier, monospace;">The SQL database has issued an error.</span><br />
<br />
<div class="separator" style="clear: both; text-align: center;"><a href="http://1.bp.blogspot.com/_LvOWIBLIb0Q/S5TkKYoB5SI/AAAAAAAAAC4/nPnh4BWj0Es/s1600-h/Capture1.JPG" imageanchor="1" style="clear: left; cssfloat: left; float: left; margin-bottom: 1em; margin-right: 1em;"><img border="0" height="232" kt="true" src="http://1.bp.blogspot.com/_LvOWIBLIb0Q/S5TkKYoB5SI/AAAAAAAAAC4/nPnh4BWj0Es/s320/Capture1.JPG" width="320" /></a></div><br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
#2 Event ID 117<br />
<br />
<span style="font-family: "Courier New", Courier, monospace;">Object Server 01: </span><br />
<span style="font-family: "Courier New", Courier, monospace;">The database reported (session 1 (-AOS-)): </span><br />
<span style="font-family: "Courier New", Courier, monospace;">[Microsoft][SQL Native Client][SQL Server]Changed language setting to us_english. </span><br />
<span style="font-family: "Courier New", Courier, monospace;">The SQL statement was: </span><br />
<span style="font-family: "Courier New", Courier, monospace;">"UPDATE SYSLASTVALUE SET VALUE=?,RECVERSION=? WHERE (((((((USERID=?) AND (RECORDTYPE=?)) AND (ELEMENTNAME=?)) AND (DESIGNNAME=?)) AND (ISKERNEL=?)) AND (COMPANY=?)) AND (RECVERSION=?))"</span><br />
<br />
<div class="separator" style="clear: both; text-align: center;"><a href="http://4.bp.blogspot.com/_LvOWIBLIb0Q/S5TkZoJrAyI/AAAAAAAAADA/ld5nE44XHQE/s1600-h/Capture2.JPG" imageanchor="1" style="clear: left; cssfloat: left; float: left; margin-bottom: 1em; margin-right: 1em;"><img border="0" height="260" kt="true" src="http://4.bp.blogspot.com/_LvOWIBLIb0Q/S5TkZoJrAyI/AAAAAAAAADA/ld5nE44XHQE/s320/Capture2.JPG" width="320" /></a></div><br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<span style="font-family: inherit;">I don't know if this has any impact on the solutions at all and I have also found some information on Partnersource describing this as "noice". And I also find it a little bit hard to understand why a syncronization of the system table SYSLASTVALUE should be needed since the real error message in fact is stating "Changed language setting to us_english.".</span><br />
<br />
The reason for posting this is that I find it a little bit hard to understand why something is logget as an error situation if this is "just noice". AX is in general bad at categorizing events in event log application, but I would like to share some experience with others regarding this. Since it's reported from the ODBC layer it could be related to settings like default language for the DBO user (aka AOS Service Account) or inproper settings for Regional Settings for the same Service Account. This is a couple of my own teories left to verify, but bottom line I find it hard to be "just noice".<br />
<br />
Hopefully we can start a good discussion around this and bring the issue forward to the system vendor instead of reporting it individually (perhaps a bigger impact).<br />
<br />
Update March 10 2010:<br />
For those of you not reading the comments, I would like to point out that Chris pointed to an important KB-article from Microsoft. After looking a little bit more at the details (Googled for NativeError 5703), I found another reference on <a href="http://msdn.microsoft.com/en-us/library/ms811006.aspx">MSDN</a>. Quote:<br />
<blockquote>The SQL Server ODBC driver returns SQL_SUCCESS_WITH_INFO on a successful SQLConnect, SQLDriverConnect, or SQLBrowseConnect. When an ODBC application calls SQLError after getting SQL_SUCCESS_WITH_INFO, it can receive the following messages: <br />
<br />
5701—indicates SQL Server initially putting the user's context into the default database defined at the server for the login ID used in the connection<br />
<strong>5703</strong>—indicates the language being used on the server<br />
<br />
If either the ODBC data source has a default database specified or the application specified the DATABASE keyword on SQLDriverConnect or SQLBrowseConnect, there will be a second 5701 message that indicates the user's context has been switched to the database requested.</blockquote>My conclusion is that the AOS kernel treat every error raised from the ODBC layer as an error. If Microsoft could implement a change to filter out NativeError 5701 and 5703, a lot of confusion could be saved and not at least a lot of time investigating this issue could also be saved.<br />
<br />
Until further notice, this is my conclusion.<br />
<br />
Again, thank you Chris for leaving this valuable information.<br />
<br />
Update #2 March 11 2010:<br />
<br />
I have today posted this as a suggestion on the MS Dynamics AX Suggestions Home page at Microsoft Connect. Please sign in at Connect and vote this up if you find this issue to be a valuable improvement.<br />
<br />
Update #3 May 11 2010:<br />
<br />
The EMEA Dynamics AX Support team recently released a post giving another explanation. It can be found <a href="http://blogs.msdn.com/emeadaxsupport/archive/2010/05/10/event-117-changed-language-setting-to-us-english.aspx">here</a>.Hans-Petter Lundhttp://www.blogger.com/profile/02781240948020780728noreply@blogger.com8tag:blogger.com,1999:blog-6214587450644532051.post-33935399697754234152010-03-05T13:01:00.001+01:002010-03-05T13:01:54.785+01:00AX Load BalancingA tree tiered architecture has been around since AX 4.0. In AX 2009 you have 3 possible AOS configurations:<br />
<ol><li>Single AOS instance(s)</li>
<li>Load Balanced AOS instances <strong>without</strong> a dedicated load balancer</li>
<li>Load Balanced AOS instances <strong>with</strong> a dedicted load balancer</li>
</ol>After experimenting a little bit with all of the possible configurations, I find it a little bit difficult to separate configuration 2 and 3 above. The only difference is the presence of one (or several) AOS instance(s) defined as dedicated load balancers only handling the load balancing functionality (no end user sessions) for AX clients that whish to log on to AX (handshake). So the big question is when to use a configuration with a dedicated load balancer. I can't see any reason or benefit other than limiting the need to adjust the client configurations when AOS instances move out and in of the cluster. The only benefit deploying a dedicated load balancer is that this will be the only AOS instance referenced by the clients and that this makes the client configuration more static compared to configuration 2 when every AOS instance in fact both is acting as a load balancer and handling client sessions.<br />
<br />
And information from Microsoft states that a dedicated load balancer only is needed when you have more than 4 AOS instances in the same cluster.<br />
<br />
All combinations in the client configurations will work (no difference wheter you only reference the dedicated load balancing instance and/or all AOS instances).<br />
<br />
Any comments around this matter will be appreciated.Hans-Petter Lundhttp://www.blogger.com/profile/02781240948020780728noreply@blogger.com1tag:blogger.com,1999:blog-6214587450644532051.post-60980563324265789142010-02-03T23:55:00.001+01:002010-02-04T08:46:41.081+01:00Short note on AX and database mirroring in SQL Server 2008The last days, I have been working with a customer running AX 2009 and SQL Server 2008 SP1 Standard (x64) on Windows Server 2008 SP2. The solution suffered from general performance issues that possibly could have a lot of sources. As usual my attention was around SQL Server and this time I started looking at Wait Stats which showed a waste amount of waits related to mirroring. After some Googling, I was a little bit confused about this beeing normal or not. The nature of database mirroring could in fact result in high Wait Stat values since the processes involved, is mostly sleeping (suspended). But I choosed to consider this as a possible source since the nature of database mirroring in my oppinion, does'nt fit the nature of AX as a classic OLTP application. And since disabling database mirroring is an isolated and low risk operation, we choosed to stop mirroring for all database (around 10). After this, the overall performance increased and the customer reported this almost immediately. It's a little bit early to conclude, but the initial responce seems pretty promising.<br />
<a name='more'></a><br />
I will not go into the details around how mirroring was set up and the underlying infrastructure, but since AX is a OLTP application with a lot of inserts, deletes and updates within small, repeating and identical transactions during a normal business day, the processes responsible for doing the mirroring seems to have a big payload on the source server. Remember that database mirroring in fact is a repliction technology and that changes in the primary database, must be replicated to the secondary database (add requirements for low network latency and quality of service). It could of course be other applications that contributes more to the payload, but since time is important in situations like this, we only focused on the SQL Server instance and less on the individual databases. <br />
<br />
Another lesson is to be very restrictive when deploying several databases under the same instance as your primary AX database. The payload of each database should be evaluated and categorized to avoid resource conflicts between databases (for instance queries in the wild, long running transactions and cursor intensive applications). Despite all the positive effects of consolidating databases, the complexity increases a lot when performance issues arise for AX since the source could be another application. My general advise is to prioritize a dedicated databaseserver for your AX production database since this makes it a lot easier to optimize AX. Yes, it will have an impact on the cost (hardware and licenses), but it will normally pay off in the long for customers relying on AX as a mission critical solution. This is an advice I generally bring to my customers.<br />
<br />
If interesting, I can throw in some more details. And yes - I'm aware of database mirroring beeing one of the supported HA configurations for AX. Please add a comment to indicate further details.<br />
<br />
So long.Hans-Petter Lundhttp://www.blogger.com/profile/02781240948020780728noreply@blogger.com1tag:blogger.com,1999:blog-6214587450644532051.post-77895575829165856662010-01-06T11:03:00.000+01:002010-01-06T11:03:46.008+01:00Minor observation installing AX 2009Some time back, I did a QA run on one installation suffering some performance issues. The consultant originally installing AX choosed to use the installer to create the database (shown in the picture below). Personally I prefer to create the database manually, both to get control over every aspect and it usually don't take more than 30 minutes to get everything in place manually. The solution at hand was running SQL Server 2008.<br />
<div class="separator" style="clear: both; text-align: center;"><a href="http://2.bp.blogspot.com/_LvOWIBLIb0Q/S0RLBQzqwCI/AAAAAAAAACw/QGnv1P8hjTA/s1600-h/AX2009installcomponents.GIF" imageanchor="1" style="clear: left; cssfloat: left; float: left; margin-bottom: 1em; margin-right: 1em;"><img border="0" ps="true" src="http://2.bp.blogspot.com/_LvOWIBLIb0Q/S0RLBQzqwCI/AAAAAAAAACw/QGnv1P8hjTA/s400/AX2009installcomponents.GIF" /></a><br />
</div>While looking into the database configuration (sp_helpdb), I noticed that the compatibility level was set to 90 which corresponds to SQL Server 2005. At this stage, I asked the consultant doing the installation why he had choosen to set the compatibility level to 90 and he then answered that he always used the AX installer to create the database.<br />
<br />
Without testing this option when installing AX, it seems like Microsoft has provided a template database beeing attached to the specified SQL Server instance by the installer in the security context of the setup user. I guess the installer asks for some information like collation, file locations etc. but compatibility level keeps untouched.<br />
<br />
Compatibility level is a database level configuration option and it is used by the database instance to decide which functionality the database instance should "activate" for each database. It's mostly used to provide backwards compatibility during migration of databases, but it could also impact the ability to utilize new features.<br />
<br />
A good reference can be found at <a href="http://msdn.microsoft.com/en-us/library/bb510680.aspx">MSDN</a> and compatibility level could possibly be a source for some time consuming investigations. It seems like compatibility level = 90 is OK even for an AX database running on SQL Server 2008, but <em>I don't see any reason for not setting it to 100 to make sure all new features in SQL Server 2008 is enabled for the AX database</em>.<br />
<br />
Or always create the database manually using the system database <em>model</em> as the template (will in most situations match the version of SQL Server).Hans-Petter Lundhttp://www.blogger.com/profile/02781240948020780728noreply@blogger.com2tag:blogger.com,1999:blog-6214587450644532051.post-91843766174231076142009-12-23T23:51:00.000+01:002009-12-23T23:51:52.106+01:00A new year approachingWith another week to go and the Cristmas hollidays coming, it's time to reflect on the past and coming year. I think 2009 was a good year for AX 2009 despite the product beeing released in 2008. The main reason for 2009 beeing a good year for AX 2009 is mainly based on the Gartner report positioning AX 2009 the number one (#1) leader in the magic quadrant for what we call SMB here in Norway. This could of course be marketing hoopla, but if you read the report, Gartner pays special attention to "Microsoft delivering on their vision". Personally I find this interesting and I suggest that every partner study the current Roadmap and Statement of Direction (SOD) to see what Microsoft is planning (visionary) for AX in the future. In my mind, AX 2009 did'nt bring a lot of news on the techology side (the new batch framework and the support for UTC is perhaps the most important improvements), but overall MS managed to position AX as a real challenger and maybe also a winner in the combat against SAP and Oracle/PeopleSoft.<br />
<br />
Based on the number of hotfixes released for AX 2009 and SP1, MS still has some challenges regarding quality. Maybe a slowdown in the release cycle would be a good advise and maybe also broaden the early adoption program to gain some more experience from the field. Again this is really not special to AX, since we have to remember that all software is manufactured by humans and no human is free of errors. All in all I think AX 2009 was a great step forward at least with regards to technology and architecture, since the product is well positioned to compete with the biggest rivals even in the upper, right quadrant. Finally "MS got rid of most of (every?) not so industry standard implementation as expected" and lifted the product up to the MS level of integration (still some ground to cover, but yet greatly improved).<br />
<br />
So it's exiting times generally and with regards to AX. I'm positive about the year to come and also the next decade. From the Roadmap and SOD, I read a steady growth both vertically and horizontaly with regards to functionality. We are already seeing some evidence of this with MS buying verticals from partners (like the POS vertical from a Danish world wide partner financing? a rather special twist in buing a highly specialized ERP solution called Guideix A/S). The future story of this evolution of one of my previous employers, will be very interesting to follow. Driven by market, customers or product/technology? Who knows...<br />
<br />
Anyway I'm optimistic about the future of AX and I seriously meen that AX 2009 brought AX closer (really close) to what the product has been marketed as since the beginning (Damgaard back in 1998 - more than 10 years ago). At the same time I have to admire the Damgaard brothers for the introduction of a true 3-tired solution (was it 2.5?) that MS now has adopted and brought forward to a pure 3-tiered solution with no other choices. Add the rather annoying AOCP beeing replaced with MS RPC in AX 4.0 and you get the picture.<br />
<br />
One final message to all x++ developers out there, is to take the time to study and understand the difference between the different caching schemes available in AX (look at the DEV III course documentation or Inside AX 4.0/2009 book). This is key knowledge to utilize the 3-tier architecture in AX 4.0 and 2009 (also valid for earlier versions when running in 3-tire thin configurations) and at the same time, rather complicated. From my experience, this is an area that get far to less attention and that has a big potential for optimizations (and performance gains).<br />
<br />
Without digging deeper into the philosopical area, I would take the opportunity to wish my few (but valuable) readers, a happyy Christmas and an interesting new AX year (and decade)!<br />
<br />
See you in 2010! So long...Hans-Petter Lundhttp://www.blogger.com/profile/02781240948020780728noreply@blogger.com2tag:blogger.com,1999:blog-6214587450644532051.post-55002637499133435902009-12-16T09:04:00.001+01:002009-12-16T09:05:37.378+01:00DAS or SAN for SQL Server part III thought a follow up was adequate for this one. After looking for some more views, oppinions and recommendations, I found the following posts (3 part) on the blog for the <em>Microsoft SQL Server Development Customer Advisory Team</em>:<br />
<br />
<a href="http://blogs.msdn.com/sqlcat/archive/2005/10/11/479887.aspx">Deploying SQL Server with SAN #1<br />
</a><a href="http://blogs.msdn.com/sqlcat/archive/2005/11/21/495440.aspx">Deploying SQL Server with SAN #2</a><br />
<a href="http://blogs.msdn.com/sqlcat/archive/2005/11/17/493944.aspx">Deploying SQL Server with SAN #3</a><br />
<br />
<a name='more'></a><br />
There are many different oppinions out there, but I usually pay special attention to what Microsoft says since they are as close to the products as possible. At least I found this information valuable as kind of a formal reference. Look at separation of I/O based on the characteristics for each category of file types that SQL Server ulimately read and write from/to as a good example (often argued by the SAN guys - "we want to maintain a single array of disks instead of hooking a set of disks to a LUN"). And as argued earlier, SAN's complicates and often blurres the picture when dealing with performance issues when you are sharing the SAN with other applications/usage patterns (dedicated SAN to SQL Server is a good thing). <br />
<br />
In my oppinion it's important to get every piece in a solution configured as optimal as possible from the start to secure a best practise deployment. A best practise deployment will again make sure that you have control over the deployment with regards to configuration and setup, when for instance performance issues arise. Under these circumstances, it's a lot easier to narrow down the scope for the activities necessary to diagnose the issue (similar to what the doctor does when you feel ill).<br />
<br />
And the different SAN vendors add some more to the table where each vendor has it's own set of recommendations and of course some invaluable piece of magical software solving every challenge.<br />
<br />
As you probably have noticed, I'm a simple man trying to live by the prinicple "Keep It Simple Stupid", but this is not an easy rule to apply in the world where IT technology plays a key role in every business.<br />
<br />
It would be interesting to gather some comments around this matter, so come on and post your comments preferably in the form of real world experiences.<br />
<br />
So long.Hans-Petter Lundhttp://www.blogger.com/profile/02781240948020780728noreply@blogger.com0tag:blogger.com,1999:blog-6214587450644532051.post-37294386395844006642009-12-15T13:19:00.001+01:002009-12-15T13:19:40.514+01:00AX Application DBAYesterday I recieved a newsletter from SSWUG titled <br />
<blockquote>Are You an application DBA?<br />
</blockquote>My first reflection was that I have been and that I partly still is an application DBA for AX (and also some Axapta solutions). My second thought was that this is an interesting question, since I very often see a total lack of DBA responsibilities and naturally even less DBA's that focus on AX. When I meet someone with a DBA role, it's often in relationship to hosted solutions (outsourcing) and these guys are general DBA's focusing on "the big picture" (at best). <br />
<br />
One example was a customer with a consolidated SQL Server solution counting almost 60 user databases supporting the same number of applications. When facing these kinds of situations, the potential for optimizing the AX database is rather small. Take tempdb as an example. AX 4.0 and later benefits from Read Committed Snapshot Isolation as a consequence of introducing versioning and optimistic locking. This again increases the load on tempdb, since the version store are held in tempdb. Since tempdb is a system database shared between every database on the same instance, the total load on tempdb again impacts AX. And I can say that different applications uses tempdb differently and often not following best practice. Mixing OLTP and OLAP load on the same instance or database server, is another classic.<br />
<br />
This is some examples of when you need to know how the application uses SQL Server and maybe not something a general DBA would pay attention to without looking into how each application actually utilizes tempdb. Another example is locking and lock escalations in other applications impacting for instance AX. Add databases consuming a considerable amount of CPU in combination with high I/O load.<br />
<br />
So in my oppinion it's a great need for application DBA's and AX is a good example since AX is a ERP solution (very often mission critical). <em>I would bet that all customers running AX would see a good return on investment (ROI) hiring an application DBA for AX responsible for pro active maintenance and follow up on queries not performing at the full potential, long running queries etc.</em> But the economic downturn probably impact the willingness of customers spending money on this and this again justifies for calling in people like my self for short term activities (fire fighting). This is a bit of a paradox to me...Hans-Petter Lundhttp://www.blogger.com/profile/02781240948020780728noreply@blogger.com0tag:blogger.com,1999:blog-6214587450644532051.post-16480041571012025032009-12-04T15:00:00.004+01:002009-12-04T15:36:40.205+01:00AX and virtualization (to do or not)I have only done one completely virtualized implementation of AX 2009 (including SQL Server 2008 EE x64). This solution is not yet in production, but in the meanwhile I have looked at several other virtualized implementations done by other partners and often operated by another vendor (hosted).<br /><br />One of them (AX 4.0) consists of 2 AOS servers in a normal AX load-balancing cluster. The interesting part in this setup is that one server is a dedicted, physical server with DAS, while the other is virtualized (ESX 3.5). When talking to the users, they complain about overall performance when having sessions against the AOS instance on the virtualized server. I suspect that the most clever users always looks at the caption in the main AX window to see which AOS server they hit (and maybe they also start one additional session immediately to hit the physical one followed by closing the first session against the virtual). Everything seems ok from the server console (PerMon, TaskMan, Event log etc.), but I also feel (subjective) that the loading of the AX client also takes some more time when hitting the virtualized one.<br /><br />Again I have to talk about complexity. Ideeally AX AOS should be the perfect candidate to virtualize since it's a CPU, memory and network intensive process. The AOS server will never pay a high physical I/O load and disk I/O is in general low (of cource some batches could impact this in AX 2009). And AX 2009 is now fully supported on several virtualized platforms. So exactly why do I bring in complexity again? As with Storage Area Networks, a virtualized environment is simple to utilize (when it's working as expected), but the technology and the levels of infrastructure behind adds a lot of potential sources when things are not running as expected (most virtualized environments also utilizes a SAN). I guess the odds for getting down to all the needed details is a lot better when implemented at a customer site, but customers nowdays tend to outsource this since "it's not part of their core business". In this scenario, the complexity is very visible since the AX partner (or the consultant doing the performance audit) don't even get all the details or access to the parts of the system necessary for defining the big picture. Seen from the hosting partner, it's all about utilizing the underlying platform as much as possible trying to maximize the potential of the platform. This often means mixing customers on the same platform (logically isolated on every level), but ulitmately sharing the exact same resources at a certain level. This again typically leads to traditional bottlenecks, but they are well hidden for both the customer and the man in the midle.<br /><br />So what's the lesson here? Always differentiate between hosted solutions and locally implemented ones! The main principles are the same, but it's cruical to bring in the hole army of partners in the planning when the solution is operated by a hosting partner. Without this, you are basically left on your own and you'll probably never be able to see the big picture consisting of all the details, to judge where the reall issues causing the problems are hiding. I guess this is true for every application or solution.Hans-Petter Lundhttp://www.blogger.com/profile/02781240948020780728noreply@blogger.com1tag:blogger.com,1999:blog-6214587450644532051.post-29224215925388706672009-11-18T09:06:00.002+01:002009-11-18T09:34:30.131+01:00DAS or SAN for SQL Server?Performance issues is always complicated, but a common approach is possible (in fact the only way to work through this is to define the problem area and structure the different factors into groups). In my approach the operation platform is one key group while the database is another. Based on the work I have done since September, I have found it very hard to get real and trustworthy information about the utilization of SAN storage when this is used for SQL Server. And as a advisor I don't have deep knowledge about the solutions from the indivdual SAN vendors (expertice and experience required). In my mind the old rules about separation of physical I/O from the I/O characteristics still applies despite the fact that SAN's normally have high end controllers capable of handling huge I/O loads. DAS (Direct Attached Storage) as the traditional way of providing storage, seems to be much easier to work with when analysing performance issues at the database level mainly because good old Performance Monitor will tell you all you have to know to conclude and defined possible counter measures. This is NOT the same for SAN's! Since a SAN mainly is used for storage provision and consolidation, you have to work your way through the hole SAN setup and identify every piece of software that is generatig I/O against the SAN. Add some interconnect (normally fiber switches, HBA's etc.) in between and you have multiplied the complexity by at least PI.<br /><br />Add another overhead for hosted solutions where several customers normally share the same infrastructure and the picture starts to be rather though to control. During my search I found another <a href="http://sqlblogcasts.com/blogs/grumpyolddba/archive/2008/12/31/comparestorage-grumpyolddba.aspx">blog</a> discussing the same issues and his summary resembles much of my own experience.<br /><br />So this is yet another example of how developments in technology actually complicates the everyday work for both customers and consultants, and this is clearly something to account for when doing the TCO matrix. <br /><br />Based on this, customers should evaluate SQL Server storage and consider to implemented database storage as DAS. Do you agree?Hans-Petter Lundhttp://www.blogger.com/profile/02781240948020780728noreply@blogger.com0tag:blogger.com,1999:blog-6214587450644532051.post-43065676732378824912009-11-06T14:10:00.003+01:002009-11-06T14:21:25.167+01:00Current challenges and issuesIn my new role I have been busy working with a couple of hosted solutions experiencing various stability and performance issues. It’s easy to conclude that hosting AX solutions externally is demanding and that it requires a lot of attention from the customer to establish a good working relation between the hosting partner and the AX partner.<br /> <br />Even more important is the ability to regulate the responsibilities between the different parties. Simple things like for instance database maintenance must be defined in a way that separates regular maintenance not requiring AX knowledge and the opposite. Typical maintenance tasks like reorganizing and re indexing falls into the first category since it can be performed by any DBA (no changes of the definitions or design). When it comes to maintenance requiring AX knowledge (requiring changes in tables node in the AOT), it’s as important to makes sure the AX partner has the necessary access to SQL Server to be able to utilize all the valuable information provided in the form of Dynamics Management Views (I’m not mentioning Oracle here, since it seems like SQL Server is the dominating RDBMS for AX at least here in Norway).<br /><br />SQL Server 2005 brought a lot of good news in this area and SQL Server 2008 took this even further with the introduction of a brand new Activity Monitor and the Performance Data Collection. Developers should in my opinion pay more attention to the load that their customizations put on the database server and examination of query plans, should be obligatory before releasing changes in the production solution.<br /><br />In addition to the simple examples mentioned above, my experience says that even if each solution has different characteristics, some common areas can be defined to guide the approach. Without going into the details, the following summarizes what I normally define as the key sources for each category:<br /><br /><strong>Stability</strong><br />• Network related issues (AOS -> database, AOS -> application share)<br />• Operational knowledge (description of the relationships between the different server roles in the AX solution and routines describing how to perform a controlled stop – start sequence)<br />• Pro active maintenance of the AX application and kernels (implementing hot fixes and roll ups for current SP level, new SP)<br /><br /><strong>Performance</strong><br />• Physical disk I/O at the database level (separation and isolation, Raid levels, sector alignment, block size) regardless of DAS, SAN, NAS heads etc. (general rules apply)<br />• General load on database instance and utilization of system resources (both OS and SQL Server internals)<br />• Database configuration, usage and maintenance (best practice configuration, indexes, transactions, space allocation, index maintenance) <br />• Customizations (caching, run on, query width and selectivity)<br />• Identify and implement hot fixes related to performance issues (both application and kernels)<br /><br />While talking about database configuration, I would very much recommend the Check lists that the AX Performance Team has compiled and published on their blog. This is vital information for everyone involved in installing and configuring AX, but also as a general source for hosting partners and customers. The best thing is that this is based on experience and best practice, and in my opinion the value of their recommendations goes beyond AX (general for OLTP applications).<br /><br />In addition to working with troubled solutions (time consuming, but very motivating), I have implemented “my first” AX solution in a pure virtualized environment including SQL Server 2008 Enterprise. I’m excited about this solution mainly because it’s always interesting to make new experiences. Many people have probably walked this path already, but it’s a first time for everything.<br />This finalizes my first blog entry in several months, but I will be paying more attention to my blog from now on.<br /><br />Happy weekend!Hans-Petter Lundhttp://www.blogger.com/profile/02781240948020780728noreply@blogger.com0tag:blogger.com,1999:blog-6214587450644532051.post-10543401689966306582009-06-25T07:54:00.004+02:002009-06-26T14:59:59.666+02:00OpportunitiesThis time I'll post a short professional status - I'm currently unemployed. My company decided to end the Dynamics business after 2 years. Not the nicest entry to the summer holliday, but at least a opportunity to get close to the Norwegian Dynamics business talking to customers, partners and Microsoft in a new setting. This business seems to be going very well at the moment despite the economic downturn. One of my reflections is why my company decided to end this business when the market is very positive around both AX and CRM... Without going into details, ERP in general seems to be a challenge for my company and paired with the history of the company, it's quite obvious that ERP was never a part of the culture. This is always difficult to uncover during the interviews and you need some time within a company to really see this.<br /><br />I hope to keep this blog going and to have a closure of my next professional move as soon as possible followed by a long summer holliday together with my family.<br /><br />Happy summer to the WWW!<br /><br />Update 09/06/26:<br /><br />I'm closing the hunt and I'm signing a new work agreement early next week. And this blog will still be alive after a long summer holliday. Stay tuned for updates in August/September.Hans-Petter Lundhttp://www.blogger.com/profile/02781240948020780728noreply@blogger.com0