Many times on a Windows Server or PC you will have had multiple users log in at some point in time, and each user account has it’s own Recycling Bin. When getting cramped for free space, it can be handy to empty all Recycling Bin’s at one time, so you do have to, or can’t log into the other accounts:
Windows7, Server2008/R2, Server2012/R2
rd /s c:\$Recycle.Bin
WindowsXP, Vista, Server2003/R2
rd /s c:\recycler
Sometimes servers become unresponsive. You can’t RDP, you can’t get in via console, yet you still want to give them the common courtesy of shutting down gracefully. These commands will allow you to do just that. I would establish a persistent ping to the IP of the server you want to shut down, run the command, grab a beer, give it at least 5 minutes to see if the pings drop off, and come back as the system restarts.
REBOOT REMOTE MACHINE
shutdown -r -m \\SERVERNAME.DOMAIN.LOCAL
FORCE REBOOT REMOTE MACHINE:
shutdown -r -f -m \\SERVERNAME.DOMAIN.LOCAL
If attempting to do this from a PC that is not a member of the same domain/network that you are rebooting, you may need to specify credentials:
net use \\SERVERNAME.DOMAIN.LOCAL
Many times, Open License versions of Office 2010/2013 will install without ever prompting you for a product key, defaulting to the 30 or 60 day trial mode. Couple of quick commands that can tell you what’s up with a user’s Office installation.
1. Determine Your MS Office Configuration
Office 2010 (32bit) – C:\Program Files\Microsoft Office\Office14
Office 2013 (32bit) – C:\Program Files\Microsoft Office\Office15
Office 2010 (32bit) – C:\Program Files (x86)\Microsoft Office\Office14
Office 2010 (64bit) – C:\Program Files\Microsoft Office\Office14
Office 2013 (32bit) – C:\Program Files (x86)\Microsoft Office\Office15
Office 2013 (64bit) – C:\Program Files\Microsoft Office\Office15
2. Check MS Office Activation Status
- Open an administrative level command prompt.
- Change directory to the Office14/Office15 folder:
cd “C:\Program Files\Microsoft Office\Office14”
- Run the query status command:
cscript ospp.vbs /dstatus
- The license name and/or license description gives the license type for Office, while license status shows activation status of Office 2010.
3. Input Activation Key
cscript ospp.vbs /inpkey:XXXXX-XXXXX-XXXXX-XXXXX-XXXXX
4. Force Key Activation With Microsoft
cscript ospp.vbs /act
5. Grab a beer.