File:  [NetBSD Developer Wiki] / wikisrc / ports / sandpoint / inststorcenter.mdwn
Revision 1.1: download - view: text, annotated - select for diffs
Thu Oct 31 21:05:10 2013 UTC (10 years, 1 month ago) by mspo
Branches: MAIN
CVS tags: HEAD
fix sandpoint links

    1: Introduction
    2: ============
    3: 
    4: <table>
    5: <tbody>
    6: <tr class="odd">
    7: <td align="left"><p>This document describes in depth how to prepare your Iomega StorCenter G2 for installing OS/sandpoint. The three supported models are:</p>
    8: <ul>
    9: <li>StorCenter G2 Single Drive, 200MHz</li>
   10: <li>StorCenter G2 Dual Drive, 200MHz</li>
   11: <li>StorCenter G2 Quad Drive, 266MHz</li>
   12: </ul>
   13: <p>All models have 64 MB RAM and a PATA disk interface. Note that newer StorCenter models use an ARM CPU and are not supported.</p>
   14: <p>To install OS/sandpoint you will have to open the case for getting access to the serial console. This is shown here for the Single Drive model.</p></td>
   15: <td align="left"><img src="../../images/ports/sandpoint/iomega_portrait.jpg" alt="StorCenter Single Drive" /></td>
   16: </tr>
   17: </tbody>
   18: </table>
   19: 
   20: Accessing the serial interface
   21: ==============================
   22: 
   23: We need a serial console to get access to the firmware. That includes
   24: soldering a cable to the board and building (or buying) a serial adapter
   25: to convert from the StorCenter's TTL levels to RS232 levels.
   26: 
   27: Disassemble the StorCenter Single Drive
   28: ---------------------------------------
   29: 
   30: <table>
   31: <tbody>
   32: <tr class="odd">
   33: <td align="left"><img src="../../images/ports/sandpoint/iomega_open1.jpg" alt="StorCenter disassembly step 1" /></td>
   34: <td align="left"><p>The Single Drive model is somewhat tricky to open. Move the cover by applying some force into the direction away from the interface bezel. It will eventually snap open. Then remove the metal shielding. Again, there are no screws. It is held in place by some brackets. Just pull it upwards and you will see the hard disk.</p></td>
   35: <td align="left"><img src="../../images/ports/sandpoint/iomega_open2.jpg" alt="StorCenter disassembly step 2" /></td>
   36: </tr>
   37: </tbody>
   38: </table>
   39: 
   40: <table>
   41: <tbody>
   42: <tr class="odd">
   43: <td align="left"><img src="../../images/ports/sandpoint/iomega_open3.jpg" alt="StorCenter disassembly step 3" /></td>
   44: <td align="left"><p>Do not try to access the screws, which are securing the disk drive, through the plastic vents. To be able to pull the metal case up we have to remove four screws at the bottom first, which are hidden behind a plastic plate. Pry open the plastic plate using a levering tool, like a screw driver. You will need some force to do that.</p></td>
   45: </tr>
   46: </tbody>
   47: </table>
   48: 
   49: <table>
   50: <tbody>
   51: <tr class="odd">
   52: <td align="left"><img src="../../images/ports/sandpoint/iomega_open4.jpg" alt="StorCenter disassembly step 4" /></td>
   53: <td align="left"><p>Remove the four screws at the bottom. Now you can easily pull the metal case out.</p></td>
   54: <td align="left"><img src="../../images/ports/sandpoint/iomega_open5.jpg" alt="StorCenter disassembly step 5" /></td>
   55: </tr>
   56: </tbody>
   57: </table>
   58: 
   59: <table>
   60: <tbody>
   61: <tr class="odd">
   62: <td align="left"><img src="../../images/ports/sandpoint/iomega_open6.jpg" alt="StorCenter disassembly step 6" /></td>
   63: <td align="left"><p>Remove the four screws which are securing the hard disk and unplug its connectors. Also remove the fan and the LED from the metal case. Now you can pull the mainboard out of the metal case, by moving it into the direction of the rear bezel.</p></td>
   64: </tr>
   65: </tbody>
   66: </table>
   67: 
   68: Locate the serial header
   69: ------------------------
   70: 
   71: Look out for an unpopulated 8-pin header, called `J11` (marked red on
   72: the picture to the left). The leftmost four pins can be used for the
   73: serial interface. The pin assignments are shown in the table.
   74: 
   75: <table>
   76: <tbody>
   77: <tr class="odd">
   78: <td align="left"><img src="../../images/ports/sandpoint/iomega_board.jpg" alt="StorCenter mainboard" /></td>
   79: <td align="left"><table>
   80: <tbody>
   81: <tr class="odd">
   82: <td align="left"><strong>Pin number</strong></td>
   83: <td align="left"><strong>Function</strong></td>
   84: </tr>
   85: <tr class="even">
   86: <td align="left">1</td>
   87: <td align="left">3.3V</td>
   88: </tr>
   89: <tr class="odd">
   90: <td align="left">2</td>
   91: <td align="left">TXD</td>
   92: </tr>
   93: <tr class="even">
   94: <td align="left">3</td>
   95: <td align="left">GND</td>
   96: </tr>
   97: <tr class="odd">
   98: <td align="left">4</td>
   99: <td align="left">RXD</td>
  100: </tr>
  101: </tbody>
  102: </table></td>
  103: <td align="left"><img src="../../images/ports/sandpoint/iomega_ser_header.jpg" alt="Header pin assignments" /></td>
  104: </tr>
  105: </tbody>
  106: </table>
  107: 
  108: Attaching a serial cable
  109: ------------------------
  110: 
  111: <table>
  112: <tbody>
  113: <tr class="odd">
  114: <td align="left"><p>It is not recommended to solder a header onto <code>J11</code>, because then you would no longer be able to close the case. Instead you should just solder a 4-wire ribbon cable, which is flat enough to hide under the disk drive. Also make sure to choose a small 4-pin plug, which you can connect to your external cable with the actual D-SUB 9 connector. Alternatively you can cut a hole into the case.</p></td>
  115: <td align="left"><img src="../../images/ports/sandpoint/iomega_ser_cable.jpg" alt="StorCenter serial cable attached" /></td>
  116: </tr>
  117: </tbody>
  118: </table>
  119: 
  120: Serial connection
  121: -----------------
  122: 
  123: The serial port on the StorCenter is using 3.3V TTL levels, which have
  124: to be converted into regular RS232 levels by a level shifter circuit. If
  125: you are not anxious using a soldering iron you find detailed
  126: instructions how to build such a converter here:
  127: 
  128: -   Serial adapter for 3.3V TTL
  129: 
  130: Make sure that the layout of the plug fits to the pinout of the
  131: StorCenter's serial header, as shown above.
  132: 
  133: Another option is to buy such a converter. There are solutions for a
  134: standard RS232 interface and for an USB interface. Look out for:
  135: 
  136: -   RS232 level shifter / breakout board (MAX3232 based)
  137: -   USB to TLL serial level shifter / breakout board (FT232 based)
  138: 
  139: First installation
  140: ==================
  141: 
  142: Accessing the Firmware
  143: ----------------------
  144: 
  145: Provided the serial converter is installed and working correctly you
  146: should be able to connect to the firmware's serial console. Iomega is
  147: using [U-Boot](http://www.denx.de/wiki/U-Boot/), the Universal Boot
  148: Loader.
  149: 
  150: Now you can connect with any terminal program to the StorCenter's serial
  151: console. The easiest approach may be to use OS's `tip(1)` command to
  152: make a direct console connection at 115200bps.
  153: 
  154:     # tip -115200 console
  155: 
  156: Note that when using a serial connection via USB you may have to make an
  157: entry for `/dev/ttyU0` in `/etc/remote`.
  158: 
  159: Immediately after switching your StorCenter on it will display the
  160: following information (output is from a Single Drive model) and gives
  161: you one second to stop autobooting.
  162: 
  163:     U-Boot 1.0.0 (Sep  2 2005 - 14:49:11)
  164: 
  165:     CPU:   MPC8241 Revision 1.4 at 199.999 MHz: 16 kB I-Cache 16 kB D-Cache
  166:     Board: StorCenter
  167:     PICR1 is now 00141b98
  168:     PICR2 is now 00040605
  169:     AMBOR is now c1
  170:     DRAM:  64 MB   
  171:     FLASH:  8 MB   
  172:     In:    serial  
  173:     Out:   serial
  174:     Err:   serial
  175:     Net:   PCI device RTL8169#0: unknown chip version, assuming RTL-8169
  176:     PCI device: TxConfig = 0x0
  177:     RTL8169#0
  178:     Hit any key to stop autoboot:  0
  179: 
  180: altboot
  181: -------
  182: 
  183: The `altboot(8)` utility functions as a bridge between the Iomega
  184: firmware and the OS kernel startup environment. NAS firmware often
  185: provides no means to boot a kernel from disk or from the network and
  186: doesn't initialize all hardware correctly. We will also use it to pass a
  187: bootinfo list to the kernel.
  188: 
  189: The `altboot` boot loader has to be loaded and started using U-Boot.
  190: Usually there are three ways to invoke it:
  191: 
  192: -   loadb
  193:     to load a binary file via serial line in kermit mode
  194: -   tftpboot
  195:     to load a binary file over the network with TFTP protocol
  196: -   start it from the flash memory
  197: 
  198: The last option is prefered once the installation is completed, but
  199: obviously it is not possible for the first time boot. Fortunately U-Boot
  200: has set up the network interface, which we can use after configuring the
  201: `ipaddr` and `serverip` environment variables:
  202: 
  203:     IOMEGA=> 
  204:     IOMEGA=> 
  205:     IOMEGA=> 
  206:     Saving Environment to Flash...
  207:     Un-Protected 1 sectors
  208:     Erasing Flash...
  209:     . done
  210:     Erased 1 sectors
  211:     Writing to Flash... done
  212:     Protected 1 sectors
  213: 
  214: Once you have set up TFTP and DHCP ([read below](#altboot_install)) you
  215: can download `altboot` like this:
  216: 
  217:     IOMEGA=> 
  218:     TFTP from server 192.168.0.5; our IP address is 192.168.0.105
  219:     Filename 'altboot.bin'.
  220:     Load address: 0x1000000
  221:     Loading: ###############
  222:     done
  223:     Bytes transferred = 74732 (123ec hex)
  224: 
  225: Boot the INSTALL kernel with altboot
  226: ------------------------------------
  227: 
  228: Now you can use `altboot` to launch the `netbsd-INSTALL` kernel for
  229: installing OS. You may choose to load it with TFTP or from NFS. For TFTP
  230: you have to enable `tftpd(8)` in `/etc/inetd.conf`, and for NFS there is
  231: a documentation at [The Network File
  232: System](http://www.&os;.org/docs/guide/en/chap-net-services.html#chap-net-services-nfs).
  233: But in both cases you have to set up a DHCP server, which is explained
  234: in the [DHCP Howto](http://www.&os;.org/docs/network/dhcp.html). An
  235: appropriate `dhcpd.conf` entry could look like this:
  236: 
  237:             host storcenter {
  238:                     hardware ethernet 00:d0:b8:xx:xx:xx;
  239:                     fixed-address 192.168.0.105;
  240:                     next-server 192.168.0.5;
  241:                     option root-path "/export/storcenter/root";
  242:             }
  243: 
  244: The `root-path` option is only needed when using NFS and should match
  245: your exported NFS directory. Uncompress `netbsd-INSTALL.gz` from the
  246: OS/sandpoint distribution and copy it into the NFS or TFTP directory.
  247: Then start the DHCP, NFS or TFTP server and boot the installation kernel
  248: from the firmware either with
  249: 
  250:     IOMEGA=> 
  251: 
  252: or from NFS:
  253: 
  254:     IOMEGA=> 
  255: 
  256: Our bootloader configures the hardware, determines the IP address, loads
  257: the kernel via network and launches it:
  258: 
  259:     ## Starting application at 0x01000000 ...
  260: 
  261:     >> OS/sandpoint altboot, revision 1.8 (Wed Nov 23 21:51:40 CET 2011)
  262:     >> IOMEGA StorCenter G2, cpu 200 MHz, bus 100 MHz, 64MB SDRAM
  263:     channel 0 present
  264:     wd0: <ST3300822A> DMA LBA LBA48 286168 MB
  265:     wd0: no disklabel
  266:     MAC address 00:d0:b8:xx:xx:xx
  267:     100Mbps-FDX
  268:     Hit any key to enter interactive mode: 0
  269:     loading "netbsd-INSTALL" 5222228+112540=0x516b78
  270:     entry=0x90000, ssym=0x5a66f0, esym=0x5a6b78
  271:     Copyright (c) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005,
  272:         2006, 2007, 2008, 2009, 2010, 2011
  273:         The OS Foundation, Inc.  All rights reserved.
  274:     Copyright (c) 1982, 1986, 1989, 1991, 1993
  275:         The Regents of the University of California.  All rights reserved.
  276: 
  277:     OS 5.99.59 (INSTALL) #10: Fri Dec 30 18:53:09 CET 2011
  278:         frank@compaq.owl.de:/home/frank/netbsd/current/src/sys/arch/sandpoint/compile/obj/INSTALL
  279:     Model: iomega
  280:     total memory = 65536 KB
  281:     avail memory = 57904 KB
  282:     OpenPIC Version 1.2: Supports 1 CPUs and 26 interrupt sources.
  283:     mainbus0 (root)
  284:     cpu0 at mainbus0: 8245 (Revision 0.4), ID 0 (primary)
  285:     cpu0: HID0 0x90c000<DOZE,DPM,ICE,DCE>, powersave: 1
  286:     eumb0 at mainbus0
  287:     com0 at eumb0 unit 0: ns16550a, working fifo
  288:     com0: console
  289:     com0: interrupting at irq 40
  290:     ociic0 at eumb0
  291:     iic0 at ociic0: I2C bus
  292:     dsrtc0 at iic0 addr 0x68: DS1307 Real-time Clock/NVRAM
  293:     satmgr0 at eumb0 unit 1: button manager (iomega)
  294:     satmgr0: interrupting at irq 41
  295:     pci0 at mainbus0 bus 0
  296:     pchb0 at pci0 dev 0 function 0
  297:     pchb0: vendor 0x1057 product 0x0006 (rev. 0x14)
  298:     viaide0 at pci0 dev 13 function 0
  299:     viaide0: VIA Technologies VT6410 IDE controller
  300:     viaide0: using irq 17 for native-PCI interrupt
  301:     atabus0 at viaide0 channel 0
  302:     atabus1 at viaide0 channel 1
  303:     ohci0 at pci0 dev 14 function 0: vendor 0x1033 product 0x0035 (rev. 0x43)
  304:     ohci0: interrupting at irq 18
  305:     ohci0: OHCI version 1.0
  306:     usb0 at ohci0: USB revision 1.0
  307:     ohci1 at pci0 dev 14 function 1: vendor 0x1033 product 0x0035 (rev. 0x43)
  308:     ohci1: interrupting at irq 19
  309:     ohci1: OHCI version 1.0
  310:     usb1 at ohci1: USB revision 1.0
  311:     ehci0 at pci0 dev 14 function 2: vendor 0x1033 product 0x00e0 (rev. 0x04)
  312:     ehci0: interrupting at irq 20
  313:     ehci0: companion controllers, 3 ports each: ohci0 ohci1
  314:     usb2 at ehci0: USB revision 2.0
  315:     re0 at pci0 dev 15 function 0: RealTek 8169/8110 Gigabit Ethernet (rev. 0x10)
  316:     re0: interrupting at irq 16
  317:     re0: Ethernet address 00:d0:b8:xx:xx:xx
  318:     rgephy0 at re0 phy 7: RTL8169S/8110S/8211 1000BASE-T media interface, rev. 3
  319:     rgephy0: 10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, 1000baseT, 1000baseT-FDX, auto
  320:     biomask 1f000000 netmask 1f000000 ttymask 1f000000
  321:     uhub0 at usb0: vendor 0x1033 OHCI root hub, class 9/0, rev 1.00/1.00, addr 1
  322:     uhub1 at usb1: vendor 0x1033 OHCI root hub, class 9/0, rev 1.00/1.00, addr 1
  323:     uhub2 at usb2: vendor 0x1033 EHCI root hub, class 9/0, rev 2.00/1.00, addr 1
  324:     wd0 at atabus0 drive 0
  325:     wd0: <ST3300822A>
  326:     wd0: 279 GB, 581421 cyl, 16 head, 63 sec, 512 bytes/sect x 586072368 sectors
  327:     boot device: re0
  328:     root on md0a dumps on md0b
  329:     root file system type: ffs
  330:     WARNING: preposterous TOD clock time
  331:     WARNING: using filesystem time
  332:     WARNING: CHECK AND RESET THE DATE!
  333:     erase ^H, werase ^W, kill ^U, intr ^C, status ^T
  334:     Terminal type? [vt100]
  335: 
  336: Just follow the usual procedure to install a OS system.
  337: 
  338: Sandpoint installation window
  339: Post installation steps
  340: =======================
  341: 
  342: After a successful installation you want to make the system boot
  343: standalone when switched on, without the need for a serial console. So
  344: you have to modify the `bootcmd` in U-Boot's environment and write the
  345: `altboot.bin` binary to the Flash ROM.
  346: 
  347: To find a suitable place in the Flash ROM you can use the `flinfo`
  348: command and look out for empty sectors `(E)`. On my StorCenter I have
  349: chosen `0xffe80000`. Replace that in all the following commands if you
  350: have chosen a different address.
  351: 
  352: Load `altboot.bin` into memory at `0x1000000` again, as explained above.
  353: Then execute the following commands to write it to Flash ROM:
  354: 
  355:     IOMEGA=> protect off ffe80000 ffe9ffff
  356:     Un-Protected 2 sectors
  357:     IOMEGA=> erase ffe80000 ffe9ffff
  358: 
  359:     . done
  360:     Erased 2 sectors
  361:     IOMEGA=> cp.b 1000000 ffe80000 18000
  362:     Copy to Flash... done
  363:     IOMEGA=> protect on ffe80000 ffe9ffff
  364:     Protected 2 sectors
  365: 
  366: Finally adapt the `bootcmd` environment string to autoboot `altboot` and
  367: start the `netbsd` kernel (which is the default name) from `wd0` on each
  368: reboot:
  369: 
  370:     IOMEGA=> setenv bootcmd cp.b ffe80000 1000000 18000\; go 1000000 wd0:
  371:     IOMEGA=> saveenv
  372:     Saving Environment to Flash...
  373:     Un-Protected 1 sectors
  374:     Erasing Flash...
  375:     . done
  376:     Erased 1 sectors
  377:     Writing to Flash... done
  378:     Protected 1 sectors
  379: 
  380: The `\` is important for `setenv` not to misinterpret the `;` as the end
  381: of the command.
  382: 
  383: Have fun with your mini OS server!

CVSweb for NetBSD wikisrc <wikimaster@NetBSD.org> software: FreeBSD-CVSweb