How to reboot android device emulator in Genymotion

67,379

Solution 1

You can use the command line with adb reboot. It should restart your device.

To use adb you need to be inside the adb binary's folder. ie, <android SDK>/platform-tools/ or <genymotion folder>/tools/ if the android SDK is not installed. You can also these folders to your path to access it from anywhere.

Solution 2

works for me on mac:

  • open terminal
  • go to /Applications/Android Studio.app/sdk/platform-tools
  • make sure adb is in directory (use ls command)
  • ./adb reboot

Genymotion emulator restarts...

Solution 3

You can press emulator power button. When pressed, you will see option dialog. That dialog you can choose "Restart". Hope for help.

enter image description here

Solution 4

Found the solution using also the answer from @eyal-lezmy and other stuff on the web. If you have more than one device running, you can reboot a specific device in this way

  1. LIST DEVICES

From <genymotion-installer-path> launch genymotion-shell

Inside the shell, run devices, take note of IP address and port of the device you want to reboot and exit.

  1. REBOOT WITH ADB

From <android-sdk-folder>/platform-tools run

adb -s <device-ip>:<device-port> reboot

Solution 5

When on linux I found the adb binary in /path/to/genymotion/tools/adb

In my case:

~/genymotion/tools/adb reboot

Works like a charm.

Share:
67,379
user3926701
Author by

user3926701

Updated on March 20, 2020

Comments

  • user3926701
    user3926701 about 4 years

    How can i test my application after reboot(BOOT COMPLETED) using Genymotion I am using nexus 4 as device

    <receiver android:name="com.template.SampleBootReceiver"
                android:enabled="true">
        <intent-filter>
            <action android:name="android.intent.action.BOOT_COMPLETED"/>
        </intent-filter>
    </receiver>
    
  • B M
    B M over 9 years
    what you see the option?
  • user3926701
    user3926701 over 9 years
    power off ,Airplane mode,Silent Mode
  • B M
    B M over 9 years
    I think you android version may be old. So you can use "Power Off". When Device Power On, reboot the Android OS.
  • user3926701
    user3926701 over 9 years
    genymotion version 2.2.2
  • B M
    B M over 9 years
    No. I mean android os version of your device emulator. Eg: Android Version : 4.0
  • user3926701
    user3926701 over 9 years
    android version: 4.4.2
  • B M
    B M over 9 years
    you can make 2 ways "Power Off" or "Close your emulator windows". that 2 ways are boot again your device. when boot again, If you test your application receiver don't run, you should check your code.
  • orip
    orip over 9 years
    This is the creator of Genymotion (context for those who don't know)
  • eyal-lezmy
    eyal-lezmy over 9 years
    I'm far to be the Genymotion's creator but I'm part of the team that's right! :-)
  • Taxellool
    Taxellool about 9 years
    @eyal-lezmy How? using genyshell, says command adb not found. is there another command line?
  • eyal-lezmy
    eyal-lezmy about 9 years
    To use adb you need to be inside the adb binary's folder. ie, <android SDK>/platform-tools or <genymotion folder>/tools if the android SDK is not installed. Or you can add on the these folders to your path to access it from everywhere.
  • Confuse
    Confuse about 9 years
    Genymotion 5.0 - only seeing Shut Down -.-
  • tomexou
    tomexou almost 9 years
    Remember to press the button in a "long hold". That's the point.
  • Mike Bethany
    Mike Bethany over 8 years
    @eyal-lezmy Ironically this is NOT the correct answer and it's from one of the dev team. It ignores the actual question because you can't run adb reboot from the Genymotion Shell. Down voted until it's corrected.
  • eyal-lezmy
    eyal-lezmy over 8 years
    @mike adb reboot had to be run from the command line (or terminal) and not from the Genyshell. Like evey adb command. I hope it will help you.
  • StefanHeimberg
    StefanHeimberg about 8 years
    almost perfect... but where can i find out the device-port? "Genymotion Shell > devices list" does only show the ip address. thanks
  • Roger_S
    Roger_S about 8 years
    From stackoverflow.com/questions/24906377/… I found that the port is 5555 for Genymotion devices
  • bubakazouba
    bubakazouba about 8 years
    where is the genymotion folder?
  • Nick Sarafa
    Nick Sarafa almost 8 years
    The platform-tools directory might be inside of the android-sdk-macosx directory depending on your Android Studio setup
  • user25
    user25 over 7 years
    Nothing happens on the latest Genymotion Emulator 23 API. After adb reboot from C:\Program Files\Genymobile\Genymotion\tools Underscore _ just blinks infinitely (s9.postimg.org/linusf90v/Screenshot_1.png)
  • Admin
    Admin over 7 years
    @eyal-lezmy Could you take a look at some of my questions regarding Google play services on genymotion emulator. I repeatedly get the "Google play services has stopped". Over and over again. Tried every combination of devices and open gapps (about 30). Rebootibg, clearing data, storage, caches, nothing helps. And no useful info in catlog.
  • eyal-lezmy
    eyal-lezmy over 7 years
    Please open a dedicated post to explain the problem
  • Alan Nelson
    Alan Nelson about 7 years
    Sorry about how huge the picture is. New to posting ;)
  • Ninja Coding
    Ninja Coding almost 7 years
    i agree with @mike, this is not the right answer since question is "in genymotion" and answer is out of geymotion context, it's a generic adb command.
  • User
    User over 5 years
    No sdk folder within Android Studio
  • Abhilash
    Abhilash about 3 years
    Path in mac - ~/Application/Genymotion.app/Contents/MacOS/tools/adb