Difference between revisions of "Laptop Testing"

From FreekiWiki
Jump to navigation Jump to search
(It lives!)
 
m (Updated build specs, and while loop sleep time)
Line 18: Line 18:
 
* Grant-top
 
* Grant-top
 
* Low-end
 
* Low-end
 +
* Mid-grade
 
* High-end
 
* High-end
  
Line 115: Line 116:
 
# '''Unplug''' the laptop and put a '''Battery Testing''' label on it!
 
# '''Unplug''' the laptop and put a '''Battery Testing''' label on it!
 
# Open another terminal, and type the following:
 
# Open another terminal, and type the following:
  $ while : ; do stress-test ; sleep 180 ; done
+
  $ while true ; do stress-test ; sleep 300 ; done
 
This will tell the computer to run a <code>stress-test</code> for 3 minutes, and then rest for 3 minutes until the battery dies.
 
This will tell the computer to run a <code>stress-test</code> for 3 minutes, and then rest for 3 minutes until the battery dies.
  

Revision as of 21:32, 3 November 2011

The Laptop Testing shelf is located in the far corner of the room from the entrance. There are a handful of ethernet cables for booting to the network, as well as a few long power strips for charging batteries. When you put a system on the Testing shelf, MAKE SURE YOU KEEP ITS AC ADAPTER WITH IT (even for Battery tests)!

Memtest

After a laptop has been deemed fit for building out, we want to ensure the memory installed is still good. Hence, Memtest.

A laptop successfully completes Memtest if it makes 3 passes without error. Periodically check on the systems running Memtest to see if any errors are reported. If so, make note of where in memory the errors occurred. Occasionally, you can infer which stick is bad based on where the error occurred, and save a stick of RAM. Consult your Instructor if you have any questions.

STEPS NOTES AND DETAILED DESCRIPTION
Install the proper amount of RAM Check the specs on the whiteboard and confirm with your Instructor that the appropriate amount of RAM is installed. You should only be running Memtest on the following types of laptops:
  • FG-PDX
  • Grant-top
  • Low-end
  • Mid-grade
  • High-end

As-Is machines go straight to the Store after being outfitted.

Run Memtest Depending on the system, there are a couple approaches we can take:

Boot from Network

  1. Try and confirm the laptop can boot to network by investigating its BIOS. Occasionally you will have to explicitly enable a Network Boot or PXE option,
  2. Securely connect an ethernet cable to the laptop and reboot. Usually, you can specify a Network Boot by hitting F12 while the system POSTs. If this doesn't work, you might have to move the Network Boot option first in the Boot Order,
  3. Once you see Free Geek's Net Boot menu, select Memtest86+ from the list,
  4. Confirm that Memtest is actively running and reporting the correct amount of memory and update the Keeper Label.

Boot from HDD

If you've already installed an imaged hard drive, then Memtest is available on the local disk. Follow these steps:

  1. Power on the laptop and, immediately after it POSTs, hold down the Shift key,
  2. If done correctly, you should see a message flash in the upper left corner of the screen that says GRUB loading... and a menu shortly after that. If the system continues to boot into Ubuntu, you've missed the bootloader. Reboot the system and try again. The timing can be tricky and if you find yourself having trouble, ask your Instructor to demonstrate it for you,
  3. Once you see the GRUB menu, choose the Memory test (memtest86+) option,
  4. Confirm that Memtest is actively running and reporting the correct amount of memory and update the Keeper Label.

Boot from LiveCD

If the laptop you're working on doesn't support network booting and there isn't a hard drive available, you can try booting off of a LiveCD. There are a few available on the workbench, sometimes even a dedicated Memtest Boot CD. In general, once you boot from the CD, you should be presented with a list of boot options. Try and find Memory Test (memtest86+) in that list. If it's not there, try another boot CD. As always, if that doens't work, consult your Instructor.

Troubleshooting Memtest

Memtest Freezes

Sometimes you'll get Memtest loaded onto a machine, blue screen and all, but it won't indicate any activity. The newer versions of Memtest are incompatible with certain older chipsets in laptops. The work-around we have available is to use an earlier version. Unfortunately, this is only available on the Network at the moment.

  1. Follow the instructions under Boot from Network above up until the Net Boot menu,
  2. Select Other Memtest versions from the menu, and choose the earliest version available (usually something like 2.0.1.1),
  3. Confirm that Memtest is successfully running.

Misreported Available Memory

  • Confirm that Memtest is reporting approximately the amount of installed memory. If there is a large discrepancy (e.g., 384MB reported of 512MB installed), you may either have a bad stick of RAM, a bad DIMM slot, or the system may be claiming too much video memory. Reboot into BIOS and see about lowering the amount of memory dedicated to video if the latter. Otherwise, swap in a new stick or two.

Battery Test

Once an imaged hard drive has been installed in a laptop, we can test its battery. This can happen either before or after the laptop has been built out, but needs to occur before its QC.

STEPS NOTES AND DETAILED DESCRIPTION
Adjust the Power Settings These steps are covered under the Laptop Build Checklist:
  1. Boot up Ubuntu and log in,
  2. Select System >> Preferences >> Power Preferences
  3. Under On AC Power:
    • When laptop lid is closed: Blank Screen
  4. Under On Battery Power:
    • When laptop lid is closed: Blank Screen
    • When battery power is critically low: Shutdown
  5. Under General:
    • Notification Area: Always display an icon
  6. Click Close.
Make sure the Battery is Charged You can either hover your mouse over the Battery Icon on the top panel or, more reliably, type the following into a terminal:
$ cat /proc/acpi/battery/BAT?/{info,state}

This will tell you how much charge the battery is rated to keep, as well as how much charge it had the last time it was full and what its current charge is at without attempting to guess how long the battery will last (Ubuntu is notoriously optimistic in its estimations). Here's some example output:

present:                 yes
design capacity:         56160 mWh
last full capacity:      49200 mWh
battery technology:      rechargeable
design voltage:          10800 mV
design capacity warning: 2460 mWh
design capacity low:     200 mWh
cycle count:		  0
capacity granularity 1:  1 mWh
capacity granularity 2:  1 mWh
model number:            42T5262
serial number:           35098
battery type:            LION
OEM info:                SANYO
present:                 yes 
capacity state:          ok
charging state:          charging
present rate:            0
remaining capacity:      47800 mWh
present voltage:         11243 mV

Here you can see the remaining capacity is just a little bit below the last full capacity, but that the battery is reporting charging at a rate of 0. This can be attributed to the natural degradation of the battery, and so this should be good to test.

Running Batterytest There are two ways you can run a Battery Test:

Method 1: Playing a CD

  1. Find a music CD and insert it into the laptop,
  2. Open Rhythmbox, and select the CD in the left pane so that a track list appears in the right pane,
  3. Be sure to click the Repeat button (an arrow looping around to itself), and then click Play,
  4. Watch the laptop for a moment and ensure the CD is playing,
  5. Open a terminal and type batterytest
    • If you get any output from the above command, type rm ~/bat_mon into the terminal and run batterytest again.
  6. Unplug the laptop and put a Battery Testing label on it!
  7. Mute the laptop before moving on and update the Keeper label!

Method 2: While loop

  1. Open a terminal and type batterytest
    • If you get any output from the above command, type rm ~/bat_mon into the terminal and run batterytest again.
  2. Unplug the laptop and put a Battery Testing label on it!
  3. Open another terminal, and type the following:
$ while true ; do stress-test ; sleep 300 ; done

This will tell the computer to run a stress-test for 3 minutes, and then rest for 3 minutes until the battery dies.

Make sure that you leave the AC Adapter with the laptop on the shelf. This makes it easier to check the results of the battery test and move it along the production line.


Badblocks

Occasionally we'll get a laptop (especially netbooks) where it is exceedingly difficult to remove the hard drive, or the hard drive has an incompatible adapter with our imaging stations. When this happens, we can wipe the hard drive while it is inside of the computer and then install Ubuntu on it.

STEPS NOTES AND DETAILED DESCRIPTION
Adjust the Boot Order It is imperative that we not boot from the hard drive before it has been wiped. The first thing to do is boot the laptop and set the Optical drive and, if available, Network device first in the boot order.
Boot into a Live environment
  • If a Network Boot is available, you can select Debian Rescue at the bottom of the Netboot menu. This will load a console version of Debian onto the systems memory,
  • If you can't get the system to boot from the Network, try using a LiveCD (with an external Optical drive, if necessary). We only need a commandline, so as soon as the environment is loaded, drop to a console with Ctrl + Alt + F1,
Running Badblocks Once you have a console up, type the following:
$ sudo badblocks -wvvf /dev/sda -c 1024

This will start writing arbitrary data to every sector of the harddrive, making five full passes with different patterns each time. Note that this procedure will take a long time (somewhere along 3-5 hours).