Hi Jpa-
1.
Ran against Accounting - however - please understand that any machine I run with audit_windows works fine.
############################################################
Y:\>cscript //nologo audit_windows.vbs accounting ldap="LDAP://Auxiant.local"
starting audit - accounting
Not pinging target, attempting to audit.
My PID is : 4928
Audit Start Time : 2012-10-03 14:10:27
Audit Location: remote
-------------------
system info
windows info
User data is null for physicalDeliveryOfficeName
User data is null for company
Windows User: administrator@auxiant
bios info
scsi info
processor info
memory info
motherboard info
optical info
modem info
video info
monitor info
sound info
disk info
partition info
mount point info
shares info
network card info
network address info
DNS info
printer info
Port: IP_192.168.10.142
IP:
First attempt to detect if PortName matches an IP address
0 Resulting IP is
Not a valid IP address so far. Using PortName.
1 Resulting IP is 192.168.10.142
IP: 192.168.10.142
Status: OK
RegKey: Software\Microsoft\Windows NT\CurrentVersion\Print\Printers\Mailroom\DsDriver\
Colour: 0
Duplex: 1
Printer: SAVIN 4051 -- IP_192.168.10.142 -- 192.168.10.142 -- OK
Port: CRDPTR::192.168.10.24
IP:
First attempt to detect if PortName matches an IP address
0 Resulting IP is
Not a valid IP address so far. Using PortName.
1 Resulting IP is
Assuming printer is attached by network to a hostname, not an IP
Printer has a hostname but no IP. Running NSLookup
2 Resulting IP is
Status:
RegKey: Software\Microsoft\Windows NT\CurrentVersion\Print\Printers\IDCard\DsDriver\
Colour: 1
Duplex: 1
Printer: DTC550 Card Printer -- CRDPTR::192.168.10.24 -- --
Port: IP_192.168.10.127
IP:
First attempt to detect if PortName matches an IP address
0 Resulting IP is
Not a valid IP address so far. Using PortName.
1 Resulting IP is 192.168.10.127
IP: 192.168.10.127
Status: OK
RegKey: Software\Microsoft\Windows NT\CurrentVersion\Print\Printers\Claims\DsDriver\
Colour: 0
Duplex: 1
Printer: Canon iR5070e -- IP_192.168.10.127 -- 192.168.10.127 -- OK
Port: IP_192.168.10.16
IP:
First attempt to detect if PortName matches an IP address
0 Resulting IP is
Not a valid IP address so far. Using PortName.
1 Resulting IP is 192.168.10.16
IP: 192.168.10.16
Status: OK
RegKey: Software\Microsoft\Windows NT\CurrentVersion\Print\Printers\CDR_MKT_Color\DsDriver\
Colour: 1
Duplex: 1
Printer: HP Color LaserJet 4700 -- IP_192.168.10.16 -- 192.168.10.16 -- OK
Port: IP_192.168.10.17
IP:
First attempt to detect if PortName matches an IP address
0 Resulting IP is
Not a valid IP address so far. Using PortName.
1 Resulting IP is 192.168.10.17
IP: 192.168.10.17
Status: OK
RegKey: Software\Microsoft\Windows NT\CurrentVersion\Print\Printers\CDR_Marketing_BLK\DsDriver\
Colour: 0
Duplex: 1
Printer: Canon iR2200-3300e -- IP_192.168.10.17 -- 192.168.10.17 -- OK
Port: CDR_HRA_HP4250
IP:
First attempt to detect if PortName matches an IP address
0 Resulting IP is
Not a valid IP address so far. Using PortName.
1 Resulting IP is
Assuming printer is attached by network to a hostname, not an IP
Printer has a hostname but no IP. Running NSLookup
2 Resulting IP is
Status:
RegKey: Software\Microsoft\Windows NT\CurrentVersion\Print\Printers\CDR_HRA_HP4250\DsDriver\
Colour: 0
Duplex: 0
Printer: HP LaserJet 4250 -- CDR_HRA_HP4250 -- --
Port: IP_192.168.10.50
IP:
First attempt to detect if PortName matches an IP address
0 Resulting IP is
Not a valid IP address so far. Using PortName.
1 Resulting IP is 192.168.10.50
IP: 192.168.10.50
Status: OK
RegKey: Software\Microsoft\Windows NT\CurrentVersion\Print\Printers\Accounting\DsDriver\
Colour: 1
Duplex: 1
Printer: SAVIN 2535/2235 -- IP_192.168.10.50 -- 192.168.10.50 -- OK
scheduled tasks
environment variables
logs
pagefile
local users info
local groups info
Codec info
ODBC Driver info
MDAC info
DirectX info
Windows Media Player info
Internet Explorer info
Outlook Express info
Software info
Services info
mssqlserver
SQL info
SQL Express: n
SQL Server: y
DB Version: 8.00.2039
DB Edition: Developer Edition
DB Login Type: Allow Windows Authentication or SQL Server Authentication
DB Port: 1433
DB Type: SQL Server
SQL State: Running
Which Instance: MSSQLSERVER
Provider=SQLOLEDB;Integrated Security=SSPI;Persist Security Info=False;Data Source=accounting;DATABA
SE=master
DB Instance: MSSQLSERVER
DB Count: 9
DB Name: AuxiantFlex
DB Name: AuxiantFlex_backup
DB Name: helpdesk
DB Name: master
DB Name: model
DB Name: msdb
DB Name: Northwind
DB Name: pubs
DB Name: tempdb
IIS 6 Installed
CD Keys
network routing info
Audit Generated in 770 seconds.
Submitting audit online
Audit Submitted
Response
--------
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en"><meta http-equiv=
"Content-type" content="text/html; charset=utf-8" />
<head>
<title>XHTML-document</title>
</head>
<body>
<a href='http://mdnoav2/index.php/system'>Back to input page</a><br />
<a href='http://mdnoav2/index.php'>Front Page</a><br />
System Key: 4C4C4544-0052-3310-804E-B4C04F433531-accounting<br />
Exist Type: bulk<br />
System id: 49<br />
<b>Update</b><br />
<div style="border:1px solid #990000;padding-left:20px;margin:0 0 10px 0;">
<h4>A PHP Error was encountered</h4>
<p>Severity: Notice</p>
<p>Message: Undefined variable: snmp_manufacturer</p>
<p>Filename: models/m_printer.php</p>
<p>Line Number: 142</p>
</div><div style="border:1px solid #990000;padding-left:20px;margin:0 0 10px 0;">
<h4>A PHP Error was encountered</h4>
<p>Severity: Notice</p>
<p>Message: Undefined variable: snmp_model</p>
<p>Filename: models/m_printer.php</p>
<p>Line Number: 150</p>
</div><div style="border:1px solid #990000;padding-left:20px;margin:0 0 10px 0;">
<h4>A PHP Error was encountered</h4>
<p>Severity: Notice</p>
<p>Message: Undefined variable: snmp_manufacturer</p>
<p>Filename: models/m_printer.php</p>
<p>Line Number: 142</p>
</div><div style="border:1px solid #990000;padding-left:20px;margin:0 0 10px 0;">
<h4>A PHP Error was encountered</h4>
<p>Severity: Notice</p>
<p>Message: Undefined variable: snmp_model</p>
<p>Filename: models/m_printer.php</p>
<p>Line Number: 150</p>
</div><div style="border:1px solid #990000;padding-left:20px;margin:0 0 10px 0;">
<h4>A PHP Error was encountered</h4>
<p>Severity: Notice</p>
<p>Message: Undefined variable: snmp_manufacturer</p>
<p>Filename: models/m_printer.php</p>
<p>Line Number: 142</p>
</div><div style="border:1px solid #990000;padding-left:20px;margin:0 0 10px 0;">
<h4>A PHP Error was encountered</h4>
<p>Severity: Notice</p>
<p>Message: Undefined variable: snmp_model</p>
<p>Filename: models/m_printer.php</p>
<p>Line Number: 150</p>
</div><div style="border:1px solid #990000;padding-left:20px;margin:0 0 10px 0;">
<h4>A PHP Error was encountered</h4>
<p>Severity: Notice</p>
<p>Message: Undefined variable: snmp_manufacturer</p>
<p>Filename: models/m_printer.php</p>
<p>Line Number: 142</p>
</div><div style="border:1px solid #990000;padding-left:20px;margin:0 0 10px 0;">
<h4>A PHP Error was encountered</h4>
<p>Severity: Notice</p>
<p>Message: Undefined variable: snmp_model</p>
<p>Filename: models/m_printer.php</p>
<p>Line Number: 150</p>
</div><div style="border:1px solid #990000;padding-left:20px;margin:0 0 10px 0;">
<h4>A PHP Error was encountered</h4>
<p>Severity: Notice</p>
<p>Message: Undefined variable: snmp_manufacturer</p>
<p>Filename: models/m_printer.php</p>
<p>Line Number: 142</p>
</div><div style="border:1px solid #990000;padding-left:20px;margin:0 0 10px 0;">
<h4>A PHP Error was encountered</h4>
<p>Severity: Notice</p>
<p>Message: Undefined variable: snmp_model</p>
<p>Filename: models/m_printer.php</p>
<p>Line Number: 150</p>
</div>Time: seconds.</body>
</html>
Total Execution Time: 775 seconds.
############################################
2.
Slowly adding some cryptic debugging/logging to the "audit_domain" script to see what could be happening...
Y:\>cscript //nologo audit_domain.vbs ldap="LDAP://Auxiant.local" >> C:\Software\OAv2\Logs\audit_domain.txt
3.
Starts out fine...
Now Auditing:
LDAP://dc=Auxiant,dc=localselect name, location, operatingSystem, lastLogon from 'LDAP://dc=Auxiant,dc=local' where objectclass='computer'
number of systems retrieved from ldap: 241
number of filtered systems: 234
--------------
Have list of PC's from AD-LDAP
0 of 234
processes running: 1
next system: 2V87W61
....
233 of 234
processes running: 2
next system: WINXPTEST
--------------
4.
Echo - finished loop here --> "End of Loop - what happened"?
if audit_run_type = "local" then
wscript.echo(run_type)
for i = 0 to ubound(pc_array)
while num_running > number_of_audits
wscript.echo("processes running (" & num_running & ") greater than number wanted (" & number_of_audits & ")")
wscript.echo("therefore - sleeping for 4 seconds.")
wscript.sleep 4000
num_running = HowMany
wend
if pc_array(i) <> "" then
wscript.echo(i & " of " & ubound(pc_array))
wscript.echo("processes running: " & num_running)
wscript.echo("next system: " & pc_array(i))
wscript.echo("--------------")
command1 = "cscript //nologo """ & script_name & """ " & pc_array(i) & " ldap=""" & local_domain & """ "
set sh1=wscript.createobject("wscript.shell")
sh1.run command1, 6, false
set sh1 = nothing
num_running = HowMany
end if
next
end if
--> wscript.echo("End of Loop - what happened?")
5.
"Made it to checking how many cscripts are running" echo line - end of script...
--> wscript.echo("Made it to checking how many cscripts are running...")
Function HowMany()
Dim Proc1,Proc2,Proc3
Set Proc1 = GetObject("winmgmts:{impersonationLevel=impersonate}!\\.\root\cimv2")
Set Proc2 = Proc1.ExecQuery("select * from win32_process" )
HowMany=0
For Each Proc3 in Proc2
If LCase(Proc3.Caption) = "cscript.exe" Then
HowMany=HowMany + 1
End If
Next
End Function
6.
Will work on adding more debugging - need to see what some of the values of vars set -Ex: run_type" and pc_array, domain_array, etc.
Other ideas I can try?
Thx.
-SP