Starting my preparation for 98-375 exam

It has been a while since I had taken any Microsoft exam as there were rather a lot of other things happening. Finally I’ve decided to get back to certification and learning and this time it will be “fundamentals”/MTA level exam yet on topic quite new to me which will allow me to learn quite a few things. Exam I will be taking this time is Microsoft 98-375: HTML5 Application Development Fundamentals and I will probably combine prepping to this exam with doing Harvard’s CS50’s Web Programming with Python and JavaScript course on edX.

Just for tracking I’m posting my very first practice test exam attempt results below (results I’ve got more or less expected for attempt taken without any preparation at all):

98-375 practice exam attempt without preparation 🙂

As you can see exam topics grouped in 4 blocks: Code by Using JavaScript, Format the UI by Using CSS, Manage the Application Life Cycle, Build the UI by using HTML5 – quite interesting set of things to explore.

You can expect some related posts about this exam and related topics as I go through exam preparation process.

How to collect process dump with LeakTrack information using ProcDump + Debug Diagnostic Tool

Just a short note on how to collect process dump including LeakTrack information.

Download latest version of Microsoft Debug Diagnostic Tool, at the moment it is Debug Diagnostic Tool v2 Update 3 and install it going through an installation wizard steps as shown below:

Debug Diagnostics Installation Wizard Page 1
Debug Diagnostics Installation Wizard Page 2
Debug Diagnostics Installation Wizard Page 3
Debug Diagnostics Installation Wizard Page 4
Debug Diagnostics Installation Wizard Page 5

Once installation wizard completes, download ProcDump and unzip it on the server where you going to collect dump file. Next, run DebugDiag 2 Collection:

DebugDiag 2 Collection icon in Start Menu

Cancel out initial “Select Rule Type” dialog:

Debug Diagnostic Tool – Select Rule Type

Navigate to Processes tab select process for which you need to collect
LeakTrack, right click on it and select Monitor For Leaks:

Debug Diagnostic Tool – Monitor For Leaks

Click Yes in “Do you want to enable ‘Service Mode’ and continue” pop up:

Debug Diagnostic Tool – Enable Service Mode

You will see confirmation that monitoring for leak has started:

Debug Diagnostic Tool – Monitoring for leaks in the specified process

Now let it run and wait till the process you monitor use up large amount of RAM and take dump using procdump.exe, you can see some hints on the command line syntax below:

Script to run procdump.exe

Once dump taken you can stop monitoring for leaks and close Debug Diagnostic tool:

Debug Diagnostic Tool – Stop Monitoring For Leaks

After following steps above your process memory dump should contain LeakTrack information. You can tell that by the dump file size – if you take a dump without enabling Monitor For Leaks option in Debug Diagnostic Tool at the same time you will see that your dump file size will be smaller if compared with one which you take while running Monitor For Leaks .

How to take process dump using CDB

Just a short explanation of how to take process dump using CDB.

First you need to get Debugging Tools for Windows. To get Debugging Tools as a standalone tool set you can just download Windows SDK and during installation select Debugging Tools for Windows:

Installing Debugging Tools for Windows

Once Debugging tools for Windows are downloaded and installed you can find cdb.exe in the following location – C:\Program Files (x86)\Windows Kits\10\Debuggers\x64 (note that number highlighted in bold may vary depending on SDK version installed – in my case it is 10, and you obviously have cdb.exe for different platforms – x86/x64 etc. – just navigate to appropriate subfolder of Debuggers folder).

To take dump launch CMD in elevated mode, switch directory to CDB location and execute cdb -p <PROCESS PID> to take crash dump (remember that PID information can be found in Task Manager or retrieved with PowerShell using Get-Process “%ProcessName%” | select -expand id):

CDB attaching to the process by PID

At this stage CDB is attached to process and closing this CMD window will terminate process you are attached to. Once CDB is loaded type in the following commands:

..loadby sos clr

!Thread

You will receive “No export Thread found” error – it can be ignored, and some more commands needs to be executed. First run !StopOnException -create System.StackOverflowException it may not work from the first attempt, just re-run it once again until you see confirmation that breakpoint was created:

CDB set breakpoint

Once breakpoint is set type gn and wait for process crash:

When process crashed the following commands have to be executed:

.logopen C:\dumps\k2hostserver.log

!ClrStack

.logclose

.dump /ma /u C:\dumps\process.dmp

gn

gn

….

Repeat typing gn until you get “there is no debugee” message. Your dump will be written in the location you specified above (C:\dumps\process.dmp).

Invalid URI error on attempt to create new web application

You may see the following error message on attempt to create new web application using SharePoint 2013 CA UI:

Invalid URI: The hostname could not be parsed.

Error message says: “Invalid URI: The hostname could not be parsed“, at the same time creation of web application using PowerShell may work just fine. This error can be caused by the fact that you have asterisk (“*”) as a value of Host name property in bindings of one of your existing web applications. Removing asterisk and leaving host name blank should resolve this issue.

PowerShell Script – Detect installed SQL Server Version and switch to appropriate setup directory

Some time ago I wrote a blog post where I explained how to change SQL Server instance collation for installed SQL server instance (see “Changing SQL collation for deployed instance without reinstall (almost)“). That post contained some scripting bits to detect installed SQL Server version and navigate to appropriate setup directory to facilitate collation change process. Recently I had a bit of time to consolidate these bits of PowerShell into one script which detects installed SQL Server version and changes directory to appropriate setup folder. Here you have it: