http://en.code-bude.net/2013/02/16/how-to-increase-storage-on-tp-link-wr703n-with-extroot/

http://www.electronicsfaq.com/2015/12/openwrt-1505-chaos-calmer-on-tl-mr3020.html

————

stato iniziale dopo refresh

Filesystem           1K-blocks      Used Available Use% Mounted on
rootfs                     640       212       428  33% /
/dev/root                 2304      2304         0 100% /rom
tmpfs                    14428       500     13928   3% /tmp
tmpfs                    14428        36     14392   0% /tmp/root
tmpfs                      512         0       512   0% /dev
/dev/mtdblock3             640       212       428  33% /overlay
overlayfs:/overlay         640       212       428  33% /

————-

dopo update

Filesystem           1K-blocks      Used Available Use% Mounted on
rootfs                     640       216       424  34% /
/dev/root                 2304      2304         0 100% /rom
tmpfs                    14428      1120     13308   8% /tmp
tmpfs                    14428        36     14392   0% /tmp/root
tmpfs                      512         0       512   0% /dev
/dev/mtdblock3             640       216       424  34% /overlay
overlayfs:/overlay         640       216       424  34% /

————–

install ext4ko

root@OpenWrt:~# opkg install kmod-fs-ext4
Installing kmod-fs-ext4 (3.10.49-1) to root…
Downloading http://downloads.openwrt.org/barrier_breaker/14.07/ar71xx/generic/packages/base/kmod-fs-ext4_3.10.49-1_ar71xx.ipk.
Installing kmod-lib-crc16 (3.10.49-1) to root…
Downloading http://downloads.openwrt.org/barrier_breaker/14.07/ar71xx/generic/packages/base/kmod-lib-crc16_3.10.49-1_ar71xx.ipk.
Installing kmod-crypto-hash (3.10.49-1) to root…
Downloading http://downloads.openwrt.org/barrier_breaker/14.07/ar71xx/generic/packages/base/kmod-crypto-hash_3.10.49-1_ar71xx.ipk.
Configuring kmod-crypto-hash.
Configuring kmod-lib-crc16.
Configuring kmod-fs-ext4.
kmod: failed to insert /lib/modules/3.10.49/ext4.ko
root@OpenWrt:~# df
Filesystem           1K-blocks      Used Available Use% Mounted on
rootfs                     640       452       188  71% /
/dev/root                 2304      2304         0 100% /rom
tmpfs                    14428      1120     13308   8% /tmp
tmpfs                    14428        36     14392   0% /tmp/root
tmpfs                      512         0       512   0% /dev
/dev/mtdblock3             640       452       188  71% /overlay
overlayfs:/overlay         640       452       188  71% /

—————————–

root@OpenWrt:~# opkg install kmod-usb-storage
Installing kmod-usb-storage (3.10.49-1) to root…
Downloading http://downloads.openwrt.org/barrier_breaker/14.07/ar71xx/generic/packages/base/kmod-usb-storage_3.10.49-1_ar71xx.ipk.
Installing kmod-scsi-core (3.10.49-1) to root…
Downloading http://downloads.openwrt.org/barrier_breaker/14.07/ar71xx/generic/packages/base/kmod-scsi-core_3.10.49-1_ar71xx.ipk.
Configuring kmod-scsi-core.
kmod: failed to insert /lib/modules/3.10.49/sd_mod.ko
Configuring kmod-usb-storage.
root@OpenWrt:~# df
Filesystem           1K-blocks      Used Available Use% Mounted on
rootfs                     640       544        96  85% /
/dev/root                 2304      2304         0 100% /rom
tmpfs                    14428      1120     13308   8% /tmp
tmpfs                    14428        36     14392   0% /tmp/root
tmpfs                      512         0       512   0% /dev
/dev/mtdblock3             640       544        96  85% /overlay
overlayfs:/overlay         640       544        96  85% /

————-

after reboot:

 

Wed Dec 30 13:38:18 2015 kern.info kernel: [   84.850000] scsi1 : usb-storage 1-1:1.0
Wed Dec 30 13:38:19 2015 kern.notice kernel: [   85.860000] scsi 1:0:0:0: Direct-Access              USB Reader       0001 PQ: 0 ANSI: 0 CCS
Wed Dec 30 13:38:19 2015 kern.notice kernel: [   86.270000] sd 1:0:0:0: [sda] 15523840 512-byte logical blocks: (7.94 GB/7.40 GiB)
Wed Dec 30 13:38:19 2015 kern.notice kernel: [   86.280000] sd 1:0:0:0: [sda] Write Protect is off
Wed Dec 30 13:38:19 2015 kern.debug kernel: [   86.280000] sd 1:0:0:0: [sda] Mode Sense: 03 00 00 00
Wed Dec 30 13:38:19 2015 kern.err kernel: [   86.280000] sd 1:0:0:0: [sda] No Caching mode page found
Wed Dec 30 13:38:19 2015 kern.err kernel: [   86.290000] sd 1:0:0:0: [sda] Assuming drive cache: write through
Wed Dec 30 13:38:19 2015 kern.err kernel: [   86.300000] sd 1:0:0:0: [sda] No Caching mode page found
Wed Dec 30 13:38:19 2015 kern.err kernel: [   86.300000] sd 1:0:0:0: [sda] Assuming drive cache: write through
Wed Dec 30 13:38:19 2015 kern.info kernel: [   86.320000]  sda: sda1 sda2
Wed Dec 30 13:38:19 2015 kern.err kernel: [   86.340000] sd 1:0:0:0: [sda] No Caching mode page found
Wed Dec 30 13:38:19 2015 kern.err kernel: [   86.340000] sd 1:0:0:0: [sda] Assuming drive cache: write through
Wed Dec 30 13:38:19 2015 kern.notice kernel: [   86.350000] sd 1:0:0:0: [sda] Attached SCSI removable disk

 

root@OpenWrt:~# mkdir /mnt/
root@OpenWrt:~# mount /dev/sda2 /mnt/
root@OpenWrt:~# df
Filesystem           1K-blocks      Used Available Use% Mounted on
rootfs                     640       544        96  85% /
/dev/root                 2304      2304         0 100% /rom
tmpfs                    14428        72     14356   0% /tmp
/dev/mtdblock3             640       544        96  85% /overlay
overlayfs:/overlay         640       544        96  85% /
tmpfs                      512         0       512   0% /dev
/dev/sda2              1413536      2160   1321520   0% /mnt

 

 

 

 

——

copy filesystem:

root@OpenWrt:~# mkdir -p /tmp/cproot
root@OpenWrt:~# mount –bind / /tmp/cproot
root@OpenWrt:/mnt# cd /
root@OpenWrt:/# tar -C /tmp/cproot -cvf – . | tar -C /mnt/ -xf –

 

root@OpenWrt:/# df
Filesystem           1K-blocks      Used Available Use% Mounted on
rootfs                     640       544        96  85% /
/dev/root                 2304      2304         0 100% /rom
tmpfs                    14428        72     14356   0% /tmp
/dev/mtdblock3             640       544        96  85% /overlay
overlayfs:/overlay         640       544        96  85% /
tmpfs                      512         0       512   0% /dev
/dev/sda2              1413536     11552   1312128   1% /mnt/
root@OpenWrt:/# cat >> /etc/config/fstab << EOF
> config ‘mount’
>         option target        /
>         option device        /dev/sda1
>         option fstype        ext4
>         option options       rw,sync
>         option enabled       1
>         option enabled_fsck  0
> EOF

reboot!

 

 

 

 

Annunci