How to find the IP address of a computer that I am connected to?
Hi all,
One of my computers (an iMac) was recently stolen, but I have been able to connect to it over the internet through Apple's 'back to my mac' feature. In order for the police to find these people they need to know the IP address of the stolen computer.
I suspect that I will have find the IP address through the terminal, so I was wondering how a UNIX user would go about finding the IP address of a computer that they have mounted as a disk image? (sorry if I am using Mac terminology here rather than Unix terminology).
Are there any log files that would list the IP addresses that have been accessed recently? (the computer has since disappeared, so this would be the preferred method)
If not, how would I find out what the IP address is when I am next able to access it?
I understand that the Mac OSX may do things differently to pure UNIX, but hopefully there are enough similarities to allow me to do what I need. My knowledge of how UNIX/the terminal works is undoubtedly very poor compared to most of the users of this forum (i.e. I only use UNIX for some very basic work on the supercomputers at university), so please do really spell it out for me!
I'm not familiar with the operating system of Macs but I know they're unix based. I would use ifconfig -a to tell me what ip address it's configured to if I was on a unix or linux box.
Once you know what the IP address is by the command above, you could also run 'tracert'(windows) or 'traceroute'(unix/linux) from the PC you are connecting from to try and help the law enforcement officials locate the device.
It will also be helpful to give them the MAC address of your laptop, as this information can sometimes be critical. (looks like this 00:00:00:00:00:00, should be in the ifconfig -a output..)
If you can get a shell on this MAC laptop, it might also be worthwhile to put something in a startup script somewhere after the network is connected to e-mail you this information. At least that way whenever they turn it on, you get an e-mail containing this data. Not sure where this would be on a macintosh though. (perhaps /etc/rc3.d..?)
The problem with ifconfig is that it will tell you the LAN IP address your MAC is connected to.
I don't know what kind of programs there is on a MAC, but if you have at least mail, wget and a basic shell, and if you know how to code a simple script that you can send to your MAC (via ssh, ...), write a script that wget to a site that returns your current IP address (Current IP Check for example) and send this page to your email address.
I didn't test the script above, but I hope it can help you a bit
If you can send this script to your machine via SSH or anything else, set the executable flag and use cron (or similar on MAC) to execute this script every hour or so, you'll receive regular emails containing the current (external) IP address of your MAC.
The problem with ifconfig is that it will tell you the LAN IP address your MAC is connected to.
I don't know what kind of programs there is on a MAC, but if you have at least mail, wget and a basic shell
OSX doesn't come with wget. I compiled wget for OSX once but only as a PPC version... I do think OSX comes with curl though. I'm not too sure on the details on how to use curl but 'curl http://site.com/path/to/file' at least should do what you expect.
Hi,
I am trying to write a script that will check all used IP on the server and then print me an addressees that are not in use. Problem is in comparing two variables
#!/bin/bash
NETSTAT=$(netstat -ntp | awk '{ print $4 }' | grep -v "127.0.0.1" | cut -d ":" -f1 | grep "^"|sort | uniq )... (6 Replies)
Hi Guys,
I want to find another(Local host) machine IP address from my machine.. We are all connected in the same server, I mean same LAN.
What i done is
Connected with that user machine using SSH and SU.. After that i used IFCONFIG but it shows my Ip address. Can not able to get the... (8 Replies)
Hello
A friend and I recently got our hands on an old computer (a rainbow '83 I think), cleaned it, etc... And now we're trying to get the thing running. The problem is that the included OS is badly documented, so I thought of installing an old version of UNIX on it. So the questions are: Is that... (8 Replies)
I have my iMac and MB pro connected by firewire. I can see the connection in the finderwindow, but can't locate the machines in terminal. Can someone help me? I do most of my work in Terminal and would like to move/copy files from one machine to another like that -- I could have sworn I was able... (4 Replies)
My computer is one of three computer on our LAN. Our router is a Time Capsule. My computer is the only of of three computers that has been assigned a static IP address on the LAN, because it runs an Apache installation. I tinker around with web development from time to time, and I wanted to be... (7 Replies)
I'm trying to find the IP address of a print queue. I tried this, but nada.
cat /etc/hosts | lp -d lp01
Looked in the hosts file but it's not there (2 Replies)
Arright, here's what I'm trying to do. I want to dig up currently active IP addresses on my subnet, and my present strategy is to ping every address until I find active ones, then ping them more often to verify their status. Next, I want to find the names of the computers associated with those... (1 Reply)