Thursday, April 10, 2014

Office 2013 tweaks

Keep office from trying to connect to the internet with this registry key:

HKEY_CURRENT_USER\Software\Microsoft\Office\15.0\Common\Internet\useOnlineContent

Set Dword to 0

Have Office go directly to a document screen and pass the annoying startup page:
HKEY_CURRENT_USER\Software\MicrosoftOffice\15.0\ommon\General
Create a DWord of DisableBootToOfficeStart
Set DWord to 1

Friday, February 7, 2014

If you move mailboxes and they don't remove here is a cleanup command

set the keep deleted mailbox retention period to 0, run clean-mailboxdatabase "databasename" to remove the disconnected mailboxes. 

Monday, January 6, 2014

Clear log files for exchange if your out of disk space

Dismount any databases, or if the database won't mount because the disk is full.  If the database won't mount, check and make sure it is in a clean shutdown state:

eseutil /MH "Database Location and Name"

Make sure it reports "clean shutdown" or "consistent"

MOVE the log files to somewhere you have space and remount the database.

Friday, January 3, 2014

Users redirectored folders show as My Documents in the folders

If you are redirecting folders to a server share and the folders all show as "My Documents" this could be due to the desktop.ini in the root of the users folder.  If the administrators or domain admin group has full control, set them to deny read.  Make sure the user is the owner of the folder as well.

Friday, December 27, 2013

Use PSEXEC to run a command against a list of machines and have it run a command from the machine

Start by creating a list of computers that need the command run on them (pclist.txt.).  Use the file copy command for /f %a in (pclist.txt) do copy /y \\server\share\file.bat \\%a\c$\ to copy the files to the machines in the pclist.txt.  In this example the file is copied to the root.  Next, from an elevated command prompt run:
psexec @pclist.txt c:\file.bat

This will execute the batch or exe file you copied to the remote machine on the remote machine. 
If you need to authenticate run:
psexec @pclist.txt -u domain\user c:\file.bat and it will prompt for a password.



copy files to multiple remote computers

To copy a file to multiple computers first create a txt file with all the computer names in it.  Place the file you want to copy in an accessible location for all the machines.  Run the following command:

for /f %a in (pclist.txt) do copy /y \\server\share\file.txt \\%a\c$\

This "should" copy the file to the machines listed assuming you have remote access.

Thursday, December 19, 2013

Exchange dynamic distribution groups based on security groups.

To create an exchange dynamic distribution group based on security group this can be done through powershell. The command specifies where to create the dynamic distribution group and what group the users will be a member of to pull the addresses from. The group name is “Dyn_universal” the security group is dyn_test, so any user in the OU test that is a member of dyn_test will get mail sent to the distribution group. New-DynamicDistributionGroup "Dyn_universal" -Alias "Dyn_universal" -OrganizationalUnit "OU=Test,DC=mydomain,DC=local" -RecipientFilter "MemberOfGroup -eq 'CN=dyn_test,OU=test,DC=mydomain,DC=local'"