Powershell to check Last Reboot on a Windows Server

Not sure I will ever need to use this again, but needed a way to check who last rebooted a server. We used this code: Get-EventLog -logname “system” | where-object {($_.eventid -eq 1074)} | % {if(($_.TimeGenerated).DayOfYear -eq (get-date).DayOfYear){$_.EventID,$_.TimeGenerated,$_.Message}} Note that event ID 1074 gives you if a user requested a… Continue reading

Moving WordPress

This assumes you have created a LAMP server and it is working correctly 1. copy files using ftp client 2. Make Backup of sql (mysqldump -u root -p [databasename] > Backupfile.sql;) 3. on new server – upload files (/var/www/[sitename]) 4. copy sql backup to directory to restore from 5. connect… Continue reading

Meeting Invites to people outside your Exchange Organization

We had an incident where a user was inviting attendees to her meeting using Outlook Scheduling Assistant. She would create a meeting then add all the attendees and send out the invite. Well an attendee would delete that event from their Outlook Calendar and it would in turn send out to… Continue reading

Power Shell Script to Clear and Save Event Logs

This is a work in progress script that will Save and clear event logs. I got this from http://technet.microsoft.com/en-us/magazine/2009.07.heyscriptingguy.aspx In the futre I will be adding code to upload the files to Sharepoint Document Library or List (still thinking of the best way I want to review these). I will… Continue reading