WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

Re: [Xen-devel] kernel BUG at arch/x86/xen/mmu.c:1860!

To: Pasi Kärkkäinen <pasik@xxxxxx>
Subject: Re: [Xen-devel] kernel BUG at arch/x86/xen/mmu.c:1860!
From: Teck Choon Giam <giamteckchoon@xxxxxxxxx>
Date: Wed, 29 Dec 2010 12:58:15 +0800
Cc: xen-devel@xxxxxxxxxxxxxxxxxxx, Konrad Rzeszutek Wilk <konrad.wilk@xxxxxxxxxx>
Delivery-date: Tue, 28 Dec 2010 20:59:45 -0800
Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:received:in-reply-to :references:date:message-id:subject:from:to:cc:content-type; bh=k0PSaP9VCy1iQkJYfgaAZJNmw+P5RceBMlOGnTVoQYk=; b=eXCsTJqBaLA3qtAcLf4P1qsULgmDLfHPzLSK07FxQa4bW7rOfggozXPMlt/kl4gg/Y KZvvjr0C+bvwlePa0QpwXWdPxFe2da7gpraSr5G/vkeQs5EutlpoqkqJr8QfA+fYNOTo n9JvqW/oIsoQfDFW4uCxZ3142tSVZUOx6xNCo=
Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; b=l6Dt5DqiRk5qa5rDc6NNeo0Iq+k9zHEQHk3vNuR5xaA7DJFUTuE/srjzsDrGcukoxR N9KLF18BRCIF8pVg1D2z1eoSbpbyCgqcgqE+RWfixljRlz3NSK9e/XBoNBJyTC54zl3J MXAC3oz43pFIOkTp5hKZ2h9glTBX0PpD60hhs=
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <AANLkTin7A71hjbbDCVjvX6+q8yVGrg9dK4pesccNzQhh@xxxxxxxxxxxxxx>
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
References: <AANLkTi=Hwjooo43FiLPAAGzzOTG440ij_QsEqks6ECVv@xxxxxxxxxxxxxx> <20101227155314.GG3728@xxxxxxxxxxxx> <AANLkTikNvKGc78HQOMtVfi=Q+r8r92=svzZcMLQ2xojQ@xxxxxxxxxxxxxx> <20101228104256.GJ2754@xxxxxxxxxxx> <AANLkTin+B1LZLWeJ2z3ZN6AovDbdnmDg4crQkX66K53c@xxxxxxxxxxxxxx> <AANLkTin7A71hjbbDCVjvX6+q8yVGrg9dK4pesccNzQhh@xxxxxxxxxxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
Below is my latest test crash script:

----------8<----------8<----------8<----------8<----------8<----------8<----------8<----------8<----------
#!/bin/sh
#
# This script is to create lvm snapshot, mount it, umount it and remove in a
# specified number of loops to test whether it will crash the host server.
# All LVM snapshots assumed can be mounted like if you are running a PV domU.
#
# Created by Giam Teck Choon
#

# The LV name and for this case we are using XenGroup
LVGroupName=XenGroup

# return 1 if is mounted otherwise return 0
check_mount() {
    local checkdir=${1}
    if [ -n "$checkdir" ] ; then
        local check=`grep "$checkdir" /proc/mounts`
        if [ -n "$check" ] ; then
            return 1
        fi
    fi
    return 0
}

do_lvm_create_remove() {
    # number of loops default is 1
    local loopcountlimit=${1:-1}
    # snapshot size default is 1G
    local snapshotsize=${2:-1G}
    # implement a sleep between create, mount, umount and remove (default is 0 which is no pause)
    local pauseinterval=${3:-0}
    # execute commands after each pause/sleep such as sync or anything that you want to test
    local commands=${4}
    # We filter out snapshot and swap
    local count=0
    if [ -d "/dev/${LVGroupName}" ] ; then
        while [ "$count" -lt "$loopcountlimit" ]
        do
            count=`expr $count + 1`
            echo "${count} ... ... "
            for i in `ls /dev/${LVGroupName} | grep -Ev 'snapshot$' | grep -Ev 'swap$'`; do
                if [ -h "/dev/${LVGroupName}/${i}" ] ; then
                    echo -n "lvcreate -s -v -n ${i}-snapshot -L ${snapshotsize} /dev/${LVGroupName}/${i} ... ... "
                    lvcreate -s -v -n ${i}-snapshot -L ${snapshotsize} /dev/${LVGroupName}/${i}
                    echo "done."
                    sleep ${pauseinterval}
                    if [ -n "$commands" ] ; then
                        echo -n "${commands} ... ... "
                        $commands
                        echo "done."
                    fi
                    mkdir -p /mnt/testlvm/${i}
                    if [ -h "/dev/${LVGroupName}/${i}-snapshot" ] ; then
                        check_mount /mnt/testlvm/${i}
                        local ismount=$?
                        if [ "$ismount" -eq 0 ] ; then
                            echo -n "mount /dev/${LVGroupName}/${i}-snapshot /mnt/testlvm/${i} ... ... "
                            mount /dev/${LVGroupName}/${i}-snapshot /mnt/testlvm/${i}
                            echo "done."
                            sleep ${pauseinterval}
                            if [ -n "$commands" ] ; then
                                echo -n "${commands} ... ... "
                                $commands
                                echo "done."
                            fi
                        fi
                        check_mount /mnt/testlvm/${i}
                        local ismount2=$?
                        if [ "$ismount2" -eq 1 ] ; then
                            echo -n "umount /mnt/testlvm/${i} ... ... "
                            umount /mnt/testlvm/${i}
                            echo "done."
                            sleep ${pauseinterval}
                            if [ -n "$commands" ] ; then
                                echo -n "${commands} ... ... "
                                $commands
                                echo "done."
                            fi
                        fi
                    fi
                    rm -rf /mnt/testlvm/${i}
                    echo -n "lvremove -f /dev/${LVGroupName}/${i}-snapshot ... ... "
                    lvremove -f /dev/${LVGroupName}/${i}-snapshot
                    echo "done."
                    sleep ${pauseinterval}
                    if [ -n "$commands" ] ; then
                        echo -n "${commands} ... ... "
                        $commands
                        echo "done."
                    fi
                fi
            done
            rm -fr /mnt/testlvm
        done
    else
        echo "/dev/${LVGroupName} directory not found!"
        exit 1
    fi
}

case $1 in
    loop)    shift
        do_lvm_create_remove "$@"
        ;;
    *)    cat <<HELP
Usage: $0 loop loopcountlimit snapshotsize pauseinterval commands
Where:
    loopcountlimit is default to 1
    snapshotsize is default to 1G
    pauseinterval is default to 0
    commands is default to none

Example to run with 100 loops without pause/sleep:
    $0 loop 100

Example to run with 100 loops with pause/sleep of 5 seconds:
    $0 loop 100 1G 5

Example to run with 100 loops with snapshot size of 2G instead of 1G:
    $0 loop 100 2G

Example to run with 50 loops, 1G snapshot size, 5 seconds pause and with sync:
command with each pause/sleep
    $0 loop 50 1G 5 sync

Example to run with 50 loops, 1G snapshot size, no pause and with sync:
command with each pause/sleep
    $0 loop 50 1G 0 sync

Example to run your own commands:
    $0 loop 100 1G 5 "echo hi && sync"

HELP
        ;;
esac
----------8<----------8<----------8<----------8<----------8<----------8<----------8<----------8<----------

Thanks.

Kindest regards,
Giam Teck Choon
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel
<Prev in Thread] Current Thread [Next in Thread>