You may be able to use PsExec to retrive the info you are looking for
psexec \\machine ipconfig
You can use the IP address or the name of the box for machine.
Thanks
Mike
On 3/2/06, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
I know that it all made sense to you when you wrote all that. However, I am
very slow and still on my first cup of coffee. So, in slooooooow motion:
Is the "old computer" dead or alive? If dead, is it dead as in just turned
off, or dead as in re-imaged? why is it important that you know its IP addy?
By that, I mean what's the stated end-goal here?
Sincerely,
Dèjì Akómöláfé, MCSE+M MCSA+M MCT
Microsoft MVP - Directory Services
www.readymaids.com - we know IT
www.akomolafe.com
Do you now realize that Today is the Tomorrow you were worried about
Yesterday? -anon
________________________________
From: [EMAIL PROTECTED] on behalf of Rich Milburn
Sent: Thu 3/2/2006 9:33 AM
To: [email protected]
Subject: [ActiveDir] (OT) How to find a computer on same segment but
different ip subnet
Sorry for the OT, but there are a lot of people here with extensive outside
skills and this might be a tricky thing to do (but I don't want to post it on
forumz.hackz.tw)...
I have 2 computers - one with a default (from image) of 192.168.1.34 /
255.255.255.224, and one with 192.168.2.34, same netmask. So they are on
different subnets, but they are on the same hub/switch. They are both
running NetBEUI. I can net view \\oldcomputer and see the shares on the old
computer. Of course I cannot ping the old computer. I have a _vbscript_ to
grab the IP address of the old computer, thinking it will use whatever
transport it can to get to the old computer. Bzzzt. Thanks for playing.
Returns "computer does not exist" message when it times out. So if I change
the new computer's IP to the same subnet (say 192.168.2.35) then the script
works beautifully. Well, a lot of help that is. If I disable tcp/ip, then
the script fails immediately. So I think the call does not use NetBEUI, only
TCP/IP. Why? Who knows, should be layer 7 vs. layer (I forget - 3? 4?) why
should _vbscript_/WMI care what transport is used? Does it try to do a
WINS/NetBIOS lookup of the computer name and fail b/c there's no TCP/IP?
So surely there is a way to put to computers on the same wire, do a broadcast
or something to grab that computer's IP. If I know the IP, I can reconfigure
the local machine, no worries. I could ask the manager to put in the old
computer's IP address... but we can't depend upon them to tell us if the old
case is black or white, apparently, so we don't even want to go there with
ipconfig, type it in, verify, ask again, call help desk, etc. We're trying
to save $1000 a pop.
So does anyone know how to:
* use a command line tool to return the IP of another computer via
broadcast or something
* make WMI use NetBEUI if you know the computer name?
* any other ideas?
Here is the script I'm using... I haven't polished it, but it works on the
same subnet... (watch for line wrap)
On Error Resume Next
strComputer = InputBox("Please enter the old computer name")
Set objWMIService = GetObject("winmgmts:{impersonationLevel=impersonate}!\\"
& strComputer & "\root\CIMV2")
If err.number <> 0 Then
Msgbox "The computer name you entered was invalid. The error
was:" & vbNewline & err.Description
err.clear
End If
Set colItems = objWMIService.ExecQuery("SELECT * FROM
Win32_NetworkAdapterConfiguration",,48)
For Each objItem In colItems
strIPAddress = Join(objItem.IPAddress, ",")
strIPSubnet = Join(objItem.IPSubnet, ",")
strDefaultIPGateway = Join(objItem.DefaultIPGateway, ",")
If strIPAddress <> "" Then
if Left(CStr(strIPAddress),3) =
Left(CStr(strDefaultIPGateway),3) Then strIP = CStr(strIPAddress)
End If
Next
msgbox "My Address = " & strIPAddress & vbcrlf & "My Netmask = " &
strIPSubnet & vbcrlf & "My Gateway = " & strDefaultIPGateway
Rich
________________________________
-------APPLEBEE'S INTERNATIONAL, INC. CONFIDENTIALITY NOTICE-------
PRIVILEGED / CONFIDENTIAL INFORMATION may be contained in this
message or any attachments. This information is strictly confidential and may
be subject to attorney-client privilege. This message is intended only for
the use of the named addressee. If you are not the intended recipient of this
message, unauthorized forwarding, printing, copying, distribution, or using
such information is strictly prohibited and may be unlawful. If you have
received this in error, you should kindly notify the sender by reply e-mail
and immediately destroy this message. Unauthorized interception of this
e-mail is a violation of federal criminal law. Applebee's International, Inc.
reserves the right to monitor and review the content of all messages sent to
and from this e-mail address. Messages sent to or from this e-mail address
may be stored on the Applebee's International, Inc. e-mail system.
________________________________
List info : http://www.activedir.org/List.aspx
List FAQ : http://www.activedir.org/ListFAQ.aspx
List archive: http://www.mail-archive.com/activedir%40mail.activedir.org/
