获取 Android 模拟器的 MAC

启动模拟器, 用adb shell 登陆

用下面的命令可以获取

    # ip link show
1: lo: mtu 16436 qdisc noqueue state UNKNOWN 
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
2: eth0: mtu 1500 qdisc pfifo_fast state UNKNOWN qlen 1000
    link/ether 52:54:00:12:34:56 brd ff:ff:ff:ff:ff:ff
3: sit0: mtu 1480 qdisc noop state DOWN 
    link/sit 0.0.0.0 brd 0.0.0.0

多次启动同一个 avd, 或不同 avd 地址不会变化,  在不同机器上启动 都是这个默认值


尝试对其进行修改,但报告错误,还不知道原因

# ip link set eth0 address 52:54:00:12:34:57
RTNETLINK answers: Device or resource busy


要查看环境变量用

#getprop

[ARGH]: [ARGH]
[dalvik.vm.heapsize]: [64m]
[dalvik.vm.stack-trace-file]: [/data/anr/traces.txt]
[dev.bootcomplete]: [1]
[gsm.current.phone-type]: [1]
[gsm.defaultpdpcontext.active]: [true]
[gsm.network.type]: [UMTS]
[gsm.nitz.time]: [1402042146111]
[gsm.operator.alpha]: [Android]
[gsm.operator.iso-country]: [us]
[gsm.operator.isroaming]: [false]
[gsm.operator.numeric]: [310260]
[gsm.sim.operator.alpha]: [Android]
[gsm.sim.operator.iso-country]: [us]
[gsm.sim.operator.numeric]: [310260]
[gsm.sim.state]: [READY]
[gsm.version.ril-impl]: [android reference-ril 1.0]
[init.svc.adbd]: [running]
[init.svc.bootanim]: [stopped]
[init.svc.console]: [running]
[init.svc.dbus]: [running]
[init.svc.debuggerd]: [running]
[init.svc.drm]: [running]
[init.svc.goldfish-logcat]: [stopped]
[init.svc.goldfish-setup]: [stopped]
[init.svc.installd]: [running]
[init.svc.keystore]: [running]
[init.svc.media]: [running]
[init.svc.netd]: [running]
[init.svc.qemu-props]: [stopped]
[init.svc.qemud]: [running]
[init.svc.ril-daemon]: [running]
[init.svc.servicemanager]: [running]
[init.svc.surfaceflinger]: [running]
[init.svc.ueventd]: [running]
[init.svc.vold]: [running]
[init.svc.zygote]: [running]
[net.bt.name]: [Android]
[net.change]: [net.dnschange]
[net.dns1]: [10.0.2.3]
[net.dnschange]: [1]
[net.eth0.dns1]: [10.0.2.3]
[net.eth0.gw]: [10.0.2.2]
[net.gprs.local-ip]: [10.0.2.15]
[net.hostname]: [android-27893ddc3cb6544a]
[net.qtaguid_enabled]: [0]
[net.tcp.buffersize.default]: [4096,87380,110208,4096,16384,110208]
[net.tcp.buffersize.edge]: [4093,26280,35040,4096,16384,35040]
[net.tcp.buffersize.gprs]: [4092,8760,11680,4096,8760,11680]
[net.tcp.buffersize.hspa]: [4094,87380,262144,4096,16384,262144]
[net.tcp.buffersize.lte]: [524288,1048576,2097152,262144,524288,1048576]
[net.tcp.buffersize.umts]: [4094,87380,110208,4096,16384,110208]
[net.tcp.buffersize.wifi]: [524288,1048576,2097152,262144,524288,1048576]
[persist.sys.country]: [US]
[persist.sys.language]: [en]
[persist.sys.localevar]: []
[persist.sys.profiler_ms]: [0]
[persist.sys.timezone]: [Asia/Chungking]
[persist.sys.usb.config]: [adb]
[qemu.hw.mainkeys]: [0]
[qemu.sf.fake_camera]: [back]
[qemu.sf.lcd_density]: [213]
[rild.libargs]: [-d /dev/ttyS0]
[rild.libpath]: [/system/lib/libreference-ril.so]
[ro.allow.mock.location]: [1]
[ro.baseband]: [unknown]
[ro.board.platform]: []
[ro.boot.hardware]: [goldfish]
[ro.bootloader]: [unknown]
[ro.bootmode]: [unknown]
[ro.build.characteristics]: [default]
[ro.build.date.utc]: [1345693736]
[ro.build.date]: [Thu Aug 23 11:48:56 CST 2012]
[ro.build.description]: [sdk_x86-eng 4.1.1 JRO03H eng.android-build.20120823.114606 test-keys]
[ro.build.display.id]: [sdk_x86-eng 4.1.1 JRO03H eng.android-build.20120823.114606 test-keys]
[ro.build.host]: [intelotc-srv]
[ro.build.id]: [JRO03H]
[ro.build.product]: [generic_x86]
[ro.build.tags]: [test-keys]
[ro.build.type]: [eng]
[ro.build.user]: [android-build]
[ro.build.version.codename]: [REL]
[ro.build.version.incremental]: [eng.android-build.20120823.114606]
[ro.build.version.release]: [4.1.1]
[ro.build.version.sdk]: [16]
[ro.com.google.locationfeatures]: [1]
[ro.config.alarm_alert]: [Alarm_Classic.ogg]
[ro.config.low_ram]: [true]
[ro.config.notification_sound]: [OnTheHunt.ogg]
[ro.debuggable]: [1]
[ro.factorytest]: [0]
[ro.hardware]: [goldfish]
[ro.kernel.android.checkjni]: [1]
[ro.kernel.android.qemud]: [ttyS1]
[ro.kernel.androidboot.hardware]: [goldfish]
[ro.kernel.clocksource]: [pit]
[ro.kernel.console]: [ttyS0]
[ro.kernel.ndns]: [1]
[ro.kernel.qemu.gles]: [1]
[ro.kernel.qemu]: [1]
[ro.product.board]: []
[ro.product.brand]: [generic_x86]
[ro.product.cpu.abi]: [x86]
[ro.product.device]: [generic_x86]
[ro.product.locale.language]: [en]
[ro.product.locale.region]: [US]
[ro.product.manufacturer]: [unknown]
[ro.product.model]: [Android SDK built for x86]
[ro.product.name]: [sdk_x86]
[ro.radio.use-ppp]: [no]
[ro.revision]: [0]
[ro.runtime.firstboot]: [1402042148124]
[ro.secure]: [0]
[ro.serialno]: []
[ro.setupwizard.mode]: [EMULATOR]
[ro.wifi.channels]: []
[service.bootanim.exit]: [1]
[status.battery.level]: [5]
[status.battery.level_raw]: [50]
[status.battery.level_scale]: [9]
[status.battery.state]: [Slow]
[sys.boot_completed]: [1]
[sys.usb.config]: [adb]
[sys.usb.state]: [adb]
[system_init.startsurfaceflinger]: [0]

你可能感兴趣的:(Android)