Closed Bug 1007899 Opened 12 years ago Closed 8 years ago

On Nexus 4, "./flash.sh gecko" or "./scripts/fastxul.sh" do not restart b2g - manual shutdown + reboot required

Categories

(Firefox OS Graveyard :: General, defect)

x86_64
Linux
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED WONTFIX

People

(Reporter: botond, Unassigned)

Details

(Keywords: regression)

Attachments

(2 files)

Attached file Output of 'adb logcat'
Ever since I updated my B2G repo (master branch) a week or so ago, "./flash.sh gecko" stopped restarting B2G after updating gecko. It _says_ it does, i.e. the output of "./flash.sh" is what it usually is (see attachment), but B2G does not start, and I have to manually shut down the phone and reboot it to get B2G to start. Attached is the output of 'adb logcat' around the "./flash.sh gecko" call. The "Assertion failure: FuzzyEqualsAdditive" is from when B2G was running before the flash. The output after that should cover the period directly before and after the flash. This issue is really annoying because it requires an extra step (manual shutdown and reboot) every time I flash gecko onto the phone. Please let me know if there is anything else I can do to help diagnose the problem.
Summary: "./flash.sh gecko" does not restart b2g - manually reboot required → "./flash.sh gecko" does not restart b2g - manual shutdown + reboot required
I've been seeing this too when flashing a Nexus 4.
(In reply to Mike Habicher [:mikeh] from comment #2) > I've been seeing this too when flashing a Nexus 4. Right, I should have mentioned I was using a Nexus 4.
I'm still seeing this, and would really like to see it fixed, as Nexus 4 is my primary development phone and this makes edit/compile/reflash cycles very annoying. Does anyone have any pointers on where to start looking into this?
Summary: "./flash.sh gecko" does not restart b2g - manual shutdown + reboot required → On Nexus 4, "./flash.sh gecko" or "./scripts/fastxul.sh" do not restart b2g - manual shutdown + reboot required
Workaround: after running "./flash.sh gecko" or "./scripts/fastxul.sh", run "adb reboot". Thanks to Armen for letting me know about this!
Did you update the B2G repo? Doing repo sync updates everything except for the B2G repo itself. You need to do a: > git pull to update the files directly in the B2G repo itself (which includes flash.sh)
When I do: ./flash.sh gecko (on my Nexus 4), it stops and restarts b2g. It doesn't reboot the phone, just does the stop, update, start. See: https://github.com/mozilla-b2g/B2G/blob/master/flash.sh#L332
(In reply to Dave Hylands [:dhylands] from comment #6) > Did you update the B2G repo? > > Doing repo sync updates everything except for the B2G repo itself. > > You need to do a: > > > git pull > > to update the files directly in the B2G repo itself (which includes flash.sh) I did.
(In reply to Dave Hylands [:dhylands] from comment #7) > When I do: ./flash.sh gecko (on my Nexus 4), it stops and restarts b2g. It > doesn't reboot the phone, just does the stop, update, start. > > See: https://github.com/mozilla-b2g/B2G/blob/master/flash.sh#L332 For me, b2g does not restart. I have to do a reboot in order for it to restart.
Botond, when you do: > adb shell do you see: > root@mako:/ # or > root@mako:/ $ The prompt with a # is a root shell, and the prompt with a $ shell is a "shell user" shell. I'm going to guess that you're getting a "shell user" shell. And "adb shell stop b2g" is essentially a noop with a shell user shell. The /default.prop file on the phone determines what type of shell you get. ro.secure=1 - you can only user a user shell. ro.secure=1, ro.debuggable=1 - You get a user shell by default, but you can use "adb root" to relaunch adbd on the phone as root (this doesn't persist across reboots). ro.secure=0 - You get a root shell by default.
I see a mistake in my table, so updating here: The /default.prop file on the phone determines what type of shell you get. ro.secure=1, ro.debuggable=0 - You can only user a user shell. The only way to get a root shell is if you have the su command on the phone. ro.secure=1, ro.debuggable=1 - You get a user shell by default, but you can use "adb root" to relaunch adbd on the phone as root (this doesn't persist across reboots). ro.secure=0 - You get a root shell by default.
(In reply to Dave Hylands [:dhylands] from comment #10) > Botond, when you do: > > > adb shell > > do you see: > > > root@mako:/ # > > or > > > root@mako:/ $ > > The prompt with a # is a root shell, and the prompt with a $ shell is a > "shell user" shell. > > I'm going to guess that you're getting a "shell user" shell. Nope. I get a root shell ('#').
ok - so something is wrong. If you manually do: > adb shell stop b2g && adb shell start b2g do you see it restarting? You should see the "based on mozilla" on the red square splash. Can you edit your flash.sh script and add set -x after the load_config and attach the output of running: > ./flash.sh gecko to this bug? So your edited flash.sh should look like: > #!/bin/bash > > . load-config.sh > > set -x > > ADB=${ADB:-adb} I just built the latest master, flashed it, and then "./flash.sh gecko" and everything seems to be working as expected (i.e. it restarted gecko - I saw the splash and then the lock screen)
Firefox OS is not being worked on
Status: NEW → RESOLVED
Closed: 8 years ago
Resolution: --- → WONTFIX
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: