The most Powerful Feature of the HP Touchpad (LVM) - TouchPad General

Flash files are available here to automatically create the swap partition:
https://forum.xda-developers.com/hp-touchpad/general/how-to-create-swap-partition-size-t3892060#post78939182
How to configure the Hp Touchpad internal storage
The most important feature that was ahead of its time and still until today is the use of LVM (Logical Volume Manager) for managing the internal storage.
To the regular user it will be insignificant but it can provide great benefits if deploy properly.
I could be wrong, but the TP could be the first and only mobile device ever shipped with LVM even now. (someone can correct me on this)
What is LVM?
https://en.wikipedia.org/wiki/Logical_Volume_Manager_(Linux)
I am a regular user and not an expert on LVM in Linux, the only device that I have to play with LVM is the TP and will show you the basics usage and it may not even have the full potential settings.
In webOS there is a program (app) call Tailor ( Formerly Known as Resizah ), a graphical interface to manage LVM.
http://preware.pivotce.com/package/org.webosinternals.tailor
https://www.webos-internals.org/wiki/Application:Tailor
https://forums.webosnation.com/webos-internals/304871-tailor-device-live-partition-filesystem-editor-beta-testing.html
https://github.com/rwhitby/tailor
The last alpha version 0.3.1 allows for creating a LuneOS partition.
Also you can create all Android partitions inside WebOS, create and resize all partitions while running WebOS.The magic of LVM!
Attached is a screen shot of my TP running Taylor.
Think of it as creating, deleting , moving, expanding or reducing (files and folders) with your file manager. Instead it will be the actual storage card, partitions, volumes. All done withing the OS no need to reboot or enter any commands. Resizing the android system, cache or data partition live inside android with just touch input.! That is how easy it could have been, but Android does not use LVM and the TP had to follow the rest of the herd. The reason that WebOS, Android, LuneOS (and more OS) can be install together is due to the flexibility of LVM.
The ToolBox by jcsullins provides scripts to create webOS and Android volumes and resize system, cache and data. But is not a live system and limited to pre-configure settings.
All the flexibility and easy to use comes with a risk of data lost as we know not everything in the computer world works as intended, due to the endless configuration and uses of each user.
Code:
This is a 32G Touchpad with WebOS, Android and LuneOS install and perfectly running.
Factory install WebOS (original)
Used ToolBox to create Android system, cache and data
Used Taylor to create luneos-root
List of physical volumes
/dev/store/root [ 568.00 MB]
/dev/store/var [ 64.00 MB]
/dev/store/update [ 16.00 MB]
/dev/store/log [ 24.00 MB]
/dev/store/mojodb [ 256.00 MB]
/dev/store/filecache [ 136.00 MB]
/dev/store/media [ 19.44 GB]
/dev/store/swap [ 400.00 MB]
/dev/store/cm-cache [ 200.00 MB]
/dev/store/cm-data [ 4.88 GB]
/dev/store/cm-system [ 1.17 GB]
/dev/store/luneos-root [ 1.95 GB]
12 disks
0 partitions
0 LVM physical volume whole disks
0 LVM physical volumes
LVM is reporting to each OS its own disks and each OS mounts its own Disk using f stabs. In reality there is only one storage, not 12 ( the magic of LVM !
This is a 32G Touchpad that was completely reset using the Toolbox.
/dev/block/mmcblk0p8 [ 10.00 MiB]
/dev/block/mmcblk0p9 [ 1.46 MiB]
/dev/block/mmcblk0p1 [ 100.00 MiB]
/dev/block/mmcblk0p10 [ 3.00 MiB]
/dev/block/mmcblk0p11 [ 3.00 MiB]
/dev/block/mmcblk0p3 [ 1.46 MiB]
/dev/block/mmcblk0p12 [ 4.00 MiB]
/dev/block/mmcblk0p13 [ 32.00 MiB]
/dev/block/mmcblk0p14 [ 29.09 GiB] LVM physical volume
/dev/block/mmcblk0p6 [ 750.00 KiB]
/dev/store/media [ 29.09 GiB]
/dev/block/mmcblk0p7 [ 2.44 MiB]
1 disk
10 partitions
0 LVM physical volume whole disks
1 LVM physical volume
/dev/block/mmcblk0p13 ( is the boot partition ) 32 MB where all the uImages are boot it from.
This is the physical volume the real internal storage.
PV VG Fmt Attr PSize PFree
/dev/block/mmcblk0p14 store lvm2 a- 29.09g 0
This is the logical volume of the physical volume which is part of the volume group "store"
The media USB storage in Android. This is the logical volume to resize and create other logical volume.
--- Logical volume ---
LV Name /dev/store/media
VG Name store
LV UUID WhFWig-xwTY-0SK3-OnrS-32mq-gADG-7mLY7c
LV Write Access read/write
LV Status available
# open 1
LV Size 29.09 GiB
Current LE 3723
Segments 1
Allocation inherit
Read ahead sectors auto
- currently set to 4096
Persistent major 254
Persistent minor 6
Block device 253:6
This is all done loading TWRP mounting /boot and adb shell.
The working directory for lvm.static is:
/boot/usr/sbin
to execute ./lvm.static plus command.
Resizing Logical volume /dev/store/media to 1GB
./lvm.static lvresize --size 1G /dev/store/media
PV VG Fmt Attr PSize PFree
/dev/block/mmcblk0p14 store lvm2 a- 29.09g 28.09g
Now there is 28.09g free to be allocated to any volume (disk) we want to create
Keep in mind the Persistent minor is 6 of the major 254 ( the next disk can be from 0 to 5 and 7 to 254 ) but 6 is already taken.
Creating Android volume cm-system
./lvm.static lvcreate -L 1.3G -M y --major 254 --minor 0 -n /dev/store/cm-system
Creating Android volume cm-cache
./lvm.static lvcreate -L 200M -M y --major 254 --minor 1 -n /dev/store/cm-cache
Creating Android volume cm-data (4GB)
./lvm.static lvcreate -L 4G -M y --major 254 --minor 2 -n /dev/store/cm-data
Activating the new logical volume
/boot/usr/sbin # ./lvm.static vgchange -ay
4 logical volume(s) in volume group "store" now active
/boot/usr/sbin # ./lvm.static pvs
PV VG Fmt Attr PSize PFree
/dev/block/mmcblk0p14 store lvm2 a- 29.09g 22.59g
There is 22.59GB free to create more volume or disk!
Let's create volumes to install Linux as chroot
./lvm.static lvcreate -L 2G -M y --major 254 --minor 5 -n /dev/store/Linux-root
Another chroot as Debian!
./lvm.static lvcreate -L 2G -M y --major 254 --minor 7 -n /dev/store/debian-root
Create LuneOS volume
./lvm.static lvcreate -L 2G -M y --major 254 --minor 4 -n /dev/store/luneos-root
There is 16.59GB free
/boot/usr/sbin # ./lvm.static pvs
PV VG Fmt Attr PSize PFree
/dev/block/mmcblk0p14 store lvm2 a- 29.09g 16.59g
Let's create another Android installation ( completely independent )
Android PIE system
./lvm.static lvcreate -L 1.3G -M y --major 254 --minor 8 -n /dev/store/A_PIE-system
Android PIE cache
./lvm.static lvcreate -L 200M -M y --major 254 --minor 9 -n /dev/store/A_PIE-cache
Android PIE Data (4GB)
./lvm.static lvcreate -L 4G -M y --major 254 --minor 10 -n /dev/store/A_PIE-data
There is 11.09GB free
/boot/usr/sbin # ./lvm.static pvs
PV VG Fmt Attr PSize PFree
/dev/block/mmcblk0p14 store lvm2 a- 29.09g 11.09g
Let's create SailFishOS!
./lvm.static lvcreate -L 2G -M y --major 254 --minor 11 -n /dev/store/Sailfish_OS
Another Installation Android 10 Queso!
A_Queso-system
./lvm.static lvcreate -L 1.3G -M y --major 254 --minor 12 -n /dev/store/A_Queso-system
A_Queso-cache
./lvm.static lvcreate -L 200M -M y --major 254 --minor 13 -n /dev/store/A_Queso-cache
A_Queso_data
./lvm.static lvcreate -L 2G -M y --major 254 --minor 14 -n /dev/store/A_Queso_data
There is 5.59GB free
PV VG Fmt Attr PSize PFree
/dev/block/mmcblk0p14 store lvm2 a- 29.09g 5.59g
What about a swap volume!
./lvm.static lvcreate -L 1G -C y -M y --major 254 --minor 15 -n /dev/store/swap
Now we can give the command to LVM to extend media to use the 4.59GB available and use it all.
/lvm.static lvresize -l 100%FREE /dev/store/media
15 logical volume(s) in volume group "store" now active
Here is the summary of all the disks available:
/boot/usr/sbin # ./lvm.static lvmdiskscan
/dev/block/mmcblk0p8 [ 10.00 MiB]
/dev/store/cm-system [ 1.30 GiB]
/dev/block/mmcblk0p9 [ 1.46 MiB]
/dev/block/mmcblk0p1 [ 100.00 MiB]
/dev/store/cm-cache [ 200.00 MiB]
/dev/block/mmcblk0p10 [ 3.00 MiB]
/dev/store/cm-data [ 4.00 GiB]
/dev/block/mmcblk0p11 [ 3.00 MiB]
/dev/block/mmcblk0p3 [ 1.46 MiB]
/dev/block/mmcblk0p12 [ 4.00 MiB]
/dev/store/luneos-root [ 2.00 GiB]
/dev/block/mmcblk0p13 [ 32.00 MiB]
/dev/store/Linux-root [ 2.00 GiB]
/dev/block/mmcblk0p14 [ 29.09 GiB] LVM physical volume
/dev/block/mmcblk0p6 [ 750.00 KiB]
/dev/store/media [ 4.59 GiB]
/dev/block/mmcblk0p7 [ 2.44 MiB]
/dev/store/debian-root [ 2.00 GiB]
/dev/store/A_PIE-system [ 1.30 GiB]
/dev/store/A_PIE-cache [ 200.00 MiB]
/dev/store/A_PIE-data [ 4.00 GiB]
/dev/store/Sailfish_OS [ 2.00 GiB]
/dev/store/A_Queso-system [ 1.30 GiB]
/dev/store/A_Queso-cache [ 200.00 MiB]
/dev/store/A_Queso_data [ 2.00 GiB]
/dev/store/swap [ 1.00 GiB]
15 disks
10 partitions
0 LVM physical volume whole disks
1 LVM physical volume
Now we can format every disk with ext2, ext3, ext4 and vfat
Example to format Android system volumen
mke2fs -E lazy_itable_init=0 -t ext4 /dev/store/cm-system
mke2fs -E lazy_itable_init=0 -t ext4 /dev/store/cm-cache
mke2fs -E lazy_itable_init=0 -t ext4 /dev/store/cm-data
To make swap
mkswap /dev/store/swap
This is very easy to create, and quick there is no waitting time is done as soon as you press enter.
We have create it a Touchpad that is capable of running the following OS independently.
Current Version of Android
A version of Android PIE 9
A version of Android Queso 10
LuneOS
SailfishOS
Linux-root (to run as chroot or native)
debian-root (to run as chroot or native)
A 1GB swap file
The volume size of the disk created are minimum or below requirement but this is to show how powerful and simple LVM is to set up.

Hi @HP_TOUCHPAD !
Good to see someone with your structured approach sharing tutorials and hints! Cheers for that!
I stumbled upon my 16GB and 32GB Touchpads on the weekend and I want to give them a new spin.
Especially LuneOS was not known to me before your post!
Any chance of you sharing your current setup and how you managed to set it up?
I am curious to factory reset my Touchpads (at least the 32GB one) and set them up with webOS + LuneOS + Android (which ROM do you use?)...
You being the knowledgable 'tutor' around here - would you share your 'webOS + LuneOS + Android' experience and how to set it up?
Cheers!
Curious greetings, raimerik

Thank you for your comments!
As of right now I am working on just that, a simple way for anyone just to flash a zip file and have everything that you need to have the Tablet set up. There is a lot of steps to do and gets confusing, hopefully the new process will work for everyone.
I will post when done!

HP_TOUCHPAD said:
Thank you for your comments!
As of right now I am working on just that, a simple way for anyone just to flash a zip file and have everything that you need to have the Tablet set up. There is a lot of steps to do and gets confusing, hopefully the new process will work for everyone.
I will post when done!
Click to expand...
Click to collapse
Wow - cheers! - looking forward to testing it once it's done! :] raimerik

I will try it and test it out too. My Touchpad is afraid of nothing.

Related

Bricked my touchpad and how I fixed it.

======================================
Story to explain how I partially "bricked" my touchpad
======================================
I say partially because WebOS wouldn't boot but I could get into recovery
It started out when I put Android on my touchpad. It worked perfectly.
The next day, I suddenly couldn't edit any files on Android, so I hooked it up to my computer. Windows said I should reformat it. So I just let windows reformat it to fat32.
After the format, something odd happened. I wasn't sure what was going on, but basically:
Android was able to write to the SD card now, but when I plugged it into my computer to look look at the files, it showed me what windows formatted. Same happened when I booted to WebOS.
So great, now I have created myself a problem.
Attempting to fix it, I decided to uninstall android and run webos doctor. Didn't fix my problem.
I then proceeded to "recreate the filesystem" with these commands.
Code:
lvm.static vgscan --ignorelockingfailure
lvm.static vgchange -ay --ignorelockingfailure
lvm.static vgremove store
lvm.static vgscan --ignorelockingfailure
lvm.static vgchange -ay --ignorelockingfailure
lvm.static vgcreate -s 8M store /dev/mmcblk0p14
lvm.static vgscan --ignorelockingfailure
lvm.static vgchange -ay --ignorelockingfailure
lvm.static lvcreate -l 71 -i 1 -M y --major 254 --minor 0 -n root store
lvm.static lvcreate -l 8 -i 1 -M y --major 254 --minor 1 -n var store
lvm.static lvcreate -l 2 -i 1 -M y --major 254 --minor 2 -n update store
lvm.static lvcreate -l 3 -i 1 -M y --major 254 --minor 3 -n log store
lvm.static lvcreate -l 32 -i 1 -M y --major 254 --minor 4 -n mojodb store
lvm.static lvcreate -l 17 -i 1 -M y --major 254 --minor 5 -n filecache store
lvm.static lvcreate -l 3523 -i 1 -M y --major 254 --minor 6 -n media store
lvm.static lvcreate -l 64 -i 1 -M y --major 254 --minor 7 -n swap store
lvm.static vgscan --ignorelockingfailure
lvm.static vgchange -ay --ignorelockingfailure
mkdosfs -f 1 -s 64 /dev/store/media
Well, I caused myself a bigger problem. Now WebOS won't even boot.
======================================
Trying to figure out what went wrong
======================================
Great, my touchpad won't boot.
I tried to doctor it, and it get's stuck at 8%. I checked the logs and found this bit of useful information
Part of doctor log
Code:
INFO: Unmounting /dev/mapper/store-log
Oct 24, 2011 3:53:09 AM com.palm.nova.installer.core.MountUtils umountPart
WARNING: MountUtils: unmount failed, retrying in 1 second
Oct 24, 2011 3:53:10 AM com.palm.nova.installer.core.MountUtils umountPart
SEVERE: MountUtils: unmount failed: umount: can't umount /dev/mapper/store-log:
No such file or directory
So I went back to root access and tried to mount all partitions.
mount -a
Code:
mount: mounting /dev/mapper/store-var on /var failed: Invalid argument
mount: mounting /dev/mapper/store-log on /var/log failed: Invalid argument
Turns out this is the real reason doctor failed.
I then checked everything I could to see if i could find any other problems
pvscan
Code:
Filesystem Size Used Available Use% Mounted on
/dev/root 28.8M 21.2M 7.6M 74% /
/dev/root 28.8M 21.2M 7.6M 74% /dev/.static/dev
tmpfs 2.0M 108.0K 1.9M 5% /dev
tmpfs 32.0M 0 32.0M 0% /tmp
tmpfs 16.0M 0 16.0M 0% /var/run
tmpfs 32.0M 0 32.0M 0% /tmp
tmpfs 459.7M 0 459.7M 0% /media/ram
/dev/mapper/store-media
27.5G 64.0K 27.5G 0% /media/internal
lvscan
Code:
ACTIVE '/dev/store/root' [568.00 MB] inherit
ACTIVE '/dev/store/var' [64.00 MB] inherit
ACTIVE '/dev/store/update' [16.00 MB] inherit
ACTIVE '/dev/store/log' [24.00 MB] inherit
ACTIVE '/dev/store/mojodb' [256.00 MB] inherit
ACTIVE '/dev/store/filecache' [136.00 MB] inherit
ACTIVE '/dev/store/media' [27.53 GB] inherit
ACTIVE '/dev/store/swap' [512.00 MB] inherit
fstab
Code:
# fstab auto-generated by trenchcoat
# <filesystem> <mount point> <type> <options> <dump> <pass>
rootfs / ext3 ro,suid,dev,exec,auto,nouser,async,noatime 1
1
/dev/mapper/store-var /var ext3 noatime,data=writeback 0 0
/dev/mapper/store-cryptodb /var/db ext3 noauto,noatime,data=ordered
0 0
/dev/mapper/store-cryptofilecache /var/file-cache ext3 noauto,noatime,u
ser_xattr 0 0
/dev/mapper/store-log /var/log ext3 noatime 0 0
/dev/mapper/store-update /var/lib/update ext3 noauto,noatime 0
0
proc /proc proc defaults 0 0
devpts /dev/pts devpts mode=0620,gid=5 0 0
tmpfs /tmp tmpfs size=40M,mode=1777 0 0
tmpfs /var/run tmpfs size=16M,mode=1777 0 0
tmpfs /var/tmp tmpfs size=32M,mode=1777 0 0
tmpfs /media/ram tmpfs defaults 0 0
/dev/mapper/store-media /media/internal vfat utf8,shortname=mixed,umask=0000
0 0
===================
Actually fixing it
===================
I found something different using the lvdisplay command verses another thread where a guy posted his.
This is from another forum I found, look at segments
Code:
--- Logical volume ---
LV Name /dev/store/media
VG Name store
LV UUID GwzQv1-Oewn-niF3-y2i4-jM23-n8ke-DbWAzV
LV Write Access read/write
LV Status available
# open 1
LV Size 4.00 GB
Current LE 512
Segments 1
Allocation inherit
Read ahead sectors auto
- currently set to 256
Persistent major 254
Persistent minor 6
Block device 254:6
Here is mine.
Mine for some reason shows 2 segments instead of 1, so I assume there is a problem here.
Code:
---Logicalvolume---
LV Name /dev/store/media
VG Name store
LV UUID muJmcF-yDe4-qF6d-QA8E-T31q-FMSq-6RTiZx
LV Write Access read/write
LV Status available
# open 1
LV Size 27.53GB
Current LE 3524
Segments 2
Allocation inherit
Read ahead sectors auto
-currently set to 256
Persistent major 254
Persistent minor 6
Block device 254:6
.
[edit1] - I managed to fixed having 2 segments by deleting that partition altogether and making a new one, I assume mine had 2 segments due to me formatting it in windows.
[edit2] - after booting up my touchpad and hooking it up to my computer, I can see all the files on that partition again.
======================================
Edit 2
======================================
Thanks to TheSilverRing for pointing out I forgot to mention how to actually fix it
I fixed the mounting problem by formatting log and var to ext3.
use these commands -
mkfs.ext3 /dev/mapper/store-var
mkfs.ext3 /dev/mapper/store-log
mount -a
mkdir /var/log
mkdir /var/tmp
mkdir /var/run
I doctored my touchpad, and it boots up to live another day.
Hi, I'm having the same error when I try to doctor my TouchPad, although I haven't installed CM7 or messed with my unit in any way, it came with this problem out of the box.
So I try to do the same thing you did, I tried to format the log volume using developer mode console as well as the available console after failed doctoring. Both ways it claims to format successfully, but still gives "Invalid Argument" error when I try to mount the volume. I tried checking the filesystem on the volume, I get an error suggesting "zero size partition", although lvscan says that the log volume is 64MB. I can't remove any volumes or volume group from lvm either, it says it does it but I scan it again and its still there. Basically any changes I try to make are not persistent.
What do I do to fix this?
My touchpad seems to be in read only mode. Not able to webos doctor properly because of it. Cant reinstall cyanogenmod either. I have access to webos recovery and clockwork mod. Any command to get write access back?
hyperfire21 said:
My touchpad seems to be in read only mode. Not able to webos doctor properly because of it. Cant reinstall cyanogenmod either. I have access to webos recovery and clockwork mod. Any command to get write access back?
Click to expand...
Click to collapse
After 5 frustrating evenings alternating between charging and linux shell of the nova boot image trying to wipe partitions and partition table to be able to doctor again, I did not succeed. It simply won't write anything, including the block device of the flash. Because I didn't have cyanogenmod installed or anything other than WebOS, I did not void my warranty, so I sent it to HP, because it would not update or doctor to 3.0.4 . It arrived at the El Paso, TX facility on Friday, should have it (or the replacement) back by the end of the week.
Look in this thread for the outcome, when HP sends me back my TouchPad:
http://forum.xda-developers.com/showthread.php?t=1326004&page=2
I put my touchpad into a similar state, although mine did not end up with the 2 segments. I wiped my partition 14 with dd, sort of deliberately. I was investigating a native openembedded linux build but got wrapped around the axle with the uImage boot cmd line. Anyway, I got tired of using lvm as the kernel cmd line becomes more complex. So when I was putting things back I did the same lvm.static commands and pretty much what the OP did here, I have 2 touchpads so I copied the LVM structure from the golden one, it was the same as listed here.
There are a couple of things that might help someone that were not mentioned -
When booting you may see an error like:
mount: mounting /dev/mapper/store-var on /var failed: Invalid argument
mount: mounting /dev/mapper/store-log on /var/log failed: Invalid argument
What you need to do is format store-var and store-log like the OP said.
However, you will also need to create some mount points in var too, as per the fstab:
mkfs.ext3 /dev/mapper/store-var
mkfs.ext3 /dev/mapper/store-log
mount -a
mkdir /var/log
mkdir /var/tmp
mkdir /var/run
---------- Post added at 06:46 PM ---------- Previous post was at 06:37 PM ----------
what do you mean by read-only mode?
mount -o remount, rw /
replace '/' with whatever mount point your want Read/Write, you didn't really make clear what you meant by read-only.
Look at the fstab above, the lines with 'ro' , in them specifically the root, will be mounted read only.
If the file system has errors the os will mount it read only too - fsck the partition to fix it.
Could you post something about the error such as the novaterm command you are trying to execute as well as the output from 'mount'
I will mention my case for the record, my TouchPad had a problem writing to the flash, like the partition table writing failed, formatting filesystems failed, wiring to block device failed with I/O errors.
HP replaced components inside my TouchPad to solve the problem. If you have not voided the warranty on your device and your flash fails to write, you have a hardware problem, and should have HP service it at no cost to you.
Please try all the software repair methods posted in these threads before blaming the hardware though!!!

making a nook-bootable SD card (in general) on Linux

It took me a while to figure out why verygreen's image worked, but I was not able to reproduce the result by creating my own partitions and copying his files over. Looking more closely at verygreen's image and my own, I noticed that the first partitions started at different positions. I was able to get my homebrew SD card working just by making the first partition start at the 63rd sector:
Code:
$ sudo fdisk -l /dev/sdb
Disk /dev/sdb: 15.9 GB, 15931539456 bytes
64 heads, 32 sectors/track, 15193 cylinders, total 31116288 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x000e525a
Device Boot Start End Blocks Id System
/dev/sdb1 * 63 329790 164864 e W95 FAT16 (LBA)
/dev/sdb2 329791 1312830 491520 83 Linux
/dev/sdb3 1312831 3409982 1048576 83 Linux
/dev/sdb4 3409983 31116287 13853152+ c W95 FAT32 (LBA)
How do you do this using fdisk? After you create the first partition, type 'x' for extra functionality (experts only). From there, you could then type 'b', then '1', then '63' to make your first partition start at the right place. Press 'r' to return to the main menu, and make the rest of your partitions from there. Note that this operation breaks whatever filesystem was originally on the first partition, so it would need to be reformatted. MAKE BACKUPS. Don't forget to write changes!
FatTire and nemith confirmed that the first partition needed to be special, and pointed to this informational page. It even contains a nifty script. I didn't need most of that, since tweaking the beginning-of-data worked for me every time, but give it a read anyway.
You know, I'm sure this was something very simple for the ones that knew. But I too struggled with creating a bootable sdcard from scratch. I would set up all the correct partitions with the correct flags and still nogo. Who would've thought it would be something as simple as that. Thanks for this!
-Racks
Now I can create my own "Verygreen" installer img, muah ha hah... It was that whole formatting the uSD thing with those special considerations that has been tripping me up the whole time.
This didnt work for me, anyone have a script that could format a boot partition and an ext 3 partition with it? one with custom boot size like 4Gb fat or 3GB fat or 5GB fat prefferably 4.5GB but if you know how to customise the script below to create 4.5 GB fat partiton right now this creates only a 73 Mb fat partition the rest ext3
#! /bin/sh
# mkcard.sh v0.5
# (c) Copyright 2009 Graeme Gregory <[email protected]>
# Licensed under terms of GPLv2
#
# Parts of the procudure base on the work of Denys Dmytriyenko
# http://wiki.omap.com/index.php/MMC_Boot_Format
export LC_ALL=C
if [ $# -ne 1 ]; then
echo "Usage: $0 <drive>"
exit 1;
fi
DRIVE=$1
dd if=/dev/zero of=$DRIVE bs=1024 count=1024
SIZE=`fdisk -l $DRIVE | grep Disk | grep bytes | awk '{print $5}'`
echo DISK SIZE - $SIZE bytes
CYLINDERS=`echo $SIZE/255/63/512 | bc`
echo CYLINDERS - $CYLINDERS
{
echo ,9,0x0C,*
echo ,,,-
} | sfdisk -D -H 255 -S 63 -C $CYLINDERS $DRIVE
sleep 1
if [ -x `which kpartx` ]; then
kpartx -a ${DRIVE}
fi
# handle various device names.
# note something like fdisk -l /dev/loop0 | egrep -E '^/dev' | cut -d' ' -f1
# won't work due to https://bugzilla.redhat.com/show_bug.cgi?id=649572
PARTITION1=${DRIVE}1
if [ ! -b ${PARTITION1} ]; then
PARTITION1=${DRIVE}p1
fi
DRIVE_NAME=`basename $DRIVE`
DEV_DIR=`dirname $DRIVE`
if [ ! -b ${PARTITION1} ]; then
PARTITION1=$DEV_DIR/mapper/${DRIVE_NAME}p1
fi
PARTITION2=${DRIVE}2
if [ ! -b ${PARTITION2} ]; then
PARTITION2=${DRIVE}p2
fi
if [ ! -b ${PARTITION2} ]; then
PARTITION2=$DEV_DIR/mapper/${DRIVE_NAME}p2
fi
# now make partitions.
if [ -b ${PARTITION1} ]; then
umount ${PARTITION1}
mkfs.vfat -F 32 -n "boot" ${PARTITION1}
else
echo "Cant find boot partition in /dev"
fi
if [ -b ${PARITION2} ]; then
umount ${PARTITION2}
mke2fs -j -L "Angstrom" ${PARTITION2}
else
echo "Cant find rootfs partition in /dev"
fi
DroidisLINUX said:
This didnt work for me, anyone have a script that could format a boot partition and an ext 3 partition with it? one with custom boot size like 4Gb fat or 3GB fat or 5GB fat prefferably 4.5GB but if you know how to customise the script below to create 4.5 GB fat partiton right now this creates only a 73 Mb fat partition the rest ext3
#! /bin/sh
# mkcard.sh v0.5
# (c) Copyright 2009 Graeme Gregory <[email protected]>
# Licensed under terms of GPLv2
#
# Parts of the procudure base on the work of Denys Dmytriyenko
# http://wiki.omap.com/index.php/MMC_Boot_Format
export LC_ALL=C
if [ $# -ne 1 ]; then
echo "Usage: $0 <drive>"
exit 1;
fi
DRIVE=$1
dd if=/dev/zero of=$DRIVE bs=1024 count=1024
SIZE=`fdisk -l $DRIVE | grep Disk | grep bytes | awk '{print $5}'`
echo DISK SIZE - $SIZE bytes
CYLINDERS=`echo $SIZE/255/63/512 | bc`
echo CYLINDERS - $CYLINDERS
{
echo ,9,0x0C,*
echo ,,,-
} | sfdisk -D -H 255 -S 63 -C $CYLINDERS $DRIVE
sleep 1
if [ -x `which kpartx` ]; then
kpartx -a ${DRIVE}
fi
# handle various device names.
# note something like fdisk -l /dev/loop0 | egrep -E '^/dev' | cut -d' ' -f1
# won't work due to https://bugzilla.redhat.com/show_bug.cgi?id=649572
PARTITION1=${DRIVE}1
if [ ! -b ${PARTITION1} ]; then
PARTITION1=${DRIVE}p1
fi
DRIVE_NAME=`basename $DRIVE`
DEV_DIR=`dirname $DRIVE`
if [ ! -b ${PARTITION1} ]; then
PARTITION1=$DEV_DIR/mapper/${DRIVE_NAME}p1
fi
PARTITION2=${DRIVE}2
if [ ! -b ${PARTITION2} ]; then
PARTITION2=${DRIVE}p2
fi
if [ ! -b ${PARTITION2} ]; then
PARTITION2=$DEV_DIR/mapper/${DRIVE_NAME}p2
fi
# now make partitions.
if [ -b ${PARTITION1} ]; then
umount ${PARTITION1}
mkfs.vfat -F 32 -n "boot" ${PARTITION1}
else
echo "Cant find boot partition in /dev"
fi
if [ -b ${PARITION2} ]; then
umount ${PARTITION2}
mke2fs -j -L "Angstrom" ${PARTITION2}
else
echo "Cant find rootfs partition in /dev"
fi
Click to expand...
Click to collapse
Code:
# fdisk /dev/sdb
Command (m for help): o
Building a new DOS disklabel. Changes will remain in memory only,
until you decide to write them. After that, of course, the previous
content won't be recoverable.
Warning: invalid flag 0x0000 of partition table 4 will be corrected by w(rite)
Print card info:
Command (m for help): p
Disk /dev/sdb: 128 MB, 128450560 bytes
....
Note card size in bytes. Needed later below.
Then go into "Expert mode":
Command (m for help): x
Now we want to set the geometry to 255 heads, 63 sectors and calculate the number of cylinders required for the particular SD/MMC card:
Expert command (m for help): h
Number of heads (1-256, default 4): 255
Expert command (m for help): s
Number of sectors (1-63, default 62): 63
Warning: setting sector offset for DOS compatiblity
Expert command (m for help): c
Number of cylinders (1-1048576, default 1011): 15
In this case 128MB card is used (reported as 128450560 bytes by fdisk above), thus 128450560 / 255 / 63 / 512 = 15.6 rounded down to 15 cylinders. Numbers there are 255 heads, 63 sectors, 512 bytes per sector.
Now, return to main mode and create a new partition:
Expert command (m for help): r
Command (m for help): n
Command action
e extended
p primary partition (1-4)
p
Partition number (1-4): 1
First cylinder (1-15, default 1): 1
Last cylinder or +size or +sizeM or +sizeK (1-15, default 15): 15
Mark it bootable:
Command (m for help): a
Partition number (1-4): 1
And change its type to FAT32:
Command (m for help): t
Selected partition 1
Hex code (type L to list codes): c
Changed system type of partition 1 to c (W95 FAT32 (LBA))
The result is:
Command (m for help): p
Disk /dev/sdb: 128 MB, 128450560 bytes
255 heads, 63 sectors/track, 15 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/sdb1 * 1 15 120456 c W95 FAT32 (LBA)
Now, really write configuration to card (until here, card is not changed):
Command (m for help): w
The partition table has been altered!
Calling ioctl() to re-read partition table.
WARNING: If you have created or modified any DOS 6.x
partitions, please see the fdisk manual page for additional
information.
Syncing disks.
Done! What's left is to format our partition as FAT32 to be mounted and populated:
# mkfs.vfat -F 32 /dev/sdb1
mkfs.vfat 2.11 (12 Mar 2005)
Note: before running mkfs.vfat (included in the dosfstools package in Debian) make sure /dev/sdb is not mounted.
# mount /dev/sdb1 /mnt/tmp
Note: If you use additional mkfs.vfat parameter -n you can give the card a name, e.g. for easier identification (i.e. mkfs.vfat -n omap3 -F 32 /dev/sdb1)
The SD/MMC card is now ready to be used to boot OMAP3 boards.
sfdisk
In order to format same card using sfdisk, one needs to do the following:
# sfdisk -H 255 -S 63 -C 15 /dev/sdb << EOF
> ,,b,*
> EOF
This worked for me, once I used mkcard.sh I deleted the partitions then created a new partition following these steps and now I have a 4.5 Gb boot partition and a 3.0 ext3 Angstrom partition and a 500 Mb swap partition I found that the angstrom only needed about 2.7 to 2.8 Gb or space so that was why I wanted it this way so I could still have a large sdcard when I boot normaly.
I did have to do some math as my sdcard is a 8 GB sdcard not a 128 megs but once i did the math the cyclenders came out to be 966 and then I did everything else like it said make sure to add bootable flag and edit first sector at 63 on the first partition then it works, if you have problems try to change id to option e worked (W95 FAT16 (LBA)) and use mkfs.vfat -F 16 /dev/sdb1 other wise try option c mkfs.vfat -F 32 /dev/sdb1. I got the fat 32 to work so I am happy

[Guide] Factory condition restoration / Downgrade to webOS 3.0.0

This is for all those people who want to start over. I made the mistake of using webOS Doctor without removing the Android and Linux partitions. That left me with a deer turd for an HP TouchPad. So after about 2 hours of slaving, I figured out what to do
I. What you need
Novacom - Click
Novaterm - Click (or found in C:\Program Files\Palm, Inc\terminal. Run novaterm.bat)
Recovery uImage - Click
WebOS Doctor 3.0.0 - Click
WebOS Doctor 3.0.4 (optional) - Click
II. What to do
1) Install Novacom and extract Novaterm.
2) Open a command prompt and navigate to your Palm, Inc folder (usually \Program Files\Palm, Inc)
3) Move the recovery uImage to the Palm, Inc folder.
4) Boot your Touchpad into recovery (Power + Volume Up from power off)
5) In that command prompt, run ( novacom boot mem:// < nova-installer-image-topaz.uImage ) (without the parenthesis)
6) Once run, all you'll see on the Touchpad is the HP logo. This is good. Now open Novaterm and hit Connect
7) If you see a prompt that says something like "[email protected] device" this is good, now run these commands IN ORDER and these commands are CASE SENSITIVE
(For 32GB Touchpads only)
lvm.static vgscan --ignorelockingfailure
lvm.static vgchange -ay --ignorelockingfailure
lvm.static vgremove store
lvm.static vgscan --ignorelockingfailure
lvm.static vgchange -ay --ignorelockingfailure
lvm.static vgcreate -s 8M store /dev/mmcblk0p14
lvm.static vgscan --ignorelockingfailure
lvm.static vgchange -ay --ignorelockingfailure
lvm.static lvcreate -l 71 -i 1 -M y --major 254 --minor 0 -n root store
lvm.static lvcreate -l 8 -i 1 -M y --major 254 --minor 1 -n var store
lvm.static lvcreate -l 2 -i 1 -M y --major 254 --minor 2 -n update store
lvm.static lvcreate -l 3 -i 1 -M y --major 254 --minor 3 -n log store
lvm.static lvcreate -l 32 -i 1 -M y --major 254 --minor 4 -n mojodb store
lvm.static lvcreate -l 17 -i 1 -M y --major 254 --minor 5 -n filecache store
lvm.static lvcreate -l 3523 -i 1 -M y --major 254 --minor 6 -n media store
lvm.static lvcreate -l 64 -i 1 -M y --major 254 --minor 7 -n swap store
lvm.static vgscan --ignorelockingfailure
lvm.static vgchange -ay --ignorelockingfailure
mkdosfs -f 1 -s 64 /dev/store/media
Click to expand...
Click to collapse
(16GB Touchpads)
lvm.static vgscan --ignorelockingfailure
lvm.static vgchange -ay --ignorelockingfailure
lvm.static vgremove store
lvm.static vgscan --ignorelockingfailure
lvm.static vgchange -ay --ignorelockingfailure
lvm.static vgcreate -s 8M store /dev/mmcblk0p14
lvm.static vgscan --ignorelockingfailure
lvm.static vgchange -ay --ignorelockingfailure
lvm.static lvcreate -l 71 -i 1 -M y --major 254 --minor 0 -n root store
lvm.static lvcreate -l 8 -i 1 -M y --major 254 --minor 1 -n var store
lvm.static lvcreate -l 2 -i 1 -M y --major 254 --minor 2 -n update store
lvm.static lvcreate -l 3 -i 1 -M y --major 254 --minor 3 -n log store
lvm.static lvcreate -l 32 -i 1 -M y --major 254 --minor 4 -n mojodb store
lvm.static lvcreate -l 17 -i 1 -M y --major 254 --minor 5 -n filecache store
lvm.static lvcreate -l 1618 -i 1 -M y --major 254 --minor 6 -n media store
lvm.static lvcreate -l 64 -i 1 -M y --major 254 --minor 7 -n swap store
lvm.static vgscan --ignorelockingfailure
lvm.static vgchange -ay --ignorelockingfailure
mkdosfs -f 1 -s 64 /dev/store/media
Click to expand...
Click to collapse
8) When done, reboot the Touchpad into recovery (Power + Center/Home until screen off, then Power + Volume Up)
9) Run webOS Doctor 3.0.0 (This is to ensure a repartitioning and no other version will work at this point )
Branch 1) You can stop here to have 3.0.0 as your webOS version. You've just completed a downgrade that was before thought impossible.
Branch 2) If you want webOS 3.0.4, continue on.
10) When webOS Doctor is complete, hold down Power and Center, and when the screen turns off, immediately hold Power and Volume Up.
11) You'll see the USB icon again, just run webOS Doctor 3.0.4 and you're done.
Have fun.
_____________________________
For those having problems with novaterm:
LordGibson said:
I had the same problem with the downloaded novaterm on three different win7x64 machines. If you've run WebOS Doctor at all you should have a Palm, Inc/terminal/ folder with a novaterm.bat in it. Try using that instead.
Click to expand...
Click to collapse
For those having problems with Java:
lafester said:
got it working by adding the path to java.
set PATH =%PATH%;c:\program files (x86)\java\jre6\bin.
Click to expand...
Click to collapse
If someone can, can they provide the partition layout for 16GB Touchpads?
How could we find the partition layout ?
Edit :
--
I ran the following command on my 16GB TouchPad :
Code:
lvm.static vgdisplay
And I get :
Code:
Free PE / Size 1683 / 13.15 GB
Is it what you're looking for ?
spadewalk said:
How could we find the partition layout ?
Edit :
--
I ran the following command on my 16GB TouchPad :
Code:
lvm.static vgdisplay
And I get :
Code:
Free PE / Size 1683 / 13.15 GB
Is it what you're looking for ?
Click to expand...
Click to collapse
Can you run lvm.static lvdisplay ?
Sure.
Here you have :
Code:
lvm.static lvdisplay
--- Logical volume ---
LV Name /dev/store/root
VG Name store
LV UUID Aq5Mpj-p1ou-AMwd-j0YJ-1ytK-nHVn-NlOGUR
LV Write Access read/write
LV Status available
# open 1
LV Size 568.00 MB
Current LE 71
Segments 1
Allocation inherit
Read ahead sectors auto
- currently set to 256
Persistent major 254
Persistent minor 0
Block device 254:0
--- Logical volume ---
LV Name /dev/store/var
VG Name store
LV UUID 1OQAZu-Zx0P-fK6M-xdYj-8T0z-CoDw-2pwy00
LV Write Access read/write
LV Status available
# open 1
LV Size 64.00 MB
Current LE 8
Segments 1
Allocation inherit
Read ahead sectors auto
- currently set to 256
Persistent major 254
Persistent minor 1
Block device 254:1
--- Logical volume ---
LV Name /dev/store/update
VG Name store
LV UUID 9Cpv99-Al2S-eCWp-ioAi-AGMS-T10i-qba3pn
LV Write Access read/write
LV Status available
# open 0
LV Size 16.00 MB
Current LE 2
Segments 1
Allocation inherit
Read ahead sectors auto
- currently set to 256
Persistent major 254
Persistent minor 2
Block device 254:2
--- Logical volume ---
LV Name /dev/store/log
VG Name store
LV UUID jaNcqX-uRU7-uwWi-yvZE-KHiN-K5RX-mh3jkJ
LV Write Access read/write
LV Status available
# open 1
LV Size 24.00 MB
Current LE 3
Segments 1
Allocation inherit
Read ahead sectors auto
- currently set to 256
Persistent major 254
Persistent minor 3
Block device 254:3
--- Logical volume ---
LV Name /dev/store/mojodb
VG Name store
LV UUID 7nT2OX-nlbV-U6HQ-UrVi-Pja6-nDwP-BpHsTR
LV Write Access read/write
LV Status available
# open 1
LV Size 256.00 MB
Current LE 32
Segments 2
Allocation inherit
Read ahead sectors auto
- currently set to 256
Persistent major 254
Persistent minor 4
Block device 254:4
--- Logical volume ---
LV Name /dev/store/filecache
VG Name store
LV UUID oH0jt0-AcIO-pFTF-3wD7-cYC2-W88I-H0UqPj
LV Write Access read/write
LV Status available
# open 1
LV Size 136.00 MB
Current LE 17
Segments 1
Allocation inherit
Read ahead sectors auto
- currently set to 256
Persistent major 254
Persistent minor 5
Block device 254:5
--- Logical volume ---
LV Name /dev/store/media
VG Name store
LV UUID NWNspe-aKe5-glCM-c0mb-15sM-32Mu-64e8jx
LV Write Access read/write
LV Status available
# open 1
LV Size 12.64 GB
Current LE 1618
Segments 1
Allocation inherit
Read ahead sectors auto
- currently set to 256
Persistent major 254
Persistent minor 6
Block device 254:6
--- Logical volume ---
LV Name /dev/store/swap
VG Name store
LV UUID TOq7Y8-2XCB-diKE-3D7s-3pIp-Ksbl-4LbZP0
LV Write Access read/write
LV Status available
# open 1
LV Size 512.00 MB
Current LE 64
Segments 2
Allocation inherit
Read ahead sectors auto
- currently set to 256
Persistent major 254
Persistent minor 7
Block device 254:7
spadewalk said:
Sure.
Here you have :
Code:
lvm.static lvdisplay
--- Logical volume ---
LV Name /dev/store/root
VG Name store
LV UUID Aq5Mpj-p1ou-AMwd-j0YJ-1ytK-nHVn-NlOGUR
LV Write Access read/write
LV Status available
# open 1
LV Size 568.00 MB
Current LE 71
Segments 1
Allocation inherit
Read ahead sectors auto
- currently set to 256
Persistent major 254
Persistent minor 0
Block device 254:0
--- Logical volume ---
LV Name /dev/store/var
VG Name store
LV UUID 1OQAZu-Zx0P-fK6M-xdYj-8T0z-CoDw-2pwy00
LV Write Access read/write
LV Status available
# open 1
LV Size 64.00 MB
Current LE 8
Segments 1
Allocation inherit
Read ahead sectors auto
- currently set to 256
Persistent major 254
Persistent minor 1
Block device 254:1
--- Logical volume ---
LV Name /dev/store/update
VG Name store
LV UUID 9Cpv99-Al2S-eCWp-ioAi-AGMS-T10i-qba3pn
LV Write Access read/write
LV Status available
# open 0
LV Size 16.00 MB
Current LE 2
Segments 1
Allocation inherit
Read ahead sectors auto
- currently set to 256
Persistent major 254
Persistent minor 2
Block device 254:2
--- Logical volume ---
LV Name /dev/store/log
VG Name store
LV UUID jaNcqX-uRU7-uwWi-yvZE-KHiN-K5RX-mh3jkJ
LV Write Access read/write
LV Status available
# open 1
LV Size 24.00 MB
Current LE 3
Segments 1
Allocation inherit
Read ahead sectors auto
- currently set to 256
Persistent major 254
Persistent minor 3
Block device 254:3
--- Logical volume ---
LV Name /dev/store/mojodb
VG Name store
LV UUID 7nT2OX-nlbV-U6HQ-UrVi-Pja6-nDwP-BpHsTR
LV Write Access read/write
LV Status available
# open 1
LV Size 256.00 MB
Current LE 32
Segments 2
Allocation inherit
Read ahead sectors auto
- currently set to 256
Persistent major 254
Persistent minor 4
Block device 254:4
--- Logical volume ---
LV Name /dev/store/filecache
VG Name store
LV UUID oH0jt0-AcIO-pFTF-3wD7-cYC2-W88I-H0UqPj
LV Write Access read/write
LV Status available
# open 1
LV Size 136.00 MB
Current LE 17
Segments 1
Allocation inherit
Read ahead sectors auto
- currently set to 256
Persistent major 254
Persistent minor 5
Block device 254:5
--- Logical volume ---
LV Name /dev/store/media
VG Name store
LV UUID NWNspe-aKe5-glCM-c0mb-15sM-32Mu-64e8jx
LV Write Access read/write
LV Status available
# open 1
LV Size 12.64 GB
Current LE 1618
Segments 1
Allocation inherit
Read ahead sectors auto
- currently set to 256
Persistent major 254
Persistent minor 6
Block device 254:6
--- Logical volume ---
LV Name /dev/store/swap
VG Name store
LV UUID TOq7Y8-2XCB-diKE-3D7s-3pIp-Ksbl-4LbZP0
LV Write Access read/write
LV Status available
# open 1
LV Size 512.00 MB
Current LE 64
Segments 2
Allocation inherit
Read ahead sectors auto
- currently set to 256
Persistent major 254
Persistent minor 7
Block device 254:7
Click to expand...
Click to collapse
Thank you. I was able to make the correct commands for 16GB Touchpads.
Good, that's awesome.
where is the novacom installer?
and the webdoctor, for that matter?
did i have to read 20 other threads / posts before this one?
lol
serialteg said:
where is the novacom installer?
and the webdoctor, for that matter?
did i have to read 20 other threads / posts before this one?
lol
Click to expand...
Click to collapse
If you even bothered to look at the post, you'd see that next to each one, there is a word that says "click". And if you clicked on them, you'd see that they are DIRECT links to what you need.
Just wanted to say this worked for me too; in case anyone is worried. I had Ubuntu native, CM9, and Webos (duh) installed but my /media/internal partition was messed up (webos and windows 7 said it was 22GB while lvscan said 14GB). I tried doctoring but just got a hp logo boot loop. These commands got me back to webos.
same here, but after following this tutorial my touchpad iz back to life, thank you !
Wow this is a great tut and I bet there is a lot of people who wI'll
Be needing this soon!!
Thanks
saved my TP thanks!!! but my app catalog has a yellow triangle in the corner....any ideas?
Sadly, this did not work for me. The WebOS Doctor 3.0.0 completes successfully but the TP never boots up fully - rolls right back into the boot loop. Just for the hell of it I ran the 3.0.5 update afterwards. That also completes successfully, but lands right back into the boot loop.
I've just finished my third attempt from start to finish with no luck. Guess I must be looking at a hardware problem. . . Any other ideas?
LordGibson said:
Sadly, this did not work for me. The WebOS Doctor 3.0.0 completes successfully but the TP never boots up fully - rolls right back into the boot loop. Just for the hell of it I ran the 3.0.5 update afterwards. That also completes successfully, but lands right back into the boot loop.
I've just finished my third attempt from start to finish with no luck. Guess I must be looking at a hardware problem. . . Any other ideas?
Click to expand...
Click to collapse
Did you run the comands in order and did you use the proper partition setup for your touchpad?
rr5678 said:
Did you run the comands in order and did you use the proper partition setup for your touchpad?
Click to expand...
Click to collapse
Affirmative. By the third time through I was pretty anal about doing everything perfectly and exactly as indicated.
LordGibson said:
Affirmative. By the third time through I was pretty anal about doing everything perfectly and exactly as indicated.
Click to expand...
Click to collapse
Start it. And while it's doing the boot loop, see if you can connect with novaterm.
It's a refurb unit, so it's probably a hardware problem - just strange that the doctors seemingly work so well.
Maybe I'll try 16gb just for the hell of it. Perhaps it was mis-labeled. . .
---------- Post added at 10:27 PM ---------- Previous post was at 10:23 PM ----------
rr5678 said:
Start it. And while it's doing the boot loop, see if you can connect with novaterm.
Click to expand...
Click to collapse
No joy. Windows signals a connection, but can't find device in novaterm.
---------- Post added at 10:54 PM ---------- Previous post was at 10:27 PM ----------
LordGibson said:
Maybe I'll try 16gb just for the hell of it. Perhaps it was mis-labeled. . .
Click to expand...
Click to collapse
For future reference, I would recommend against this course of action.
LordGibson said:
---------- Post added at 10:27 PM ---------- Previous post was at 10:23 PM ----------
No joy. Windows signals a connection, but can't find device in novaterm.
Click to expand...
Click to collapse
Boot it into the recovery uImage and check what's in the boot folder.
LordGibson said:
---------- Post added at 10:54 PM ---------- Previous post was at 10:27 PM ----------
For future reference, I would recommend against this course of action.
Click to expand...
Click to collapse
You could have had yourself a doorstop.
Code:
[email protected]:/boot# ls -la
drwxr-xr-x 2 root root 1024 Jul 30 2011 .
drwxr-xr-x 17 root root 1024 Jul 30 2011 ..
-rw-r--r-- 1 root root 490764 Jul 30 2011 boot-genesis.tar.gz
-rw-r--r-- 1 root root 119371 Jul 30 2011 boot-images.tar.gz
-rw-r--r-- 1 root root 115392 Jul 30 2011 boot.bin
-rwxr-xr-x 1 root root 1131 Jul 30 2011 genesis-update.xml
-rwxr-xr-x 1 root root 2224 Jul 30 2011 image-update.xml
lrwxrwxrwx 1 root root 29 Jul 30 2011 uImage -> uImage-2.6.35-palm-tenderloin
-rw-r--r-- 1 root root 3333228 Jul 30 2011 uImage-2.6.35-palm-tenderloin

[Q]Error building cyanogenmod

I am getting these errors while the system.img is being made. Making for an ARMv6 device . Samsung Galaxy Fit aka Beni
I am getting these errors
+ FC=
+ case $EXT_VARIANT in
+ '[' -z system ']'
+ '[' -z 229938816 ']'
+ '[' -n '' ']'
+ MAKE_EXT4FS_CMD='make_ext4fs -s -l 229938816 -a system /home/yajnavalkya/cm10/out/target/product/beni/obj/PACKAGING/systemimage_intermediates/system.img /home/yajnavalkya/cm10/out/target/product/beni/system'
+ echo make_ext4fs -s -l 229938816 -a system /home/yajnavalkya/cm10/out/target/product/beni/obj/PACKAGING/systemimage_intermediates/system.img /home/yajnavalkya/cm10/out/target/product/beni/system
make_ext4fs -s -l 229938816 -a system /home/yajnavalkya/cm10/out/target/product/beni/obj/PACKAGING/systemimage_intermediates/system.img /home/yajnavalkya/cm10/out/target/product/beni/system
+ make_ext4fs -s -l 229938816 -a system /home/yajnavalkya/cm10/out/target/product/beni/obj/PACKAGING/systemimage_intermediates/system.img /home/yajnavalkya/cm10/out/target/product/beni/system
Creating filesystem with parameters:
Size: 229937152
Block size: 4096
Blocks per group: 32768
Inodes per group: 7024
Inode size: 256
Journal blocks: 1024
Label:
Blocks: 56137
Block groups: 2
Reserved block group size: 15
error: do_inode_allocate_extents: Failed to allocate 2006 blocks
+ '[' 1 -ne 0 ']'
+ exit 4
error: failed to build /home/yajnavalkya/cm10/out/target/product/beni/obj/PACKAGING/systemimage_intermediates/system.img from /home/yajnavalkya/cm10/out/target/product/beni/system
make: *** [/home/yajnavalkya/cm10/out/target/product/beni/obj/PACKAGING/systemimage_intermediates/system.img] Error 1
make: *** Deleting file `/home/yajnavalkya/cm10/out/target/product/beni/obj/PACKAGING/systemimage_intermediates/system.img'
I have a AMD fx-6100(3.4GHZ), 4GB RAM and 50GB free space on HDD but i am getting this error. How to solve this
Not enough memory.
Yeah...not enough HDD space...once everything is downloaded, extracted, then built...it takes close to 70gb...the out directory alone ends up being about 25gb...
Sent from my SGH-I997 using Tapatalk 2
mg2195 said:
Yeah...not enough HDD space...once everything is downloaded, extracted, then built...it takes close to 70gb...the out directory alone ends up being about 25gb...
Sent from my SGH-I997 using Tapatalk 2
Click to expand...
Click to collapse
Still 50 GB of Diskspace is left:laugh:

Multi-Boot RPi from Command Line [31 Oct 2013]

I wrote a shell script to multi-boot my RPi from a terminal. Script can be executed remotely via SSH or VNC.
Features:
Automatically detect all ext4 partitions of all storage devices attached to RPi (ext4 is the default partition type for hosting an RPi-compatible OS)
Reconstruct boot device names (root=/dev/*) from partition editor output. No changes are made to storage devices
Generate table of boot options and prompt user for option
Include option to shutdown
Reboot to selected rootfs, e.g. /dev/sda2 according to user-selected boot option
Script uses partition editor (parted) to identify the storage device paths. I did have to install parted on Raspbmc:
Code:
sudo apt-get install parted
Presently I have triple boot:
Raspbian #1 on SD (/dev/mmcblk0p2)
Raspbian #2 on USB HD (/dev/sda2)
Raspbmc on USB HD (/dev/sda4)
Partition Info:
PNY 16GB SD
[email protected]:/boot# parted /dev/mmcblk0 print
Model: SD SD16G (sd/mmc)
Disk /dev/mmcblk0: 16.0GB
Sector size (logical/physical): 512B/512B
Partition Table: msdos
Number Start End Size Type File system Flags
1 4194kB 62.9MB 58.7MB primary fat16 lba
2 62.9MB 16.0GB 15.9GB primary ext4
Western Digital 160GB HD 7200 RPM
[email protected]:/boot# parted /dev/sda print
Model: WDC WD1600BJKT-75F4T (scsi)
Disk /dev/sda: 160GB
Sector size (logical/physical): 512B/512B
Partition Table: msdos
Number Start End Size Type File system Flags
1 4194kB 62.9MB 58.7MB primary fat16 lba
2 77.6MB 21.5GB 21.5GB primary ext4
3 21.5GB 25.8GB 4295MB primary linux-swap(v1)
4 25.8GB 160GB 134GB primary ext4
And here's the boot script (/boot/rpiboot.sh):
Code:
#!/bin/sh
echo
echo "Reboot RPi to rootfs... "
cd /boot
ftxt="cmdline.txt"
fbak="cmdline.bak"
fnew="cmdline.new"
if [ -f $fnew ]
then
rm $fnew
fi
echo
rootfs=$(awk '{for (i=1; i<NF; i++) if (match($i,"root=")) {sub("root=", "", $i); print $i} }' $ftxt)
echo "Current rootfs: $rootfs"
#Reconstructing device names from partition editor output
parted /dev/mmcblk0 print > parted.txt
mmcname=$(awk '/\/dev\// {printf "%s", substr($2,1,length($2)-1) }' parted.txt)
awk -v mmcname=$mmcname '/ext4/ {printf "%sp%d\n", mmcname, $1 > "ext4.txt" }' parted.txt
parted /dev/sda print > parted.txt
mmcname=$(awk '/\/dev\// {printf "%s", substr($2,1,length($2)-1) }' parted.txt)
awk -v mmcname=$mmcname '/ext4/ {printf "%s%d\n", mmcname, $1 >> "ext4.txt" }' parted.txt
echo
echo "Boot options for rootfs:"
cat -n ext4.txt > ext4_enum.txt
more ext4_enum.txt
echo
printf "Enter boot option (press ENTER to shutdown or CNTL-z to exit):"
read -r ext4_index
if test -z "$ext4_index"
then
echo
echo "Shutting down in 3 seconds..."
sleep 3
shutdown -h now
exit 0
fi
#Determine rootfs corresponding to boot option
rootfs=$(awk -v ext4_index=$ext4_index '{if (match($1,ext4_index)) print $2}' ext4_enum.txt)
if test -z "$rootfs"
then
echo
echo "Invalid boot option or other error. Exiting..."
exit 1
fi
awk -v rootfs=$rootfs -v fnew=$fnew '{
for (i=1; i<NF; i++) if (match($i,"root=")) {$i = "root=" rootfs; print $0 > fnew} }' $ftxt
if [ -f $fnew ]
then
printf "Press ENTER to reboot to $rootfs, or CNTL-z to exit."
read -r text
mv $ftxt $fbak
mv $fnew $ftxt
fi
echo
echo "/boot/cmdline.txt:"
more $ftxt
echo "Rebooting to $rootfs in 3 seconds..."
sleep 3
reboot
exit 0
Launching rpiboot.sh as root, here are my own results of a boot switch from /dev/sda2 (Raspbian) to /dev/sda4 (Raspbmc):
Code:
[email protected] ~ $ sudo sh /boot/rpiboot.sh
Reboot RPi to rootfs...
Current rootfs: /dev/sda2
Boot options for rootfs:
1 /dev/mmcblk0p2
2 /dev/sda2
3 /dev/sda4
Enter boot option (press ENTER to shutdown or CNTL-z to exit):3
Press ENTER to reboot to /dev/sda4, or CNTL-z to exit.
/boot/cmdline.txt:
dwc_otg.lpm_enable=0 root=/dev/sda4 rootfstype=ext4 noatime quiet rootwait loglevel=1 sdhci-bcm2708.enable_l
lm=1 dwc_otg.microframe_schedule=1 dwc_otg.fiq_fix_enable=0 dwc_otg.fiq_split_enable=0 dwc_otg.trans_backoff
=3000
Rebooting to /dev/sda4 in 3 seconds...
Broadcast message from [email protected] (pts/0) (Thu Oct 31 15:28:20 2013):
The system is going down for reboot NOW!
[email protected] ~ $ Connection to 10.0.0.16 closed by remote host.
Connection to 10.0.0.16 closed.
[email protected]:~#
And voila, Raspbmc comes up. I now SSH in from my Ubuntu laptop:
Code:
[email protected]:~# ssh [email protected]
[email protected]'s password:
The programs included with the Debian GNU/Linux system are free software;
the exact distribution terms for each program are described in the
individual files in /usr/share/doc/*/copyright.
Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent
permitted by applicable law.
[email protected]:~$
Of course VNC renders the elegant desktop experience, and setting up VNC is fairly straightforward:
http://learn.adafruit.com/adafruit-...control-with-vnc/running-vncserver-at-startup
However VNC does not work on Raspbmc since VNC relies on the X11 window system, while Raspbmc’s XBMC implementation is rendered in the framebuffer only. Thus VNC cannot be used as there is no X-session available for connection. See:
http://www.raspbmc.com/wiki/user/frequently-asked-questions/
But SSH works well.
Blessings. Enjoy!
tanks!
hello is verry good
please tuto create multiboot for noobs lol
And Raspbmc is EOL.
help
[email protected]:~ $ df -h
Sys. de fichiers Taille Utilis▒ Dispo Uti% Mont▒ sur
/dev/root 7,2G 4,5G 2,5G 65% /
devtmpfs 364M 0 364M 0% /dev
tmpfs 368M 0 368M 0% /dev/shm
tmpfs 368M 5,3M 363M 2% /run
tmpfs 5,0M 4,0K 5,0M 1% /run/lock
tmpfs 368M 0 368M 0% /sys/fs/cgroup
tmpfs 1,0M 4,0K 1020K 1% /var/pipeyelog
/dev/mmcblk0p1 60M 20M 41M 34% /boot
tmpfs 74M 0 74M 0% /run/user/1000
/dev/sda3 6,3G 15M 6,0G 1% /media/pi/e836e8e0-22be-4f6e-8836-1f4 039a627e8
/dev/sda2 7,2G 4,5G 2,5G 65% /media/pi/ad6203a1-ec50-4f44-a1c0-e6c 3dd4c9202
/dev/sda1 60M 20M 41M 34% /media/pi/boot
[email protected]:~ $ sudo sh /boot/rpiboot.sh
Reboot RPi to rootfs...
Current rootfs: /dev/mmcblk0p2
Boot options for rootfs:
1 /dev/mmcblk0p2
Enter boot option (press ENTER to shutdown or CNTL-z to exit):^Z
[1]+ Stopp▒ sudo sh /boot/rpiboot.sh
[email protected]:~ $
why not see my sda2 and sda3 partition ( Raspbian and raspbmc ) ??

Categories

Resources