Procedures here:

For Lync 2013: http://technet.microsoft.com/en-us/library/gg412729.aspx

For Exchange 2013:

http://social.technet.microsoft.com/wiki/contents/articles/30540.exchange-2013-cu8-upgrade.aspx

http://technet.microsoft.com/en-us/library/bb125224(v=exchg.150).aspx

Script for exchange:

@echo off
cls
echo Exchange 2013 forest preparation – 2015
echo ————————————————
echo.
echo prereq: be sure you have set powershell execution policy to unrestricted (KB981474)
echo.
echo Run this script from the SCHEMA MASTER server
echo and use a credential member of Amaiislab Enterprise admins+domain admins+schema admins groups
echo.
echo AD replication status:
echo ———————-
repadmin /replsummary
echo.
echo ************************************************************
echo.
echo From the command prompt prepare the Active Directory Schema…
echo Do you want continue?
pause
.\setup.exe /PrepareSchema /IAcceptExchangeServerLicenseTerms
echo.
echo ************************************************************
echo.
echo From the commmand prompt prepare the forest AD objects and permissions…
echo Do you want continue?
pause
.\setup.exe /PrepareAD /ActiveDirectorySplitPermissions:false /OrganizationName:MYORGEXCHANGE /IAcceptExchangeServerLicenseTerms

echo.

echo ************************************************************
echo.
echo From the command prompt prepare the domain AD objects and permissions…
echo Do you want continue?
pause
.\setup.exe /PrepareDomain /IAcceptExchangeServerLicenseTerms
echo ************************************************************
echo.
echo Force AD replication status:
echo —————————-
repadmin /syncall
echo.
echo Check AD replication status:
echo —————————-
repadmin /showreps
echo.
echo ************* END of PREP phase *************
goto end
:end