Merge pull request 'content/flashing-lsi-9211' (#8) from content/flashing-lsi-9211 into master

Reviewed-on: #8
This commit is contained in:
Rick van Lieshout 2023-04-12 23:09:12 +02:00
commit d91730dd8c
16 changed files with 115 additions and 25 deletions

1
.nvmrc Normal file
View File

@ -0,0 +1 @@
18.9.0

View File

@ -37,7 +37,7 @@
],
"author": {
"name": "Rick van Lieshout",
"photo": "/me.png",
"photo": "/content/me.png",
"bio": "I'm a passionate software architect that bifurcates his love between great software development and leading others to learn and adopt new things.",
"contacts": {
"email": "info@rickvanlieshout.com",

View File

@ -0,0 +1,92 @@
---
title: Flashing the LSI-9211 to IT mode using an EFI shell
date: "2023-04-12"
template: "post"
category: "Homelab"
tags:
- "lsi"
- "lsi9211"
- "raid card"
- "storage"
- "SAS2000"
- "it mode"
description: "Flashing the LSI-9211 used to be way more difficult, luckily the EFI shell makes this task a lot simpler!"
socialImage: /media/flash-result.jpg
---
I've been building a new storage-oriented server for a while now and have yet again decided to go with (3 +1 backup) LSI 9211 raid controllers.
The reason I keep going for these specific raid controllers is quite simple. The card can theoretically support (8x500MB) 4GB/s in throughput divided over 8 drives (2x SFF-8087) which is near the maximum for consumer hard drives.
Using 3 of these will allow me to use 24 drives in a single chassis without an expander whilst getting pretty good performance.
The fourth card that I got, and flashed, is simply used as a backup or debug card in case of any errors.
## Downloading the files
Before we can start flashing we will need to download some files.
The table below lists all the files with a brief description of what we'll use them for.
| File | Description |
| --------------------------------------------------------------- | ------------------------------- |
| [EFI flashing utility](https://docs.broadcom.com/docs/12350820) | Flashing utility |
| [EFI ROM image](https://docs.broadcom.com/docs/12348628) | Card ROM file |
| [SAS2008 Firmware](https://docs.broadcom.com/docs/12350504) | IR and IT firmware for the 9211 |
## Prepping the flash drive
Make sure that you have a flash drive that is **32GB** or smaller and that it is formatted as **FAT32**.
Next, we'll add the following files to the **root** of the flash drive:
- `Installer_P20_for_UEFI/sas2flash_efi_ebc_rel/sas2flash.efi`
- `UEFI_BSD_P20/uefi_bsd_rel/Signed/x64sas2.efi`
- `9210-8i_Package_P20_IR_IT_FW_BIOS_for_MSDOS_Windows/sasbios_rel/mptsas2.rom`
- `9210-8i_Package_P20_IR_IT_FW_BIOS_for_MSDOS_Windows/Firmware/HBA_9210_8i_IT/2108it.bin`
## Flashing with EFI
Because we are going to flash using EFI we don't really need anything besides the built-in EFI shell from our motherboard. Simply insert the flash drive and go into the BIOS or use the "select boot device" functionality to select the EFI shell:
!["picture of the monitor showing boot options"](./media/boot-selector.jpg "selecting the EFI shell boot option")
After the shell has booted successfully you can use the `map` command to see all available devices. In the image below you'll see that my flash drive is listed as `fs1`:
![A list of devices in the EFI shell](./media/map-devices.jpg "a list of devices note that `fs1` is my flash drive")
To switch into the drive simply enter the drive name on the command line followed by a semicolon:
```efi
fs1:
```
Next, we'll determine that our adapters are available and we will simultaneously take note of their identifier, we can do so by issuing the following command:
```efi
sas2flash.efi -listall
```
!["list of adapters"](./media/list-adapters.jpg "a list of adapters, I flash them one at a time so I only have card '0' available to me")
Next, we can empty the current firmware with the following command:
```efi
sas2flash.efi -o -e 6
```
![Showing the result of the erasing action](./media/empty-firmware.jpg "bye, bye firmware 😢")
Now we'll simply flash the new (IT-mode) firmware on it with the following command:
```efi
sas2flash.efi -o -f 2108it.bin -b mptsas2.rom
```
![result of flashing in the EFI shell](./media/flash-result.jpg "1 card down, 3 more to go!")
Wait patiently until the operations have completed. Note that it might seem like the steps repeat, just wait until it is completely done and exits back to the shell by itself.
## Multiple cards and conclusion
You can rerun the commands for different cards (by adding `-c x` where x is the card number from `listall`) or by simply physically switching the current one out for a different one.
That's all there is too it, if you need any help feel free to hit me up!

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.9 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.4 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.5 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.3 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.8 MiB

View File

@ -7,6 +7,7 @@ tags:
- "Lego"
- "house"
description: "What started as a simple decoration piece to fill some empty space in my home quickly grew into a new hobby of which the remnants can be found throughout my house"
socialImage: /media/building-the-owl.jpg
---
## The problem

View File

@ -108,7 +108,7 @@ export default {
},
{
resolve: "gatsby-remark-images-medium-zoom",
options: { background: "rgb(0, 0, 0,50%)" },
options: { background: "rgb(0, 0, 0,70%)" },
},
"gatsby-remark-autolink-headers",
"gatsby-remark-prismjs",

View File

@ -1,7 +1,7 @@
import contacts from "./contacts";
export default {
photo: "/me.png",
photo: "/content/me.png",
bio: "",
name: "Rick van Lieshout",
contacts,

20
package-lock.json generated
View File

@ -66,7 +66,6 @@
"@types/react-helmet": "^6.1.6",
"@types/react-test-renderer": "^18.0.0",
"@types/react-toggle": "^4.0.3",
"@types/sass": "^1.45.0",
"@typescript-eslint/eslint-plugin": "^5.56.0",
"@typescript-eslint/parser": "^5.56.0",
"autoprefixer": "^10.4.14",
@ -6907,16 +6906,6 @@
"@types/node": "*"
}
},
"node_modules/@types/sass": {
"version": "1.45.0",
"resolved": "https://registry.npmjs.org/@types/sass/-/sass-1.45.0.tgz",
"integrity": "sha512-jn7qwGFmJHwUSphV8zZneO3GmtlgLsmhs/LQyVvQbIIa+fzGMUiHI4HXJZL3FT8MJmgXWbLGiVVY7ElvHq6vDA==",
"deprecated": "This is a stub types definition. sass provides its own type definitions, so you do not need this installed.",
"dev": true,
"dependencies": {
"sass": "*"
}
},
"node_modules/@types/sax": {
"version": "1.2.4",
"resolved": "https://registry.npmjs.org/@types/sax/-/sax-1.2.4.tgz",
@ -39029,15 +39018,6 @@
"@types/node": "*"
}
},
"@types/sass": {
"version": "1.45.0",
"resolved": "https://registry.npmjs.org/@types/sass/-/sass-1.45.0.tgz",
"integrity": "sha512-jn7qwGFmJHwUSphV8zZneO3GmtlgLsmhs/LQyVvQbIIa+fzGMUiHI4HXJZL3FT8MJmgXWbLGiVVY7ElvHq6vDA==",
"dev": true,
"requires": {
"sass": "*"
}
},
"@types/sax": {
"version": "1.2.4",
"resolved": "https://registry.npmjs.org/@types/sax/-/sax-1.2.4.tgz",

View File

@ -10,9 +10,16 @@ interface Props {
description?: string;
socialImage?: string;
children: React.ReactNode;
noIndex?: boolean;
}
const Layout: React.FC<Props> = ({ children, title, description, socialImage = "" }: Props) => {
const Layout: React.FC<Props> = ({
children,
title,
description,
socialImage = "",
noIndex = false,
}: Props) => {
const { author, url } = useSiteMetadata();
const metaImage = socialImage || author.photo;
const metaImageUrl = url + metaImage;
@ -29,6 +36,7 @@ const Layout: React.FC<Props> = ({ children, title, description, socialImage = "
<meta name="twitter:title" content={title} />
<meta name="twitter:description" content={description} />
<meta name="twitter:image" content={metaImageUrl} />
{noIndex && <meta name="robots" content="noindex" />}
</Helmet>
{children}
<CookieBar />

View File

@ -28,7 +28,7 @@ const TagTemplate: React.FC<Props> = ({ data, pageContext }: Props) => {
currentPage > 0 ? `${group} - Page ${currentPage} - ${siteTitle}` : `${group} - ${siteTitle}`;
return (
<Layout title={pageTitle} description={siteSubtitle}>
<Layout title={pageTitle} description={siteSubtitle} noIndex>
<Sidebar />
<Page title={group}>
<Feed edges={edges} />

View File

@ -66,6 +66,14 @@ RewriteRule ^(.*)$ http://www.mastermindzh.com/$1 [L,R=301]
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
<Files *.html>
FileETag None
Header unset ETag
Header set Cache-Control "max-age=0, no-cache, no-store, must-revalidate"
Header set Pragma "no-cache"
Header set Expires "Thu, 1 Jan 1970 00:00:00 UTC"
</Files>
# redirect old blog pages
Redirect /home /
Redirect /cookies /pages/legal/cookies

BIN
static/content/me.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 49 KiB