New M1015 cards installed, now what?

Status
Not open for further replies.

tstorzuk

Explorer
Joined
Jun 13, 2011
Messages
92
Ok, so I finally got my M1015 cards and the right length cables to go with them.

So now what?

When I crossflash them, should I flash with or without the card BIOS? Does it make a difference? Because it's crossflashed in IT mode (straight pass through), so would it matter if the BIOS is available or not? All of the controlling is going to be done via FreeNAS with that type of set up, right?

Once I get them installed into my new motherboard (Supermicro X9SCM-F) and plugged into the backplanes, I then have to install FreeNAS onto the memory stick that I have onboard (Patriot Autobahn 32GB PSF32GLSABUSB). I set up my NIC, and log in from another PC.

What are those stress tests that I should be running, and how do I run them from within FreeNAS? Be detailed please....jgreco! Or should I be loading a boot disc of some type and running them individually from there?

I have noticed that when I have all 3 M1015 cards installed it takes a LONG time to boot into FreeNAS. About 20 minutes. Is that because none of the drives are set up in the software at this point? For stress testing I'll probably only have one card installed at a time if that will help with reboot speed.
 

jgreco

Resident Grinch
Joined
May 29, 2011
Messages
18,680
I believe that you could probably flash the cards without the BIOS, but on a Supermicro board, you ought to be able to set the mainboard BIOS to not try booting from any of the drives, and then you'd still get a BIOS listing of the attached drives, which seems useful, plus the option to go into the setup (which is admittedly trite for SATA drives).

20 minutes seems like it is waiting around for something. I'd rather not try to replicate the issue here because it would involve taking things apart. Is it during the BIOS probe? Or after FreeNAS begins booting? What happens if you hook one drive up to each controller? etc.

For stress testing, get your system up and running first. You can do a wide variety of things to help identify problems with your hardware (especially drives). For new drives, run a SMART conveyance and then a SMART long test. Then see how it goes sucking down data at max speed. You can write a little script to do that, running multiple parallel dd's. If your devices are numbered da1...da24, you might do something like

Code:
#! /bin/sh -

i=1
while [ ${i} -lt 25 ]; do
dd if=/dev/da${i} of=/dev/null bs=1048576 &
i=`expr ${i} + 1`
done


or something like that. That's just a starting point to make sure there are no super-obvious problems. Then you want to move on to things like making sure all the results from those dd's show similar amounts of time, and then maybe move on to more stressy things like run the script, wait an hour, and run it again to cause massive seek action. You're mainly watching for unexplained problems. You can get more and more aggressive as your confidence in the platform increases.
 

tstorzuk

Explorer
Joined
Jun 13, 2011
Messages
92
For new drives, run a SMART conveyance and then a SMART long test.

Jgreco,

Ok, got the system up and running (short a sweet like usual). For running the SMART conveyance test, I went to S.M.A.R.T. Test > Add S.M.A.R.T. Test

Picked my current 8 available drives (da0, da1, da2, da3, da4, da5, da6, da7), choose the type of test "Conveyance Self-Test (ATA Only)", Give it a short description, change none of the other settings (Hour, Day of Month, Month, Day of Week) and hit the Save. So it actually won't run this test until an hour passes by?
 

jgreco

Resident Grinch
Joined
May 29, 2011
Messages
18,680
No idea, I usually do this sort of work from the command line, figuring it out as I go.
 

tstorzuk

Explorer
Joined
Jun 13, 2011
Messages
92
No idea, I usually do this sort of work from the command line, figuring it out as I go.

Well, at least that's a starting point. Go to the command line.

To run the script, do I have to actually make a script file first, and then run it?
 

tstorzuk

Explorer
Joined
Jun 13, 2011
Messages
92
Code:
#! /bin/sh -

i=1
while [ ${i} -lt 25 ]; do
dd if=/dev/da${i} of=/dev/null bs=1048576 &
i=`expr ${i} + 1`
done


Ok, I tried your code at the command line (no script file) and I got an error message;
Code:
bash: [: missing ']'


Any hints, since you only figure stuff out at the command prompt as you go?

I really hope I didn't waste a bunch of money buying the recommended hardware, to not be able to find out how to check the drives integrity.
 

jgreco

Resident Grinch
Joined
May 29, 2011
Messages
18,680
You need to create a script file and then run it in order to do that. You can do the equivalent from the command prompt by hand if you wish.
 

tstorzuk

Explorer
Joined
Jun 13, 2011
Messages
92
You can do the equivalent from the command prompt by hand if you wish.

Like I mentioned, I tried it at the command prompt (within the GUI). Unless you mean the boot option command prompt, or some other command prompt?

If I make it as a script file, do I save it with the *.scr extension (myscript.scr as an example) or some other extension?
Where would the best place (folder/path) to save it be?
 

tstorzuk

Explorer
Joined
Jun 13, 2011
Messages
92
Ok, so I've had a bit of time to read up on the "dd" command, and look back at your previous post from the other thread that I started;

Code:
#! /bin/sh -

i=1
while [ ${i} -lt 25 ]; do
dd if=/dev/da${i} of=/dev/null bs=1048576 &
i=`expr ${i} + 1`
done


#!/bin/sh - (Shebang - Use Bourne shell script) not sure what the trailing "-" is for though (FreeBSD ships with /bin/sh, /bin/csh, /bin/tcsh)
if (input file)
bs (block size) a number divisible by 512 (1048576 is good)
da$ (which disc, requires a number) da0, da1, da2, da3, da4, da5, da6, da7 available on the current M1015 card (this is dealt with in a different statement in the code as shown below.

use a # for {i} - 0, 1, 2, 3, 4, 5, 6, 7 (should it be the first if=/dev/da${i} or the second 'expr ${i} + 1', my guess is the second, as it's setting what {i} will be for the first one as well, then adding a 1, and continuing through until the n=7th disc)
Ahhhh, I see the difference. In the script file it actually sets i=1. Could I set i=0 to start with the first drive? I would think so.

Too bad I'm not sitting in front of my server right now to be able to test this out. It'll have to wait until I am. But at least I have a better understanding of what's being run on the disc drives, and how to run it.
 

jgreco

Resident Grinch
Joined
May 29, 2011
Messages
18,680
I don't know what you're looking at in the GUI. I mean at a command prompt. Use the console, or ssh in, or whatever.
 

tstorzuk

Explorer
Joined
Jun 13, 2011
Messages
92
I don't know what you're looking at in the GUI.

As shown below, taken from the Initial Setup page;
GUI-SHELL.png
http://doc.freenas.org/index.php/Initial_Setup
 

jgreco

Resident Grinch
Joined
May 29, 2011
Messages
18,680
Well, either it works or it doesn't. If it doesn't, then use the shell option from the system console, or turn on SSH and use shell via remote login.
 

tstorzuk

Explorer
Joined
Jun 13, 2011
Messages
92
Well, either it works or it doesn't. If it doesn't, then use the shell option from the system console, or turn on SSH and use shell via remote login.

Ok, tried it at the system console. I ran the following;

dd if=/dev/da${0} of=/dev/null bs=1048576 & (error message after entering this line of code)
done

It gave me the following error;

[root@******] ~# dd: /dev/da: No such file or directory

So I must be missing something from the proper directory path? It looks like it was typed in correctly. And I tried it with different drives;

/dev/da${1}
/dev/da${2}

etc.....

A little help please.

- - - Updated - - -

Ahhh,

Got it running on the first drive. Had to change the code to;

dd if=/dev/da0 of=/dev/null bs=1048576

so it's running on drive 0. Any idea how long it should take to fully read a 3TB drive? I have 24 to go through, so I'm guessing this is going to take a while.

What about the next step, writing zeros to all the drives. What's the code to use to do that (now that I'll have a better chance of interpreting what it's supposed to say)?
 

jgreco

Resident Grinch
Joined
May 29, 2011
Messages
18,680
You can put the commands in the background to do them in parallel, that's what the ampersand at the end of the command would do in the script. 3TB might take many hours.
 

tstorzuk

Explorer
Joined
Jun 13, 2011
Messages
92
I was going to ask if I could run it on more than one drive at the same time, because the CPU does have 4 cores.....

Since I can't get the code to run the way that you wrote, can I start up another 3 drives right now, 1, 2 and 3 buy running the same code, but changing the drive numbers?

- - - Updated - - -

Nope, running the different codes doesn't work. Only one drive runs at a time the way I got it running.
 

jgreco

Resident Grinch
Joined
May 29, 2011
Messages
18,680
Well, I know it works. So fix the way you got it running, because this is getting a little tedious.
 

tstorzuk

Explorer
Joined
Jun 13, 2011
Messages
92
I'm glad that it works for you. But it's not working for me. I would let you remote login via SSH if I had any idea how to set it up, but I don't.

I've tried the first line of your multi-drive check, and I continuously get an error;
Code:
[root@******] ~# #! /bin/sh -
/bin/sh: Event not found.

is the error that I get when I run it exactly the way you wrote it
Code:
#!: Command not found.

Is what I get when I try any of the below iterations
#! /bin/sh -
#! /bin/sh
#!/bin/sh -
#!/bin/sh

So not being able to get past the first line of code is quite frustrating on this end.

Could this indicate a faulty installation? Should I perhaps try re-installing FreeNAS?
 

jgreco

Resident Grinch
Joined
May 29, 2011
Messages
18,680
The words "You can write a little script to do that, running multiple parallel dd's" come back to haunt us...
 

tstorzuk

Explorer
Joined
Jun 13, 2011
Messages
92
The words "You can write a little script to do that, running multiple parallel dd's" come back to haunt us...

Previously asked;
To run the script, do I have to actually make a script file first, and then run it?
No reply

If I make it as a script file, do I save it with the *.scr extension (myscript.scr as an example) or some other extension?
Where would the best place (folder/path) to save it be?
No reply

Yup, it was either the words "You can write a little script to do that, running multiple parallel dd's" or the unanswered questions directly asking for help with those words that came back to haunt us...

Had this been a DOS environment, I would have had no problems with this.

Tried
Code:
touch myscript

came back with
Code:
touch: myscript: Read-only file system


Tried
Code:
mkdir myscript

came back with
Code:
mkdir: myscript: Read-only file system


Running a ls on the root folder only shows the following directories
./
../
which go up the directory tree.

So which directory can I go into to actually make the script file?
 

titan_rw

Guru
Joined
Sep 1, 2012
Messages
586
Please please please, go read something about the command line and unix before going any further.

These are not really the forums for unix 101. The reason your questions didn't get answered is because they show a complete lack of any unix command line knowledge. It would take hours and hours of back and forth on a forum to teach enough about the unix command line for the purposes at hand. There's a certain assumed level of knowledge when someone suggests a shell script for a certain task.

jgreco's been more than patient. If you don't have the knowledge to use what he's given, I don't think the command line is for you.

That being said, if all you want to do is wipe your drives before using them, the GUI supports that. Go to 'view disks', choose 'wipe' on the disk in question, and pick either 'full with zeros' or 'full with random data'.
 
Status
Not open for further replies.
Top