Welcome guest. Before posting on our computer help forum, you must register. Click here it's easy and free.

Author Topic: Machine Spec. help.  (Read 5339 times)

0 Members and 1 Guest are viewing this topic.

diarmuid

    Topic Starter


    Starter

    Machine Spec. help.
    « on: August 25, 2008, 03:10:59 AM »
    I have been tasked with obtaining some information about the PC's in my building.  i have 100 pc's and i wish to determine the following.

    1. The RAM
    2. The processer, type, make etc.
    3. the machine identifiaction code.

    I was hoping to write a bat/cmd file etc. and e-mail a link of the file to the users in question and ge them to run the file and send a report back to me.

    Can this be done?

    Regards

    Diarmuid

    jamesj2001



      Beginner

      Thanked: 1
      Re: Machine Spec. help.
      « Reply #1 on: August 25, 2008, 06:03:33 AM »
      I think it would be less work just to write them an email telling them to hit windows+pause/break and tell you what they see.

      Carbon Dudeoxide

      • Global Moderator

      • Mastermind
      • Thanked: 169
        • Yes
        • Yes
        • Yes
      • Certifications: List
      • Experience: Guru
      • OS: Mac OS
      Re: Machine Spec. help.
      « Reply #2 on: August 25, 2008, 07:19:34 AM »
      Quote
      I have been tasked with obtaining some information about the PC's in my building. 
      Hmmm....What Building?

      diarmuid

        Topic Starter


        Starter

        Re: Machine Spec. help.
        « Reply #3 on: August 25, 2008, 10:02:48 AM »
        lol,  sounds a bit dodgy.   ;)

        Basically, i'm a CAD manager and i am trying to asses what my mchine specs are for my cad operators, as i may need to upgrade some of them.  Just trying to get a feel for what i have.

        FYI.  here is a batch file a student here figured out for me.  There is a start up batch for each user i will just call up the batch tomorrow, and assuming you log off tonight your'll be picked up.  I will hope to tell the batch to write to a location on the network.

        Thanks for the help though.

        Diarmuid


        *******************

        @ECHO OFF

        systeminfo.exe > temp.txt

        @ECHO OFF
        find "Host Name:"  < temp.txt> %ComputerName%.txt
        find "Processor(s):"  < temp.txt>> %ComputerName%.txt
        find "Total Physical Memory:" < temp.txt>> %ComputerName%.txt
        find "Virtual Memory:"  < temp.txt>> %ComputerName%.txt
        find "Domain:"  < temp.txt>> %ComputerName%.txt
        find "Logon Server:" < temp.txt>> %ComputerName%.txt

        @ECHO OFF
        del temp.txt

        cls

        fyrye

        • Guest
        Re: Machine Spec. help.
        « Reply #4 on: August 28, 2008, 01:47:43 PM »
        I do the same thing but have the luxury of being able to be in windows XP to be able to quality control the systems.
        I started out with BAT and moved on to scripts that can pull information directly from the windows API with out having to parse info or call on other windows programs using start/call etc.
        Though I do have some machines that do not have an OS installed, I check the BIOS for time date ram/cpu etc

        But to give you the degree of quality control we require, I have to check every aspect of the system from
        • HD/DVD-RW/FDD model number,
        • Ram size,
        • CPU speed,
        • BIOS revision,
        • windows version,
        • change windows product key code,
        • activate windows,
        • the time and date,
        • test burn a "CD",
        • test write a floppy,
        • test com1 and com2, LPT 1,
        • check HD filesystem type and size,
        • disable automatic updates,
        • change file sharing on a folder and set permission access to everyone,
        • setup a secondary partition and format it as NTFS,
        • check Intranet access via PING,
        • change another folder to not read only,
        • empty the recycle bin,
        • check device manager for ANY errors,
        • test USB ports,
        • deactivate windows,
        • as well as create a new SID as we use a single image to create thousands of these machines a year, each costing about $1,200 US
        It took roughly 30-45mins to do this manually and some steps were usually skipped either from forgetfulness or time crunches. I wrote a DOS file to help out with the CD burn test, ping test, and port test calling on a saved hyperterminal template to test com1 and then com2. which saved us about 5 mins per machine.
        I later wrote a complete WScript File (.wsf) to be able to do all of these cutting QC time down to 5 mins, All the tech has to do manually now, is check the screws are in the right places...

        Here's a javascript example
        Copy paste it in Notepad rename it as Spec.js
        The code can be setup to run remotely, or sent back to you as txt file etc. Pretty much anything you can do on your PC  you can access it via script, simply search google for msdn WMI tasks

        Code: [Select]
        var wbemFlagReturnImmediately=0x10;
        var wbemFlagForwardOnly=0x20;
        var jsCrLf=String.fromCharCode(13, 10);
        var jsQuote=String.fromCharCode(34);

        //Windows Management Interface
        function wmiCon(strComp){
        try{
        var objWMIService = GetObject( "winmgmts://"+ strComp +"/root/cimv2" );
        }
        catch(error){
        var strMsg = jsCrLf + "WMI Connection Error # " + error + jsCrLf;
        WScript.Echo(strMsg);
        WScript.Quit(0);
        }
        return objWMIService;
        }

        function wmiSQL(wmiBase){
        var objWMIService = wmiCon(".");
        try{
        var colItems = objWMIService.ExecQuery( "SELECT * FROM Win32_" + wmiBase, "WQL", wbemFlagReturnImmediately | wbemFlagForwardOnly ); //query
        }
        catch(error){
        var strMsg = jsCrLf + "WMI Query Error # " + error + jsCrLf;
        WScript.Echo(strMsg);
        WScript.Quit(0);
        }
        objWMIService.close;
        return colItems;
        }

        var strMemTotal,strHostName,strDomain,strCpuCount, strCPUSpeed = "", strToAdd = ""
        var colItems = wmiSQL("Processor");
        var enumItems = new Enumerator(colItems);
        for (x=0 ; !enumItems.atEnd(); enumItems.moveNext()) {
        var objItem = enumItems.item();
        if (x >= 1){strToAdd = ", " + x + ") "}
        else{strToAdd = String(x + ") ")}
        strCPUSpeed += strToAdd + objItem.MaxClockSpeed(x) + " MHz";
        x++;
        }

        var colItems = wmiSQL("ComputerSystem");
        var enumItems = new Enumerator(colItems);
        for (x=0 ; !enumItems.atEnd(); enumItems.moveNext()){
        objItem = enumItems.item();
        strMemTotal = objItem.TotalPhysicalMemory;
        strHostName = objItem.Name;
        strDomain = objItem.Domain;
        strCpuCount = objItem.NumberOfProcessors;
        x++;
        }
        strMemTotal = strMemTotal / 1048576;
        strMemTotal = Math.round(strMemTotal);

        var strSaveto = "C:\\" + strHostName + ".txt"
        var strSysInfo = "HostName: " + strHostName
        + "\nDomain: " + strDomain
        + "\nCPU Count: " + strCpuCount
        + "\nCPU Speed: " + strCPUSpeed
        + "\nMemory: " + strMemTotal + " MBs";

        WScript.Echo(strSysInfo + "\n\nResults Saved to " + strSaveto);

        var fso, f
        var ForReading=1, ForWritting=2, ForAppending=8;
        fso = new ActiveXObject("Scripting.FileSystemObject");
        f = fso.OpenTextFile(strSaveto, ForWritting, true);
        var strToReplace = /\n/g;  //g - global, i - case insensitive, m - multiline search
        strSysInfo = strSysInfo.replace(strToReplace, jsCrLf);
        f.write(strSysInfo);
        f.close();
        fso.close;
        « Last Edit: August 28, 2008, 03:24:15 PM by fyrye »