First, the output of nvram show:

<termoutput>
root@OpenWrt:~# nvram show
os_ram_addr=80001000
et0macaddr=00:0F:66:51:03:1A
watchdog=5000
boot_wait=off
wl0_infra=1
et0mdcport=0
Intel_firmware_version=v1.41.8
pmon_ver=PMON 3.31.15.0
wl0_ifname=eth2
edirecting to <a href="/cgi-bin/webif.sh">main page</a>...
                </div>
        </body>
</html>
* {
        margin: 0;
        padding: 0;
}

html, body {
        font-family: Verdana, Helvetica, sans-serif;
        font-size: 10pt;
        width: inherit;
        height: 100%;
}

dt {
        font-weight: bold;
}

dd {
        margin-left: 1em;
        margin-bottom: 0.2em;
}

ul {
        display: inline;
        list-style-type: none;
}

ul.about {
        display: block;
        list-style-type: disc;
}
li.about {
        margin-left: 2em;
}

hr {
        display: none;
}

hr.separator {
        display: block;
}

th {
        text-align: left;
}

.selected-maincat {
        font-weight: bold;
}

#container {
        position: relative;
        min-height: 100%;
}

#header {
        position: relative;
        width: 100%;
}

#header #header-title {
        padding-top: 2em;
        padding-bottom: 0.2em;
        color: white;
        background-color: #3D5C7A;
}

#header #header-title #openwrt-title {
        position: relative;
        float: left;
        left: 1em;
        top: 0.7em;
}

#header #header-title #openwrt-title h1 {
        font-size: 2.8em;
}

#header #header-title #short-status {
        position: relative;
        text-align: right;
        right: 1em;
        line-height: 1.2em;
        padding-bottom: 0.2em;
}

#header #header-title #short-status ul {
        font-s
U4
wl0_mode=ap
os_flash_addr=bfc40000
boardtype=bcm94710dev
et1macaddr=00:0F:66:51:03:1B
lan_netmask=255.255.255.0
wl0_ssid=OpenWrt
et1mdcport=1
vlan2hwname=et0
flash_type=Intel 28F320C3 2Mx16 BotB
wan_proto=dhcp
wifi_ifnames=
lan_ifnames=vlan0 vlan2 eth2
pppoe_ifname=
wan_ifnames=
lan_ipaddr=192.168.3.1
clkfreq=125
lan_proto=static
vlan1hwname=et0
firmware_version=v1.42.2
sdram_config=0x0000
scratch=a0180000
lan_ifname=br0
sdram_refresh=0x8040
sdram_ncdl=0x00000000
et0phyaddr=30
wifi_ifname=
wan_ifname=vlan1
wl0_radio=1
sdram_init=0x0419
dl_ram_addr=a0001000
boot_date=Fri Sep 26 00:37:28 2003
'\w' ?></pre>

<? footer ?>
<!--
##WEBIF:name:Status:2:Wireless
-->
#!/bin/sh
exec ./webif/info.sh
<html>
        <head>
                <meta http-equiv="refresh" content="0; URL=/cgi-bin/webif.sh" />
        </head>
        <body>
                <div style="vertical-align: middle; text-align: center; height: 100%">
P4
boot_ver=v1.5
et1phyaddr=30
boardnum=42
pppoe_ifnames=
size: 2271 bytes (30497 left)
</termoutput>

I did a search for HTML in NVRAM but found nothing.  It's a bit of a haze, but here's sorta what happened...

I was struggling with getting my WRT54G V1.1 to work with a static IP address behind this silly Netopia router from SBC.  The Netopia was configured fine and I was able to get any PC I wanted to wrork with a static IP.  When I tried to configure my LinkSys box, it couldn't talk out the WAN side and I could ping its WAN interface from oter machines on that same side of the network.

I tried a bunch of stuff and didn't notice anything odd.  Then I decided to re-flash using the web interface with the jffs and nvram boxes checked.  I wanted a fresh start.  Being a jackass, I also chose a different image - the wrt54g image from the pptp folder 'cause that's kinda what I wanted anyway...

The box came up fine.  When I did an nvram show, the above output came up!  I did a get on boot_date and wl0_ifname - and those settings individually came out with their respective apparently corrupted output.

So I did another web interface flash with the boxes checked - only this time I used the regular image instead of the pptp image.  Same deal - EXACTLY.

I then issued "mtd -r erase nvram", rebooted, and saw sane looking nvram.

Enjoy.

-Saro