Olpc-runin-tests: Difference between revisions

From OLPC
Jump to navigation Jump to search
(Created page with ''''olpc-runin-tests''' is a collection of tests for the XO-1.5 laptop that are run during late stages of laptop production. It could also be useful for in-field diagnostics. It i…')
 
No edit summary
 
(13 intermediate revisions by 2 users not shown)
Line 1: Line 1:
'''olpc-runin-tests''' is a collection of tests for the XO-1.5 laptop that are run during late stages of laptop production. It could also be useful for in-field diagnostics. It is designed to test the hardware as well as the software installation.
'''olpc-runin-tests''' is a collection of tests for the XO-1.5, XO-1.75 and XO-4 that are run during late stages of laptop production.


(It might also be useful for in-field diagnostics. It is designed to test the hardware as well as the software installation, but is not designed to cover all software functions. The software testing is not intended to discover and report software failures, since these would unnecessarily interrupt production. Care should be taken not to use it for software testing without understanding the limitations.)
== For developers ==


By default, the tests are run in a loop for several hours. If any test fails at any point, the system is shutdown.
Source:
* git://dev.laptop.org/projects/runin
* http://dev.laptop.org/git/projects/runin


Logs are written to /runin/logdir, which is later packed into a .tar.gz. fail.log is the single log which you can quickly check for success or failure; the file is empty on success.
Current maintainer: Richard Smith


== One-off Test ==
Questions and contributions should be sent to the devel [[Mailing lists|mailing list]].


To repeat the RUNIN tests on a shipped laptop, connect the AC adapter, charge the battery, log in, start Terminal, and type;
== Original design document ==


sudo touch /runin/{force,soiled}
Note: this is not fully reflective of the current implementation, but is enough to give you a feel.
sudo reboot


After the test run, look in /runin/logdir for the output.
<pre>
Early in the boot (rc.d S00- or some such) check the TS mfg flag for run in


If the file /runin/logdir/fail.log is present and contains text, then the test run failed. Further details might be gleaned from the other logs.
if !run-in then exit
run-in = [ `cat /OFW/mfg-data/TS` == "RUNIN" ] (or what ever bash function we have to do this)


== Setting Burn Time ==
Start run-in test:
remove /bootpart/runin/fail.log
remove /bootpart/runin/olpc.fth
uncompress fs_hash.md5.whatever
Start X with our set of tests in xinitrc.


The default burn time, the time that the test will run for, is set in the runin sources.
Grab start time.
Start tests:


For 13.1.0 and later, the BT manufacturing tag may contain a number of seconds for the run.
- Set the charger pwm to 0% so it runs off of battery as much as possible
Tell EC not to charge battery. Run test for n hours on battery.
After 4-n hours re-enable full power and tell EC to charge battery
- Run md5deep to compare the all the files vs the manifest.
run over and over.
? running multiple md5deeps on different parts of the fs
for a different type of stress.
- Run cpuburn with floating point
- Run memtester
- Run camera with output to the screen an possbily to file


This allows you to override the default time that set in the code.
- Run play audio (file of silence)


ok add-tag BT 7200 \ 2 hour runin
- Check cputemp
ok add-tag BT 86400 \ 24 hour runin


== Repeating Tests ==
- ? Turn wireless on and off by reloading firmware?
- ? Suspend resume?
- ? do some r and r stuff to work the video engine harder ?


At the firmware [[ok]] prompt, set the TS manufacturing tag to RUNIN:
- Reboot tests [Not quite sure how to do with other long running tests]
ok delete-tag TS
ok add-tag TS RUNIN


Boot the system as normal, and instead of the normal boot routine, the runin tests will kick in.
Wait time < 4hours:
watch /tmp/fail.log for any items to show up
if present the write fail.log and olpc.fth to /bootpart/runin and reboot


When done, use the [[ok]] prompt to reset the TS tag to SHIP:
Check battery to make sure it returned to fully charged
ok delete-tag TS
ok add-tag TS SHIP


(Was broken in 12.1.0, see <trac>11952</trac>.)
Clean up droppings

== Kernel Suspend and Resume Stability Testing ==

Runin is being used for testing stability of suspend and resume. See [[XO-1.75/Kernel/Runin]] and [[XO-4/Kernel/Runin]].

== For developers ==

Source:
* git://dev.laptop.org/projects/runin
* http://dev.laptop.org/git/projects/runin


Current maintainer: James Cameron
Re-run md5deep to verify the files are still pristine.
Copy Run-In result file into /bootpart/runin
</pre>


Questions and contributions can be sent to the maintainer, but should be sent to the devel [[Mailing lists|mailing list]].
* Each test runs in its own process and checks for pass fail and appends to /tmp/fail.log
* If any test fails it outputs a fail report into a 'fail.log'. Top level script watchs for items in /tmp/fail.log and if found aborts the runin early. Then copies the /tmp/fail.log and rundone.fth to /bootpart/runin.

Latest revision as of 19:49, 7 February 2014

olpc-runin-tests is a collection of tests for the XO-1.5, XO-1.75 and XO-4 that are run during late stages of laptop production.

(It might also be useful for in-field diagnostics. It is designed to test the hardware as well as the software installation, but is not designed to cover all software functions. The software testing is not intended to discover and report software failures, since these would unnecessarily interrupt production. Care should be taken not to use it for software testing without understanding the limitations.)

By default, the tests are run in a loop for several hours. If any test fails at any point, the system is shutdown.

Logs are written to /runin/logdir, which is later packed into a .tar.gz. fail.log is the single log which you can quickly check for success or failure; the file is empty on success.

One-off Test

To repeat the RUNIN tests on a shipped laptop, connect the AC adapter, charge the battery, log in, start Terminal, and type;

sudo touch /runin/{force,soiled}
sudo reboot

After the test run, look in /runin/logdir for the output.

If the file /runin/logdir/fail.log is present and contains text, then the test run failed. Further details might be gleaned from the other logs.

Setting Burn Time

The default burn time, the time that the test will run for, is set in the runin sources.

For 13.1.0 and later, the BT manufacturing tag may contain a number of seconds for the run.

This allows you to override the default time that set in the code.

ok add-tag BT 7200  \ 2 hour runin
ok add-tag BT 86400 \ 24 hour runin

Repeating Tests

At the firmware ok prompt, set the TS manufacturing tag to RUNIN:

ok delete-tag TS
ok add-tag TS RUNIN

Boot the system as normal, and instead of the normal boot routine, the runin tests will kick in.

When done, use the ok prompt to reset the TS tag to SHIP:

ok delete-tag TS
ok add-tag TS SHIP

(Was broken in 12.1.0, see <trac>11952</trac>.)

Kernel Suspend and Resume Stability Testing

Runin is being used for testing stability of suspend and resume. See XO-1.75/Kernel/Runin and XO-4/Kernel/Runin.

For developers

Source:

Current maintainer: James Cameron

Questions and contributions can be sent to the maintainer, but should be sent to the devel mailing list.