2011-09-09 3 views
2

私はルータのファームウェアを抽出し、それを変更したいと思う。私はbitsumのファームウェアmodキットを使用しました。エラーはないようです。私はrootfs.img(squashfsイメージ)ファイルもあるimage_partsディレクトリを得ることができます。問題は私もそれをマウントすることもunsquashfsすることもできません。ファームウェアイメージをスアンサッシュまたはマウントする方法は?

これは、抽出出力である:

# ./extract-ng.sh AirTies_Air5021RU_FW_1.2.0.16_FullImage.bin 
Firmware Mod Kit (extract-ng) 0.69 beta, (c)2011 Craig Heffner, Jeremy Collake 
http://www.bitsum.com 

Scanning firmware... 

DECIMAL HEX   DESCRIPTION 
------------------------------------------------------------------------------------------------------- 
65228  0xFECC  Squashfs filesystem, big endian, version 2.0, size: 1369418 bytes, 382 inodes, blocksize: 65536 bytes, created: Tue May 3 13:44:22 2011 

Extracting 65228 bytes of header image at offset 0 
Extracting squashfs file system at offset 65228 
Extracting 160 byte footer from offset 1972107 
Extracting squashfs files... 
Firmware extraction successful! 
Firmware parts can be found in 'fmk/*' 

マウント試行出力:

fmk# ls 
image_parts logs rootfs 
fmk# cd image_parts/ 
fmk/image_parts# ls 
footer.img header.img rootfs.img 
fmk/image_parts# file rootfs.img 
rootfs.img: Squashfs filesystem, big endian, version 2.0, 1369418 bytes, 382 inodes, blocksize: 65536 bytes, created: Tue May 3 13:44:22 2011 
fmk/image_parts# mount rootfs.img /mnt/rootfs/ -o loop -t squashfs 
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 
fmk/image_parts# dmesg | tail -n 1 
[24799.284066] SQUASHFS error: Can't find a SQUASHFS superblock on loop0 

unsquashfs出力を試行:

fmk/image_parts# unsquashfs rootfs.img 
Reading a different endian SQUASHFS filesystem on rootfs.img 
Parallel unsquashfs: Using 1 processor 
336 inodes (377 blocks) to write 

[=============================|                     ] 99/377 26% 
gzip uncompress failed with error code -3 

Failed to write squashfs-root/lib/libqueue.so, skipping 
[=============================|                     ] 100/377 26% 
gzip uncompress failed with error code -3 

gzip uncompress failed with error code -3 

gzip uncompress failed with error code -3 

... 


Failed to write squashfs-root/lib/modules/2.6.8.1/extra/blaa_dd.ko, skipping 
[====================================|                   ] 123/377 32% 
gzip uncompress failed with error code -3 

gzip uncompress failed with error code -3 

... 

Failed to write squashfs-root/webs/management/ui_password.html, skipping 
[========================================================|              ] 191/377 50% 
gzip uncompress failed with error code -3 

Failed to write squashfs-root/webs/index.html, skipping 
[========================================================|              ] 192/377 50% 
gzip uncompress failed with error code -3 

... 


Failed to write squashfs-root/usr/sbin/brctl, skipping 
[===============================================================================================================|] 377/377 100% 
created 188 files 
created 46 directories 
created 52 symlinks 
created 95 devices 
created 1 fifos 

iが "エラーコード-3" 検索し、それはZ_DATA_ERRORあります(データが壊れているか不完全である)。 今私は何をすべきですか?

おかげ

+0

これは代わりにserverfaultにしてはいけませんか? –

答えて

3

Bcm63xxファームウェアイメージはのsquashfs-LZMAのような特別なフォーマットを持っています。私はbcm tools(brfwmod.exe)という名前のファームウェアイメージを抽出するいくつかのツールを手に入れました。 lzma-unsquashというコマンドがあります。私は正常にtheeseツールでそれをunaquash。

+1

こんにちはJosef。この[link](https://docs.google.com/file/d/0BzD4hxGinKcycHFhOS13NWJTMms/edit?usp=sharing)からダウンロードできます。 – kursat

+0

これらのbcm-toolsを投稿していただきありがとうございます! 私の前のコメントは私のメールアドレスを含んでいたので削除しました。私はそれを編集できません。 – hunger

関連する問題