Flashing DD-WRT in Asus RT-N18U using Ash shell commands

Post new topic   Reply to topic    DD-WRT Forum Index -> Broadcom SoC based Hardware
Author Message
mwchang
DD-WRT Guru


Joined: 26 Mar 2013
Posts: 1855
Location: Hung Hom, Hong Kong

PostPosted: Mon May 15, 2023 11:03    Post subject: Flashing DD-WRT in Asus RT-N18U using Ash shell commands Reply with quote
First time flashing firmware NOT via WEBUI.

Code:
~# nohup mtd write asus_rt-n18u-firmware.trx linux &
~# cat nohup.out
Unlocking linux ...
[flash] : Could not unlock MTD device: linux
linux: Not supported
Writing from asus_rt-n18u-firmware.trx to linux ...  [w]
Warning unaligned data, we use manual padding to avoid errors. size was 90112!!!
~# reboot -n


1. Should I have used "mtd"?

I copied the command-line from a script in an old post in the forum. But a Wiki entry said "mtd" should not have been used.

2. Should I have used "linux"? Or should it be "ddwrt"?

More information:
Code:
~# cat /proc/mtd
dev:    size   erasesize  name
mtd0: 00080000 00020000 "boot"
mtd1: 00180000 00020000 "nvram"
mtd2: 01e00000 00020000 "linux"
mtd3: 01c60000 00020000 "rootfs"
mtd4: 06000000 00020000 "ddwrt"

_________________
Router: Asus RT-N18U (rev. A1)

Drink, Blink, Stretch! Live long and prosper! May the Force and farces be with you!

Facebook: https://www.facebook.com/changmanwai
Website: https://sites.google.com/site/changmw
SETI@Home profile: http://setiathome.berkeley.edu/view_profile.php?userid=211832
GitHub: https://github.com/changmw/changmw
Sponsor
blkt
DD-WRT Guru


Joined: 20 Jan 2019
Posts: 5660

PostPosted: Tue May 16, 2023 2:11    Post subject: Reply with quote
This CLI Flash line from the build threads. Do not use mtd. Use linux not dd-wrt. Really old threads not good idea.

'cd /tmp' then 'wget {file URL}' (http only) or 'curl -O {file URL}' (http, https, ftp). 'write {file} linux' then 'reboot'.
mwchang
DD-WRT Guru


Joined: 26 Mar 2013
Posts: 1855
Location: Hung Hom, Hong Kong

PostPosted: Tue May 16, 2023 3:20    Post subject: Reply with quote
blkt wrote:
This CLI Flash line from the build threads. Do not use mtd. Use linux not dd-wrt. Really old threads not good idea.

'cd /tmp' then
'wget {file URL}' (http only) or 'curl -O {file URL}' (http, https, ftp).
'write {file} linux' then
'reboot'.

Thanks. Just a bit confused....

_________________
Router: Asus RT-N18U (rev. A1)

Drink, Blink, Stretch! Live long and prosper! May the Force and farces be with you!

Facebook: https://www.facebook.com/changmanwai
Website: https://sites.google.com/site/changmw
SETI@Home profile: http://setiathome.berkeley.edu/view_profile.php?userid=211832
GitHub: https://github.com/changmw/changmw
Display posts from previous:    Page 1 of 1
Post new topic   Reply to topic    DD-WRT Forum Index -> Broadcom SoC based Hardware All times are GMT

Navigation

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum