Category Archives: General

Downgrading you ClearDB MySql database in Azure

Are you running a website or application in Windows Azure with data stored in MySql? I upgraded my database from the free database with a maximum of 20 Mb to the 1 GB option, costing me $9.90 a month. Well, I cleared it out and was going to do a downgrade from payed to free again. Well, it seems ClearDB doesn’t really like downgrading since the Revenue stream goes sour… So you’re on your own and need to create a new database and manually (woop!) migrate data. Feels like we’re back to 1886.

Steps:
Login to ClearDB site
Create a new database in the free plan
Copy server name, user name and password to a textfile, or just remember it all 🙂
Download MySql Workbench from Oracle (http://dev.mysql.com/downloads/tools/workbench/)
Install Workbench (next, next, finish)
Get the server name, user name and password to your existing database, wp-config.php has it or check the connection strings for your Azure website.

ClearDB01
 

 

 

Configure MySql Workbench to connect to old server
 Dump database

ClearDB02

 

 

 

 

 

 

 

 

Edit dump file to reflect new server and database name. Or make corresponding changes in Workbench, but this is easier to explain.

ClearDB04

 

 

 

 

 

 

 

Import/restore to new database in Workbench

ClearDB03

 

 

 

 

 

 

 

 

Edit wp-config.php to reflect new server name

ClearDB05

 

 

 

 

 

 

 

Verify it all works by reloading your website in your browser. (important!)

Delete old database on ClearDB site. This will also clear your payment plan. Login to Amazon and verify your payment authorizations to make sure.

SWE – Nya och uppdaterade videos

Har uppdaterat och förkortat videon till avsnitt 1, hur man skapar en gateway. Har även spelat in en ny som visar hur man installerar en domänkontrollant i Windows Azure och vad man bör tänka på… Om du tar dig igenom en eller bägge så är feedback supervälkommet! Du hittar avsnitten under “TV”.

Trevlig helg!

PDT user creator in, hold it… PowerShell!

 

 

Well, I’ve read about it. I’ve tried some. I’ve never written one myself. But it finally happened! Using the PDT (PowerShell Deployment Toolkit) I’ve come to realise that creating the users and groups in my lab Environment takes some time. And what’s better to go PowerShell when it’s time to create a new script, don’t wanna be seen doing old vb-scripts 🙂

If you haven’t tested PDT yet, go do it instantly! It’s written by Rob Willis from Microsoft, and he has saved me at least 200 hours already. Check it out at http://blogs.technet.com/b/privatecloud/archive/2013/02/08/deployment-introducing-powershell-deployment-toolkit.aspx

 

Copy / save as PDTUserCreator.ps1


# Script creates users, ou:s and groups for PDT #
# Created by Joachim Nässlander, Microsoft #
# joachim.nasslander@microsoft.com #
# #
# Script provided as-is #
# #

# Import module and check for write permissions
cls
Import-Module ActiveDirectory
try {
New-ADUser -name TemporaryUser -SamAccountName TemporaryUser
Remove-ADUser TemporaryUser -Confirm:$false
}
catch
{
Write-Host “No write permissions in Active Directory”
Exit
}

# Create arrays, passwords, get domains and stuff
$PDTusers=”!installer”,”!vmm”,”!or”,”!ac”,”!om_saa”,”!om_das”,”!om_dra”,”!om_dwa”,”!sm_s”,”!sm_w”,”!sm_r”,”!sm_a”,”!sql”,”!jd”
$PDTUserPassword=”P@ssw0rd”
$SecurePDTUserPassword=$PDTUserPassword | ConvertTo-SecureString -AsPlainText -Force
$PDTOUs=”Services”,”Servers”,”Groups”,”Users”
$PDTGroups=”AC Admins”, “OM Admins”, “CM Admins”, “SM Admins”, “Orchestrator Admins”, “VMM Admins”, “DPM Admins”, “SQL Admins”
$Domain=Get-ADDomain
$DistName=$Domain.DistinguishedName
$DNSRoot=$Domain.DNSRoot
# Check / create ou’s
if (dsquery ou domainroot -name HQ)
{}
else {
New-ADOrganizationalUnit -Name “HQ” -Path $DistName -ErrorAction SilentlyContinue
}
foreach($ou in $PDTOUs){
if (dsquery ou domainroot -name $ou)
{}
else {
New-ADOrganizationalUnit -Name “$ou” -Path “OU=HQ,$DistName” -ErrorAction SilentlyContinue
}
}
# Check / create groups
foreach($group in $PDTGroups){
if (dsquery group -samid $group)
{}
else {

New-ADGroup -Name $group -GroupScope Global -Path “OU=Groups,OU=HQ,$DistName” -ErrorAction SilentlyContinue
}
}
# Check / create users
foreach ($user in $PDTusers){
if (dsquery user -samid $user)
{}
else
{
New-ADUser -Name “$user” -SamAccountName “$user” -ChangePasswordAtLogon 0 -AccountPassword $SecurePDTUserPassword -Description “PDT created user” -Enabled 1 -Path “OU=Users,OU=HQ,$DistName”
}
}
Add-ADGroupMember -Identity “SQL Admins” -Members “!sql” -ErrorAction SilentlyContinue
Write-Host “PDT users, groups and OU’s created”

The blue badge!

Haven’t posted for quite a while, have been waiting for everything to settle down and become official. But as of November 1:st I’m employed by Microsoft and as such I’ve got my own blue badge. I’ll be working as a TSP with the System Center suite of software. This moves my focus away from cluster / hyper-v / server core a bit, but knowing myself I probably won’t let that go either.

At the moment I’m in the middle of the boarding process, getting my machine up to speed, parking permits, phone numbers, access to internal systems and all that. But soon I’ll be at a meeting near you, or at a conference or user group. Have any SC-related questions? Email me at jonas (at) microsoft.com!

 

I've moved!

Stuff around here won’t work as you expect it to for a while, I’ve switched web hosting from my old supplier to the fantastic Binero.se. Unfortunately I’ve also decided to update the look and functionality around here, which breaks stuff 🙂

Unboxing the Samsung Slate

The Samsung Slate is a fantastic device and now that I’ve finally gotten my hands on one (thank you SO very much!) I’ll share my experiences with you.

Unboxing stuff is always exciting and I’m glad to say that Samsung actually manages to give the user a great experience, it’s not a PC in a cardboard box. It’s a good looking box, the Slate is positioned on top and makes you wanna rush through it all…

But I didn’t. Click the picture to have a walkthrough of unboxing the Samsung Slate!

Once unboxed I started it, it’s blazingly fast!

It came installed with Windows 7 with the touch features enabled. Quite easy to use with the pen, but of course I still decided to go for Windows 8 Consumer Preview. That’ll be another post, quite fascinating how to install the OS on this baby!

Read more about the slate here: http://www.samsung.com/us/computer/tablet-pcs/XE700T1A-A01US
Read more about Windows 8 Consumer Preview: http://windows.microsoft.com/en-US/windows-8/consumer-preview

In the following posts we’ll take a look at OS installation, using Windows 8 and I’ll try to see if I can use the Slate instead of my laptop for a whole week at work!