Related
I'm trying to make an auto install script within the initramfs. I've got everything working, including automatic fdisk, but I cannot get mkfs.ext4 to work on the Android kernel, and there is no version of Busybox with the ext4 applet. Does anyone have a mkfs.ext4 that runs successfully on Android? When I run it from a terminal the output is
Code:
mkfs.ext4: 1: Syntax error: word unexpected (expecting ")")
Here's my code if you want to see what I'm doing.
Code:
mount /dev/mmcblk1p1 /tmp/mnt
if [ -f /tmp/mnt/mysticfw.tar.gz ]; then
$FDISK /dev/mmcblk0 < /home/fdisk.input
$MKFS_EXT4 -O ^huge_file /dev/mmcblk0p2
mount /dev/mmcblk1p2 /tmp/tmproot
mkdir /tmp/tmproot/itworks
tar -xzvf /tmp/mnt/mysticfw.tar.gz -C /tmp/tmproot/
sync
#rm /tmp/mnt/mysticfw.tar.gz
umount /tmp/tmproot
fi
sync
umount /tmp/mnt
It automatically partitions the stock Android block and installs a tar.gz from the internal storage to simplify my unsquashed 2.1.4 filesystem install, and the only part I can't get working is mkfs.ext4.
Found one! It's 3 MBs though, so if anyone has a smaller one, it would be very nice.
msticninja said:
I'm trying to make an auto install script within the initramfs. I've got everything working, including automatic fdisk, but I cannot get mkfs.ext4 to work on the Android kernel, and there is no version of Busybox with the ext4 applet. Does anyone have a mkfs.ext4 that runs successfully on Android? When I run it from a terminal the output is
Code:
mkfs.ext4: 1: Syntax error: word unexpected (expecting ")")
Click to expand...
Click to collapse
Why do you don't use the mke2fs from Uruk for example (the easiest way) asking $auron if it's ok for him. His size is only 49KB.
Find it like the following on Uruk installation:
Code:
[COLOR="DarkRed"]
# mkfs.ext4 -V
mke2fs 1.41.3 (12-Oct-2008)
Using EXT2FS Library version 1.41.3
# find / -name mke2fs | xargs ls -l
-rwxr-xr-x 1 root root 30584 Dec 15 03:46 /system/bin/mke2fs
[B]-rwxr-xr-x 5 root root 49248 4 Jan 15 13:14 /usr/local/sbin/mke2fs[/B]
#/usr/local/sbin/mke2fs -V
mke2fs 1.41.3 (12-Oct-2008)
Using EXT2FS Library version 1.41.3
[/COLOR]
Here's my code if you want to see what I'm doing.
Code:
mount /dev/mmcblk1p1 /tmp/mnt
if [ -f /tmp/mnt/mysticfw.tar.gz ]; then
$FDISK /dev/mmcblk0 < /home/fdisk.input
$MKFS_EXT4 -O ^huge_file /dev/mmcblk0p2
mount /dev/mmcblk1p2 /tmp/tmproot
mkdir /tmp/tmproot/itworks
tar -xzvf /tmp/mnt/mysticfw.tar.gz -C /tmp/tmproot/
sync
#rm /tmp/mnt/mysticfw.tar.gz
umount /tmp/tmproot
fi
sync
umount /tmp/mnt
It automatically partitions the stock Android block and installs a tar.gz from the internal storage to simplify my unsquashed 2.1.4 filesystem install, and the only part I can't get working is mkfs.ext4.
Click to expand...
Click to collapse
and don't forget to add "-l" on FDISK command and change the device mmcblk0 with mmcblk1 on the lines:
Code:
$FDISK /dev/mmcblk0 < /home/fdisk.input
$MKFS_EXT4 -O ^huge_file /dev/mmcblk0p2
Cheers,
shklifo said:
Why do you don't use the mke2fs from Uruk for example (the easiest way) asking $auron if it's ok for him. His size is only 49KB.
Find it like the following on Uruk installation:
Code:
[COLOR="DarkRed"]
# mkfs.ext4 -V
mke2fs 1.41.3 (12-Oct-2008)
Using EXT2FS Library version 1.41.3
# find / -name mke2fs | xargs ls -l
-rwxr-xr-x 1 root root 30584 Dec 15 03:46 /system/bin/mke2fs
[B]-rwxr-xr-x 5 root root 49248 4 Jan 15 13:14 /usr/local/sbin/mke2fs[/B]
#/usr/local/sbin/mke2fs -V
mke2fs 1.41.3 (12-Oct-2008)
Using EXT2FS Library version 1.41.3
[/COLOR]
and don't forget to add "-l" on FDISK command and change the device mmcblk0 with mmcblk1 on the lines:
Code:
$FDISK /dev/mmcblk0 < /home/fdisk.input
$MKFS_EXT4 -O ^huge_file /dev/mmcblk0p2
Cheers,
Click to expand...
Click to collapse
Why didn't I think of that? Thanks.
But regarding mmcblk0/1, I'm replacing the stock Android, so the fdisk.input file contains the commands to delete mmcblk0p2 and p3, and make a new partition in the unused space. I hate using space on my Internal Storage, so I'm using Archos' space.
msticninja said:
Why didn't I think of that? Thanks.
But regarding mmcblk0/1, I'm replacing the stock Android, so the fdisk.input file contains the commands to delete mmcblk0p2 and p3, and make a new partition in the unused space. I hate using space on my Internal Storage, so I'm using Archos' space.
Click to expand...
Click to collapse
If you are using the mmcblk0p2 as rootfs as you say (and you are expanded tar archive on mmcblk1p2), than you have to change the line:
mount /dev/mmcblk1p2 /tmp/tmproot
Click to expand...
Click to collapse
with
mount /dev/mmcblk0p2 /tmp/tmproot
Click to expand...
Click to collapse
shklifo said:
If you are using the mmcblk0p2 as rootfs as you say (and you are expanded tar archive on mmcblk1p2), than you have to change the line:
with
Click to expand...
Click to collapse
I know, that's my current data partition, I'll change it once I'm done testing. The tar file just has a test file in it, so when I boot back into block1, I can see if the IF statement was executed by seeing if it was extracted to block1. I'll also have to change etc/mountpoints once testing is actually finished.
One more question since you're so quick. I think I have everything working, except it needs a reboot in between the fdisk and mke2fs commands to reload the partition table. I'm trying to use partprobe instead of rebooting, but it hasn't been cross compiled to work on Android, AFAIK. Have you seen a way to reload the MBR without rebooting?
msticninja said:
I know, that's my current data partition, I'll change it once I'm done testing. The tar file just has a test file in it, so when I boot back into block1, I can see if the IF statement was executed by seeing if it was extracted to block1. I'll also have to change etc/mountpoints once testing is actually finished.
One more question since you're so quick. I think I have everything working, except it needs a reboot in between the fdisk and mke2fs commands to reload the partition table. I'm trying to use partprobe instead of rebooting, but it hasn't been cross compiled to work on Android, AFAIK. Have you seen a way to reload the MBR without rebooting?
Click to expand...
Click to collapse
I'v been looking at the recovery_lib.sh in the recovery boot image and can't find anything special to re-read the partition table. And yes they also use fdisk to repartition. So I suspect the driver for the block device does not cache the MBR and you can just mke2fs after the partition table is created.
I can't remember from what firmware that recovery boot image was but I think it's from the 2.1.04 and they do some repartitioning there for the swap space.
I'll check it again and get back to you.
wdl1908 said:
I'v been looking at the recovery_lib.sh in the recovery boot image and can't find anything special to re-read the partition table. And yes they also use fdisk to repartition. So I suspect the driver for the block device does not cache the MBR and you can just mke2fs after the partition table is created.
I can't remember from what firmware that recovery boot image was but I think it's from the 2.1.04 and they do some repartitioning there for the swap space.
I'll check it again and get back to you.
Click to expand...
Click to collapse
I just checked the recovery image from 2.1.04 and after the fdisk commands there is nothing to re-read the MBR the next commands executed are mount commands to check if the fs is present I suggest you look at the /etc/scripts/recovery_lib.sh yourself it could give some clues on how to do things.
wdl1908 said:
I just checked the recovery image from 2.1.04 and after the fdisk commands there is nothing to re-read the MBR the next commands executed are mount commands to check if the fs is present I suggest you look at the /etc/scripts/recovery_lib.sh yourself it could give some clues on how to do things.
Click to expand...
Click to collapse
For me too, it have nothing to do with a reboot to load partitions table and access partition to format them with the choised filesystem.
You can delete any partition on linux (except rootfs one ), recreate them and directly format them as you like, reboot isn't necesary.
Thanks for all the replies, very helpful, but I'm stuck. Fdisk seems to use ioctl to reload the partition table, so you don't need a reboot if everything on the device is unmounted before writing the partition table, but I'm having very strange issues with mke2fs now. I've had the whole thing work twice now, but when I flash back to stock, then retry the script, it usually does everything except the formatting. Here's the code:
Code:
mount /dev/mmcblk1p1 /tmp/mnt
if [ -f /tmp/mnt/mysticfw.tar.gz ]; then
umount /dev/mmcblk0p1
umount /dev/mmcblk0p2
umount /dev/mmcblk0p3
umount /dev/mmcblk0p4
fdisk /dev/mmcblk0 < /home/fdisk.input
mv /tmp/mnt/mysticfw.tar.gz /tmp/mnt/mysticf.tar.gz
sync
umount /tmp/mnt
log_and_reboot
fi
if [ -f /tmp/mnt/mysticf.tar.gz ]; then
rm /etc/mtab
touch /etc/mtab
mke2fs -T ext4 -O ^huge_file /dev/mmcblk0p2
mount /dev/mmcblk0p2 /tmp/tmproot
tar -xzf /tmp/mnt/mysticf.tar.gz -C /tmp/tmproot/
sync
mv /tmp/mnt/mysticf.tar.gz /tmp/mnt/mysticdone.tar.gz
umount /tmp/tmproot
rm /etc/mtab
ln -s /proc/mounts /etc/mtab
fi
sync
umount /tmp/mnt
I have it reboot after the fdisk just in case, and the fdisk works perfectly, so the second IF/THEN is the issue. I had to retouch the mtab just to make sure it's empty, as mke2fs fails if mtab doesn't exist(at least in terminal), then I relink it to /proc/mounts as they do in the stock firmware. Here's my mke2fs.conf:
Code:
[defaults]
base_features = sparse_super,filetype,resize_inode,dir_index,ext_attr
blocksize = 4096
inode_size = 256
inode_ratio = 16384
[fs_types]
ext3 = {
features = has_journal
}
ext4 = {
features = has_journal,extent,huge_file,flex_bg,uninit_bg,dir_nlink,extra_isize
inode_size = 256
}
ext4dev = {
features = has_journal,extent,huge_file,flex_bg,uninit_bg,dir_nlink,extra_isize
inode_size = 256
options = test_fs=1
}
small = {
blocksize = 1024
inode_size = 128
inode_ratio = 4096
}
floppy = {
blocksize = 1024
inode_size = 128
inode_ratio = 8192
}
news = {
inode_ratio = 4096
}
largefile = {
inode_ratio = 1048576
blocksize = -1
}
largefile4 = {
inode_ratio = 4194304
blocksize = -1
}
hurd = {
blocksize = 4096
inode_size = 128
}
Is there a way to echo the output from my script to a file like dontpanic so I can see what the error is?
msticninja said:
Is there a way to echo the output from my script to a file like dontpanic so I can see what the error is?
Click to expand...
Click to collapse
Simple append (">>") and "echo" doesn't work to a redirected logfile?
I've only learned what I've needed to learn over the years, usually with endless google searches and reading through man pages, so I've never tried to log outputs, because I could always see the output in a terminal or onscreen during boot. Android is the first time I haven't been able to actually see the boot process.
Once again, thanks for your help. I probably could've googled this, but I kind of asked as an afterthought. I didn't even think about redirecting. So if the mke2fs line is the one I want to log, I just add "2&>> /tmp/mnt/logfile" to the end of it, right?
Also, thanks for your original thread about booting from Internal Storage, I never got around to developing on Android until you posted that, and I realized just how similar Android is to L/unix(e.g. exactly the same).
msticninja said:
I didn't even think about redirecting. So if the mke2fs line is the one I want to log, I just add "2&>> /tmp/mnt/logfile" to the end of it, right?
Click to expand...
Click to collapse
ehm, no.
In your case must be like the following:
Code:
"your command" >> /tmp/mnt/logfile 2>&1
That means redirect all messages from STDERR (2 - standard error) to STDOUT (1 - standard output) and all messaged collected on STDOUT to the redirected log file /tmp/mnt/logfile, or more comprensible redirect all mesage including error ones to the log file.
I'm working in Unix environments and use them often
And a good practice in developing is to use "echo" to the same log file, so you know the exact place the script is running, like:
Code:
echo "I'm just before the formatting step of the ..." >> /tmp/mnt/logfile
shklifo said:
ehm, no.
In your case must be like the following:
Code:
"your command" >> /tmp/mnt/logfile 2>&1
That means redirect all messages from STDERR (2 - standard error) to STDOUT (1 - standard output) and all messaged collected on STDOUT to the redirected log file /tmp/mnt/logfile, or more comprensible redirect all mesage including error ones to the log file.
I'm working in Unix environments and use them often
And a good practice in developing is to use "echo" to the same log file, so you know the exact place the script is running, like:
Code:
echo "I'm just before the formatting step of the ..." >> /tmp/mnt/logfile
Click to expand...
Click to collapse
Strange. The google searching lead me to believe the "2>&1" was before the location, and replaced ">>". Once again, thanks for the help.
any chance of you getting this uploaded? iterested in this since I'm not that good with linux
TjaXanK said:
any chance of you getting this uploaded? iterested in this since I'm not that good with linux
Click to expand...
Click to collapse
I could probably finish it, but I'm waiting for a new version of Uruk first, as his install script already gets rid of the linux steps, it just doesn't give you the choice to install to the internal memory yet. Once he does that, I'll add my changes to make it install to the Archos partition. The latest Uruk is also a bit too big for the archos partition. I had to cut my data partition down to ~150 megs.
msticninja said:
I could probably finish it, but I'm waiting for a new version of Uruk first, as his install script already gets rid of the linux steps, it just doesn't give you the choice to install to the internal memory yet. Once he does that, I'll add my changes to make it install to the Archos partition. The latest Uruk is also a bit too big for the archos partition. I had to cut my data partition down to ~150 megs.
Click to expand...
Click to collapse
ok, I'm currently running urk with the new install system and it's brillant but it would be perfect if we could run it without cutting down on our storage space
hello,
Question on this post, I have no access to answer
http://forum.xda-developers.com/showthread.php?t=1081239
Thanks, good work to unpack the .img file.
I have a problem
repacking factoryfs_custom.img only 10,2*Mio (10678552 octets)
Code:
[email protected]:/home/max/ext4_utils# mkdir tempdir; mount -o loop output.img tempdir
[email protected]:/home/max/ext4_utils# ./mkuserimg.sh -s /some/directory/with/files ./factoryfs_custom.img ext4 ./temp 512M
in mkuserimg.sh PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games
./make_ext4fs -s -l 512M -a ./temp ./factoryfs_custom.img /some/directory/with/files
Creating filesystem with parameters:
Size: 536870912
Block size: 4096
Blocks per group: 32768
Inodes per group: 8192
Inode size: 256
Journal blocks: 2048
Label:
Blocks: 131072
Block groups: 4
Reserved block group size: 31
Created filesystem with 10/32768 inodes and 4205/131072 blocks
[email protected]:/home/max/ext4_utils# ls -l factoryfs_custom.img
-rw-r--r-- 1 root root 10678552 2011-05-28 09:57 factoryfs_custom.img
[email protected]:/home/max/ext4_utils#
what is the problem?
sorry for my bad English
Thanks
Can we move my question in the original post?
http://forum.xda-developers.com/showthread.php?t=1081239
Thank
max30 said:
Can we move my question in the original post?
http://forum.xda-developers.com/showthread.php?t=1081239
Thank
Click to expand...
Click to collapse
It remains for me to write the six missing messages to be able to ask my question in the right place
max30 said:
It remains for me to write the six missing messages to be able to ask my question in the right place
Click to expand...
Click to collapse
I can go post in the right place now
Hi guys..
Sorry If I'm posting this in the wrong section...
But can anyone guide me how to extract System.img from a Stock ROM as I'm planning to cook a custom ROM
If you would like to see some of my previous work for SGS1 look at my signature
You can try unyaffs in a cygwin environment or wunyaffs which is for windows.
For some reason I get access violation errors with stock roms for the Tab.
With HTC roms it was possible to dump the system.img with magiciso. Again with Tab roms this no longer works.
In CWM, after mounting /system:
make_ext4fs -l 568m -s /sdcard/system.img /system
This gives you a sparse system.img which you can turn into a Linux-mountable ext4 image with simg2img
Sorry i writed on wrong thread
In Linux you can do
mkdir tmp
sudo mount -o loop -t ext4 system.img ./tmp && cp -r ./tmp/* ./system/
sudo umount ./tmp
Sent from my Samsung Galaxy Tab 10.1 using Tapatalk
jamezelle said:
In Linux you can do
mkdir tmp
sudo mount -o loop -t ext4 system.img ./tmp && cp -r ./tmp/* ./system/
sudo umount ./tmp
Sent from my Samsung Galaxy Tab 10.1 using Tapatalk
Click to expand...
Click to collapse
I'm getting an error
Code:
sudo mount -o loop -t ext4 system.img ./tmp && cp -r ./tmp/* ./system
mount: wrong fs type, bad option, bad superblock on /dev/loop0,
missing codepage or helper program, or other error
In some cases useful info is found in syslog - try
dmesg | tail or so
Nokia7Vista said:
I'm getting an error
Code:
sudo mount -o loop -t ext4 system.img ./tmp && cp -r ./tmp/* ./system
mount: wrong fs type, bad option, bad superblock on /dev/loop0,
missing codepage or helper program, or other error
In some cases useful info is found in syslog - try
dmesg | tail or so
Click to expand...
Click to collapse
See the message I posted up above? You have to run the system.img through simg2img to make it mountable.
Sent from my Samsung Galaxy Tab 10.1
mabalito said:
See the message I posted up above? You have to run the system.img through simg2img to make it mountable.
Sent from my Samsung Galaxy Tab 10.1
Click to expand...
Click to collapse
oh ok,, Thanks
Nokia7Vista said:
oh ok,, Thanks
Click to expand...
Click to collapse
Hope this helps and welcome to the GT10.1 forum
Sent from my Samsung Galaxy Tab 10.1
You could always create a regular (non-sparse) image file using dd then mount it.
Command should be similar to ****, though I'm not sure if the busybox version of dd accepts bs=1M, it may require bs=1048576. (That's MB converted to B) And count is the number of MB you want the image to be.
Code:
dd if=/dev/zero of=squeeze.img bs=1M count=512
Then mount it like this:
Code:
mount -o loop,noatime -t ext4 /sdcard/debian/squeeze.img /data/local/debian/
*Pulled from a thread I wrote awhile back, you may be able to get away without using the "noatime" option.
Having an issue making the prerooted system.img. Builds just fine only issue is when I flash it.
here is the error from the command prompt when trying to flash it:
sending 'system' (413386 KB)...
(bootloader) USB download speed was 32173kB/s
OKAY [ 13.172s]
writing 'system'...
(bootloader) Flash of partition 'system' requested
(bootloader) S1 partID 0x00000004, block 0x00022000-0x00221fff
(bootloader) Unsupported chunk type: 0x6565
Any ideas?
Try to use doomkernel instead
GR0S said:
Try to use doomkernel instead
Click to expand...
Click to collapse
Dont want a custom kernel.
Sent from my LT26i using Tapatalk 2
Spectre51 said:
Dont want a custom kernel.
Sent from my LT26i using Tapatalk 2
Click to expand...
Click to collapse
You don't have to, it won't help anyway. Might be your image is broken. Have you tried any others?
Did you create it using ext-4 tools in Linux? You can't do it properly with unyaffs for Xperia 2012 devices
Sent from my LT26i using XDA
krabappel2548 said:
Did you create it using ext-4 tools in Linux? You can't do it properly with unyaffs for Xperia 2012 devices
Sent from my LT26i using XDA
Click to expand...
Click to collapse
Yes I did. Followed the guide in the firmwares and root compilation thread.
Spectre51 said:
Yes I did. Followed the guide in the firmwares and root compilation thread.
Click to expand...
Click to collapse
Ok, I looked at the guide but I don't think it's a really good guide. Maybe I'll write a guide in general about it when I have some time
Sent from my LT26i using XDA
krabappel2548 said:
Ok, I looked at the guide but I don't think it's a really good guide. Maybe I'll write a guide in general about it when I have some time
Sent from my LT26i using XDA
Click to expand...
Click to collapse
yeh its not really complete. I had to find some help in other posts but its a starting point. Just gotta figure out if its something I am doing or if sony put something in .75 to make it harder to root this way.
Spectre51 said:
yeh its not really complete. I had to find some help in other posts but its a starting point. Just gotta figure out if its something I am doing or if sony put something in .75 to make it harder to root this way.
Click to expand...
Click to collapse
I prerooted .76 without issues by using that guide.
Could you give us some more details about the steps you followed, and eventually post all the commands you ran and their output?
crimilde said:
I prerooted .76 without issues by using that guide.
Could you give us some more details about the steps you followed, and eventually post all the commands you ran and their output?
Click to expand...
Click to collapse
Agree with this post. I created my own shell script following that guide to pre-root image for .73 and .75 and never found any issue.
Would be great if you could provide us the steps and commands you used
I'll paste the commands exactly and their output when I get back to my computer.
This is what I get when making the img:
[email protected]:/home/jtking/Desktop/android# ./sin2img.py system.sin system.img
[email protected]:/home/jtking/Desktop/android# mkdir system; mount -o loop system.img system
[email protected]:/home/jtking/Desktop/android# cp Superuser.apk system/app/
[email protected]:/home/jtking/Desktop/android# cp su system/b
bin/ build.prop
[email protected]:/home/jtking/Desktop/android# cp su system/bin/
[email protected]:/home/jtking/Desktop/android# chmod 644 system/app/Superuser.apk
[email protected]:/home/jtking/Desktop/android# chmod 06755 system/bin/su
[email protected]:/home/jtking/Desktop/android# ./mkuserimg.sh -s system ./system2.img ext4 ./temp 1024M
in mkuserimg.sh PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
./make_ext4fs -s -l 1024M -a ./temp ./system2.img system
Creating filesystem with parameters:
Size: 1073741824
Block size: 4096
Blocks per group: 32768
Inodes per group: 8192
Inode size: 256
Journal blocks: 4096
Label:
Blocks: 262144
Block groups: 8
Reserved block group size: 63
Created filesystem with 1224/65536 inodes and 107179/262144 blocks
[email protected]:/home/jtking/Desktop/android#
And again this is what I got when trying to flash that img
writing 'system'...
(bootloader) Flash of partition 'system' requested
(bootloader) S1 partID 0x00000004, block 0x00022000-0x00221fff
(bootloader) Unsupported chunk type: 0x656c
I was able to unlock the bootloader just fine with this system multiple times and had flashed the .73 system image previously so I don't think its an issue with the computer.
Thank you for posting commands you used here. Those are the same ones as I use so this problem seems too difficult for my knowledge.
There is a possible cause I'm thinking of now. That guideline creates 2 img file: system.img and system2.img. system2.img is the prerooted one and it is the file to be flashed via fastboot. Their names are confusing. The question is which file you used to flashed?
If your answer is system2.img, I think you did everything correctly. We need to find someone else who has better knowledge than me to help.
Spectre51 said:
[email protected]:/home/jtking/Desktop/android# cp su system/b
bin/ build.prop
Click to expand...
Click to collapse
Well, this line seems strange to me, what did you try to do here?
Spectre51 said:
Creating filesystem with parameters:
Size: 1073741824
Block size: 4096
Blocks per group: 32768
Inodes per group: 8192
Inode size: 256
Journal blocks: 4096
Label:
Blocks: 262144
Block groups: 8
Reserved block group size: 63
Created filesystem with 1224/65536 inodes and 107179/262144 blocks
Click to expand...
Click to collapse
I also tried to preroot and make the system img using the system.sin from 6.0.A.3.75_CE1 just to compare the output and I got:
Code:
[[email protected] ext4_utils]# ./mkuserimg.sh -s ../system ../system2.img ext4 ./temp 1024M
in mkuserimg.sh PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin:/root/bin
./make_ext4fs -s -l 1024M -a ./temp ../system2.img ../system
Creating filesystem with parameters:
Size: 1073741824
Block size: 4096
Blocks per group: 32768
Inodes per group: 8192
Inode size: 256
Journal blocks: 4096
Label:
Blocks: 262144
Block groups: 8
Reserved block group size: 63
Created filesystem with 1230/65536 inodes and 108440/262144 blocks
So the inodes and block numbers clearly differ from yours. I didn't try to flash it though, to see if it works or not, as I already got .76, but I'd suggest you try a different FTF if you didn't use the one I mentioned already.
Also, maybe it's unrelated, but when you ran make on the ext4_utils, was the result ok?
crimilde said:
Well, this line seems strange to me, what did you try to do here?
I also tried to preroot and make the system img using the system.sin from 6.0.A.3.75_CE1 just to compare the output and I got:
Code:
[[email protected] ext4_utils]# ./mkuserimg.sh -s ../system ../system2.img ext4 ./temp 1024M
in mkuserimg.sh PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin:/root/bin
./make_ext4fs -s -l 1024M -a ./temp ../system2.img ../system
Creating filesystem with parameters:
Size: 1073741824
Block size: 4096
Blocks per group: 32768
Inodes per group: 8192
Inode size: 256
Journal blocks: 4096
Label:
Blocks: 262144
Block groups: 8
Reserved block group size: 63
Created filesystem with 1230/65536 inodes and 108440/262144 blocks
So the inodes and block numbers clearly differ from yours. I didn't try to flash it though, to see if it works or not, as I already got .76, but I'd suggest you try a different FTF if you didn't use the one I mentioned already.
Also, maybe it's unrelated, but when you ran make on the ext4_utils, was the result ok?
Click to expand...
Click to collapse
1) bash completion
2) it's different sizes
Haha, I must be going bad in the eyes, what with the bash completion fail I just did right there. Thanks.
Sent from my Sony Tablet S using xda premium
tot_anusak said:
There is a possible cause I'm thinking of now. That guideline creates 2 img file: system.img and system2.img. system2.img is the prerooted one and it is the file to be flashed via fastboot. Their names are confusing. The question is which file you used to flashed?
If your answer is system2.img
Click to expand...
Click to collapse
I used system2.img to flash
crimilde said:
Also, maybe it's unrelated, but when you ran make on the ext4_utils, was the result ok?
Click to expand...
Click to collapse
ext4_utils make went fine with no errors or anything.
Just to make sure I got the system.sin the right way. From the SEUS blob_fs folder I took the two biggest files from the .75 update download and and in flashtool did the decrypt files option. Took the system.sin file from there to use for this process.
Spectre51 said:
Just to make sure I got the system.sin the right way. From the SEUS blob_fs folder I took the two biggest files from the .75 update download and and in flashtool did the decrypt files option. Took the system.sin file from there to use for this process.
Click to expand...
Click to collapse
Yes, you did it right way.
Okay not sure what the deal is then with making this pre-rooted system image. Now for the Superuser.apk and su files I got them from http://androidsu.com/superuser/ Downloaded and extracted the Superuser.apk and su from the system/app and system/bin folders and thats what I was using to put into the prerooted system.img
Is that also the correct way to do it?
Not sure why I am having so much trouble getting this to work. If I upload the system.sin can someone else try making it to see if maybe something with my system is messing it up?
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: