Lots of people have already mentioned system_profiler
, so I'll just list some other commands I'd recommend for "looking around" a Mac OS X system:
top -u -s5
My favorite command for seeing what's going on. Shows processes sorted by CPU usage, updated every 5 seconds (I find the default of 1 second to be too fast), as well as load average, physical & VM stats, etc. Replace -u
with -orsize
to sort by resident memory size instead.
sysctl vm.swapusage
VM stats -- see man sysctl for other options, or just try -a and look through the whole list.
sw_vers
Shows the OS version and build
softwareupdate -l
Polls an Apple server for a list of relevant software updates. -i -a
will download and install them. Note that it will not restart the computer for updates that require it; instead they will be marked with "[restart]" in the list, and you'll need to restart manually after installing them (but be wary of firing off updates that require a reboot when you don't have physical access to the computer -- If something goes wrong you could be in trouble).
systemsetup
networksetup
Command-line access to the general and network settings normally accessed by the System Preferences GUI app. Useful, but have the most amazingly (and painfully) verbose options I've ever seen. (I mean, -getdisablekeyboardwhenenclosurelockisengaged
? Really?)
sudo /System/Library/CoreServices/RemoteManagement/ARDAgent.app/Contents/Resources/kickstart
Command-line control for the remote management service (Apple Remote Desktop), which doubles as a VNC server if you need GUI access. The trick is that to make it work with a generic VNC client, you have to enable "legacy"-style authentication, with something like:
sudo /System/Library/CoreServices/RemoteManagement/ARDAgent.app/Contents/Resources/kickstart -configure -clientopt -setvnclegacy -vnclegacy yes -setvncpw -vncpw PWGoesHere -restart -agent
(Or, if it's not already running, use -activate instead of -restart -agent)
Use the dscl command. This example would create the user "luser", like so:
dscl . -create /Users/luser
dscl . -create /Users/luser UserShell /bin/bash
dscl . -create /Users/luser RealName "Lucius Q. User"
dscl . -create /Users/luser UniqueID "1010"
dscl . -create /Users/luser PrimaryGroupID 80
dscl . -create /Users/luser NFSHomeDirectory /Users/luser
You can then use passwd to change the user's password, or use:
dscl . -passwd /Users/luser password
You'll have to create /Users/luser for the user's home directory and change ownership so the user can access it, and be sure that the UniqueID is in fact unique.
This line will add the user to the administrator's group:
dscl . -append /Groups/admin GroupMembership luser
Best Answer
First, Open the terminal window and use ARP (Address Resolution Protocol) tool to find-out all the network attached devices.
Use this Command:
It will show all the device that are attached to your network with IP addresses and MAC addresses.
You just have match the MAC address of you NA, which will be printed on it and look for IP in results that the above command has printed.
Edit:1
If you have not found your device means your device is currently unassigned. Please try this.
IP: Assign any free local IP
MAC: Use the MAC address that you have found on your device and please use ':' as separator, as you are using MAC OS. For windows, it would be '-'.