• We’re currently investigating an issue related to the forum theme and styling that is impacting page layout and visual formatting. The problem has been identified, and we are actively working on a resolution. There is no impact to user data or functionality, this is strictly a front-end display issue. We’ll post an update once the fix has been deployed. Thanks for your patience while we get this sorted.

Attn: Shux, bot, or anyone else with registry and/or scripting knowledge

IndyJaws

Golden Member
I just checked out the offending machine that caused the problems I detailed in the Minor Bad News thread. As it turns out, that PC only had 32 MB of RAM, so a slowdown was very probable. I have a suspicion that there are other machines in the farm that also have 32 MB as well, so I'd like to take them out as a preventative (or proactive, as we like to say in IT 😉 ) measure.

Does the registry contain any information regarding the amount of RAM in the PC? Or, is there another command that could be run in a script using the full list of PC names in the domain that would report the amount of RAM in each one? I already have the .txt document from the NET VIEW command.

This might help getting the farm back up and running a bit better. 🙂 It would also drop my average CPU time from 13+ hours! 😉

Thanks in advance!
 


<< I just checked out the offending machine that caused the problems I detailed in the Minor Bad News thread. As it turns out, that PC only had 32 MB of RAM, so a slowdown was very probable. I have a suspicion that there are other machines in the farm that also have 32 MB as well, so I'd like to take them out as a preventative (or proactive, as we like to say in IT 😉 ) measure.

Does the registry contain any information regarding the amount of RAM in the PC? Or, is there another command that could be run in a script using the full list of PC names in the domain that would report the amount of RAM in each one? I already have the .txt document from the NET VIEW command.

This might help getting the farm back up and running a bit better. 🙂 It would also drop my average CPU time from 13+ hours! 😉

Thanks in advance!
>>



of course the registery contains such info 🙂. but...its just a tad easier scripting wise to poll the machine as thats a function of the OS and is easily done. the tricky part (for me atleast) is getting the info back, and polling a network...hehehe :Q
 
I can see about coming up with a batch to do that, I dont think it'll make it into the FlexInstaller though.













SHUX
 
I have looked into this earlier, as well as checking on HD space. It IS easier on a local machine to use an enviroment variable, but on a networked machine, it would be easier to pull it from within the registry. I havent went so far as to find the key, but like Narzy said, I am sure it is in there. In the future, I envision disabling some machines from being moved to the install list, having them greyed out, and giving a tool tip that explains why.

Bot
 


<< In the future, I envision disabling some machines from being moved to the install list, having them greyed out, and giving a tool tip that explains why. Bot >>



That's an excellent idea. It could prevent possible problems before they started. 🙂
 
DSLR Team Member to the Rescue?

IndyJaws, it looks like the registry location you are looking for is:

HKLM\Hardware\ResourceMap\System Resources\Physical Memory

It is binary, though and will probably not be much use.

In the past, I've done software distributions with SMS installer. It has a command in there to get system memory. If you have access to the software, I highly recommend it. I'll dig around a little and see if I can find additional information for you. Doubt it, though.
 


<< HKLM\Hardware\ResourceMap\System Resources\Physical Memory >>



Is what I was talking about earlier, it isn't the best of ways to get the info. Most tools measure the "used" or "avaliable" mamory but not a clear definable total amount of memory over the LAN.









SHUX
 
There is the good 'ol mem command. The problem is running it on my machine shows about 96MB of memory when I have about 384MBs. Not sure if it takes the swap space into the calculation, either.

I think a third party tools is needed here. If you can netmeeting into the machine it wouldn't be a problem. Just take a look at the properties.
 
Yeah I tried MEM, but it isnt to good over the LAN either and only gives you used or available:

Displays the amount of used and free memory in your system.

MEM [/PROGRAM | /DEBUG | /CLASSIFY]

/PROGRAM or /P Displays status of programs currently loaded in memory.
/DEBUG or /D Displays status of programs, internal drivers, and other
information.
/CLASSIFY or /C Classifies programs by memory usage. Lists the size of
programs, provides a summary of memory in use, and lists
largest memory block available.








SHUX
 
If all I had were admin rights on the workstations, I'd create a batch file and place it on the remote machine. Something like

mem > c:\temp\%computername%.txt

Use the AT service (I think schedule service needs to be running) to execute the batch file at a given time. It would produce something more than what he has right now.

Even better, he could have the batch file map to a network resource, and save the mem results to the network drive. That way, he wouldn't have to revist each machine. Something like:
***BATCH.BAT***

net use v: \\server\share /domain:user password
mem > v:\%computername%.txt
net use v: /del



Then, using the at command:

at \\computername 00:01 c:\temp\batch.bat
 
hmmm...it does look like I spoke too soon on the registry thing. I have purused the registry and havent found a usable key. One of my teachers at school is really good at registry stuff. I will ask him if he is there tommorow. It would be much easier than trying to batch everything out.

Bot
 
I doubt this is useable, but you guys might want to think about using the DLL files from TA IRC's favorite program, Moo.dll.😉 It powers a script that polls the hardware for certain stats, including memory. Considering that it doesn't need to have admin access AFAIK, it might do the trick.
 
I'm bringing this one back in case anyone has figured out a way to do this. If successful, I can add another 40-80 acres to the Farm! 😀
 
Bumping again...

I'd really love if someone could help me out on this one. I could seriously increase production if I could find out which clients had at least 64MB RAM! 🙂
 
I am looking at some tools to do this, I will keep you up to date on what I find. There are some things in the ResKit that have tools "like" that but arent making themselves easy to work with. 😛











SHUX
 
how about psinfo?
would it be possible to parse psinfo's output in a script or something...

-- edit--
About the Physical Memory registry key, the key value is 68 bytes binary data.
If you add the dword at offset 0x38 and the dword at offset 0x40 together it gives you total physical ram.
This was on win2k, i'm not sure if it's the same on earlier NT's or XP.
The key doesn't seem to exist in win9x..
 
offset 38 and 40 gives me 499, my physical ram is 512. offset 38 40 48 and 50 gives me 785, my physical ram INCLUDING page file = 784....hmmm....

Bot
 
I compared 3 systems all running 2000, one is 2000 pro, one is 2000 advanced server and one is 2000 pro evaluation version. it worked like my previous post on all but the evaluation version. I dont know if it is because it is evaluation version or if it is because the other 2 have sp2.

Win2000pro - 512 megs physical ram - 768 megs page file

0000 01 00 00 00 00 00 00 00
0008 00 00 00 00 00 00 00 00
0010 04 00 00 00 03 01 00 00
0018 00 10 00 00 00 00 00 00
0020 00 F0 01 00 03 01 00 00
0028 00 10 02 00 00 00 00 00
0030 00 E0 07 00 03 01 00 00
0038 00 00 10 00 00 00 00 00
0040 00 F0 EF 00 03 01 00 00
0048 00 00 00 01 00 00 00 00
0050 00 00 FF 1E

Win2000server - 512 megs physical ram - 192 megs page file

0000 01 00 00 00 00 00 00 00
0008 00 00 00 00 00 00 00 00
0010 04 00 00 00 03 01 00 00
0018 00 10 00 00 00 00 00 00
0020 00 D0 00 00 03 01 00 00
0028 00 F0 00 00 00 00 00 00
0030 00 00 09 00 03 01 00 00
0038 00 00 10 00 00 00 00 00
0040 00 F0 EF 00 03 01 00 00
0048 00 00 00 01 00 00 00 00
0050 00 00 FF 1E

Win2000 pro evaluation version - 448 megs physical ram - 672 meg page file

0000 01 00 00 00 00 00 00 00
0008 00 00 00 00 00 00 00 00
0010 03 00 00 00 03 01 00 00
0018 00 10 00 00 00 00 00 00
0020 00 E0 09 00 03 01 00 00
0028 00 00 10 00 00 00 00 00
0030 00 F0 EF 00 03 01 00 00
0038 00 00 00 01 00 00 00 00
0040 00 00 00 1B

The evaluation version doesnt have 0048 or 0050

Bot
 
I found out the following:
The binary data is basically a list of memory blocks, of base address and size pairs.
It's structured like this:

bytes 0x00 - 0x0F unknown
dword at 0x10 number of listed blocks

then for each block :

4 bytes 03 01 00 00 unknown
4 bytes (dword) base address
4 bytes 00 00 00 00 unknown
4 bytes (dword) size


Systems with less than 512 MB ram seem to have 3 blocks listed, like your 448 MB system, my 256 MB system and a 32MB system of someone else.
The amount of ram (or close estimate) can be found by taking the base address of the last block and adding the size of that block.
For the sub 512MB systems this seems to add up to exact amount, for 512MB(+) it's a little bit off the mark but still very close.

e.g.
for the first system you listed :
- number of blocks is 4
- last block base address is dword at (number of blocks * 0x10 + 0x08) = 0x48 ==> 0x01000000
- last block size is dword at (number of blocks * 0x10 + 0x10) = 0x50 ===> 0x1EFF0000
- add those two together = 0x1FFF0000 => 511.9 MB

*) This info was pieced together from things found on google and creative guessing, YMMV 🙂
 
Back
Top