Websites of friends

Archive for the 'Scripts' Category

As a continuation of the previous posts we will discuss how to manage printers remotely prnmngr.vbs from the command line.

The script we use is prnmgr.vbs found in% windir% system32 in windows XP and 2003 and% windir% system32printing_admin_scriptsEs-is on Windows / and 2008. In the next picture we see the different command options

Today I needed to know what was the disk usage of multiple remote servers to a study of performance and provide a tailored solution to a customer who wants to virtualize your physical server environment.

Performing the query using powershell get have never had to connect to each server and get a quick and accurate results. This way we can adjust more disk consumption of future migrated server.

As you can see in order to make the query I used powershell and the command get-wmiobject along with the class win32_LogicalDisk, I also used some switches to show us the records we'd mapped network drives or cd-rom (since we do not want to know this information).

The specific value of disk usage that I know I can not refer directly and I had to do a subtraction between the value size and value FreeSpace.

Today I needed RAM usage detect multiple remote servers to a study of performance and provide a tailored solution to a customer who wants to virtualize your physical server environment.

To make the query I used powershell and the command get-wmiobject along with the class win32_operatingsystem, de esta forma no necesitamos acceder remotamente a los servidores a los que les queremos detectar el uso de RAM.

El valor concreto del uso de RAM que yo sepa no lo puedo conseguir directamente y he tenido que hacer una resta entre el valor TotalVisibleMemorySize and value FreePhysicalMemory. As you all know the use of ram is not stable so if you want to do a study properly, you will have to check this value at various times of the day and do half for example.

PS: All this would not have been possible without the invaluable help of one of the best guys Scripting the moment .. Those who follow the blog already know, I do not need to put your name as you would most like to live in anonymity until further notice .. hehe ..

Greetings and see you soon and of course if any of you know how to improve the script, or has to detect the exact query RAM usage without making strange calculations in the script, please post it as a comment and so may see the whole community.

Always good people to comment and contribute knowledge and remember always constructive criticism .. At least for me.

Today we show you a script to clear space on C: \ patch removing directories.

As we all know Windows patches occupy a stretch of space and sometimes we need to release it as drive C: \ server too fair.

Today's article is at least somewhat resolved this issue by automating the removal of temporary directories annoying Windows Update has left for later reversed if a patch has caused a server crash ... but few times have you done this?, how many times you have dared to uninstall a patch you have just installed? ..

Well, for those who have never had to uninstall a patch and for those looking for free space on the servers I pass the following script that can automate to run once a month for example and free up the space that you have Windows patches removed ...

I pass a script to free up space in C: \ patch removing directories.

Directories that we are removing are:

· Content: Ie7updates located in % Windir%

· Content: Ie8updates located in % Windir%

· All Folders $ located in % Windir%

The script DeletePatchesDirectories.cmd shall be placed in a network path accessible by all users or at least accessible to the user you're going to run it remotely: