01-26-2011, 03:53 AM | #1 |
Junior Member
Posts: 1
Karma: 12
Join Date: Jan 2011
Device: Kindle k3g
|
OptWare for Kindle
Hello everyone!
I'm not sure how or where I started with this, and it certainly isn't for everyone, but some of you may find this useful. OptWare is better known as part of NSLU2-Linux - it's a very simple and very lightweight package manager designed to be integrated on top of embedded linuxes. Basically it's perfect for the Kindle although the repository is rather dated...still great for installing nano, wakelan, bitchx, and other fun toys to use from KiTerm. ...however, there's a bugbear. The existing versions of OptWare expect a version of wget that supports the "--passive-ftp" option, and the Kindle's BusyBox simply doesn't. Took enough work to fix this that I figured it was worth posting. If you'd like to fiddle with this, here are the (slightly modified) instructions originally available at: http://www.nslu2-linux.org/wiki/Optware/HomePage Note that you can't install packages to the main partition (/mnt/us) as FAT doesn't support symlinks. Code:
#First, remount root as read/write mntroot rw cd /opt feed=http://ipkg.nslu2-linux.org/feeds/optware/cs08q1armel/cross/unstable wget http://devalue.org/kindle/ipkg-opt_0.99.163-10_arm.ipk tar -xOvzf ipkg-opt_0.99.163-10_arm.ipk ./data.tar.gz | tar -C / -xzvf - mkdir -p /opt/etc/ipkg echo "src cross $feed" > /opt/etc/ipkg/feeds.conf # Usage (with nano as example) export PATH=$PATH:/opt/bin ipkg update ipkg install nano Last edited by aleksandyr; 01-26-2011 at 04:44 AM. Reason: Forgot a step! |
01-26-2011, 09:59 AM | #2 |
Enthusiast
Posts: 40
Karma: 34
Join Date: Aug 2010
Device: kindle dx US
|
a chroot debian with armel arch in a loop file placed on fat32 partition is much better
|
Advert | |
|
08-18-2011, 06:36 AM | #3 |
Junior Member
Posts: 4
Karma: 10
Join Date: Jan 2011
Device: Kindle 2 Intl
|
This is very cool! It's like apt-get Thanks aleksandyr
|
09-18-2011, 07:43 AM | #4 |
Member
Posts: 12
Karma: 14
Join Date: Sep 2011
Device: Kindle3 3G
|
OptWare in /mnt/us
I figured out how to install OptWare on /mnt/us partition (in an image file):
1. Create an ext3-image file on a Linux machine (e.g. 500MB) and copy it to your Kindle /mnt/us dd if=/dev/zero of=./local.ext3 bs=1MiB count=500 mkfs.ext3 ./local.ext3 cp local.ext3 /media/Kindle 2. Over UsbNetwork or in KiTerm: mntroot rw mkdir -p /mnt/loc mount -o loop,noatime -t ext3 /mnt/us/local.ext3 /mnt/loc mkdir -p /mnt/loc/opt/etc /mnt/loc/opt/share /mnt/loc/opt/lib /mnt/loc/opt/bin /mnt/loc/opt/tmp ln -s /mnt/loc/opt/etc /opt/etc ln -s /mnt/loc/opt/share /opt/share ln -s /mnt/loc/opt/lib /opt/lib ln -s /mnt/loc/opt/bin /opt/bin ln -s /mnt/loc/opt/tmp /opt/tmp mntroot ro 3. Now follow the aleksandyr's instruction (instead of "cd /opt" use "cd /opt/etc") 4. Instead of "ipkg" use "ipkg -t /opt/tmp" Since the root partition remains read-only, one can be pretty sure that it will be not overwhelmed! If you do a restart, you will have to mount /mnt/us/local.ext3 again (but you don't need write-privilege for that). You can also change in ipkg.conf (will be in /opt/etc ) the destination to "dest root /mnt/loc". Then new directories (like man or games) will be created in /mnt/loc/opt Last edited by danik; 09-21-2011 at 05:50 PM. |
09-20-2011, 06:16 AM | #5 |
Connoisseur
Posts: 57
Karma: 10288
Join Date: Aug 2011
Location: West Sussex
Device: Kindle 3 - 3g, Samsung Galaxy Note
|
Hi, I have previously installed optware per the original instructions here and installed a few items from it. danik's instructions on installing it in an image file seem to be a much better solution because it keeps the root partition of the kindle read only.
Could anyone provide some instructions on how to remove optware safely so that I can reinstall it per the new instructions. |
Advert | |
|
09-21-2011, 06:06 AM | #6 |
Member
Posts: 12
Karma: 14
Join Date: Sep 2011
Device: Kindle3 3G
|
With "ipkg list_installed" you can see what's installed and then remove the packages with "ipkg remove <package1> <package2>". Then you should delete the following directories in /opt: bin, etc, share, lib . You can also delete ipkg-opt_0.99.163-10_arm.ipk and configuration file of ipkg.
|
10-07-2011, 07:30 AM | #7 |
Member
Posts: 16
Karma: 24
Join Date: Sep 2011
Device: Kindle 3 WiFi v3.2.1
|
You may also want to add:
ln -s /mnt/loc/opt/sbin /opt/sbin If you choose to install man and man-pages with: ipkg -t /opt/tmp install man ipkg -t /opt/tmp install man-pages then will want to add additional sym links for the /opt/man and /opt/info directories else man won't by default find your man pages (or edit man.conf to point to /mnt/loc/opt/man). |
10-07-2011, 08:24 AM | #8 |
Wizard
Posts: 1,379
Karma: 2155307
Join Date: Nov 2010
Location: Goettingen, Germany
Device: Kindle Paperwhite, Kobo Mini
|
Note that symlinking is not needed, you can do everything with bind mounts. Also, there's no real reason to create another directory in /mnt either, it can very well be beneath /mnt/us. So you don't need writes to the root partition at all.
|
10-07-2011, 02:41 PM | #9 |
Member
Posts: 12
Karma: 14
Join Date: Sep 2011
Device: Kindle3 3G
|
For mount bind you still need mount points in /opt (except you mount to /opt directory itself but then you will hide the original opt directory of Kindle...), so you have to modify the root directory anyway, and with symlink it is easier to remount the image-file after reboot
|
10-07-2011, 04:47 PM | #10 |
Connoisseur
Posts: 84
Karma: 26720
Join Date: Mar 2011
Device: Kindle 3 WIFI
|
Symlinking has [edit] up my partition, it leaves files I cannot remove.
Last edited by dreams; 01-03-2012 at 03:11 AM. Reason: language edit by moderation |
10-08-2011, 05:59 PM | #11 |
Member
Posts: 12
Karma: 14
Join Date: Sep 2011
Device: Kindle3 3G
|
What do you mean exactly? You can always delete a symlink with rm (if you have write permissions).
|
10-09-2011, 07:09 AM | #12 |
Wizard
Posts: 1,379
Karma: 2155307
Join Date: Nov 2010
Location: Goettingen, Germany
Device: Kindle Paperwhite, Kobo Mini
|
Well, technically it would also be possible that the main partition file system is just hosed. I think it could easily happen if you forget to remount it read-only and then the power runs out in a bad moment. Linux might refuse to mount such a file system r/w, so you would need to go into rescue mode (with something like yifanlus kernel/initramfs) and fix the file system.
|
10-18-2011, 08:11 AM | #13 |
Member
Posts: 16
Karma: 24
Join Date: Sep 2011
Device: Kindle 3 WiFi v3.2.1
|
Is anyone using nano? Sometimes the screen isn't refreshed properly while I'm editing and what I see no longer matches the file contents. It's really annoying. Don't know if ncurses needs to be fixed for the e-ink display or if the TERM variable is not set correctly?
|
10-18-2011, 09:23 AM | #14 |
Wizard
Posts: 1,379
Karma: 2155307
Join Date: Nov 2010
Location: Goettingen, Germany
Device: Kindle Paperwhite, Kobo Mini
|
You don't really tell about the terminal program you're using, but I think it will be the culprit here. The terminal should be the program to handle e-ink updates, I think, using ncurses wouldn't really work because ncurses knows about rows and columns of a terminal, but knows nothing about the corresponding pixel coordinates.
|
10-18-2011, 06:22 PM | #15 |
Member
Posts: 16
Karma: 24
Join Date: Sep 2011
Device: Kindle 3 WiFi v3.2.1
|
Hi hawhill. I'm using PoP's build of kiterm (20110408). When I have some time I should probably turn on usbNetwork and try ssh in and try nano again to see what happens.
|
Thread Tools | Search this Thread |
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
The Frugal Kindle ~ Frugal Finds Under $9 for the Kindle (Kindle eBook Resource) | eTrubrown | Self-Promotions by Authors and Publishers | 3 | 10-10-2010 06:12 PM |
Transfer Kindle books from Kindle PC to Kindle 3 | ppearce | Amazon Kindle | 15 | 09-16-2010 05:11 PM |
Font hacks for the Kindle 2, Kindle International and Kindle DX | edge777 | Kindle Developer's Corner | 17 | 04-30-2010 04:11 PM |
$0.01 in Kindle Store: Interactive Sudoku for Kindle 2 and Kindle DX - Volume 1 | Xia | Deals and Resources (No Self-Promotion or Affiliate Links) | 2 | 11-07-2009 10:06 AM |