Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
Next revisionBoth sides next revision
toh:aerohive:hiveap-330 [2022/02/12 23:22] – created chunkeeytoh:aerohive:hiveap-330 [2022/02/19 18:32] – [Snapshot Releases] new method chunkeey
Line 83: Line 83:
   * This entry will be updated once the device boots with the 5.10 snapshots again.   * This entry will be updated once the device boots with the 5.10 snapshots again.
  
-Connect your PC's ethernet port to the RJ45 port labeled "eth0", and the serial connection to the RJ45 port labeled "console". 
  
-Open the serial connection (9600, 8N1) and power on the AP121.+ 
 +1. setup a network with a tftp server 
 + 
 +Start a tftp server at serverip (192.168.1.101) with the initramfs image in the servers root tftp directory. Having a dhcp server is advantageous. However static IPv4s can be set in the uboot environment later on. 
 + 
 +2. setup console port and pass uboot login challenge 
 + 
 +The AP has a serial port on the RJ45 port labeled "console". This needs special setup see above in the prerequisite section. Open the serial connection (9600, 8N1) on your PC and power on the AP330.
  
 When you see ''Hit the space bar to stop the autoboot process'' ... hit the space bar to stop the autoboot process. Enter the password to access the uboot console, which is either ''AhNf?d@ta06'' or ''administrator''. If neither works, you can try to factory reset the device by pressing and holding the reset button with a needle/paperclip when it is in the stock OS. When you see ''Hit the space bar to stop the autoboot process'' ... hit the space bar to stop the autoboot process. Enter the password to access the uboot console, which is either ''AhNf?d@ta06'' or ''administrator''. If neither works, you can try to factory reset the device by pressing and holding the reset button with a needle/paperclip when it is in the stock OS.
  
-Now is a good time to confirm your bootloader version. Issue the command+3. confirm uboot is supported 
 + 
 +confirm your bootloader version. Issue the command
 <code> <code>
 version version
 </code> </code>
  
-...+Check if the version listed there matches one of the supported uboot version. 
 + 
 +4setup IPv4 connection 
 + 
 +If you are using dhcp, you can just enter ''dhcp'' into the uboot prompt. This will 
 +set you up with an ipv4. 
 + 
 +If you are going the static assignment route. You have to set your IPv4 Address by 
 +entering: ''setenv ipaddr 192.168.1.1'' into the uboot prompt. (This requires that 
 +this IP isn't already taken by another device). 
 + 
 +5. upload initramfs firmware 
 + 
 +The next step is to transfer the OpenWrt binary to the HiveAP-330's memory. 
 +The method depends on what release you want to install. 
 + 
 +==== Snapshot Releases ==== 
 + 
 +If you start out fresh you can preemptively set the new openwrt boot command. 
 +For this to work, the uboot has to be modified (which we do in a later step). 
 +Otherwise, the stock uboot will always use a internal bootcmd that can't be 
 +overwritten and it won't boot the sysupgraded'/installed kernel later. 
 + 
 +<code> 
 +setenv owrt_boot 'setenv bootargs \"console=ttyS0,$baudrate\";bootm 0xEC040000 - 0xEC000000' 
 +save 
 +</code> 
 + 
 +To boot the initramfs, enter the following commands into uboot's prompt:  
 +<code> 
 +setenv bootargs console=ttyS0,$baudrate 
 +tftpboot 1000000 192.168.1.101:mpc85xx-p1020-hiveap-330-initramfs.bin 
 +bootm 
 +</code> 
 + 
 +6. Once OpenWrt booted: 
 +carefully copy and paste this into the root shell. One step at a time. 
 + 
 +6.1 install kmod-mtd-rw from the internet and load it 
 + 
 +  opkg update; opkg install kmod-mtd-rw 
 +  insmod mtd-rw i_want_a_brick=y 
 + 
 +6.2 create scripts that modifies uboot 
 + 
 +  cat <<- "EOF" > /tmp/uboot-update.sh 
 +  . /lib/functions/system.sh 
 +  cp "/dev/mtd$(find_mtd_index 'u-boot')" /tmp/uboot 
 +  cp /tmp/uboot /tmp/uboot_patched 
 +  ofs=$(strings -n80 -td < /tmp/uboot | grep '^ [0-9]* setenv bootargs.*cp\.l' | cut -f2 -d' ') 
 +  for off in $ofs; do 
 +    printf "run owrt_boot;            " | dd of=/tmp/uboot_patched bs=1 seek=${off} conv=notrunc 
 +  done 
 +  md5sum /tmp/uboot* 
 +  EOF 
 + 
 +6.2 run the script to generated a patched uboot 
 + 
 +  sh /tmp/uboot-update.sh 
 + 
 +The script will print out three md5sums to verify that /tmp/uboot and /tmp/uboot_patched are good. You can verify your results with the md5sums in [[toh:aerohive:hiveap-330|Aerohive HiveAP 330 / HiveAP 350]] 
 +    
 +For reference: my md5sum looked like this 
 + 
 +   d84b45a2e8aca60d630fbd422efc6b39  /tmp/uboot 
 +   6dc420f24c2028b9cf7f0c62c0c7f692  /tmp/uboot_patched 
 +   98ebc7e7480ce9148cd2799357a844b0  /tmp/uboot-update.sh <-- just for reference (an extra space/newline will change it) 
 + 
 +6.3 flash the patched uboot 
 + 
 +  mtd write /tmp/uboot_patched u-boot 
 +   
 +This uboot runs the bootcommand in the //owrt_boot// in the uboot environment. You can now upgrade back and forth by 
 +editing this uboot environment variable. 
 + 
 +7. permanent installation 
 + 
 +If you have LuCI (included in Releases), you can now load up LuCI at 192.168.1.1, and use the sysupgrade option to flash the full image to the device using the sysupgrade file for the HiveAP-330. From this point on, any future updates/builds can just be flashed through LuCI. 
 + 
 +If you don't have LuCI, you have to copy over the sysupgrade file via SFTP/SCP/SSH or download it on the device through wget or curl and use sysupgrade -n hiveap-330-sysupgrade.bin to make the installation permanent. 
 +==== (Downgrade) to Releases older or equal to 21.02 ==== 
 + 
 +If you are downgrading from a later snapshot release: You need to set and save the original boot command parameters that were used before the re-partitioning of the device: 
 +<code> 
 +setenv owrt_boot "setenv bootargs root=/dev/ram console=ttyS0,9600 ramdisk_size=700000 cache-sram-size=0x10000; cp.l 0xEC040000 0x2000000 0x500000; bootm 0xEE840000 0x2000000 0xEC000000" 
 +save 
 +</code> 
 + 
 +To run the installation enter the following commands in uboot: 
 +<code> 
 +tftpboot 0x1000000 192.168.1.101:mpc85xx-p1020-hiveap-330-initramfs 
 +tftpboot 0x6000000 192.168.1.101:mpc85xx-p1020-hiveap-330.fdt 
 +bootm 0x1000000 - 0x6000000; 
 +</code> 
 + 
 +Once OpenWrt boots and you have LuCI (included in Releases), you can now load up LuCI at 192.168.1.1, and use the sysupgrade option to flash the full image to the device using the sysupgrade file for the HiveAP-330. From this point on, any future updates/builds can just be flashed through LuCI.
  
 +If you don't have LuCI, you have to copy over the sysupgrade file via SFTP/SCP/SSH or download it on the device through ''wget'' or ''curl'' and use ''sysupgrade -n hiveap-330-sysupgrade.bin'' to make the installation permanent. This will overwrite the existing vendor firmware.
 ===== Troubleshooting/Unbricking ===== ===== Troubleshooting/Unbricking =====
  
Line 116: Line 220:
  
 ==== Photos ==== ==== Photos ====
- //Include photos of the router, board, RS-232 ports, etchere//+{{:media:aerohive:aerohive_hiveap330_pcb_topside.jpg| PCB Top-Side}} 
 +{{:media:aerohive:aerohive_hiveap330_internalantennas.jpg| PCB Bottom-Side with internal Antennas}}
  
 ==== Boot Logs ==== ==== Boot Logs ====
Line 443: Line 548:
 [   40.745350] fsl-gianfar soc@ffe00000:ethernet@b0000 eth0: Link is Up - 1Gbps/Full - flow control off [   40.745350] fsl-gianfar soc@ffe00000:ethernet@b0000 eth0: Link is Up - 1Gbps/Full - flow control off
 [   40.854813] IPv6: ADDRCONF(NETDEV_CHANGE): eth0: link becomes ready [   40.854813] IPv6: ADDRCONF(NETDEV_CHANGE): eth0: link becomes ready
- 
-   ## Booting image at 81000000 ... 
-   Image Name:   MIPS OpenWrt Linux-3.3.8 
-   Created:      2012-11-26  17:01:44 UTC 
-   Image Type:   MIPS Linux Kernel Image (lzma compressed) 
-   Data Size:    4269201 Bytes =  4.1 MB 
-   Load Address: 80060000 
-   Entry Point:  80060000 
-   Verifying Checksum at 0x81000040 ...OK 
-   Uncompressing Kernel Image ... OK 
-No initrd 
-## Transferring control to Linux (at address 80060000) ... 
-## Giving linux memsize in bytes, 67108864 
- 
-Starting kernel ... 
- 
-[    0.000000] Linux version 3.3.8 (dzubey@Spartan) (gcc version 4.6.3 20120201 (prerelease) (Linaro GCC 4.6-2012.02) ) #6 Mon Nov 26 10:01:28 MST 2012 
-[    0.000000] bootconsole [early0] enabled 
-[    0.000000] CPU revision is: 00019374 (MIPS 24Kc) 
-[    0.000000] SoC: Atheros AR9330 rev 1 
-[    0.000000] Clocks: CPU:400.000MHz, DDR:400.000MHz, AHB:200.000MHz, Ref:25.000MHz 
-[    0.000000] Determined physical RAM map: 
-[    0.000000]  memory: 04000000 @ 00000000 (usable) 
-[    0.000000] Initrd not found or empty - disabling initrd 
-[    0.000000] Zone PFN ranges: 
-[    0.000000]   Normal   0x00000000 -> 0x00004000 
-[    0.000000] Movable zone start PFN for each node 
-[    0.000000] Early memory PFN ranges 
-[    0.000000]     0: 0x00000000 -> 0x00004000 
-[    0.000000] Built 1 zonelists in Zone order, mobility grouping on.  Total pages: 16256 
-[    0.000000] Kernel command line:  board=DIR-505-A1 console=ttyATH0,115200 mtdparts=spi0.0:64k(u-boot)ro,64k(art)ro,64k(mac)ro,64k(nvram)ro,256k(language)ro,1024k(kernel),6656k(rootfs),7680k@0x80000(firmware) rootfstype=squashfs,jffs2 noinitrd 
-[    0.000000] PID hash table entries: 256 (order: -2, 1024 bytes) 
-[    0.000000] Dentry cache hash table entries: 8192 (order: 3, 32768 bytes) 
-[    0.000000] Inode-cache hash table entries: 4096 (order: 2, 16384 bytes) 
-[    0.000000] Primary instruction cache 64kB, VIPT, 4-way, linesize 32 bytes. 
-[    0.000000] Primary data cache 32kB, 4-way, VIPT, cache aliases, linesize 32 bytes 
-[    0.000000] Writing ErrCtl register=00000000 
-[    0.000000] Readback ErrCtl register=00000000 
-[    0.000000] Memory: 58492k/65536k available (2121k kernel code, 7044k reserved, 401k data, 3432k init, 0k highmem) 
-[    0.000000] SLUB: Genslabs=9, HWalign=32, Order=0-3, MinObjects=0, CPUs=1, Nodes=1 
-[    0.000000] NR_IRQS:51 
-[    0.000000] Calibrating delay loop... 265.42 BogoMIPS (lpj=1327104) 
-[    0.080000] pid_max: default: 32768 minimum: 301 
-[    0.080000] Mount-cache hash table entries: 512 
-[    0.090000] NET: Registered protocol family 16 
-[    0.090000] gpiochip_add: registered GPIOs 0 to 29 on device: ath79 
-[    0.100000] MIPS: machine is D-Link DIR-505 A1 
-[    0.350000] bio: create slab <bio-0> at 0 
-[    0.360000] Switching to clocksource MIPS 
-[    0.360000] NET: Registered protocol family 2 
-[    0.370000] IP route cache hash table entries: 1024 (order: 0, 4096 bytes) 
-[    0.370000] TCP established hash table entries: 2048 (order: 2, 16384 bytes) 
-[    0.380000] TCP bind hash table entries: 2048 (order: 1, 8192 bytes) 
-[    0.380000] TCP: Hash tables configured (established 2048 bind 2048) 
-[    0.390000] TCP reno registered 
-[    0.390000] UDP hash table entries: 256 (order: 0, 4096 bytes) 
-[    0.400000] UDP-Lite hash table entries: 256 (order: 0, 4096 bytes) 
-[    0.400000] NET: Registered protocol family 1 
-[    6.810000] squashfs: version 4.0 (2009/01/31) Phillip Lougher 
-[    6.820000] JFFS2 version 2.2 (NAND) (SUMMARY) (LZMA) (RTIME) (CMODE_PRIORITY) (c) 2001-2006 Red Hat, Inc. 
-[    6.830000] msgmni has been set to 114 
-[    6.830000] io scheduler noop registered 
-[    6.830000] io scheduler deadline registered (default) 
-[    6.840000] Serial: 8250/16550 driver, 1 ports, IRQ sharing disabled 
-[    6.840000] ar933x-uart: ttyATH0 at MMIO 0x18020000 (irq = 11) is a AR933X UART 
-[    6.850000] console [ttyATH0] enabled, bootconsole disabled 
-[    6.850000] console [ttyATH0] enabled, bootconsole disabled 
-[    6.870000] m25p80 spi0.0: found mx25l6405d, expected m25p80 
-[    6.870000] m25p80 spi0.0: mx25l6405d (8192 Kbytes) 
-[    6.880000] 8 cmdlinepart partitions found on MTD device spi0.0 
-[    6.880000] Creating 8 MTD partitions on "spi0.0": 
-[    6.890000] 0x000000000000-0x000000010000 : "u-boot" 
-[    6.890000] 0x000000010000-0x000000020000 : "art" 
-[    6.900000] 0x000000020000-0x000000030000 : "mac" 
-[    6.900000] 0x000000030000-0x000000040000 : "nvram" 
-[    6.910000] 0x000000040000-0x000000080000 : "language" 
-[    6.910000] 0x000000080000-0x000000180000 : "kernel" 
-[    6.920000] 0x000000180000-0x000000800000 : "rootfs" 
-[    6.920000] mtd: partition "rootfs" set to be root filesystem 
-[    6.930000] mtd: partition "rootfs_data" created automatically, ofs=6E0000, len=120000  
-[    6.940000] 0x0000006e0000-0x000000800000 : "rootfs_data" 
-[    6.940000] 0x000000080000-0x000000800000 : "firmware" 
-[    6.970000] ag71xx_mdio: probed 
-[    6.970000] eth0: Atheros AG71xx at 0xb9000000, irq 4 
-[    7.530000] ag71xx ag71xx.0: eth0: connected to PHY at ag71xx-mdio.1:04 [uid=004dd041, driver=Generic PHY] 
-[    7.540000] TCP cubic registered 
-[    7.540000] NET: Registered protocol family 17 
-[    7.540000] Bridge firewalling registered 
-[    7.550000] 8021q: 802.1Q VLAN Support v1.8 
-[    7.580000] Freeing unused kernel memory: 3432k freed 
-- preinit - 
-Press the [f] key and hit [enter] to enter failsafe mode 
-[   10.530000] eth0: link up (100Mbps/Full duplex) 
-- regular preinit - 
-[   11.540000] eth0: link down 
-- init - 
-[   11.860000] Compat-drivers backport release: compat-drivers-2012-09-04-2-gddac993 
-[   11.860000] Backport based on wireless-testing.git master-2012-09-07 
-[   11.870000] compat.git: wireless-testing.git 
-[   11.900000] cfg80211: Calling CRDA to update world regulatory domain 
-[   11.910000] cfg80211: World regulatory domain updated: 
-[   11.910000] cfg80211:   (start_freq - end_freq @ bandwidth), (max_antenna_gain, max_eirp) 
-[   11.920000] cfg80211:   (2402000 KHz - 2472000 KHz @ 40000 KHz), (300 mBi, 2000 mBm) 
-[   11.930000] cfg80211:   (2457000 KHz - 2482000 KHz @ 20000 KHz), (300 mBi, 2000 mBm) 
-[   11.940000] cfg80211:   (2474000 KHz - 2494000 KHz @ 20000 KHz), (300 mBi, 2000 mBm) 
-[   11.950000] cfg80211:   (5170000 KHz - 5250000 KHz @ 40000 KHz), (300 mBi, 2000 mBm) 
-[   11.950000] cfg80211:   (5735000 KHz - 5835000 KHz @ 40000 KHz), (300 mBi, 2000 mBm) 
-[   12.030000] NET: Registered protocol family 10 
-[   12.170000] usbcore: registered new interface driver usbfs 
-[   12.170000] usbcore: registered new interface driver hub 
-[   12.180000] usbcore: registered new device driver usb 
-[   12.330000] ieee80211 phy0: Atheros AR9330 Rev:1 mem=0xb8100000, irq=2 
-[   12.340000] cfg80211: Calling CRDA for country: US 
-[   12.340000] cfg80211: Regulatory domain changed to country: US 
-[   12.340000] cfg80211:   (start_freq - end_freq @ bandwidth), (max_antenna_gain, max_eirp) 
-[   12.350000] cfg80211:   (2402000 KHz - 2472000 KHz @ 40000 KHz), (300 mBi, 2700 mBm) 
-[   12.360000] cfg80211:   (5170000 KHz - 5250000 KHz @ 40000 KHz), (300 mBi, 1700 mBm) 
-[   12.370000] cfg80211:   (5250000 KHz - 5330000 KHz @ 40000 KHz), (300 mBi, 2000 mBm) 
-[   12.380000] cfg80211:   (5490000 KHz - 5600000 KHz @ 40000 KHz), (300 mBi, 2000 mBm) 
-[   12.380000] cfg80211:   (5650000 KHz - 5710000 KHz @ 40000 KHz), (300 mBi, 2000 mBm) 
-[   12.390000] cfg80211:   (5735000 KHz - 5835000 KHz @ 40000 KHz), (300 mBi, 3000 mBm) 
-[   12.470000] PPP generic driver version 2.4.2 
-[   12.510000] tun: Universal TUN/TAP device driver, 1.6 
-[   12.510000] tun: (C) 1999-2004 Max Krasnyansky <maxk@qualcomm.com> 
-[   12.610000] ip_tables: (C) 2000-2006 Netfilter Core Team 
-[   12.780000] NET: Registered protocol family 24 
-[   12.800000] nf_conntrack version 0.5.0 (967 buckets, 3868 max) 
-[   13.320000] xt_time: kernel timezone is -0000 
-[   13.760000] Netfilter messages via NETLINK v0.30. 
-[   13.780000] Ebtables v2.0 registered 
-[   14.030000] ip6_tables: (C) 2000-2006 Netfilter Core Team 
-[   14.270000] ctnetlink v0.93: registering with nfnetlink. 
-[   14.420000] pwm: module license 'unspecified' taints kernel. 
-[   14.430000] Disabling lock debugging due to kernel taint 
-[   14.430000] pwm: Unknown symbol device_unregister (err 0) 
-[   14.440000] pwm: Unknown symbol put_device (err 0) 
-[   14.440000] pwm: Unknown symbol __class_register (err 0) 
-[   14.450000] pwm: Unknown symbol device_create (err 0) 
-[   14.450000] pwm: Unknown symbol sysfs_create_group (err 0) 
-[   14.460000] pwm: Unknown symbol queue_work (err 0) 
-[   14.460000] pwm: Unknown symbol __alloc_workqueue_key (err 0) 
-[   14.470000] pwm: Unknown symbol class_find_device (err 0) 
-[   14.510000] i2c /dev entries driver 
-[   14.530000] gpio_pwm: Unknown symbol pwm_unregister (err 0) 
-[   14.530000] gpio_pwm: Unknown symbol pwm_register (err 0) 
-[   14.590000] usbcore: registered new interface driver usbserial 
-[   14.600000] USB Serial support registered for generic 
-[   14.600000] usbcore: registered new interface driver usbserial_generic 
-[   14.610000] usbserial: USB Serial Driver core 
-[   14.650000] Linux video capture interface: v2.00 
-[   14.710000] USB Serial support registered for FTDI USB Serial Device 
-[   14.720000] usbcore: registered new interface driver ftdi_sio 
-[   14.720000] ftdi_sio: v1.6.0:USB FTDI Serial Converters Driver 
-[   14.750000] USB Serial support registered for pl2303 
-[   14.750000] usbcore: registered new interface driver pl2303 
-[   14.760000] pl2303: Prolific PL2303 USB to serial adaptor driver 
-[   14.840000] fuse init (API version 7.18) 
-[   14.870000] usbcore: registered new interface driver uvcvideo 
-[   14.880000] USB Video Class driver (1.1.1) 
- 
-Please press Enter to activate this console. [   16.910000] ADDRCONF(NETDEV_UP): eth0: link is not ready 
-[   16.910000] device eth0 entered promiscuous mode 
-[   16.920000] ADDRCONF(NETDEV_UP): br-lan: link is not ready 
-[   17.530000] eth0: link up (100Mbps/Full duplex) 
-[   17.530000] br-lan: port 1(eth0) entered forwarding state 
-[   17.540000] br-lan: port 1(eth0) entered forwarding state 
-[   17.540000] ADDRCONF(NETDEV_CHANGE): eth0: link becomes ready 
-[   17.550000] ADDRCONF(NETDEV_CHANGE): br-lan: link becomes ready 
-[   19.540000] br-lan: port 1(eth0) entered forwarding state 
 </code></hidden> </code></hidden>
  
  
  • Last modified: 2024/02/11 21:39
  • by 127.0.0.1