Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Readers > Amazon Kindle > Kindle Developer's Corner

Notices

Reply
 
Thread Tools Search this Thread
Old 03-06-2020, 03:08 PM   #1
Hzj_jie
Member
Hzj_jie will become famous soon enoughHzj_jie will become famous soon enoughHzj_jie will become famous soon enoughHzj_jie will become famous soon enoughHzj_jie will become famous soon enoughHzj_jie will become famous soon enough
 
Posts: 18
Karma: 638
Join Date: Feb 2016
Device: kobo aura hd
Block OTA by removing ota related binaries

This is still in the evaluating stage; I will update the post to explain whether it would permanently work or not.

My use scenario is pretty common, I need wifi to sync reading progress between my devices through koreader, use wikipedia, etc. So I cannot disable wifi just for blocking ota.
But ota breaks jailbreak easily, especially 5.12.*. So yesterday, my voyage automatically updated itself; and I have to run emergency again to bring back my jailbreak.

The idea is also very straightforward. I randomly found there were two processes on kindle otaupd and otav3. The first one looks like a daemon, the second one looks like the real implementation of ota. So I renamed these two files in /usr/bin/ to otaupd.bck and otav3.bck and manually kill the existing processes. After that, the processes definitely won't be brought back again.
So far, no obvious negative impacts were found.

I have done the same thing on both a voyage and a pw4. The voyage has updated to 5.12.4, and the pw4 is kept in 5.12.3 until now.
I will let you know if it can permanently block ota.
Hzj_jie is offline   Reply With Quote
Old 03-06-2020, 03:58 PM   #2
NiLuJe
BLAM!
NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.
 
NiLuJe's Avatar
 
Posts: 13,477
Karma: 26012494
Join Date: Jun 2010
Location: Paris, France
Device: Kindle 2i, 3g, 4, 5w, PW, PW2, PW5; Kobo H2O, Forma, Elipsa, Sage, C2E
You can probably nerf 'em at the source in the elektra db (I don't have a Kindle on hand right now, and I don't remember what exactly is tweakable, but most of the daemon manager setup lives here, and I'm pretty sure there are leaves dedicated to the OTA stuff in there).

(That's... not any easier/cleaner than renaming the binaries, though, since I don't think they ship the elektra tools in the FW, and it's in the ro rootfs, *and* mounted from a squashfs image IIRC. But at least that would prevent the daemon manager from retrying the startup like an idiot. Probably. Like I said, haven't even looked at a Kindle to spout all this, so, err, take this with a grain of salt ).

Last edited by NiLuJe; 03-06-2020 at 04:02 PM.
NiLuJe is offline   Reply With Quote
Advert
Old 03-06-2020, 06:33 PM   #3
Hzj_jie
Member
Hzj_jie will become famous soon enoughHzj_jie will become famous soon enoughHzj_jie will become famous soon enoughHzj_jie will become famous soon enoughHzj_jie will become famous soon enoughHzj_jie will become famous soon enough
 
Posts: 18
Karma: 638
Join Date: Feb 2016
Device: kobo aura hd
Oh, yes, forgot to mention, need to start with "mntroot rw". So the change should be preserved after restarts.
Hzj_jie is offline   Reply With Quote
Old 03-11-2020, 11:11 PM   #4
Hzj_jie
Member
Hzj_jie will become famous soon enoughHzj_jie will become famous soon enoughHzj_jie will become famous soon enoughHzj_jie will become famous soon enoughHzj_jie will become famous soon enoughHzj_jie will become famous soon enough
 
Posts: 18
Karma: 638
Join Date: Feb 2016
Device: kobo aura hd
Emmm, likely it works, my paperwhite 4 hasn't updated it to 5.12.4 until now.
Hzj_jie is offline   Reply With Quote
Old 03-13-2020, 03:57 AM   #5
RnJ4
Junior Member
RnJ4 began at the beginning.
 
Posts: 9
Karma: 10
Join Date: Apr 2019
Device: Kindle Paperwhite3
The 5.12.4 FW is recalled by Amazon.Hopefully it will work but we need to wait until next update.
RnJ4 is offline   Reply With Quote
Advert
Old 03-30-2020, 07:59 PM   #6
Hzj_jie
Member
Hzj_jie will become famous soon enoughHzj_jie will become famous soon enoughHzj_jie will become famous soon enoughHzj_jie will become famous soon enoughHzj_jie will become famous soon enoughHzj_jie will become famous soon enough
 
Posts: 18
Karma: 638
Join Date: Feb 2016
Device: kobo aura hd
PW4 still has not updated itself. It looks like this method works.
Hzj_jie is offline   Reply With Quote
Old 06-20-2020, 02:23 AM   #7
Ruskie_it
Fanatic
Ruskie_it ought to be getting tired of karma fortunes by now.Ruskie_it ought to be getting tired of karma fortunes by now.Ruskie_it ought to be getting tired of karma fortunes by now.Ruskie_it ought to be getting tired of karma fortunes by now.Ruskie_it ought to be getting tired of karma fortunes by now.Ruskie_it ought to be getting tired of karma fortunes by now.Ruskie_it ought to be getting tired of karma fortunes by now.Ruskie_it ought to be getting tired of karma fortunes by now.Ruskie_it ought to be getting tired of karma fortunes by now.Ruskie_it ought to be getting tired of karma fortunes by now.Ruskie_it ought to be getting tired of karma fortunes by now.
 
Posts: 536
Karma: 1000000
Join Date: Dec 2011
Location: Rome, Italy
Device: Kindle PW5, Kindle PW4, Kindle 4 NT
Quote:
Originally Posted by Hzj_jie View Post
PW4 still has not updated itself. It looks like this method works.
Could you please explain this more in detail (I.e. write a step by step procedure, explaining how to mount in rw etc)?
Ruskie_it is offline   Reply With Quote
Old 06-20-2020, 11:54 AM   #8
j.p.s
Grand Sorcerer
j.p.s ought to be getting tired of karma fortunes by now.j.p.s ought to be getting tired of karma fortunes by now.j.p.s ought to be getting tired of karma fortunes by now.j.p.s ought to be getting tired of karma fortunes by now.j.p.s ought to be getting tired of karma fortunes by now.j.p.s ought to be getting tired of karma fortunes by now.j.p.s ought to be getting tired of karma fortunes by now.j.p.s ought to be getting tired of karma fortunes by now.j.p.s ought to be getting tired of karma fortunes by now.j.p.s ought to be getting tired of karma fortunes by now.j.p.s ought to be getting tired of karma fortunes by now.
 
Posts: 5,278
Karma: 98804578
Join Date: Apr 2011
Device: pb360
Quote:
Originally Posted by Ruskie_it View Post
Could you please explain this more in detail (I.e. write a step by step procedure, explaining how to mount in rw etc)?
I don't know about the rest, but the instructions for mount are given every time you
ssh into the kindle. At a shell prompt:
mntroot rw

and

mntroot ro

to go back.
j.p.s is offline   Reply With Quote
Old 06-20-2020, 12:31 PM   #9
Ruskie_it
Fanatic
Ruskie_it ought to be getting tired of karma fortunes by now.Ruskie_it ought to be getting tired of karma fortunes by now.Ruskie_it ought to be getting tired of karma fortunes by now.Ruskie_it ought to be getting tired of karma fortunes by now.Ruskie_it ought to be getting tired of karma fortunes by now.Ruskie_it ought to be getting tired of karma fortunes by now.Ruskie_it ought to be getting tired of karma fortunes by now.Ruskie_it ought to be getting tired of karma fortunes by now.Ruskie_it ought to be getting tired of karma fortunes by now.Ruskie_it ought to be getting tired of karma fortunes by now.Ruskie_it ought to be getting tired of karma fortunes by now.
 
Posts: 536
Karma: 1000000
Join Date: Dec 2011
Location: Rome, Italy
Device: Kindle PW5, Kindle PW4, Kindle 4 NT
Quote:
Originally Posted by j.p.s View Post
I don't know about the rest, but the instructions for mount are given every time you
ssh into the kindle. At a shell prompt:
mntroot rw

and

mntroot ro

to go back.
Thanks. I have experience with "normal" linux but not this specific operations.
Alright, since in the kindles I am playing lately the update.bin.tmp.partial failed both in 5.12.1 and I almost was getting the forced update in 5.11.1 I will try this trick, and let's see...
Ruskie_it is offline   Reply With Quote
Old 08-18-2020, 06:42 AM   #10
RandomGiraffe
Connoisseur
RandomGiraffe once ate a cherry pie in a record 7 seconds.RandomGiraffe once ate a cherry pie in a record 7 seconds.RandomGiraffe once ate a cherry pie in a record 7 seconds.RandomGiraffe once ate a cherry pie in a record 7 seconds.RandomGiraffe once ate a cherry pie in a record 7 seconds.RandomGiraffe once ate a cherry pie in a record 7 seconds.RandomGiraffe once ate a cherry pie in a record 7 seconds.RandomGiraffe once ate a cherry pie in a record 7 seconds.RandomGiraffe once ate a cherry pie in a record 7 seconds.RandomGiraffe once ate a cherry pie in a record 7 seconds.RandomGiraffe once ate a cherry pie in a record 7 seconds.
 
Posts: 85
Karma: 1924
Join Date: Jul 2017
Device: Kindle PW4
Quote:
Originally Posted by Ruskie_it View Post
Thanks. I have experience with "normal" linux but not this specific operations.
Alright, since in the kindles I am playing lately the update.bin.tmp.partial failed both in 5.12.1 and I almost was getting the forced update in 5.11.1 I will try this trick, and let's see...
Hey, just wondering if you got anywhere with testing this.
RandomGiraffe is offline   Reply With Quote
Old 08-21-2020, 01:49 AM   #11
Hzj_jie
Member
Hzj_jie will become famous soon enoughHzj_jie will become famous soon enoughHzj_jie will become famous soon enoughHzj_jie will become famous soon enoughHzj_jie will become famous soon enoughHzj_jie will become famous soon enough
 
Posts: 18
Karma: 638
Join Date: Feb 2016
Device: kobo aura hd
My voyage 7th and paperwhite 10th are both stuck at 5.12.4. So the trick should work.
Hzj_jie is offline   Reply With Quote
Old 08-21-2020, 02:00 AM   #12
RandomGiraffe
Connoisseur
RandomGiraffe once ate a cherry pie in a record 7 seconds.RandomGiraffe once ate a cherry pie in a record 7 seconds.RandomGiraffe once ate a cherry pie in a record 7 seconds.RandomGiraffe once ate a cherry pie in a record 7 seconds.RandomGiraffe once ate a cherry pie in a record 7 seconds.RandomGiraffe once ate a cherry pie in a record 7 seconds.RandomGiraffe once ate a cherry pie in a record 7 seconds.RandomGiraffe once ate a cherry pie in a record 7 seconds.RandomGiraffe once ate a cherry pie in a record 7 seconds.RandomGiraffe once ate a cherry pie in a record 7 seconds.RandomGiraffe once ate a cherry pie in a record 7 seconds.
 
Posts: 85
Karma: 1924
Join Date: Jul 2017
Device: Kindle PW4
That’s great news. I’m no expert on such things though, so please could you advise me how I go about doing this?
RandomGiraffe is offline   Reply With Quote
Old 08-28-2020, 01:04 AM   #13
Hzj_jie
Member
Hzj_jie will become famous soon enoughHzj_jie will become famous soon enoughHzj_jie will become famous soon enoughHzj_jie will become famous soon enoughHzj_jie will become famous soon enoughHzj_jie will become famous soon enough
 
Posts: 18
Karma: 638
Join Date: Feb 2016
Device: kobo aura hd
Sorry, I should make it more clear at the first place.

First of all, the device needs to be jail broken.
1. ssh to the device through either wifi or usbnet. I do not see a difference here.
2. mntroot rw
3. cd /usr/bin
4. mv otaupd otaupd.bck
5. mv otav3 otav3.bck
6. ps aux | grep ota
You will see four processes here. Ignore the "/usr/java/bin/cvm" and "grep ota".
The second column is the process id, note down the ids of the other two processes, otav3 and otaupd.
7. pkill {the id in the output of the last command}
8. pkill {the other id in the output of the last command}
or instead of pkill, use reboot command to reboot the device. Then you will know if these two processes would be restarted after reboot.

The otav3 seems like "ota" "v3"; I am not sure if it has been changed to v4 recently.

Indeed you do not need to use ssh, if you have koreader, use the terminal simulator in the plugin can do pretty much the same thing.
Hzj_jie is offline   Reply With Quote
Old 08-28-2020, 08:17 AM   #14
RandomGiraffe
Connoisseur
RandomGiraffe once ate a cherry pie in a record 7 seconds.RandomGiraffe once ate a cherry pie in a record 7 seconds.RandomGiraffe once ate a cherry pie in a record 7 seconds.RandomGiraffe once ate a cherry pie in a record 7 seconds.RandomGiraffe once ate a cherry pie in a record 7 seconds.RandomGiraffe once ate a cherry pie in a record 7 seconds.RandomGiraffe once ate a cherry pie in a record 7 seconds.RandomGiraffe once ate a cherry pie in a record 7 seconds.RandomGiraffe once ate a cherry pie in a record 7 seconds.RandomGiraffe once ate a cherry pie in a record 7 seconds.RandomGiraffe once ate a cherry pie in a record 7 seconds.
 
Posts: 85
Karma: 1924
Join Date: Jul 2017
Device: Kindle PW4
Amazing! And no need to apologise at all. So this should in theory block any further updates, and survive a Kindle reboot? Is it something that could possibly be built into KUAL at some point?
RandomGiraffe is offline   Reply With Quote
Old 08-28-2020, 08:35 AM   #15
Ruskie_it
Fanatic
Ruskie_it ought to be getting tired of karma fortunes by now.Ruskie_it ought to be getting tired of karma fortunes by now.Ruskie_it ought to be getting tired of karma fortunes by now.Ruskie_it ought to be getting tired of karma fortunes by now.Ruskie_it ought to be getting tired of karma fortunes by now.Ruskie_it ought to be getting tired of karma fortunes by now.Ruskie_it ought to be getting tired of karma fortunes by now.Ruskie_it ought to be getting tired of karma fortunes by now.Ruskie_it ought to be getting tired of karma fortunes by now.Ruskie_it ought to be getting tired of karma fortunes by now.Ruskie_it ought to be getting tired of karma fortunes by now.
 
Posts: 536
Karma: 1000000
Join Date: Dec 2011
Location: Rome, Italy
Device: Kindle PW5, Kindle PW4, Kindle 4 NT
Quote:
Originally Posted by RandomGiraffe View Post
Hey, just wondering if you got anywhere with testing this.
Yep, did as instructed, worked so far (but I don't use Wi-fi that often)
Ruskie_it is offline   Reply With Quote
Reply

Tags
renameotabin, update blocker


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Is it possible to format /mnt/us to ext3/4 to block OTA? zaoqi Kindle Developer's Corner 7 11-29-2019 05:45 AM
Can /etc/hosts be used to block OTA updates? zaoqi Kindle Developer's Corner 1 08-18-2019 09:35 AM
OTA blocking knc1 Kindle Developer's Corner 12 02-27-2018 12:30 PM
Block OTA before connecting wifi to register? Pajamaman Kindle Developer's Corner 2 10-21-2017 10:12 PM
5.6.1 OTA Update lredgen Kindle Developer's Corner 2 12-17-2014 06:07 PM


All times are GMT -4. The time now is 12:02 PM.


MobileRead.com is a privately owned, operated and funded community.