Thursday 28 April 2016

Converting existing Windows Server 2012 versions

Converting existing Windows Server 2012 versions

At any time after installing Windows Server 2012, you can run Setup to repair the installation (sometimes called “repair in place”) or, in certain cases, to convert to a different edition.
You can run Setup to perform a “repair in place” on any edition of Windows Server 2012; the result will be the same edition you started with.
For Windows Server 2012 Standard, you can convert the system to Windows Server 2012 Datacenter as follows: From an elevated command prompt, determine the current edition name with the command DISM /online /Get-CurrentEdition. Make note of the edition ID, an abbreviated form of the edition name. Then run DISM /online /Set-Edition:<edition ID> /ProductKey:XXXXX-XXXXX-XXXXX-XXXXX-XXXXX /AcceptEula, providing the edition ID and a retail product key. The server will restart twice.
For Windows Server 2012 Essentials, you can run Setup and convert it to Windows Server 2012 Standard by providing the appropriate retail license key.

Wednesday 20 April 2016

update/patch your vCenter 6.x Appliance using iso and cli

To update/patch your vCenter 6.x Appliance, please follow the below steps:
  1. Download VCSA patch from here.
    How to update or patch vCenter 6 Appliance (VCSA)
    Product Patches - VMware site.
  2. Take a snapshot of VCSA.
  3. Connect downloaded ISO file to the VCSA VM.
  4. Log in to the VCSA via SSH.
  5. Run the following command.
    Command> software-packages install --iso --acceptEulas
  6. Accept EULA and wait till patching/updating will be finished:
    [2015-04-28T15:15:12.118] : Staging software update packages from ISO
    [2015-04-28T15:15:13.118] : ISO mounted successfully
    [2015-04-28 15:15:13,198] : Running pre-stage script.....
    [2015-04-28T15:15:14.118] : Verifying staging area
    [2015-04-28T15:15:14.118] : Validating software update payload
    [2015-04-28T15:15:14.118] : Validation successful
    [2015-04-28 15:15:51,055] : Processing software packages in update payload 36/36
    [2015-04-28T15:16:18.118] : ISO unmounted successfully
    [2015-04-28T15:16:18.118] : (34) packages staged successfully
    [2015-04-28 15:16:18,694] : Running test transaction ....
    [2015-04-28 15:16:24,707] : Running pre-install script.....
    [2015-04-28T15:18:23.118] : Services stopped.
    [2015-04-28 15:18:23,082] : Upgrading software packages ....
    [2015-04-28 15:21:04,355] : Running post-install script.....
    [2015-04-28T15:21:05.118] : Packages upgraded successfully, Reboot is required to complete the installation.
  7. Reboot VCSA by running:
    shutdown reboot -r updating
  8. vCenter Appliance build should be changed
How to update or patch vCenter 6 Appliance (VCSA) - new build
New VCSA build version.

Sunday 17 April 2016

Remove DAG database - powershell

Remove-MailboxDataBaseCopy -Identity "Mailbox Database 0577530383\MB04" -Confirm:$True
Remove-DatabaseAvailabilityGroupServer -MailboxServer MB03 -Identity dag15
Remove-DatabaseAvailabilityGroup -Identity dag15

*Mailbox Database 0577530383 = name of database
*MB04, MB03 = location of server 
*DAG15 = name of dag

Monday 4 April 2016

deny remote desktop web access with active directory

To restrict this, first we need to create a security group in AD. 
Now log into your RD Web Access server and browse to C:\Windows\Web. Right-click the RDWeb folder and choose Properties.
Go to the Security tab and click Edit then Add.

Type the security group name that you just created in AD and hit OK.
Back in the Permissions window, make sure the group is selected, then in the Permissions section (bellow) click the Read & Executebox under the Deny column. Click OK to close all the windows. Choose Yes on the warning messages.
Now, if a user that is part of that security group tries to log in, it will get a deny message. In the future, when you want to restrict someone to log in to RD Web Access just add the account to that security group.