change windows 2012 to core mode

downloadFound yourself considering hyper-v? Microsoft has come a long way and is now becoming more popular as a serious contender in the hypervisor area. My preference is still VMware, but some businesses may find their Microsoft allegiance makes hyper-v a valid option.

Note, i do not consider Microsoft a “cheaper” solution in any circumstance. The current state of hyper-v, SDN options, clustering and VMM management falls very short of what VMware has out of the box. Anyhow, if you do choose windows, here is how you remove the GUI – hopefully saving you a little bit of RAM and reducing the running footprint open for attacks and vulnerabilities….

 

 

Powershell commands to convert between the following windows modes;

Full Server -> Server Core with GUI Management (Minimal Server Interface)

Uninstall-WindowsFeature Server-Gui-Shell -Restart

Full Server -> Server Core

Uninstall-Windowsfeature Server-Gui-Mgmt-Infra -Restart

Uninstall-WindowsFeature Server-Gui-Shell -Restart

Server Core -> Full Server

Install-WindowsFeature Server-Gui-Shell -Restart

Server Core with GUI Management (Minimal Server Interface) -> Full Server

Install-WindowsFeature Server-Gui-Shell -Restart

Note : always use windows firewall. If possible also consider AV solution to further protect your hosts.

SQL Server Setup – Error code 0x84B30002

SQL Server Setup has encountered the following error:
No feature were uninstalled during the setup execution. The requested features may not be installed. Please review the summary.txt logs for further details.

Error code 0x84B30002.

Follow the below steps it may help to uninstall, Before follow this procedure please make sure you have some idea about registry

1. Open Registry Editor
2. Navigate to HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\
3. Browse Ids one by one and identify the GUIDs for SQL Server 2008
4. Run the below command for all SQL Server 2008 Guids one by one

msiexec /x “GUID”

SQL Express – Backup Plan

SQL express doesn’t have the luxury of SQL maintenance plans, but you can still write a SQL script to dump a database to a particular location and run it via task scheduler on a daily basis.

Create SQL query and save it to a particular location… (NightlyBackup.sql)

DECLARE @pathName NVARCHAR(512)

SET @pathName = ‘D:\SQL Backup\database_‘ + Convert(varchar(8), GETDATE(), 112) + ‘.bak’

BACKUP DATABASE [database] TO DISK = @pathName WITH NOFORMAT, NOINIT, NAME = N’db_backup’, SKIP, NOREWIND, NOUNLOAD, STATS = 10

Create cmd / bat and save to similar location to above… (Backup DB to disk.cmd)

sqlcmd -S servername\INSTANCENAME -U sqluser -P sqluserpassword -i “NightlyBackup.sql”

forfiles /p “C:\SQLBackupLocation” /m *.bak /s /d -2 /c “cmd /c del @file : date >= 7 days >NUL”

Create windows task schedule event to run above at 5:30pm everyday. 

activate windows from command line – slmgr

Temporarily extend evaluation period (limited execution – see output below)…

C:\Windows\System32>cscript slmgr.vbs /rearm

C:\Windows\System32>shutdown -r -t 1

Show detailed license information…

C:\Windows\System32>cscript slmgr.vbs /dlv

License Status: Initial grace period
Time remaining: 43200 minute(s) (30 day(s))
Remaining Windows rearm count: 0

Activate windows…

C:\Windows\System32>cscript slmgr.vbs /ipk xxxxx-xxxxx-xxxxx-xxxxx-xxxxx

C:\Windows\System32>cscript slmgr.vbs /ato

Will require access to the internet – most of the time the issues are either time sync or connectivity to internet.

http://support.microsoft.com/kb/921471 Windows activation fails and may generate error code 0x8004FE33

To do this, configure the following list of CRLs to be unauthenticated on the proxy server:
http://go.microsoft.com/
https://sls.microsoft.com/
https://sls.microsoft.com:443
http://crl.microsoft.com/pki/crl/products/MicrosoftRootAuthority.crl
http://crl.microsoft.com/pki/crl/products/MicrosoftProductSecureCommunications.crl
http://www.microsoft.com/pki/crl/products/MicrosoftProductSecureCommunications.crl
http://crl.microsoft.com/pki/crl/products/MicrosoftProductSecureServer.crl
http://www.microsoft.com/pki/crl/products/MicrosoftProductSecureServer.crl
https://activation.sls.microsoft.com