0 Comments

Make sure you have Windows 10 with the anniversary update or newer.

You can verify this by pressing the winkey + R and type ‘winver’ and hit enter. The anniversary update has buildnr 14393. And make sure that you have the “Bash on Ubuntu on Windows” feature enabled.

Xmllint is not included by default, so you have to install it first.

sudo apt install libxml2-utils

You can read more about xmllint on http://xmlsoft.org/

in order to format a large XML file which has no line breaks you have to use xmllint like this:

xmllint --format input_xml_file.xml > pretty_output_xml_file.xml

You use the format option on the input_xml_file.xml and redirect the output (>) to a new file with the name pretty_output_xml_file.xml

This is a lot faster than opening the file in notepad++ and use the xml plugin to format it.

Hope it helped. Good luck!

snip_20170411144653

Pin on pinterest Plus on Googleplus Post on LinkedIn
0 Comments

Here are the 9 steps to enable the linux subsystem in the latest Windows 10 version:

  1. Windows key + I (to go to settings)
  2. Update Windows
  3. Select developer menu on left hand side
  4. Make sure that the developer mode is enabled
  5. Go back to the main page of settings
  6. On the right hand side click “programs and features”
  7. Click on install additional features on the left hand side
  8. Check the box for the linux subsystem
  9. Double click on c:/windows/system32/bash.exe to install it

 

snip_20170411142711

I had to blog this, because the GUI option mentioned on msdn did not work on my locale (nl_nl)

https://msdn.microsoft.com/en-us/commandline/wsl/install_guide#enable-the-windows-subsystem-for-linux-feature-gui

snip_20170411143020

Read more about it on MSDN https://msdn.microsoft.com/en-us/commandline/wsl/about

Good luck!

Pin on pinterest Plus on Googleplus Post on LinkedIn
0 Comments

I started my IoT (Internet of Things) journey a bit later then some. I waited for a suitable small project to come along and some free time. The creators update (Windows 15063) has just been released and apparently also the IoT version of the creators update.

I already had the Visual Studio RTM version of 2017 on my machine. I have worked with several release candidates of the 2017 version, but updated as soon as possible to the RTM update. The SDK and everything else was already setup and ready to go.

snip_20170410110914

When I started with file –> new project and selected the background application I got this error:

snip_20170406161443

“Could not add all required packages to the project.” That’s odd because this is just a file new project…

The package causing this is: “Microsoft.NETCore.UniversalWindowsPlatform.5.0.0” Unable to find version 5.0.0 of package Microsoft.NETCore.UniversalWindowsPlatform

When I manually ran the install-package command in the package console I got more info. The Jit package was also failing to install (dependency)

snip_20170406162235

I did not see how to fix it, so I turned to stack overflow. Rita Han from Microsoft reached out and confirmed that the solution workaround given by Wind Rider was the solution to my issue.

My solution explorer looked like this after the file new project and the popup with the error:

snip_20170407120531

The project.json had a yellow exclamation mark and checking it with explorer, it was not available on disk. So there is no file… that’s odd.

The workaround from SO was to manually create a project.json with this content:

{
  "dependencies": {
    "Microsoft.NETCore.UniversalWindowsPlatform": "5.0.0"
  },
  "frameworks": {
    "uap10.0": {}
  },
  "runtimes": {
    "win10-arm": {},
    "win10-arm-aot": {},
    "win10-x86": {},
    "win10-x86-aot": {},
    "win10-x64": {},
    "win10-x64-aot": {}
  }
}

and then manually edit the .csproj file.

navigate the the “ItemGroup” of project.json and add below the </itemgroup>

  <ItemGroup>
    <SDKReference Include="WindowsIoT, Version=10.0.15063.0">
      <Name>Windows IoT Extension SDK</Name>
    </SDKReference>
  </ItemGroup>

This will cause visual studio to reload things. Installing the Microsoft.NETCore.UniversalWindowsPlatform package now works Smile

 

Good luck, hope this reference helped!

Pin on pinterest Plus on Googleplus Post on LinkedIn
0 Comments

The documentation for Azure SQL db performance tuning is great and accurate with great detail on docs.microsoft.com (instead of the old msdn location)

https://docs.microsoft.com/en-us/azure/sql-database/sql-database-query-performance

I was looking at a SQL db in Azure and noticed some spikes. Here is my graph:

snip_20170215133957

I could drill into the Azure portal to see what was causing this spike and recognized the SQL statement, so I knew which product to update the SQL for. However this was not even necessary.

Here are the client stats when I copy pasted the query causing the spikes in SQL Management Studio Express. Check out the “Total execution time”

snip_20170215120138

My next step was to take a look at the execution plan of the query. There is this exclamation mark at the sort operation:

snip_20170215120257

When you hover it, you get this context popup:

snip_20170215124310

So it used tempdb. I still had no clue how to fix this, so I reached out to stack exchange. And a user named T.H. gave me the solution to create two rather simple indexes:

CREATE NONCLUSTERED INDEX TEST ON STOCKDEBUGTRIGGERED (ChangeDate)

CREATE NONCLUSTERED INDEX TEST ON STOCKDEBUG(ProductID, StockOld, StockNew)

Here is the query plan after the two new indexes:

snip_20170215124852

No more yellow exclamation mark! and fewer steps. The client statistics also prove that this is a lot faster/better:

snip_20170215124929

From an average of 4250 down to 50!

 

This is also backed by the dramatic drop in resource usage in the Azure Portal:

snip_20170215133957

So the lesson is: do not trust the Azure db perf advisor a 100% Smile

T.H. commented on Stack Exchange:

The automatic index advice is extremely limited, and often misleading, so can only be considered as a starting point.

 

Hope this info might help someone troubleshooting Azure Db perf!

 

Good luck!

Pin on pinterest Plus on Googleplus Post on LinkedIn
0 Comments

I have stored an mp3 in my OneDrive music folder on my Win 10 (build 14393.693) and it syncs to OneDrive online. So far so good. When I go to https://music.microsoft.com

it is not there. When I click on the song on https://onedrive.live.com/ it starts to open music.microsoft.com and I see:

snip_20170208101035

So something is wrong there:

snip_20170208100957

So I cannot play the mp3 which is in my OneDrive music folder. They appear up on onedrive.com so the onedrive sync is working fine. The problem is with my groove connection. When I locally start groove, there is the mp3. Because I stored it on my HDD it loads locally, but does not show up from onedrive.

Local Groove:

snip_20170208101306

I clicked on the option to reset my groove catalog which seems to reset my cloud collection:

snip_20170208101744

This does give me my recently added track. But only as “unknown”

snip_20170208101845

There is a lot which is not known…

Perhaps this all happened because I added the onedrive/music folder which is local as folder to watch for groove:

snip_20170208102004

I have removed that reference now and this seems to fix it Smile Even the new track is not an unknown one!

 

I hope this might help someone

Pin on pinterest Plus on Googleplus Post on LinkedIn