by skufel | Sep 30, 2014 | Databases, Scripting, Windows
When you try to connect to SQL Server from PowerShell script and you get following message: Unable to find type [Microsoft.SqlServer.Management.Smo.Server] then you have to download and install following components: Microsoft System CLR Types for SQL Server 2008...
by skufel | Mar 29, 2014 | Infrastructure, Scripting, Security, SysAdmin, Windows
Sometimes when you start machine with BitLocker enabled and same time some storage device was connected to USB port, BitLocker might request Recovery Key. This happens because USB ports is listed on boot device search list. To avoid this type of event best idea is to...
by skufel | Jan 3, 2014 | Infrastructure, Scripting, SysAdmin, Windows
As there is no GUI in Windows Server 2012 Core, we have to use command line and script in order to acivate system. slmgr.vbs is a VBscript which allows to set product key and activate operating system. Below most common use of slmgr.vbs. Set product key slmgr.vbs /ipk...
by skufel | Jan 3, 2014 | Infrastructure, Scripting, SysAdmin, Windows
By default remote management on Windows Server 2012 Core can be blocked by firewall. In order to enable this functionality, issue following command from Command Prompt window: Netsh.exe firewall set service remoteadmin enable ALL Once it’s done you should be...
by skufel | Dec 5, 2013 | Automation, Infrastructure, Scripting, Windows
Some handy wmic commands which might be helpful when automating OS deployment: wmic bios get serialnumber wmic computersystem get manufacturer wmic computersystem get model
by skufel | Oct 24, 2013 | Automation, Infrastructure, Scripting, SysAdmin, Windows
Handful list of parameters possible to use in CMD scripts: %~I - expands %I removing any surrounding quotes ("") %~fI - expands %I to a fully qualified path name %~dI - expands %I to a drive letter only %~pI - expands %I to a...