Showing posts from July, 2015

Rename a Microsoft CRM 2011 Server and it's MSSQL Server

Step1: Edit the MS CRM Config Registry Step A: Change this registry key HKLM\SOFTWARE\MICROSOFT\MSCRM\configdb change: Data Source=VCRM1;Initial Catalog=MSCRM_CONFIG;Integrated Security=SSPI to: Data Source=VCRM2;Initial Catalog=MSCRM_CONFIG;Integrated Security=SSPI Step B: Change this other registry key HKLM\SOFTWARE\MICROSOFT\MSCRM\ServerUrl change: http://VCRM1/MSCRMServices to: http://VCRM2/MSCRMServices Step 2: Edit the MSCONFIG database ( example VCRM1 to VCRM4 ) use MSCRM_CONFIG; update dbo.Server set name='VCRM4' where NAME='VCRM1'; update dbo.ConfigSettings set HelpServerUrl='http://VCRM4/' where HelpServerUrl='http://VCRM1/'; update dbo.DeploymentProperties set NVarCharColumn='' where NVarCharColumn LIKE '%VCRM1:80'; update dbo.Organization set ConnectionString='Data Source=VCRM4;Initial Catalog=HomesliceInsurance_MSCRM;Connection Timeout=60;Integrated Security=SSPI'; update

Bourne Shell Cookbook

Bourne Shell Scripting Cookbook for the masses 1) Numeric for loop #! /bin/bash N = 10 for ( ( c = $N ; c > 0 ; c-- ) ) do echo "Counting $c times" done

Debricking the Western Digital Mybook Live - with a new WD Red Disk

Sometimes it happens, your Western Digital Mybook Live dies and you are left with a blinking blue/green light.  Perhaps it's internal hard disk is making the famous click of death sound.  Rebuild it by purchasing a new 3TB WD Red Drive. Here's how to prepare the new disk, using Ubuntu linux.  I have copied the highlights of the famous debrick script.  Remove the disk from the WD MBL housing, and toss into a landfill or drop into your favourite ocean. Insert new disk in your favourite desktop PC's SATA port, boot with Ubuntu USB drive, and then prepare the new WD disk using these steps. You should boot from a Live CD or Live bootable USB, so that your disk is /dev/sda. Assuming that your new disk is /dev/sda parted /dev/sda --align optimal <<EOP mklabel gpt mkpart primary 528M  2576M mkpart primary 2576M 4624M mkpart primary 16M 528M mkpart primary 4624M -1M set 1 raid on set 2 raid on quit EOP sync reboot  ... mdadm --create /dev/md0 --verbose --metadata=0.

The WMI Cookbook

WMI Filters to Select Computers to which to apply group policy: Target Win 7 32 bit machines: select * from Win32_OperatingSystem WHERE Version like "6.1%" AND ProductType="1" AND NOT OSArchitecture = "64-bit" Target Win 7 64Bit machines: select * from Win32_OperatingSystem WHERE Version like "6.1%" AND ProductType="1" AND OSArchitecture = "64-bit" Target any 32 bit OS; SELECT AddressWidth FROM Win32_Processor WHERE AddressWidth ='32' Target any 64Bit OS: SELECT AddressWidth FROM Win32_Processor WHERE AddressWidth ='64'