From charlesreid1

Line 89: Line 89:


[[Image:OpenWRT54GLPing.png|500px]]
[[Image:OpenWRT54GLPing.png|500px]]
==Update software==
Now use opkg to update existing software on the router:
<pre>
$ opkg update
</pre>
==Install new software==
Careful of your disk space. Here's a couple of essential utilities:
<pre>
$ opkg install screen wget tcpdump
</pre>


=Hardware=
=Hardware=


Once you're logged into Luci, you can see what kind of hardware is on-board. There's about 14 MB of memory,
Once you're logged into Luci, you can see what kind of hardware is on-board. There's about 14 MB of memory,

Revision as of 06:56, 29 August 2016

Notes on getting the WRT54GL set up as an OpenWRT router.

This follows instructions on the OpenWRT wiki: https://wiki.openwrt.org/toh/linksys/wrt54g

Connect to Router

Before you can install OpenWRT, make sure the router is functioning normally.

Plug in

Start by plugging the router in, and connect a computer to it with an ethernet cable.

Log in

The default IP schema (discovered using ifconfig to see what IP address had been assigned to the ethernet port of the laptop connected to the router) was 192.168.1.1.

When I went to this page I logged in with the default username/password combo of admin/admin and saw the Linksys router management page:

LinksysRouterManagementPage.png

We won't be changing any of these settings, as we'll be re-flashing the router with a new operating system.

Install OpenWRT

Download image

Next you'll download the openwrt-wrt54g-squashfs.bin image from the OpenWRT page: https://downloads.openwrt.org/backfire/10.03.1/brcm-2.4/

Direct link: https://downloads.openwrt.org/backfire/10.03.1/brcm-2.4/openwrt-wrt54g-squashfs.bin

Load image onto router

On the router, navigate to the page http://192.168.1.1/Upgrade.asp

Now upload the OpenWRT binary:

LinksysRouterUploadBin.png

Log in to OpenWRT router

After 2 minutes the router will reboot itself automatically once the upgrade is complete.

You can now telenet to the router at 192.168.1.1 or you can use the Luci web interface at 192.168.1.1

Once you set a password, telnet will be disabled and ssh will be enabled.

LinksysRouterUpgrade1stLogin.png

Secure the router

First thing you do should be to set a password.

In the administration panel where you change the password, you'll also see configuration for a Dropbear SSH client, which will allow you to SSH to the router and remotely administer it. This can be set up to only listen on the local LAN, or only listen on the wifi interface, or listen on both.

Ensure tftp access

To ensure tftp is enabled, in case router gets bricked, type these commands out in telnet or ssh:

nvram set boot_wait=on
nvram set boot_time=10
nvram set wait_time=10 #important for some models
nvram commit && reboot

This will start tftp on boot. It is possible to flash the router via tftp, and is the recommended way to restore the router to a factory Linksys image.

Tftp flashing instructions: https://wiki.openwrt.org/doc/howto/generic.flashing.tftp


Connect router to internet

Before we can update existing software and download new software, we need an internet connection.

Fortunately, there is an ethernet port in the back of the Linksys labeled "internet", and plugging this into a router connected to the internet will allow the OpenWRT OS to automatically obtain an IP address on that router's network and successfully connect to the internet.

OpenWRT54GLPing.png

Update software

Now use opkg to update existing software on the router:

$ opkg update

Install new software

Careful of your disk space. Here's a couple of essential utilities:

$ opkg install screen wget tcpdump

Hardware

Once you're logged into Luci, you can see what kind of hardware is on-board. There's about 14 MB of memory,