昨天,今天,明天,每天的每天,你是否都多懂得一点点...

星期五, 三月 16, 2018

Fiddler-Orchestra in docker


This .net core version of fiddler which can be run in a docker container. It can also connect to Fiddler's Orchestra Controller to display traffic on Form(original) Fiddler. If you are a fiddler fan, you gotta like this.

For more info:
https://www.telerik.com/blogs/a-brief-user-guide-on-fiddler-orchestra

To run:

docker run --name fiddler -d --rm -p 8801:8801 -p 8855:8855 -p 8866:8866 -p 8877:8877 fennng/fiddler-orchestra

Then navigate to

http://localhost:8801

You can config the settings from Web UI

To stop:
docker stop fiddler

Optional:

You cannot connect Fiddler's Orchestra Controller directly because it's so far only bound to localhost.
Follow this step to enable viewer Orchestra's log in Fiddler: (I am assuming that you already know Fiddler well)

Control + Alt + F to bring Fiddler to front.
Alt+Q to enter QuickExec mode
Enter this code:
!listen 36363
Then hit enter.

Now your fiddler is listening to 36363. Make sure you enable "Allow remote computers to connect" in Fiddler option as well.

In your Fiddler's script, add

if (oSession.port == 36363){
oSession.host = "localhost:3636";
}

this code to OnBeforeRequest method.

Your Fiddler needs to have a public IP for the client to connect to.

Unless, If you are running Fiddler on a windows host which is running the docker as well. You can use the DockerNAT Ip, in my case is 10.0.75.1.

In Fiddler Orchestra's "Orchestra Connection" page, put your Fiddler's IP and port number 36363.

Now, you are able to see all the traffic from your Fiddler. Setting Fiddler Orchestra as a reverse proxy opens the door for remote debugging.



--
Feng

星期四, 三月 15, 2018

JetBrains dotPeek


JetBrains dotPeek is a really good tool to view code in a dll. I used it to find out that Fiddler Orchestra is hardcode to listen to localhost only. 




And this tool can  navigate between code easily. Well, more importantly, it's free.





--
Feng

Build and publish a docker image to docker hub

​​

To build a docker image, you only need a single docker file

Dockerfile


From microsoft/aspnetcore:2.0
RUN apt-get update && DEBIAN_FRONTEND=noninteractive apt-get -y install zip socat supervisor
RUN mkdir /app
COPY FiddlerOrchestra.Client.NetCore.WindowsMacLinux.zip /app
RUN cd app && unzip /app/FiddlerOrchestra.Client.NetCore.WindowsMacLinux.zip
RUN rm /app/FiddlerOrchestra.Client.NetCore.WindowsMacLinux.zip
EXPOSE 8801 8866 8855 8877
WORKDIR /app
ADD supervisord.conf /etc/supervisor/conf.d/supervisord.conf 
ENTRYPOINT ["/usr/bin/supervisord"]


In this docker file, I created a new image based on  microsoft/aspnetcore:2.0

And I copied  FiddlerOrchestra app into the image for running.

I used  supervisor to run two tasks

The content of  supervisord.conf:

[supervisord]
nodaemon=true

[program:socat]
command=socat TCP4-LISTEN:8801,fork TCP4:localhost:8800

[program:fiddler]
command=dotnet /app/FiddlerOrchestra.Client.NetCore.dll

Once you've got this ready, you can simply build the docker image with a single command. 

docker build .


Once built, you can publish it to Docker Hub. You will need to create an account first.



docker login --username=fennng





docker tag fiddler-orchestra fennng/fiddler-orchestra:1.0




docker push fennng/fiddler-orchestra










--
Feng

星期三, 三月 14, 2018

Access DB from .Net Core Docker build

When we build to docker container using Visual studio, Visual studio will create a new network for the .net core app. 

You can also setup db in the yml file, so that DB can be created in the same network. 

But If you already have a DB setup in a docker container which is in a different network as I do, how can you access this db?

Here is the solution:

Add your .net core app to both of the network. For example, I have my db container in my-net network. I ran the following command to add the .net app to this network

docker network connect --alias api-host my-net 2802

Then my app container will be in both network with a different hostname




You will also need to update the db settings to point to the correct db hostname







Now, you app can access the db through another network interface.

--
Feng

Docker build not working in VS

Most of the time, I use "dotnet run" to server the API. Today, When I switched to docker build, it gave me this error:

Error message: Operation aborted (Exception from HRESULT: 0x80004004 (E_ABORT)) 

I found the solution here:


Reset share drive




clean the solution

Then, problem solved.



--
Feng

星期日, 三月 11, 2018

Sign update.zip for MiRecovery

小米盒子增强版成功降级后, 又可以Root了. Root了以后我便想安装其它的版本. 因为降级后的版本 1.3.112d是一个不可以升级的版本, 我怕1.3是不是有点太老, 升到1.4会不会好些?

于是我便从这里下载了一个被修改过的小米recovery. 


可是我却发现它并不能用, 因为我想用他刷一个石头论坛以前下的小米1.3.72的固件的时候,刷失败了. 显示签名错误. 我明明记得我是用那个固件从石头的系统恢复回小米系统的.

于是我从石头的刷机工具里面提取了recovery, 并成功的刷入了1.3.72的固件包. 所以我就开始以为那个mirecovery 跟本没用.

但是后来,我又在这个页面找到了可以用这个recovery 刷的固件包


于是我就纳闷了, 怎么这些包又可以刷了, 这些包也不是官方包呀! 后来我发现, 原来1.3.72那个固件没有签名, 所以刷不了. 而石头中提取的recovery好像只能刷没签名的包,签了名反而不能刷. 所以就是说, 只要把包签名了, 这个mirecovery 还是能用的.

今天正好想试试自己打包update.zip 文件. 

开始也没有查资料, 先用现有的知识做个签名.

先生成一个keystore
keytool -genkey -v -keystore recovery.keystore -alias feng_recovery -keyalg RSA -keysize 2048 -validity 10000

然后用jarsigner 签名
jarsigner -verbose -sigalg SHA1withRSA -digestalg SHA1 -keystore recovery.keystore update.zip feng_recovery
Enter Passphrase for keystore:
   adding: META-INF/MANIFEST.MF
   adding: META-INF/FENG_REC.SF
   adding: META-INF/FENG_REC.RSA
   adding: system/
  signing: system/test.txt
jar signed.

签完名得到一个这样的结构


拿去recovery试,  直接就废.

E:footer is wrong
E:signature verification failed


于是上网找到这个教程.




用openssl 来生成公私钥
openssl genrsa -out key.pem 1024
openssl req -new -key key.pem -out request.pem
openssl x509 -req -days 9999 -in request.pem -signkey key.pem -out certificate.pem
openssl pkcs8 -topk8 -outform DER -in key.pem -inform PEM -out key.pk8 -nocrypt

​​
用 signapk.jar 来签名, 而不是jarsigner

java -jar signapk.jar certificate.pem key.pk8 update.zip signed-update.zip


这次的结构对了, 因为CERT.RSA, CERT.SF 的文件名对了, 跟其它我用过的包一样, 说明 signapk.jar 用对了.

再拿去试, 还是一样的错误.

然后我查了一个可以用的update.zip包的签名, 用的是signapk.jar 自带的那个testkey.


Use jarsigner, I found out it's using the testkey come with SignApk.jar
jarsigner -verify -verbose -certs  update.zip

Key for signed_update_1.3.102.2024.zip

      X.509, EMAILADDRESS=android@android.com, CN=Android, OU=Android, O=Android, L=Mountain View, ST=California, C=US
      [certificate is valid from 29/02/08 2:33 PM to 17/07/35 1:33 PM]
      [CertPath not validated: Path does not chain with any of the trust anchors]


好吧,我也用这个key 好了.
java -jar signapk.jar testkey.x509.pem testkey.pk8 update.zip signed-update.zip

然后查一下, 查出来的信息一模一样了.


X.509, EMAILADDRESS=android@android.com, CN=Android, OU=Android, O=Android, L=Mountain View, ST=California, C=US
      [certificate is valid from 29/02/08 2:33 PM to 17/07/35 1:33 PM]
      [CertPath not validated: Path does not chain with any of the trust anchors]

去试试, 我X, 还是这个错误, 有没有搞错,我到底哪里没弄对....
Still got the following error.

E:footer is wrong
E:signature verification failed
Installation aborted.

然后有人说 footer is wrong 是因为 zip 文件没有comment. 不会吧....

Someone mentioned that footer is wrong is caused by the zip comment.

查一下可用的那个包, 还真有comment


fengnz@mac:~/Downloads > unzip -z signed_ota-fixer_1.3.102.2024
Archive:  signed_ota-fixer_1.3.102.2024.zip
signed by jBART (BurgerZ)
而我做的包没有


There is no comment for my zip file

fengnz@mac:~/Documents/recovery_learn > unzip -z signed-update.zip
Archive:  signed-update.zip

行, 小事,我也加comment

fengnz@mac:~/Documents/recovery_learn > zip -z signed-update.zip
enter new zip file comment (end with .):
Signed By YuFeng Deng.
.
fengnz@mac:~/Documents/recovery_learn > unzip -z signed-update.zip
Archive:  signed-update.zip
Signed By YuFeng Deng.

加完后...还是一样...


Still same error

好吧, 我注意到它是用jBART签的名, 所以下载个jBART来用



I found that the file it created is 2K bigger than my one

签好后, 查一下comment, 跟可用的那个包一样了

fengnz@mac:~/Documents/recovery_learn > unzip -z signed_update.zip
Archive:  signed_update.zip
signed by jBART (BurgerZ)

再查一下签名, 对, 用的就是 那个testkey

jarsigner -verify -verbose -certs signed_update.zip

   X.509, EMAILADDRESS=android@android.com, CN=Android, OU=Android, O=Android, L=Mountain View, ST=California, C=US
      [certificate is valid from 29/02/08 2:33 PM to 17/07/35 1:33 PM]
      [CertPath not validated: Path does not chain with any of the trust anchors]

这回拿去试, 居然成功了!!!
Now Success

到底哪里不一样? 我也是这么签的呀? 为什么它签出来会大2K?
What's the difference between jBART sign and my own sign? The same keys are used?

我之前如果签名不对, 出的错误是"Fail to verify whole-file signature". 这回没有这么说, 所以说明whole-file signature是好的. 只是footer 错了. 那什么是footer?
It doesn't say "Fail to verify whole-file signature". Means the whole-file signature is Ok. The error is caused by the footer. What's the footer here?

然后我发现了这篇文章. 明白footer其实是在查这个zip 包的倒数第三个和第四个字节. 如果这个字节不对, 说明没有whole-file signature, 所以不是说whole-file signagure是好的, 而是跟本没有, 所以不查, footer 直接fail.

The recovery program check the footer to make sure the whole-file signature is existing. If not, it doesn't go future and throw signature failure.





然后发现其实签名还分两种, 一种是对压缩包里面的每个文件进行签名, 另一种是对整个压缩包签名, 就是所谓的whole-file signaure. 

signapk.jar 默认不做whole-file signature, 需要加 -w 参数. 

可是我的signapk.jar 不支持这个参数呀, 我早就查过了.


fengnz@mac:~/Downloads > java -jar signapk.jar
Usage: signapk publickey.x509[.pem] privatekey.pk8 input.jar output.jar

There is not -w option

然后我只好上网继续找支持 -w 的signapk.jar

The first version I found was a 7.2K signapk.jar

最后终于找到了...
I then searched hard on the internet and finally found a 9K signapk.jar which supports -w option


这个有 -w 参数耶
fengnz@mac:~/Documents/recovery_learn > java -jar signapk.jar
Usage: signapk [-w] publickey.x509[.pem] privatekey.pk8 input.jar output.jar

然后

 java -jar signapk.jar -w testkey.x509.pem testkey.pk8 update.zip signed-update.zip

成功了, 签名来的文件大小和 jBART 一样大. 试了一下, 可以用.

然后我试了下最开始自己用openssl 生成的key, 不行. 一定要用testkey.

好了...花了好几个小时, 终于解开了这个迷团. 上网查, 大家都说是因为你自签名的包不能用在stock recovery. 就没有人说到是因为忘了使用-w 参数而没有 whole-file signature. 



--
Feng

星期五, 三月 09, 2018

其实我做得还不错,3个月拿下一千订阅

对比一下其它人,我居然属于快的那一种。慢的人居然要花上两三年才能达到1000订阅。快的有六周的。

Youtube上不少视频教人1周达到1000订阅。。。都是骗人的,我看了也没啥用处。。。





--
Feng

一千订阅了,Mark






--
Feng

星期四, 三月 08, 2018

小米盒子增强版-两个Recovery界面清空数据的效果不一样

小米盒子增强版

两个Recovery界面清空数据的效果不一样

之前尝试卡刷Supersu, 卡刷结果是成功, 可是刷完重启后, supersu 没有出现,却出现了很多问题, 比如:

Home键不工作了
不能安装应用 
不能删除应用
不能投屏神器



在可以卡刷的界面里 (使用 xiaomi_update 文件进入),无法彻底清楚用户数据, 之前刷supersu 引起的问题不能解决
在默认recovery界面里则可以



--
Feng

星期日, 三月 04, 2018

Dump and read system image from mibox2



// To get all the partition names:

root@dredd:/dev/block/platform/aml_sdio.0 # ls -l
lrwxrwxrwx root     root              2023-05-15 15:28 boot -> /dev/block/boot
lrwxrwxrwx root     root              2023-05-15 15:28 boot1 -> /dev/block/boot1
lrwxrwxrwx root     root              2023-05-15 15:28 bootloader -> /dev/block/bootloader
drwxr-xr-x root     root              2023-05-15 15:28 by-num
lrwxrwxrwx root     root              2023-05-15 15:28 cache -> /dev/block/cache
lrwxrwxrwx root     root              2023-05-15 15:28 data -> /dev/block/data
lrwxrwxrwx root     root              2023-05-15 15:28 env -> /dev/block/env
lrwxrwxrwx root     root              2023-05-15 15:28 logo -> /dev/block/logo
lrwxrwxrwx root     root              2023-05-15 15:28 misc -> /dev/block/misc
lrwxrwxrwx root     root              2023-05-15 15:28 mmcblk0 -> /dev/block/mmcblk0
lrwxrwxrwx root     root              2023-05-15 15:28 mmcblk0p1 -> /dev/block/mmcblk0p1
lrwxrwxrwx root     root              2023-05-15 15:28 mmcblk1 -> /dev/block/mmcblk1
lrwxrwxrwx root     root              2023-05-15 15:28 mmcblk1boot0 -> /dev/block/mmcblk1boot0
lrwxrwxrwx root     root              2023-05-15 15:28 mmcblk1boot1 -> /dev/block/mmcblk1boot1
lrwxrwxrwx root     root              2023-05-15 15:28 panic -> /dev/block/panic
lrwxrwxrwx root     root              2023-05-15 15:28 persist -> /dev/block/persist
lrwxrwxrwx root     root              2023-05-15 15:28 recovery -> /dev/block/recovery
lrwxrwxrwx root     root              2023-05-15 15:28 reserved -> /dev/block/reserved
lrwxrwxrwx root     root              2023-05-15 15:28 system -> /dev/block/system
lrwxrwxrwx root     root              2023-05-15 15:28 system1 -> /dev/block/system1



// To dump the system partition to a image file
root@dredd:dd if=/dev/block/system of=/storage/sdcard1/system.img                                                 
1310720+0 records in
1310720+0 records out
671088640 bytes transferred in 419.644 secs (1599185 bytes/sec)
root@dredd:/dev/block/platform/aml_sdio.0 #

// Now you can use the USB Drive to copy the system image file to a computer 

// And you can also view the content of the image. The following method is on mac os.

// To attach image file as disk partition

fengnz@mac:/Volumes/SONY_8M1/root > hdiutil attach -imagekey diskimage-class=CRawDiskImage -nomount system.img
/dev/disk6


// To mount the partition to a mount point

fengnz@mac:/Volumes/SONY_8M1/root > mkdir /Volumes/ext4
fengnz@mac:/Volumes/SONY_8M1/root > sudo mount -t fuse-ext2 /dev/disk6 /Volumes/ext4
fengnz@mac:/Volumes/SONY_8M1/root > sudo ext4fuse -o allow_other /dev/disk6 /Volumes/ext4/

Now you can access the file




​// To detach the image ​

fengnz@mac:/Volumes/SONY_8M1/root > hdiutil detach disk6
"disk6" unmounted.
"disk6" ejected.


--
Feng

订阅达到888

这么吉利的数字, mark一下.




--
Feng

星期六, 三月 03, 2018

Putty MAC OS 中文乱码解决

用PUTTY连到MAC OS上的时候,中文会乱码
这时候直接输入以下命令,再ls 就正常了,立即生效。
 export LANG=zh_CN.UTF-8




--
Feng

Fix Package Installer missing from Android Mibox2 MDZ-09-AA

也不知道什么原因, 可能是我用Recovery 刷SuperSu失败, 然后我的小米盒子不能安装APK了... 就是打开高清播放器里面的U盘APK, 点击没有反应. 

还好还能用ADB安装软件.

我把盒子降级也没用, 降级再用系统自带的升级升完后也一样, 这太不科学!!!

我用ADB安装了一些软件, 用SManger 安装APK的时候, 会出现找不到打开方式的错误.

然后我用LINK2SD看了一下, 居然没有找到 Package Installer. 太不科学了. 按理来说刷机后, 什么都应该被还原了呀. 

我打开小米盒子3增强版, 然后发现里面是有MiPackageInstaller的, 在 /system/pri-app/ 里面.

然后我打开小米盒子增强版的升级包, 翻了一下, 发现有 PackageInstaller.apk, 但位置不一样, 在/system/app, 里面.


于是adb shell 进盒子里, 看到里面的确有 PackageInstaller.apk, 但却不能用. 

于是我用adb pull 把这个包抓出来, 马上用adb install 装回去. 再回到 Link2Sd, 出来了!!!!

我再用Link2Sd 把这个应用转成系统应用, 重启盒子. 我可爱的APK安装程序回来了!!!




--
Feng

星期五, 三月 02, 2018

A interesting finding of mibox 2 recovery

I used stock rom to downgrade my mibox 2 to 1.3.112d (to system 1) then rooted it with 360 root.


On MDZ-09-AA, I flashed a modified mirecovery:

MiRecovery_5.5.29.1567.zip

Then I entered recovery and can see that my recovery has been reduced from version 6 to version 5.

Then I reboot to system 2. (black screen)

Then I cut the power and reentered recovery, I then saw the recovery was back to 6.

Then I reboot to system 2 again, now this time, I can enter system2. And the system 2 is 1.5.8

Then I reboot to system 1, system 1 is still 1.3.112d.



--
Feng

A Rough log of android recovery img

Adb shell 

// To check the current system mount

root@endeavoru:/proc # cat /proc/mounts | grep system
/dev/block/platform/sdhci-tegra.3/by-name/APP /system ext4 ro,seclabel,relatime,user_xattr,acl,barrier=0,data=ordered 0 0

root@endeavoru:/ # mount | grep system
/dev/block/platform/sdhci-tegra.3/by-name/APP /system ext4 ro,seclabel,relatime,user_xattr,acl,barrier=0,data=ordered 0 0


root@endeavoru:/system # busybox mount | grep system
/dev/block/platform/sdhci-tegra.3/by-name/APP on /system type ext4 (ro,seclabel,relatime,user_xattr,acl,barrier=0,data=ordered)


What's the difference between busybox mount and mount?

// To make root folder writable

127|root@endeavoru:/ # mkdir a
mkdir failed for a, Read-only file system
255|root@endeavoru:/ # mount -o remount,rw /
root@endeavoru:/ # mkdir a
root@endeavoru:/ # ls
root@endeavoru:/ # mount -o remount,ro /
root@endeavoru:/ # mkdir b
mkdir failed for b, Read-only file system
255|root@endeavoru:/ # mount -o remount,rw /
root@endeavoru:/ # rmdir a

// To find out which partition is recovery 

root@endeavoru:/ # cat /cache/recovery/last_log |grep recovery
Starting recovery on Fri Feb 23 13:00:26 2018
recovery filesystem table
  1 /recovery emmc /dev/block/mmcblk0p5 (null) 0

root@endeavoru:/ # cat /cache/recovery/last_log | more
Starting recovery on Fri Feb 23 13:00:26 2018
can't open /dev/tty0: No such file or directory
framebuffer: fd 3 (720 x 1280)
recovery filesystem table
=========================
  0 /tmp ramdisk (null) (null) 0
  1 /recovery emmc /dev/block/mmcblk0p5 (null) 0
  2 /boot emmc /dev/block/mmcblk0p4 (null) 0
  3 /cache ext4 /dev/block/mmcblk0p13 (null) 0
  4 /data ext4 /dev/block/mmcblk0p15 (null) 0
  5 /sdcard vfat /dev/block/mmcblk0p14 (null) 0
  6 /system ext4 /dev/block/mmcblk0p12 (null) 0
  7 /misc emmc /dev/block/mmcblk0p17 (null) 0



// To List all partitions

root@endeavoru:/ # cat /proc/partitions
major minor  #blocks  name

 179        0   30535680 mmcblk0
 179        1       6144 mmcblk0p1
 179        2       2048 mmcblk0p2
 179        3       6144 mmcblk0p3


// To backup recovery 
root@endeavoru:/ # cat /dev/block/mmcblk0p5 > /mnt/sdcard/recovery.img
root@endeavoru:/ # ls -l /mnt/sdcard/recovery.img
-rwxrwx--- root     sdcard_r  8388608 2018-03-01 11:03 recovery.img

// Use adb pull to download the backup recovery.img file
fengnz@mac:~/HTC_One > adb pull /mnt/sdcard/recovery.img .
/mnt/sdcard/recovery.img: 1 file pulled. 0.6 MB/s (8388608 bytes in 13.321s)


// To download unmkbootimg go to


// To show image info (docker usage is off topic here)

docker cp unmkbootimg ubuntu:/root/
docker cp recovery.img ubuntu:/root/
docker exec -it ubuntu bash
cd root

root@072407a24838:~# ./unmkbootimg recovery.img
unmkbootimg version 1.2 - Mikael Q Kuisma <kuisma@ping.se>
Kernel size 5197608
Kernel address 0x10008000
Ramdisk size 2171498
Ramdisk address 0x11000000
Secondary size 0
Secondary address 0x10f00000
Kernel tags address 0x10000100
Flash page size 2048
Board name is ""
Command line ""
This image is built using standard mkbootimg
Extracting kernel to file zImage ...
Extracting root filesystem to file initramfs.cpio.gz ...
All done.
---------------
To recompile this image, use:
  mkbootimg --kernel zImage --ramdisk initramfs.cpio.gz -o new_boot.img
---------------


// To copy the ramdisk file out

fengnz@mac:~/HTC_One > docker cp ubuntu:/root/initramfs.cpio.gz .

// You can unzip this file and check the content




You can't mount a recovery image as it's not a regular file system. Read this for more info.



Check the res/images folder, you will see a bunch of images which may tell you where this recovery comes from.



// To unzip it in ubuntu docker
root@072407a24838:~# mkdir ramdisk
root@072407a24838:~# cd ramdisk/
root@072407a24838:~/ramdisk# apt-get install cpio
root@072407a24838:~/ramdisk# gunzip -c ../initramfs.cpio.gz | cpio -i
6419 blocks
root@072407a24838:~/ramdisk# ls
data           init                        res             system
default.prop   init.rc                     sbin            tmp
dev            init.recovery.endeavoru.rc  seapp_contexts  ueventd.goldfish.rc
etc            proc                        sepolicy        ueventd.rc
file_contexts  property_contexts           sys


You can modify the ramdisk files and repack it with the following command. 

find . | cpio -o -H newc | gzip > ../newramdisk.cpio.gz

root@072407a24838:~/ramdisk# find . | cpio -o -H newc | gzip > ../newramdisk.cpio.gz
6419 blocks
root@072407a24838:~/ramdisk# cd ..
root@072407a24838:~# ls
initramfs.cpio.gz   ramdisk  recovery.img  zImage
newramdisk.cpio.gz  rec      unmkbootimg
root@072407a24838:~# ls -l
total 18100
-rw-r--r--  1 root root    2171498 Mar  1 23:06 initramfs.cpio.gz
-rw-r--r--  1 root root    2180261 Mar  1 23:48 newramdisk.cpio.gz


// Use this docker container for mkbootimg

// Run mkbootimg docker container

docker run -it -d --name mkbootimg --privileged=true --volume $(pwd)/kernel:/kernel dvitali/android-build-tools


// Move file from ubuntu container to this one

docker cp ubuntu:/root/ temp
fengnz@mac:~/HTC_One > docker cp temp/root mkbootimg:/
fengnz@mac:~/HTC_One > docker exec -it mkbootimg bash

cd root
mkbootimg --cmdline 'no_console_suspend=1 console=null' --kernel zImage --ramdisk newramdisk.cpio.gz -o mynewimage.img

root@2008c25fe133:~# ls -l
total 25308
-rw-r--r--  1  501 dialout 2171498 Mar  1 23:06 initramfs.cpio.gz
-rw-r--r--  1 root root    7380992 Mar  2 00:31 mynewimage.img
-rw-r--r--  1  501 dialout 2180261 Mar  1 23:48 newramdisk.cpio.gz
drwxr-xr-x 11  501 dialout    4096 Mar  1 23:48 ramdisk
drwxr-xr-x  2  501 dialout    4096 Mar  1 22:24 rec
-rw-r--r--  1  501 dialout 8388608 Mar  1 22:06 recovery.img

A new image is created, but it's smaller than original. I am not sure whether it's correct.


--
Feng

其它博客地址

此博客的同步博客地址: http://fengnz.wordpress.com
这里进入我的MSN SPACE.