Pages

Monday, 17 October 2011

SED


-------------------------------------------------------------------------
USEFUL ONE-LINE SCRIPTS FOR SED (Unix stream editor)        Dec. 29, 2005
Compiled by Eric Pement - pemente[at]northpark[dot]edu        version 5.5

Latest version of this file (in English) is usually at:
   http://sed.sourceforge.net/sed1line.txt
   http://www.pement.org/sed/sed1line.txt

This file will also available in other languages:
  Chinese     - http://sed.sourceforge.net/sed1line_zh-CN.html
  Czech       - http://sed.sourceforge.net/sed1line_cz.html
  Dutch       - http://sed.sourceforge.net/sed1line_nl.html
  French      - http://sed.sourceforge.net/sed1line_fr.html
  German      - http://sed.sourceforge.net/sed1line_de.html
  Italian     - (pending)
  Portuguese  - http://sed.sourceforge.net/sed1line_pt-BR.html
  Spanish     - (pending)


FILE SPACING:

 # double space a file
 sed G

 # double space a file which already has blank lines in it. Output file
 # should contain no more than one blank line between lines of text.
 sed '/^$/d;G'

 # triple space a file
 sed 'G;G'

 # undo double-spacing (assumes even-numbered lines are always blank)
 sed 'n;d'

 # insert a blank line above every line which matches "regex"
 sed '/regex/{x;p;x;}'

 # insert a blank line below every line which matches "regex"
 sed '/regex/G'

 # insert a blank line above and below every line which matches "regex"
 sed '/regex/{x;p;x;G;}'

NUMBERING:

 # number each line of a file (simple left alignment). Using a tab (see
 # note on '\t' at end of file) instead of space will preserve margins.
 sed = filename | sed 'N;s/\n/\t/'

 # number each line of a file (number on left, right-aligned)
 sed = filename | sed 'N; s/^/     /; s/ *\(.\{6,\}\)\n/\1  /'

 # number each line of file, but only print numbers if line is not blank
 sed '/./=' filename | sed '/./N; s/\n/ /'

 # count lines (emulates "wc -l")
 sed -n '$='

TEXT CONVERSION AND SUBSTITUTION:

 # IN UNIX ENVIRONMENT: convert DOS newlines (CR/LF) to Unix format.
 sed 's/.$//'               # assumes that all lines end with CR/LF
 sed 's/^M$//'              # in bash/tcsh, press Ctrl-V then Ctrl-M
 sed 's/\x0D$//'            # works on ssed, gsed 3.02.80 or higher

 # IN UNIX ENVIRONMENT: convert Unix newlines (LF) to DOS format.
 sed "s/$/`echo -e \\\r`/"            # command line under ksh
 sed 's/$'"/`echo \\\r`/"             # command line under bash
 sed "s/$/`echo \\\r`/"               # command line under zsh
 sed 's/$/\r/'                        # gsed 3.02.80 or higher

 # IN DOS ENVIRONMENT: convert Unix newlines (LF) to DOS format.
 sed "s/$//"                          # method 1
 sed -n p                             # method 2

 # IN DOS ENVIRONMENT: convert DOS newlines (CR/LF) to Unix format.
 # Can only be done with UnxUtils sed, version 4.0.7 or higher. The
 # UnxUtils version can be identified by the custom "--text" switch
 # which appears when you use the "--help" switch. Otherwise, changing
 # DOS newlines to Unix newlines cannot be done with sed in a DOS
 # environment. Use "tr" instead.
 sed "s/\r//" infile >outfile         # UnxUtils sed v4.0.7 or higher
 tr -d \r <infile >outfile            # GNU tr version 1.22 or higher

 # delete leading whitespace (spaces, tabs) from front of each line
 # aligns all text flush left
 sed 's/^[ \t]*//'                    # see note on '\t' at end of file

 # delete trailing whitespace (spaces, tabs) from end of each line
 sed 's/[ \t]*$//'                    # see note on '\t' at end of file

 # delete BOTH leading and trailing whitespace from each line
 sed 's/^[ \t]*//;s/[ \t]*$//'

 # insert 5 blank spaces at beginning of each line (make page offset)
 sed 's/^/     /'

 # align all text flush right on a 79-column width
 sed -e :a -e 's/^.\{1,78\}$/ &/;ta'  # set at 78 plus 1 space

 # center all text in the middle of 79-column width. In method 1,
 # spaces at the beginning of the line are significant, and trailing
 # spaces are appended at the end of the line. In method 2, spaces at
 # the beginning of the line are discarded in centering the line, and
 # no trailing spaces appear at the end of lines.
 sed  -e :a -e 's/^.\{1,77\}$/ & /;ta'                     # method 1
 sed  -e :a -e 's/^.\{1,77\}$/ &/;ta' -e 's/\( *\)\1/\1/'  # method 2

 # substitute (find and replace) "foo" with "bar" on each line
 sed 's/foo/bar/'             # replaces only 1st instance in a line
 sed 's/foo/bar/4'            # replaces only 4th instance in a line
 sed 's/foo/bar/g'            # replaces ALL instances in a line
 sed 's/\(.*\)foo\(.*foo\)/\1bar\2/' # replace the next-to-last case
 sed 's/\(.*\)foo/\1bar/'            # replace only the last case

 # substitute "foo" with "bar" ONLY for lines which contain "baz"
 sed '/baz/s/foo/bar/g'

 # substitute "foo" with "bar" EXCEPT for lines which contain "baz"
 sed '/baz/!s/foo/bar/g'

 # change "scarlet" or "ruby" or "puce" to "red"
 sed 's/scarlet/red/g;s/ruby/red/g;s/puce/red/g'   # most seds
 gsed 's/scarlet\|ruby\|puce/red/g'                # GNU sed only

 # reverse order of lines (emulates "tac")
 # bug/feature in HHsed v1.5 causes blank lines to be deleted
 sed '1!G;h;$!d'               # method 1
 sed -n '1!G;h;$p'             # method 2

 # reverse each character on the line (emulates "rev")
 sed '/\n/!G;s/\(.\)\(.*\n\)/&\2\1/;//D;s/.//'

 # join pairs of lines side-by-side (like "paste")
 sed '$!N;s/\n/ /'

 # if a line ends with a backslash, append the next line to it
 sed -e :a -e '/\\$/N; s/\\\n//; ta'

 # if a line begins with an equal sign, append it to the previous line
 # and replace the "=" with a single space
 sed -e :a -e '$!N;s/\n=/ /;ta' -e 'P;D'

 # add commas to numeric strings, changing "1234567" to "1,234,567"
 gsed ':a;s/\B[0-9]\{3\}\>/,&/;ta'                     # GNU sed
 sed -e :a -e 's/\(.*[0-9]\)\([0-9]\{3\}\)/\1,\2/;ta'  # other seds

 # add commas to numbers with decimal points and minus signs (GNU sed)
 gsed -r ':a;s/(^|[^0-9.])([0-9]+)([0-9]{3})/\1\2,\3/g;ta'

 # add a blank line every 5 lines (after lines 5, 10, 15, 20, etc.)
 gsed '0~5G'                  # GNU sed only
 sed 'n;n;n;n;G;'             # other seds

SELECTIVE PRINTING OF CERTAIN LINES:

 # print first 10 lines of file (emulates behavior of "head")
 sed 10q

 # print first line of file (emulates "head -1")
 sed q

 # print the last 10 lines of a file (emulates "tail")
 sed -e :a -e '$q;N;11,$D;ba'

 # print the last 2 lines of a file (emulates "tail -2")
 sed '$!N;$!D'

 # print the last line of a file (emulates "tail -1")
 sed '$!d'                    # method 1
 sed -n '$p'                  # method 2

 # print the next-to-the-last line of a file
 sed -e '$!{h;d;}' -e x              # for 1-line files, print blank line
 sed -e '1{$q;}' -e '$!{h;d;}' -e x  # for 1-line files, print the line
 sed -e '1{$d;}' -e '$!{h;d;}' -e x  # for 1-line files, print nothing

 # print only lines which match regular expression (emulates "grep")
 sed -n '/regexp/p'           # method 1
 sed '/regexp/!d'             # method 2

 # print only lines which do NOT match regexp (emulates "grep -v")
 sed -n '/regexp/!p'          # method 1, corresponds to above
 sed '/regexp/d'              # method 2, simpler syntax

 # print the line immediately before a regexp, but not the line
 # containing the regexp
 sed -n '/regexp/{g;1!p;};h'

 # print the line immediately after a regexp, but not the line
 # containing the regexp
 sed -n '/regexp/{n;p;}'

 # print 1 line of context before and after regexp, with line number
 # indicating where the regexp occurred (similar to "grep -A1 -B1")
 sed -n -e '/regexp/{=;x;1!p;g;$!N;p;D;}' -e h

 # grep for AAA and BBB and CCC (in any order)
 sed '/AAA/!d; /BBB/!d; /CCC/!d'

 # grep for AAA and BBB and CCC (in that order)
 sed '/AAA.*BBB.*CCC/!d'

 # grep for AAA or BBB or CCC (emulates "egrep")
 sed -e '/AAA/b' -e '/BBB/b' -e '/CCC/b' -e d    # most seds
 gsed '/AAA\|BBB\|CCC/!d'                        # GNU sed only

 # print paragraph if it contains AAA (blank lines separate paragraphs)
 # HHsed v1.5 must insert a 'G;' after 'x;' in the next 3 scripts below
 sed -e '/./{H;$!d;}' -e 'x;/AAA/!d;'

 # print paragraph if it contains AAA and BBB and CCC (in any order)
 sed -e '/./{H;$!d;}' -e 'x;/AAA/!d;/BBB/!d;/CCC/!d'

 # print paragraph if it contains AAA or BBB or CCC
 sed -e '/./{H;$!d;}' -e 'x;/AAA/b' -e '/BBB/b' -e '/CCC/b' -e d
 gsed '/./{H;$!d;};x;/AAA\|BBB\|CCC/b;d'         # GNU sed only

 # print only lines of 65 characters or longer
 sed -n '/^.\{65\}/p'

 # print only lines of less than 65 characters
 sed -n '/^.\{65\}/!p'        # method 1, corresponds to above
 sed '/^.\{65\}/d'            # method 2, simpler syntax

 # print section of file from regular expression to end of file
 sed -n '/regexp/,$p'

 # print section of file based on line numbers (lines 8-12, inclusive)
 sed -n '8,12p'               # method 1
 sed '8,12!d'                 # method 2

 # print line number 52
 sed -n '52p'                 # method 1
 sed '52!d'                   # method 2
 sed '52q;d'                  # method 3, efficient on large files

 # beginning at line 3, print every 7th line
 gsed -n '3~7p'               # GNU sed only
 sed -n '3,${p;n;n;n;n;n;n;}' # other seds

 # print section of file between two regular expressions (inclusive)
 sed -n '/Iowa/,/Montana/p'             # case sensitive

SELECTIVE DELETION OF CERTAIN LINES:

 # print all of file EXCEPT section between 2 regular expressions
 sed '/Iowa/,/Montana/d'

 # delete duplicate, consecutive lines from a file (emulates "uniq").
 # First line in a set of duplicate lines is kept, rest are deleted.
 sed '$!N; /^\(.*\)\n\1$/!P; D'

 # delete duplicate, nonconsecutive lines from a file. Beware not to
 # overflow the buffer size of the hold space, or else use GNU sed.
 sed -n 'G; s/\n/&&/; /^\([ -~]*\n\).*\n\1/d; s/\n//; h; P'

 # delete all lines except duplicate lines (emulates "uniq -d").
 sed '$!N; s/^\(.*\)\n\1$/\1/; t; D'

 # delete the first 10 lines of a file
 sed '1,10d'

 # delete the last line of a file
 sed '$d'

 # delete the last 2 lines of a file
 sed 'N;$!P;$!D;$d'

 # delete the last 10 lines of a file
 sed -e :a -e '$d;N;2,10ba' -e 'P;D'   # method 1
 sed -n -e :a -e '1,10!{P;N;D;};N;ba'  # method 2

 # delete every 8th line
 gsed '0~8d'                           # GNU sed only
 sed 'n;n;n;n;n;n;n;d;'                # other seds

 # delete lines matching pattern
 sed '/pattern/d'

 # delete ALL blank lines from a file (same as "grep '.' ")
 sed '/^$/d'                           # method 1
 sed '/./!d'                           # method 2

 # delete all CONSECUTIVE blank lines from file except the first; also
 # deletes all blank lines from top and end of file (emulates "cat -s")
 sed '/./,/^$/!d'          # method 1, allows 0 blanks at top, 1 at EOF
 sed '/^$/N;/\n$/D'        # method 2, allows 1 blank at top, 0 at EOF

 # delete all CONSECUTIVE blank lines from file except the first 2:
 sed '/^$/N;/\n$/N;//D'

 # delete all leading blank lines at top of file
 sed '/./,$!d'

 # delete all trailing blank lines at end of file
 sed -e :a -e '/^\n*$/{$d;N;ba' -e '}'  # works on all seds
 sed -e :a -e '/^\n*$/N;/\n$/ba'        # ditto, except for gsed 3.02.*

 # delete the last line of each paragraph
 sed -n '/^$/{p;h;};/./{x;/./p;}'

SPECIAL APPLICATIONS:

 # remove nroff overstrikes (char, backspace) from man pages. The 'echo'
 # command may need an -e switch if you use Unix System V or bash shell.
 sed "s/.`echo \\\b`//g"    # double quotes required for Unix environment
 sed 's/.^H//g'             # in bash/tcsh, press Ctrl-V and then Ctrl-H
 sed 's/.\x08//g'           # hex expression for sed 1.5, GNU sed, ssed

 # get Usenet/e-mail message header
 sed '/^$/q'                # deletes everything after first blank line

 # get Usenet/e-mail message body
 sed '1,/^$/d'              # deletes everything up to first blank line

 # get Subject header, but remove initial "Subject: " portion
 sed '/^Subject: */!d; s///;q'

 # get return address header
 sed '/^Reply-To:/q; /^From:/h; /./d;g;q'

 # parse out the address proper. Pulls out the e-mail address by itself
 # from the 1-line return address header (see preceding script)
 sed 's/ *(.*)//; s/>.*//; s/.*[:<] *//'

 # add a leading angle bracket and space to each line (quote a message)
 sed 's/^/> /'

 # delete leading angle bracket & space from each line (unquote a message)
 sed 's/^> //'

 # remove most HTML tags (accommodates multiple-line tags)
 sed -e :a -e 's/<[^>]*>//g;/</N;//ba'

 # extract multi-part uuencoded binaries, removing extraneous header
 # info, so that only the uuencoded portion remains. Files passed to
 # sed must be passed in the proper order. Version 1 can be entered
 # from the command line; version 2 can be made into an executable
 # Unix shell script. (Modified from a script by Rahul Dhesi.)
 sed '/^end/,/^begin/d' file1 file2 ... fileX | uudecode   # vers. 1
 sed '/^end/,/^begin/d' "$@" | uudecode                    # vers. 2

 # sort paragraphs of file alphabetically. Paragraphs are separated by blank
 # lines. GNU sed uses \v for vertical tab, or any unique char will do.
 sed '/./{H;d;};x;s/\n/={NL}=/g' file | sort | sed '1s/={NL}=//;s/={NL}=/\n/g'
 gsed '/./{H;d};x;y/\n/\v/' file | sort | sed '1s/\v//;y/\v/\n/'

 # zip up each .TXT file individually, deleting the source file and
 # setting the name of each .ZIP file to the basename of the .TXT file
 # (under DOS: the "dir /b" switch returns bare filenames in all caps).
 echo @echo off >zipup.bat
 dir /b *.txt | sed "s/^\(.*\)\.TXT/pkzip -mo \1 \1.TXT/" >>zipup.bat

TYPICAL USE: Sed takes one or more editing commands and applies all of
them, in sequence, to each line of input. After all the commands have
been applied to the first input line, that line is output and a second
input line is taken for processing, and the cycle repeats. The
preceding examples assume that input comes from the standard input
device (i.e, the console, normally this will be piped input). One or
more filenames can be appended to the command line if the input does
not come from stdin. Output is sent to stdout (the screen). Thus:

 cat filename | sed '10q'        # uses piped input
 sed '10q' filename              # same effect, avoids a useless "cat"
 sed '10q' filename > newfile    # redirects output to disk

For additional syntax instructions, including the way to apply editing
commands from a disk file instead of the command line, consult "sed &
awk, 2nd Edition," by Dale Dougherty and Arnold Robbins (O'Reilly,
1997; http://www.ora.com), "UNIX Text Processing," by Dale Dougherty
and Tim O'Reilly (Hayden Books, 1987) or the tutorials by Mike Arst
distributed in U-SEDIT2.ZIP (many sites). To fully exploit the power
of sed, one must understand "regular expressions." For this, see
"Mastering Regular Expressions" by Jeffrey Friedl (O'Reilly, 1997).
The manual ("man") pages on Unix systems may be helpful (try "man
sed", "man regexp", or the subsection on regular expressions in "man
ed"), but man pages are notoriously difficult. They are not written to
teach sed use or regexps to first-time users, but as a reference text
for those already acquainted with these tools.

QUOTING SYNTAX: The preceding examples use single quotes ('...')
instead of double quotes ("...") to enclose editing commands, since
sed is typically used on a Unix platform. Single quotes prevent the
Unix shell from intrepreting the dollar sign ($) and backquotes
(`...`), which are expanded by the shell if they are enclosed in
double quotes. Users of the "csh" shell and derivatives will also need
to quote the exclamation mark (!) with the backslash (i.e., \!) to
properly run the examples listed above, even within single quotes.
Versions of sed written for DOS invariably require double quotes
("...") instead of single quotes to enclose editing commands.

USE OF '\t' IN SED SCRIPTS: For clarity in documentation, we have used
the expression '\t' to indicate a tab character (0x09) in the scripts.
However, most versions of sed do not recognize the '\t' abbreviation,
so when typing these scripts from the command line, you should press
the TAB key instead. '\t' is supported as a regular expression
metacharacter in awk, perl, and HHsed, sedmod, and GNU sed v3.02.80.

VERSIONS OF SED: Versions of sed do differ, and some slight syntax
variation is to be expected. In particular, most do not support the
use of labels (:name) or branch instructions (b,t) within editing
commands, except at the end of those commands. We have used the syntax
which will be portable to most users of sed, even though the popular
GNU versions of sed allow a more succinct syntax. When the reader sees
a fairly long command such as this:

   sed -e '/AAA/b' -e '/BBB/b' -e '/CCC/b' -e d

it is heartening to know that GNU sed will let you reduce it to:

   sed '/AAA/b;/BBB/b;/CCC/b;d'      # or even
   sed '/AAA\|BBB\|CCC/b;d'

In addition, remember that while many versions of sed accept a command
like "/one/ s/RE1/RE2/", some do NOT allow "/one/! s/RE1/RE2/", which
contains space before the 's'. Omit the space when typing the command.

OPTIMIZING FOR SPEED: If execution speed needs to be increased (due to
large input files or slow processors or hard disks), substitution will
be executed more quickly if the "find" expression is specified before
giving the "s/.../.../" instruction. Thus:

   sed 's/foo/bar/g' filename         # standard replace command
   sed '/foo/ s/foo/bar/g' filename   # executes more quickly
   sed '/foo/ s//bar/g' filename      # shorthand sed syntax

On line selection or deletion in which you only need to output lines
from the first part of the file, a "quit" command (q) in the script
will drastically reduce processing time for large files. Thus:

   sed -n '45,50p' filename           # print line nos. 45-50 of a file
   sed -n '51q;45,50p' filename       # same, but executes much faster

If you have any additional scripts to contribute or if you find errors
in this document, please send e-mail to the compiler. Indicate the
version of sed you used, the operating system it was compiled for, and
the nature of the problem. To qualify as a one-liner, the command line
must be 65 characters or less. Various scripts in this file have been
written or contributed by:

 Al Aab                   # founder of "seders" list
 Edgar Allen              # various
 Yiorgos Adamopoulos      # various
 Dale Dougherty           # author of "sed & awk"
 Carlos Duarte            # author of "do it with sed"
 Eric Pement              # author of this document
 Ken Pizzini              # author of GNU sed v3.02
 S.G. Ravenhall           # great de-html script
 Greg Ubben               # many contributions & much help
-------------------------------------------------------------------------

Saturday, 17 September 2011

Cloud Computing : adoption issues


Cloud Computing : adoption issues


In my previous post about ” Cloud Computing” , I tried to explain my understanding about cloud computing so far. In this post I am trying to highlight some of the important points and concerns , from various research studies, that need attention while planning for a cloud based services for any organisation.

Issues with Cloud adoption

There are three types of potential users of cloud computing services: consumers, small organizations, and medium to large organizations. Consumers and small organizations have relatively simpler requirements for adopting a new technology than medium to large organizations, and have much less to lose if the adoption goes awry. There are at least seven types of adoption issues for cloud computing . They are
Outage (availability)
Security
Performance
Compliance
Private clouds
Integration
Cost
Environment

Of these, outage, security, and performance are quality of service (QoS) issues. Only some of the adoption issues matter to consumers and small organizations. However, all of them are of concern to medium to large organizations.

1. Outage

An outage may be temporary and permanent. A permanent outage occurs when a cloud service provider goes out of business. This has happened, and will happen again. Temporary outage of cloud computing services appears to be inevitable. It may happen several times a year, and each time it may last a few hours or nearly one full day or even longer. When large cloud services become unavailable, there is a nearly instant and worldwide coverage of the outage. Such services as Amazon, Google, Citrix, etc. have experienced highly publicized outages during the past couple of years.

The users of a cloud service should exercise prudence, and take one or more of the following precautions. First, they should not entrust absolutely mission-critical applications and data to the cloud service providers; that is, they should use cloud services for non-mission-critical applications and data. This explains the current uses of cloud services for Web site hosting, software testing and online data backup. Second, they should keep backups of applications and data on on-premises servers and storage, or on a secondary cloud service. Third, they should secure as favorable a service-level agreement (SLA) as possible from the cloud service provider for a favorable partial redress in case of temporary outages. We note that none of these precautions is entirely satisfactory. The first limits the use of the cloud service. The second and third erode the cost advantage of the cloud service. The third never fully compensates for the actual damage.

2. Security

The security of computer systems, and the data stored on them, can be compromised in so many ways, 100% security is simply impossible. Sophisticated hackers can break into just about any computer system. A cloud may become a “honey pot” that attracts hackers. Accidents may happen during physical transportation or electronic transfer of a large volume of data. Dishonest staff members may do bad things to the computer system or data. We believe, however, that the clouds are not less secure than on premises computing systems. There is no reason that the best security technologies and processes that can have been adopted for on premises computing systems cannot be used by the cloud service providers.

Further, the effects of security breaches on the cloud service providers are as great or even greater than those on medium to large organizations. As such, the cloud service providers should be highly motivated to do their best to secure their servers and data. The security measures that Amazon Web Services employs may serve as a model for other cloud service providers. The user can run his customized machine image with a full root access. The user can have his own ingress firewall. The user can also have granular access control for every file. The user needs CERT, a public key, a long ID string, a security ID to access Amazon’s resources.

3. Performance

A major source of performance problem for cloud services is the communication time between the client computer and the Web server in the cloud. This problem becomes serious as the number of simultaneous users increases, and the amount of data transferred to and from the cloud increases. Even the physical distance between the client computer and the cloud makes a difference. Sometimes organizations discover the need to substantially increase the communication bandwidth shortly after adopting cloud services. Before adopting cloud services, organizations must assess the communication bandwidth requirements, and evaluate the performance behavior of the applications with respect to transfer of large amounts of data. Another source of performance problem is the inability for the service provider to scale up their computing infrastructure as customer demands increase beyond the original expectation. Before adopting cloud services, organizations must understand the service provider’s capacity assumptions and scale-out plans regarding the computing infrastructure.

4. Compliance

In most of the countries, enterprises are subject to some government regulations regarding the secure storage, privacy, and disclosure of data. These regulations were written without consideration of cloud computing, that is, an enterprise storing data on a third-party computing facilities that are shared with other enterprises. It is not clear if cloud computing will violate such regulations.

5. Private Clouds

A private cloud is an on-premises cloud. A private cloud, except for its physical location, works just like a normal, or public, cloud. The virtual machines and storage are created by virtualizing physical computing resources; and the virtual computing resources are dynamically allocated and deallocated based on the needs of the users. Further, the users or departments in the enterprise are charged for the services they actually use.

Since the term “cloud” was coined to refer to a remote third-party service provider, the term “private cloud” is an oxymoron. Besides, one of the primary motivations for cloud services has been touted as the freedom from having to administer on-premises computing resources. A possible justification for the use of the term private clouds is the fact that a private cloud is envisioned as a central cloud for an enterprise, and it is to be accessed by users in different departments, as though it is a remote computing resource. In any case, the concept of private clouds has gained grounds recently.

Private clouds can serve as a halfway step before the adoption of public cloud services. Enterprises can gain experience using cloud services, and prepare their IT infrastructure and staff properly. Further, enterprises can make use of hybrid cloud services based on their private clouds and some public clouds. For example, when the capacity of the private cloud is exceeded, the enterprise may tap into the public cloud. There are adoption issues for hybrid cloud services. Today, if a workload is to be moved from a private cloud to a public cloud, both clouds require the same hypervisor, the same chipsets for the servers, and the same file system. Further, virtualization vendors have different virtual machine formats. To alleviate this problem, the Distributed Management Task Force has proposed an Open Virtual Machine Format.

6. Integration

Since organizations may need to adopt multiple service providers to various reasons, they need to integrate applications and data on multiple public clouds. Further, many organizations are likely to adopt hybrid clouds, they need to integrate applications and data between the private clouds and the public clouds. Technologies such as enterprise information integration (or federated database systems), enterprise application integration, and enterprise service bus can be adapted to address the cloud integration issues.

7. Cost

Cost is generally not regarded as an adoption issue. People take the “only pay for what you use” part of the marketing definition of cloud computing as a given. In the 1980s and 1990s, people took for granted about the promise of cost savings in outsourcing software development. The cost savings, while still significant, turned out to be much less than had been presumed, because of the need to communicate between the two parties (e.g., travel, stationing staff), to re-do work that was not done properly, gradual increase in fees charged, etc. Similarly, the promised cost benefits of cloud computing are bound to be eroded. As observed above, the need to maintain onpremises backup or secondary cloud services in order to cushion the impact of occasional outages certainly adds to the cost. The need to increase communication bandwidth to maintain a desired performance level adds to the cost. Further, the “remote administering of computing resources” part of the marketing definition of cloud computing does not mean that organizations that adopt cloud services can totally depend on the service providers for the administering of the applications, virtual machines and storage. The organizations still need to monitor the performance and availability of the virtual computing resources.

There are various monitoring tools, both commercial and open source. Monitoring requires staff time, and possibly commercial tools. These add to the cost. IaaS service providers create virtual computing resources out of physical computing resources, and allocate the virtual computing resources to different users. This means that multiple users share common physical computing resources. Some organizations insist on having dedicated physical computing resources in the cloud in order to prevent other “tenants” from possibly crossing paths. Use of dedicated physical resources in the cloud can substantially erode the cost benefits of cloud computing.

Cloud Computing – It’s not just another buzzword, but a near future


Cloud Computing – It’s not just another buzzword, but a near future



WHAT IS CLOUD COMPUTING?

Google, Yahoo, Amazon, and others have built large, purpose-built architectures to support their applications and taught the rest of the world how to do massively scalable architectures to support compute, storage, and application services.

Cloud computing is about moving services, computation and/or data—for cost and business advantage—off-site to an internal or external, location-transparent, centralized facility or contractor. By making data available in the cloud, it can be more easily and ubiquitously accessed, often at much lower cost, increasing its value by enabling opportunities for enhanced collaboration, integration, and analysis on a shared common platform.

Cloud computing can be divided into three areas:

SaaS (software-as-a-service). WAN-enabled application services e.g., Google Apps, Salesforce.com, WebEx
PaaS (platform-as-a-service). Foundational elements to develop new applicationse.g., Coghead, Google Application Engine
IaaS (infrastructure-as-a-service). Providing computational and storage infrastructure in a centralized,location-transparent service e.g., Amazon

Enabling technologies. The following precursor technologies enabled cloud computing as it exists today:
SaaS
Inexpensive storage
Inexpensive and plentiful client CPU bandwidth to support significant client computation
Sophisticated client algorithms, including HTML, CSS, AJAX, REST
Client broadband
SOA (service-oriented architectures)
Large infrastructure implementations from Google, Yahoo, Amazon, and others that provided real-world, massively scalable, distributed computing
Commercial virtualization

CAPEX ( Capital Expenses) VS. OPEX ( Operation Expenses) TRADEOFF

In the past, developing an application service required a large CapEx (capital expense) to build infrastructure for peak service demand before deployment. The risk of a service’s success combined with the operational requirement of a large CapEx investment severely restricted funding. Cloud computing addresses this problem by allowing expenses to track closely with resource use, thus following income rather than having to purchase for peak capacity before income is realized. Running application services on a cloud platform accomplishes this in three fundamental ways:
It moves CapEx to OpEx (operational expense), closely correlating expenses with resource use.

It allows service owners to eliminate significant system-administration head count by avoiding the need for internally purchased servers.

It smooths the path to service scaling by not requiring the CapEx-intensive architectural changes needed to scale up service capacity in the event of service success.

Because the cost of deploying new services is much lower and expenses track real usage, businesses can develop and deploy more services without fear of writing off huge capital investments for dedicated infrastructure that may never be needed. While start-ups are more focused on cost, enterprises are equally focused on flexibility to make required service changes and achieve maximum agility. Some Silicon Valley start-ups are able to go completely without infrastructure, instead using outside services for e-mail, Internet, phone, and source control. This allows the start-up to focus all of its resources on its core differentiating efforts.

BENEFITS of Cloud computing
Large-scale multitenancy achieves significant economic advantage. Sharing the resources and purchasing power of very large-scale multitenant data centers provides an economic advantage. As an example, a major engineering services company’s current internal cost to provide a gigabyte of managed storage is $3.75 per month, while Amazon charges 10 to 15 cents per month. Initially, ISP charges at the company were $3,500 per megabyte per month. After examining the cost structure of companies such as YouTube, the engineering services company assumed that YouTube’s costs were in the teens. Taking advantage of network peering arrangements and consolidating the company’s interfaces to a place close to the ISP’s POP (point-of-presence) have brought costs down to YouTube levels.
Broad use of virtualization has also significantly reduced the company’s data-center CapEx. Prior to virtualization, server utilization was between 2 and 3 percent and total data-center floor space was around 35,000 square feet. With virtualization in widespread use, server utilization is up to 80 percent and server consolidation has shrunk the square footage of the data center to 1,000 square feet.
As more cloud service vendors become available, computing and storage will become a true commodity with fine-grained pricing models, complete with arbitrage opportunities, similar to other commodities such as natural gas and electric power. Under a cloud model, pricing is based on direct storage use and/or the number of CPU cycles expended. It frees service owners from coarser-grained pricing models based on the commitment of whole servers or storage units.
Transforming high fixed-capital costs to low variable expenses. Setting up an internal cloud within a company provides an efficient service platform while placing a limit on internal capital expenditures for IT infrastructure. An external cloud service provider can supply overflow service capacity when demand increases beyond internal capacity.
Previously, companies had to operate servers for projects even though they might never be invoked—such as servicing warranties. A cost of $800 to $1,000 per month is not unreasonable to have a server idle on the data-center floor. By moving these projects to an external IaaS vendor, those functions can be placed in the cloud and the service run only when required, at pennies per CPU hour. In this way, companies can transform what was a high fixed cost into a very low variable one.
Flexibility. For large enterprises, the ease of deploying a full service set without having to set up base infrastructure to support it can be even more attractive than cost savings. Bechtel must set up new engineering centers with very little notice worldwide. Using internal cloud IT resources, Bechtel can now set up these centers to be fully functional within 30 days.
Smoother scalability path. For application architectures that easily scale with added hardware and infrastructure resources, cloud computing allows for many single services to scale over a wide demand range. Animoto’s service started with 50 instances on Amazon. Because of its popularity, it was able to meet soaring demand and scale to 3,500 instances within three days. It is not a given, however, that all application architectures scale that easily. Databases are a good example of hard-to-scale applications—hence, the widespread use of programs such as Amazon’s SimpleDB.
Self-service IT infrastructure.Cloud-computing service models are often self-service, even in internal models. Previously, you had to partner with IT to develop your application, provide an execution platform, and run it. Now, much like Amazon, IT departments define use policies for automated platform and infrastructure services with line-of-business-owners developing applications on their own to meet those requirements.
Severely reduced disaster recovery cost. Most SMBs (small- to medium-size businesses) make no investment in DR (disaster recovery). By enabling VMs (virtual machines) to be sent to the cloud for access only when needed, virtualization becomes a cost-effective DR mechanism. Typical DR costs are 2N (twice the cost of the infrastructure). With a cloud-based model, true DR is available for 1.05N, a significant savings. Additionally, because external cloud service providers replicate their data, even the loss of one or two data centers will not result in lost data.
Common application platform enables third parties to add value. While telcos are moving to cloud platforms for cost effectiveness, they also see opportunities resulting from a common application platform. By allowing third parties to use their platforms, telcos can deploy services that either extend the telco’s services or operate independently.
Increased automation. Amazon sees automation as a significant benefit of a cloud services model. Moving into the cloud requires a much higher level of automation because moving off-premises eliminates on-call system administrators.
Release from ABI and operating-system dependencies and restrictions. Amazon also sees cloud computing as a way of releasing data centers from the need to support the ABI (application binary interface) and operating-system requirements of key applications. With EC2, Amazon provides five popular VMs to choose from: three flavors of Linux, OpenSolaris, and Windows Server. Its only concern is effectively running the VMs; it does not have to be involved with the VM’s internal operations.
MapReduce enables new services. Although not the most cost-efficient way of providing data-warehouse functionality, MapReduce’s use of a large parallel-processing resource has enabled a number of companies to provide cloud-based data-warehousing services. This frees customers from having to invest in large specialty hardware purchases for small service requirements. MapReduce is expected to enable additional service types that were once limited to dedicated hardware.

USE CASES for Cloud Computing
An international financial exchange paid for the development of a large service. It hosted data in the cloud and ran the application on the client’s desktop. All operations were on a pay-as-you-go basis. This is an example of a very low initial investment required to make a commercial service operational.
Shazam is a start-up company whose service executes on the Apple iPod. It samples songs being played on the radio, matches the songs to a library in the cloud, and returns a link to purchase that song on the iPod. It is an example of a smart device coupled with cloud-based computation and storage.
Animoto, hosted on Amazon, was able to track demand of its service and scale up from 50 instances to 3,500 instances over a three-day period.
A national newspaper wanted to place scanned images covering a 60-year period online. After being repeatedly turned down by the CIO for the use of six servers, the newspaper moved four terabytes into S3, ran all the software over a weekend on EC2 for $25, and launched its product.
A major international auto-race organizer supports special race Web sites that provide live streaming video and realtime technical information. Previously, it would retain an ISP, acquire massive server power, and hire 500 engineers to baby-sit the servers at the ISP to institute server failover manually. When it moved to EC2, the savings in server rental were not that big, but it did realize orders of magnitude in personnel cost savings.
Mogulus streams 120,000 live TV channels over the Internet and owns no hardware except for the laptops it uses. It did all of the election coverage for most of the large media sites. Its CEO states that he could not be in business without IaaS.

DISTANCE IMPLICATIONS BETWEEN COMPUTATION AND DATA

How you deal with the distance between computation and data depends heavily on application requirements. If you need to minimize expensive bandwidth, then you should find a way to keep the two in proximity. In cases where bandwidth is expensive and the distances cannot be shortened, it may make sense to download an extract of the data to work on it locally. Longer term, it would be best if developers could write the application in such a way that it would dynamically adjust its data-access mechanisms in response to the operational context (bandwidth cost, bandwidth latency, security, legal data location requirements, etc.).

DATA SECURITY

A common concern about using an external cloud service provider is that it will make data less secure. Because of the wide quality range of corporate IT security, trusting information assets to a recognized cloud service provider could very easily increase the security of those assets. Given that many corporate data centers struggle to fund, architect, and staff a complete security architecture, and that cloud service providers provide IT infrastructure as their primary business and competence, clouds could possibly increase security for the majority of their users. Moreover, 75 to 80 percent of intellectual property breaches are a result of attacks made inside the company, which would not impact a decision to use clouds one way or the other.

Some Important Conclusions from various industry experts:
IT should establish a revenue metric to show the cost effectiveness of its service-delivery infrastructure. Bechtel used the inverse of the hours it took to complete its corporate projects. By increasing infrastructure utilization, it lowered its cost per unit of output by 55 percent—increasing capacity and overall satisfaction.
Although most CIOs and CTOs are interested in seeing if a cloud-based service model is a more efficient IT architecture, initial adoption is usually bottom-up and based on pragmatic business needs. Often the CIO is the last person in the adoption chain.
In deploying services for your company, make an effort first to buy those services before building them on your own. As in all successful businesses, do not get caught up in building and supporting infrastructure that is not core to your business.
If an application is performed trillions of times per day, anything with even a remote probability of failure is a certainty. Application developers must be trained to accept failure as inevitable and design for it.
Cloud computing represents a shift in power in IT away from those who control capital resources to the users and developers who employ self service to provision their own applications.
Often IT people are not rational and will resist losing control of power and budget. This can be a significant roadblock in converting to a cloud-based service architecture. Change management can often be the majority of the effort in converting to a cloud-oriented service architecture (e.g., at Bechtel it has been around 80 percent of the effort) as it takes time for people to move outside their career and risk comfort zones. A cloud service model places traditional IT skills at risk, and those people need to be transitioned from managing the physical infrastructure (such as storage or processing) to managing IT policies and service-level guarantees.
When the load varies widely, a cloud-computing service model excels. For services that impose well-defined loads, it usually is more cost effective to make the capital investment for an internal platform (e.g., running your own Microsoft Exchange server on Amazon is not a good idea).
By restructuring its Internet services to be similar to YouTube and placing interfaces closer to ISP POPs, Bechtel was able over several years to decrease latency by 50 percent and reduce Internet charges by several orders of magnitude. Bechtel currently pays $10 to $20 per megabyte per month.

Some of the challenges
Are data-ingestion services able to take physical delivery of a large amount of media for transfer to the cloud?
Are appropriate data-location choices provided to the application so that users can comply with applicable law? Depending on the laws in force, data-location compliance can be quite complex and require sophisticated abstractions.

Cloud Computing – What does it mean to System Administrators


Cloud Computing – What does it mean to System Administrators




Most of us already know that Cloud Computing is a new Buzz word in the industry and it is very true that everyone want to learn about it as much as possible. For myself, I have been reading and observing cloud computing evolution for past one year, and recently I had an opportunity to attend for IBM’s SmartCloudCamp session which has given me some insight on current state of cloud computing evolution.

I have noticed several questions from System Admin community about the Cloud computing’s effect on Infrastructure Support Teams. In this post I am just trying to address the same question in a way that I understand cloud computing.


Cloud Computing

Let me tell you a small story before we go to discuss about t the Cloud Computing.

My Sister and her family is living in a small town in the state of Andhra Pradesh, India. In the town, the power failures are so common and it is like 1 or 2 hours of power outage with a frequency of 2 or 3 times per day. My sister and her neighbors were so upset because these continuous power outages disturbing the kid’s studies and also making life difficult during the evenings. They know that there is an alternative to solve the problem by having power generator as a backup power source but most of the neighbor families are not in a position to afford for it and also they are worried about the regular maintenance cost of these devices.

One fine day, a group of smart minds came up with a solution to purchase a high capacity power generator , place it in some common place and to provide backup power connections to every home who ever ready to pay for the usage charges as per the the actual usage calculated by the electric meter plugged in at every home. Interestingly, the idea worked very well, and most of the people in the town were adapted the backup power source with the minimum capital investment and zero maintenance cost.

I believe, by this time, you might have understood the purpose of cloud computing in IT industry. If it is still unclear, lets go forward to look at it in more detailed terms

The Current definition of Cloud Computing is ” A Comprehensive solution which delivers the IT as a Service. Here the term IT can be expanded as Infrastructure, Platform, Storage and Software”. . At present the IT industry classified into two groups in terms of cloud computing , first one is Cloud Computing Service Providers and the other one is Cloud Computing Service Consumers ( Client).


Cloud Computing in its Basic Form
Quick refresh on Cloud Computing Benefits to a Client/Consumer

1. Reduced Capital Cost to setup IT Infrastructure

Scenario 1:

If any organisation want to start a new business function that needs IT infrastructure, the organisation need not go through the all the complex process of establishing IT infrastructure starting from the Data center planning. Instead the company simply can go for a Cloud Computing service provider who is providing the kind of service , in his service catalogue, that meets the organisation’s IT requirement for the new business function. The requested service could be anything like Server/Storage/Network Infrastructure, Platform Environment or already built software application which can be customized to your requirement. And the organisation will pay, to the service provider, only for the resources that has been utilized. No Capital investment, no running maintenance cost.

Scenerio 2:

If any organisation want to migrate it’s existing IT infrastructure ( or part of it ) related to less critical business function, it can again approach the Cloud Computing Service provider for a solution that works for their actuation requirement.

2. Rapid scalability with the help of dynamic infrastructure

Current Challenge:

In any business, it is very common that, the initial design of IT infrastructure happens considering the current potential of business and expected growth of business in near future. And these expectations / predictions about the future growth may or may not be correct, in current day high fluctuating business markets. Any large Investment in IT infra setup will be wasted if the related business not doing well , as expected. And at the same time insufficient IT infra resources could block the business growth if the business was progressing better than expected.

It is always a real challenge to any organisation to predict the actual requirement of IT infrastructure , and this challenge can easily addressable if the organisation considering the cloud computing solution.

Using Cloud Computing, organisations can easily scale it’s resources to the level it matches the business requirement which is very dynamic in nature.

3. Utility Pricing Model

This point is self explanatory, organisations will pay for the only resources that they have used. No Initial investment to setup infra.

4. Self Service by using Automated Provisioning

I believe, this is one key point where cloud computing affecting the existing IT infrastructure job roles.

By using automated provisioning feature of Cloud Computing , organisations can request the services mentioned in Service Catalogue and could receive the services instantly and dynamically with minimum or no technology skills.

5. Resource availability from anywhere of the world

Public clouds can be accessed from anywhere of the world using the internet, and this feature makes cloud computing as beautiful solution for many startup companies which are running using virtual teams located in different parts of world.

for more inforamtoin, you can refer my other post ” Cloud Computing – It’s not just another buzzword, but a near future “, which talks about cloud computing features and benefits.





Cloud Computing Layers



IaaS - Infrastructure as a Service

Iaas is basically a paradigm shift from “Infrastructure as an asset” to “Infrastructure as a Service”

Key Characteristics of Iaas:
Infrastructure is Platform independent
Infrastructure costs are shared by multiple clients/users
Utility Pricing – Clients will pay only for the resources they have consumed

Advantages:
Minimal or No Capital investment on Infrastructure Hardware
No Maintenance costs for Hardware
Reduced ROI risk
Avoid the wastage of Computing resources
Dynamic in nature
Rapid Scalability of Infrastructure to meet sudden peak in business requirements

Drawbacks:
Performance of Infrastructure purely depends on Vendor capability to manage resources
Consistent high usage of resources for a long term could lead to higher costs
Companies have to introduce new layer of Enterprise security to deal with the cloud computing related to security issues

Note: It is better not to adapt Iaas Solution, if the oraganisation capital budget is greater than the Operating budget

PaaS – Platform as a Service

Paas is a Paradigm shift from ” purchasing platform environment tools as a licensing product ” to “purchasing as a service”.

Key Characteristics:
Deployment purely based on cloud infrastructure
caters to agile project management methods

Advantages:
It is possible capture the complex testing & development platform requirement and automate the tasks for provisioning of consistent environment.

Drawback:
Enterprises have to introduce new layer of security to deal with the security in cloud computing environment.




SaaS – Software as a Service

SaaS is basically paradigm shift from treating “treating software as an asset of business/consumer” to “using software as a service achieve the business goals”

Advantages:
reduce Capital expenses required for the development and testing resources
Reduced ROI risk
Streamlines and Iterative updates of the software

Drawbacks:
Enterprises have to introduce new layer of security to deal with the security in cloud computing environment.


Layers of Cloud Computing





Cloud Computing Solutions for Enterprise



Public Cloud Solution for Enterprise

Public Cloud solution allows enterprise to adapt Iass, Pass and Saas services from a cloud computing service provide on the internet, and actual computing resources are available under control of Vendor.

Private Cloud Solution for Enterprise

Private Cloud Solution for Enterprise nothing but constructing cloud solution within the enterprise datacenter, to provide more security on physical resources. And the internal departments of the enterprise within the organisation can utilise and pay for cloud computing resources as if they are using public cloud resources.

Hybrid Cloud Solution for Enterprise

Hybrid cloud solution enables enterprise use both public cloud and private cloud resources same time depending on the criticality and importance of the business function.

Virtual Private Cloud Solution

Using Virtual Private Cloud Solution Companies can create their own private cloud environment with in the public cloud by using different network/firewall rules. And the purpose is to avoid external access to the enterprise resources.


Possible Cloud Computing Solutions for Enterprise


How Cloud Computing affects the Job roles in the Infrastructure Support Team



Depending on the Clod computing Solution that enterprise adapted, there will be direct and indirect effect on the various job roles with in the infrastructure support teams.

If you look at the Sysadmin role in general , the actual job role involves three major responsibilities:
Hardware administration
Operating System Builds
Operating System Administration
Network Services Administration

Once the organisation adapted the Cloud Computing solution ( IaaS / PaaS / SaaS ) , it no longer required to maintain the skillful technical people to deal with hardware related issues and OS Build operations but they still need resources to perform OS / Network administration and to customize cloud resources to meet the organisation requirements. And the same effect is true for the Network Support roles.

Cloud Computing solutions cannot replace every system administrator in the company but it will expect new level cloud computing related expertise instead of ” to be isolated hardware maintenance skills”. For sure, it’s a call for learning. And more importantly the sysadmin job roles specifically dealing with the “Hardware & OS builds” has to go away, in near future.

For any organisation, the current recruitment strategy for the SysAdmin Team is “No. of Sysadmins are directly proportional to the physical server foot print in the data center “. With IaaS adaption organisation’s server footprint will reduce drastically, and hence the no. of sysadmin positions.

As of now the Clouds were deployed to replace the Server infrastructure with windows / linux on X86 model, but not yet having solutions for Vendor Specific Server OS like Solaris on Sparc, IBM AIX and HP UX …etc. Considering the speed of evolution in cloud computing technologies, it may not take long time to provide solutions for all kinds of server infrastructure. From the other side, if the Organisation choose to migrate their applications to X86 model servers to receive the benefits of economic cloud computing then the change is more rapid.

Below pictures will give you an understanding how the roles are moving out of Infra Teams depending on the Cloud solution adapted by the organisation.
Job Role movement with IAAS Cloud Computing Solution






Job Role movement with PAAS Cloud Computing Solution






Job Role movement with PAAS Cloud Computing Solution




Final and one more story, i want to tell you, before closing this post.

As most of you already aware, India is an agricultural based society where people treat their land like “mother that feeds you everyday ” and cows like “part of family wealth”. A decade before, most of the families used to follow the traditional way of cultivation that requires more number people and long working hours . And this requirement for the human labor is the main source for the jobs , in villages, for longtime

With technology innovations in India, there were many new tools/machines had been introduced to the indian agricultural industry which in turn reduced the requirement for the human labor. During this technology change, many people back at villages worried about their livelihood for sometime. But, the worry didn’t last longtime because most of them quickly adapted the skills related to these new technologies like “regular maintenance of these new tools” , “using the tools for better productivity” and “finding new lands to cultivate using these new machines with low cost” etc., and started living better than earlier.

And I believe, same story applies for any other industry including IT. And whenever we notice an inevitable change in our way, it is always wise to understand and get ready to accept it, instead of worrying about and trying to resist it.



Note: All the opinions mentioned here are purely personal, please feel to drop your comments/inputs related to the title of this post.

Friday, 16 September 2011

Investigate a SCSI disk error from Linux


Investigate a SCSI disk error from Linux


Collect the following information when a platform reports SCSI disk errors:
The following files:
/var/log/messages*



The output from the following commands:
/sbin/fdisk -l
/bin/cat /proc/scsi/scsi
/bin/dmesg






Once you have collected the data, review the output for any similarities in the errors. If the error always reports the same target, then consider replacing the device itself.
If the errors change to different targets on the same bus, then further troubleshooting is required. In the following references, the id is the target number of the device.

Here are examples of the output you will see when the scsi disks have errors from Red Hat Linux.

Notice in this example, we can see that the channel is 0, id is 1 and lun is 0. Each line of the error refers to the same id. We can also see that the disk is getting errors on different sectors. In this case, id 1 is target 1. This would indicate that target 1 is getting the errors and is the suspect fru.

/var/log/messages

Dec 20 10:33:23 localhost kernel: SCSI disk error : host 0 channel 0 id 1 lun 0 return code = 27010000
Dec 20 10:33:23 localhost kernel: I/O error: dev 08:03, sector 0
Dec 20 10:33:23 localhost kernel: SCSI disk error : host 0 channel 0 id 1 lun 0 return code = 27010000
Dec 20 10:33:23 localhost kernel: I/O error: dev 08:03, sector 13631520
Dec 20 10:33:23 localhost kernel: EXT3-fs error (device sd(8,3)): ext3_get_inode_loc: unable to read inode block – inode=852064, block=1703940
Dec 20 10:33:23 localhost kernel: SCSI disk error : host 0 channel 0 id 1 lun 0 return code = 27010000
Dec 20 10:33:23 localhost kernel: I/O error: dev 08:03, sector 0
Dec 20 10:33:23 localhost kernel: EXT3-fs error (device sd(8,3)) in ext3_reserve_inode_write: IO failure
Dec 20 10:33:24 localhost kernel: SCSI disk error : host 0 channel 0 id 1 lun 0 return code = 27010000
Dec 20 10:33:24 localhost kernel: I/O error: dev 08:03, sector 0
Dec 20 10:33:24 localhost kernel: SCSI disk error : host 0 channel 0 id 1 lun 0 return code = 27010000
Dec 20 10:33:24 localhost kernel: I/O error: dev 08:03, sector 13631520
Dec 20 10:33:24 localhost kernel: EXT3-fs error (device sd(8,3)): ext3_get_inode_loc: unable to read inode block – inode=852064, block=1703940
Dec 20 10:33:24 localhost kernel: SCSI disk error : host 0 channel 0 id 1 lun 0 return code = 27010000
Dec 20 10:33:24 localhost kernel: I/O error: dev 08:03, sector 0
Dec 20 10:33:24 localhost kernel: EXT3-fs error (device sd(8,3)) in ext3_reserve_inode_write: IO failure
Dec 20 10:33:24 localhost kernel: SCSI disk error : host 0 channel 0 id 1 lun 0 return code = 27010000
Dec 20 10:33:24 localhost kernel: I/O error: dev 08:03, sector 0

Notice in the following example We see that the errors also report the same channel 0, id 1, and lun 0 each time. We can also note scsi bus timeouts along with scsi check condition messages for the same device. In this case, target 1 is the suspect fru.

Another example of /var/log/messages

Sep 21 23:35:41 localhost kernel: klogd 1.4.1, log source = /proc/kmsg started.
Sep 21 23:35:41 localhost kernel: Inspecting /boot/System.map-2.4.18-17.7.x.4smp
Sep 21 23:35:41 localhost kernel: Loaded 17857 symbols from /boot/System.map-2.4.18-17.7.x.4smp.
Sep 21 23:35:41 localhost kernel: Symbols match kernel version 2.4.18.
Sep 21 23:35:41 localhost kernel: Loaded 256 symbols from 11 modules.
Sep 21 23:35:41 localhost kernel: SCSI disk error : host 0 channel 0 id 1 lun 0
return code = 27010000
Sep 21 23:35:41 localhost kernel: I/O error: dev 08:17, sector 66453508
Sep 21 23:35:41 localhost kernel: SCSI disk error : host 0 channel 0 id 1 lun 0
return code = 27010000
:
:
Sep 21 23:35:49 localhost kernel: scsi :”’ aborting command due to timeout : pid
43891492, scsi0, channel 0, id 1, lun 0 Write (10) 00 00 4b ae 5b 00 00 02 00”’
Sep 21 23:35:49 localhost kernel: mptscsih: OldAbort scheduling ABORT SCSI IO
(sc=c2db7200)
Sep 21 23:35:49 localhost kernel: IOs outstanding = 5
Sep 21 23:35:49 localhost kernel: scsi : aborting command due to timeout : pid
43891493, scsi0, channel 0, id 1, lun 0 Write (10) 00 00 43 2e 5d 00 00 02 00
:
:
Sep 21 23:35:49 localhost kernel: mptscsih: ioc0: Issue of TaskMgmt Successful!
Sep 21 23:35:49 localhost kernel: SCSI host 0 abort (pid 43891492) timed out – resetting
Sep 21 23:35:49 localhost kernel: SCSI bus is being reset for host 0 channel 0.
Sep 21 23:35:50 localhost kernel: mptscsih: OldReset scheduling BUS_RESET (sc=c2db7200)
Sep 21 23:35:50 localhost kernel: IOs outstanding = 6
Sep 21 23:35:50 localhost kernel: SCSI host 0 abort (pid 43891493) timed out – resetting
:
:
Sep 21 23:35:51 localhost kernel: SCSI host 0 reset (pid 43891492) timed out again -
Sep 21 23:35:51 localhost kernel: probably an unrecoverable SCSI bus or device hang.
Sep 21 23:35:51 localhost kernel: SCSI host 0 reset (pid 43891493) timed out again -
Sep 21 23:35:51 localhost kernel: SCSI Error Report =-=-= (0:0:0)
Sep 21 23:35:51 localhost kernel: SCSI_Status=02h (CHECK CONDITION)
Sep 21 23:35:51 localhost kernel: Original_CDB[]: 28 00 02 B1 4E 62 00 00 04 00
Sep 21 23:35:51 localhost kernel: SenseData[12h]: 70 00 06 00 00 00 00 0A 00 00 00 00 29 02 02 00 00 00
Sep 21 23:35:51 localhost kernel: SenseKey=6h (UNIT ATTENTION); FRU=02h
Sep 21 23:35:51 localhost kernel: ASC/ASCQ=29h/02h “SCSI BUS RESET OCCURRED”
Sep 21 23:35:51 localhost kernel: SCSI Error Report =-=-= (0:1:0)
Sep 21 23:35:51 localhost kernel: SCSI_Status=02h (CHECK CONDITION)
Sep 21 23:35:51 localhost kernel: Original_CDB[]: 2A 00 00 45 EE 5F 00 00 02 00
Sep 21 23:35:51 localhost kernel: SenseData[12h]: 70 00 06 00 00 00 00 0A 00 00 00 00 29 02 02 00 00 00
Sep 21 23:35:51 localhost kernel: SenseKey=6h (UNIT ATTENTION); FRU=02h
Sep 21 23:35:51 localhost kernel: ASC/ASCQ=29h/02h “SCSI BUS RESET OCCURRED”
Sep 21 23:35:51 localhost kernel: md3: no spare disk to reconstruct array! — continuing in degraded mode
Sep 21 23:35:51 localhost kernel: md: updating md2 RAID superblock on device
Sep 21 23:35:52 localhost kernel: md: (skipping faulty sdb5 )
Sep 21 23:35:52 localhost kernel: md: sda5 [events: 00000012]<6>(write) sda5′s sb offset: 4192832
Sep 21 23:35:52 localhost kernel: raid1: sda7: redirecting sector 30736424 to another mirror

In the following example, we see write errors on channel 0, id 0, lun 0 along with a medium error indicating an issue with the device itself. In this example, target 0 is the suspect part.

/var/log/messages

scsi0: ERROR on channel 0, id 0, lun 0, CDB: Write (10) 00 06 1d 3a 0d 00 00 08 00
Info fld=0x61d3a0d, Deferred sd08:02: sense key Medium Error
Additional sense indicates Write error
I/O error: dev 08:02, sector 102498376
SCSI Error: (0:0:0) Status=02h (CHECK CONDITION)
Key=3h (MEDIUM ERROR); FRU=0Ch
ASC/ASCQ=0Ch/02h “”
CDB: 2A 00 07 F9 3A 2D 00 00 08 00

scsi0: ERROR on channel 0, id 0, lun 0, CDB: Write (10) 00 07 f9 3a 2d 00 00 08 00
Info fld=0x8153a0d, Deferred sd08:02: sense key Medium Error
Additional sense indicates Write error – auto reallocation failed I/O error: dev 08:02, sector 133693544

Here is an example of the output you would see from cat /proc/scsi/scsi. This will give you a model number of the drive which could help with determining a part number and disk ID. Output will deviate depending on platform model and configuration:

Attached devices:
cat /proc/scsi/scsi

Host: scsi0 Channel: 00 Id: 00 Lun: 00
Vendor: SEAGATE Model: ST373307LC Rev: 0007
Type: Direct-Access ANSI SCSI revision: 03
Host: scsi0 Channel: 00 Id: 01 Lun: 00
Vendor: SEAGATE Model: ST373307LC Rev: 0007
Type: Direct-Access

Here’s an example of what you might see with dmesg. In the example shown, we can see that there is an issue with channel 0, id 1 and lun 0. This example needs more data to determine the failure. However, one may suspect that the disk needs to be replaced as it shows an i/o error 2 times on the same disk.

Sector 3228343
scsi0 (1:0): rejecting I/O to offline device
RAID1 conf printout:
— wd:1 rd:2
disk 0, wo:0, o:1, dev:sda1
disk 1, wo:1, o:0, dev:sdb1
RAID1 conf printout:
— wd:1 rd:2
disk 0, wo:0, o:1, dev:sda1
scsi0 (1:0): rejecting I/O to offline device
md: write_disk_sb failed for device sdb2
md: errors occurred during superblock update, repeating scsi0 (1:0): rejecting I/O to offline device

RHEL 5 : Crash Dump capturing for Red Hat Linux


RHEL 5 : Crash Dump capturing for Red Hat Linux


There are numerous occasions when a crash dump can be a valuable source of information when troubleshooting a system. The most common times are a system hang or a system panic.

Under Solaris[TM] on both SPARC(R) and x86 platforms, the mechanisms for getting a crash dump in these situations are well understood. Under Linux (specifically Red Hat) this situation is less clear.

This post explains about hot to get a crash dump from Red Hat linux to aid in troubleshooting system hangs after the operating system has been loaded. It covers which versions of RHEL are required, and the differences between 32bit and 64bit support.

RHEL crash dump Utilities:

The two main options for getting a crash dump (all pages in memory dumped to a file) under RHEL are netdump and diskdump.


Netdump – Supplied in RHEL 3 U1 and later – If you are on update 1 please see RHSA-2004:017-06 from Red Hat, this will allow 64 bit os dump as well – This will dump a vmcore file containing the entire contents of memory, over the network to a dedicated netdump-server. It will also dump a thread list and register info over the network to a log file. Kernel oops information will be dumped as well.

This allows for a central netdump-server, that can receive dumps and logs from multiple systems on a network and multiple architectures. This machine can be provisioned with large amounts of disk space and allows for central maintinance.

Secuity between the client and server is catered for.

There is a bug regarding netdump working across subnets (https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=90803). Currently the server and client need to be on the same subnet. Scheduled for fix in RHEL3 U5 and RHEL4 U1.

Netdump-server is on cd1 of RHEL3 and will need to be installed manually (rpm install)

Netdump client and the kernel modules are installed by default.







Diskdump – Supplied in RHEL3 U3 and later – This is more familiar to Solaris users, and is closer to the savecore facility in solaris. A dedicated partition is formatted to receive disk dumps. When the system panics, it will write a memory image to this partition. When the system comes back up, this partition will be checked and if it contains a valid dump image, this will be written back out to /var/crash (or another location) on the system. After this has completed, the dump partiton will be reformatted (which can take a while) ready to take another crash dump.

Diskdump is supplied with RHEL3 U3 or later on both 32bit and 64bit

Both the above methods supply a vmcore image, and a textual stack dump. They do not provide a namelist or symbol table. To analyze the resultant dump image, a kernel needs to be built with debug flags set, that is matched to the kernel the customer will be running. As most RHEL installs will use the default kernel, this isn’t as tricky as might be expected.

The contents of /boot on the customer system should be tar’d up, as it can contain useful system maps for assistance in performing a Red Hat Linux crash dump.

The crash analysis tool provided with Red Hat Linux ‘crash’ contains info in the manual page about what it requires. It can be run against a live kernel image as well.

Forcing Crash Dumps from Hung Linux systems

Setting up RHEL for crash dumps

The main method for forcing a crash dump from a hung Linux system is using the alt-sysrq-<key> combination. This is analogus to STOP-A (or L1-A) on a Sun SPARC system.

echo ?h? > /proc/sysrqtrigger will have the same effect as pressing alt-sysrq-h.

Enabling alt-sysrq key sequence

The alt-sysrq key sequence is disabled by default under RHEL. To enable it, edit /etc/sysctl.conf and set kernel.sysrq = 1

Netdump configuration

http://www.redhat.com/support/wpapers/redhat/netdump/

Netdump only works on i386, not x86_64 the netconsole.o kernel module is not supplied for x86_64. Even if you roll your own kernel, it will load, but not dump the memory image over the network in 64bit mode.

The server and client need to be on the same subnet.

On the server
chkconfig netdump-server on
service netdump-server start
create user netdump with password

On the client
Edit the file /etc/sysconfig/netdump and add a line like NETDUMPADDR=10.0.0.1
make sure the DEV= line reflects the ethernet adaptor that the server is accessible on (e.g. DEV=eth1)
chkconfig netdump on
service netdump propagate (will require netdump user/password on server)
service netdump start (make sure the module loads ok)

IF the server changes IP address or mac address, then all netdump client modules will need to be unloaded and reloaded.




netdump example outputCPU#0 is frozen. CPU#1 is executing netdump. CPU#2 is frozen. CPU#3 is frozen. < netdump activated - performing handshake with the client. > NETDUMP START! < handshake completed - listening for dump requests. > 0(79500)/


Diskdump configuration

Disk dump requires RHEL3 Update 3 or later. It works under 32bit and 64bit modes.

Create a new partition using fdisk.
NOTE: It MUST be bigger than the amount of physical memory in the system.

Swap partitions cannot be used for dump devices.

Format the newly created dump partition (a reboot may be required to reread the partition tables on the disk) with diskdumpfmt -f -p <device> (e.g. diskdumpfmt -f /dev/sdb2)

chkconfig diskdump on
service diskdump start

disk dump example outputCPU frozen: #0#1 CPU#1 is executing diskdump. start dumping
dumping memory...


and on the way back upINIT: Entering runlevel: 3 Entering non-interactive startup Saving panic dump: [ OK ] Formatting dump device: [ OK ] Starting diskdump: [ OK ]


RHEL : Examining Red Hat Linux kernel state using Sysrq key combinations


RHEL : Examining Red Hat Linux kernel state using Sysrq key combinations


The internal state of a kernel based on Unix can provide valuable information on current system state. If a user process, or the kernel, is hanging, then the more information that can be gathered at that point, the greater the chance of a good diagnosis.

Under Solaris ON THE SPARC platform there are well known mechanisms for gathering stack traces, processor states and memory states. Under Linux, this can appear to be more of a black art.

This document sets out to document the information that can be captured, hopefully as early as possible, to improve the chances of a good diagnosis.




Comparisons with Sun SPARC systems.

For a Sun system, the Stop-A key sequence (or send break from a serial console) will drop a system to the ok prompt. From this point, crash dumps can be forced, or register/cpu states can be examined.

Under Linux, this ability is integrated in the kernel, and triggered using alt-sysrq key sequences.

Enabling Sysrq.

The sysrq feature needs to be enabled before it can be used. It is disabled by default on RHEL 3 and 4.

To enable the feature, edit /etc/sysctl.conf and set the value below to equal 1# Controls the System Request debugging functionality of the kernel kernel.sysrq = 1


Forcing sysrq

On X4200/X4100 Servers, once connected to the SP console (start /SP/console from ILOM prompt), and then press Esc followed by shift+b to send break, and then press the key corresponding to the sysrq-command to send.

On V65x Servers, send a break to the console, and then press the key corresponding to the sysrq-command to send.

On V20z and V40z, once connected via the platform console, press ^Ecl0<letter> to send the sysrq-command.

On Blades (B100x, B200x) send a break from the SC console, then press the letter corresponding to the sysrq-command in the serial console session to the blade.

This letter keystroke needs to be performed within 5 seconds of the break being sent. A ? character will print the menu of available options.

List of current (Linux-2.4.21) valid key presses

SysRq : HELP : loglevel0-8 reBoot Crash tErm kIll saK showMem Off showPc unRaw Sync showTasks Unmount shoWcpus

Note: Although the above menu displays characters in upper-case as the key to selection and are shown below in square brackets. They should be entered as lower-case to the ‘sysrq’ command, as it does not accept upper-case characters and will display something similar to the above menu above if upper-case is sent.

The correct keypress is in the square brackets

reBoot ? [B] ? This will reboot the system

Crash ? [C] ? This will force panic the system, by defererencing a pointer then reading from that address.

If diskdump or netdump are configured (see Technical Instruction 210668) then a crash dump can be forced.


va64-v20zc-gmp02 login: [halt sent] SysRq : Crashing the kernel by request Unable to handle kernel NULL pointer dereference at virtual address 0000000000000000 printing rip: ffffffff801f66b0 PML4 8a1c7067 PGD 89f8e067 PMD 0 Oops: 0002 CPU 0 Pid: 0, comm: swapper Not tainted RIP: 0010:[<ffffffff801f66b0>]{sysrq_handle_crash+0} RSP: 0018:ffffffff805e6280 EFLAGS: 00010292 RAX: 000000000000001f RBX: ffffffff80445cd0 RCX: 0000000000000000 RDX: 0000000000000000 RSI: ffffffff80619f18 RDI: 0000000000000063 RBP: 0000000000000000 R08: 000000000000000d R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000001 R12: 0000000000000063 R13: 0000000000000000 R14: ffffffff80619f18 R15: 0000000000000006 FS: 0000002a969654c0(0000) GS:ffffffff805e1440(0000) knlGS:0000000000000000 CS: 0010 DS: 0018 ES: 0018 CR0: 000000008005003b CR2: 0000000000000000 CR3: 0000000000101000 CR4: 00000000000006e0
Call Trace: [<ffffffff801f6d12>]{__handle_sysrq_nolock+146} [<ffffffff801f6c48>]{handle_sysrq+72} [<ffffffff801eedd5>]{receive_chars+485} [<ffffffff801ef2b6>]{rs_interrupt_single+150} [<ffffffff8011317f>]{handle_IRQ_event+95} [<ffffffff80113422>]{do_IRQ+274} [<ffffffff8010de20>]{default_idle+0} [<ffffffff8010de20>]{default_idle+0} [<ffffffff80110807>]{common_interrupt+95} <EOI> [<ffffffff8011fb45>]{thread_return+0} [<ffffffff8010de3e>]{default_idle+30} [<ffffffff8010de20>]{default_idle+0} [<ffffffff8010dec9>]{cpu_idle+73}
<SNIP>
CPU frozen: #0#1 CPU#0 is executing diskdump. start dumping


tErm – [E] – Send Term (sig 15) to all processes except init

kIll – [I] – Send Kill (sig 9) to all processes except init

saK – [K] – Kill all processes on currently active virtual console. Should give a login prompt, that is secure (e.g. not a user process trying to look like a login prompt).

ShowMem ? [M] – This will dump the following information ? the system will continue running.


SysRq : Show Memory
Mem-info: Zone:DMA freepages: 0 min: 0 low: 0 high: 0 Zone:Normal freepages:358380 min: 1246 low: 8923 high: 12889 Zone:HighMem freepages: 0 min: 0 low: 0 high: 0 Zone:DMA freepages: 2529 min: 0 low: 0 high: 0 Zone:Normal freepages:382475 min: 1278 low: 9149 high: 13212 Zone:HighMem freepages: 0 min: 0 low: 0 high: 0 Free pages: 743384 ( 0 HighMem) ( Active: 28480/8679, inactive_laundry: 2665, inactive_clean: 0, free: 743384 ) aa:0 ac:0 id:0 il:0 ic:0 fr:0 aa:676 ac:12917 id:7391 il:2262 ic:0 fr:358381 aa:0 ac:0 id:0 il:0 ic:0 fr:0 aa:0 ac:0 id:0 il:0 ic:0 fr:2529 aa:1446 ac:13441 id:1288 il:403 ic:0 fr:382475 aa:0 ac:0 id:0 il:0 ic:0 fr:0 17981*4kB 51522*8kB 28603*16kB 10636*32kB 2040*64kB 123*128kB 2*256kB 1*512kB 0*1024kB 0*2048kB 1*4096kB = 1433524kB) Swap cache: add 0, delete 0, find 0/0, race 0+0 210925 pages of slabcache 82 pages of kernel stacks 123 lowmem pagetables, 115 highmem pagetables Free swap: 2040244kB 1032047 pages of RAM 746589 free pages 33834 reserved pages 27394 pages shared 0 pages swap cached Buffer memory: 74448kB Cache memory: 76640kB CLEAN: 3301 buffers, 13183 kbyte, 67 used (last=3301), 0 locked, 0 dirty 0 delay
Red Hat Enterprise Linux AS release 3 (Taroon Update 4) Kernel 2.4.21-27.ELsmp on an x86_64


Off – [O] – Turn the system off (if supported by hardware)

showPc ? [P] (example from i386 Xeon) – shows register state (program counter)SysRq : Show Regs
Pid/TGid: 0/0, comm: swapper EIP: 0060:[<c0109129>] CPU: 3 EIP is at default_idle [kernel] 0x29 (2.4.21-27.ELsmp) ESP: 080b:c01091c2 EFLAGS: 00000246 Not tainted EAX: 00000000 EBX: c0109100 ECX: c043c680 EDX: c4956000 ESI: c4956000 EDI: c4956000 EBP: c0109100 DS: 0068 ES: 0068 FS: 0000 GS: 0000 CR0: 8005003b CR2: b75f7000 CR3: 062e1f40 CR4: 000006f0 Call Trace: [<c01091c2>] cpu_idle [kernel] 0x42 (0xc4957fb0) [<c01295e3>] printk [kernel] 0x153 (0xc4957fcc)


showTasks ? [T] – shows all tasks running with stack traces

SysRq : Show Statefree sibling task PC stack pid father child younger older init S 00000002 2604 1 0 6 2 (NOTLB) Call Trace: [<c0123f14>] schedule [kernel] 0x2f4 (0xc61f1ea0) [<c0134f65>] schedule_timeout [kernel] 0x65 (0xc61f1ee4) [<c015910c>] __get_free_pages [kernel] 0x1c (0xc61f1eec) [<c0179071>] __pollwait [kernel] 0x31 (0xc61f1ef0) [<c0134ef0>] process_timeout [kernel] 0x0 (0xc61f1f04) [<c017933b>] do_select [kernel] 0x13b (0xc61f1f1c) [<c01797de>] sys_select [kernel] 0x34e (0xc61f1f60)
migration/0 S 00000000 5500 2 0 3 1 (L-TLB) Call Trace: [<c0123f14>] schedule [kernel] 0x2f4 (0xc4955f68) [<c01258f0>] migration_task [kernel] 0x0 (0xc4955f9c) [<c0125bfb>] migration_task [kernel] 0x30b (0xc4955fac) [<c01258f0>] migration_task [kernel] 0x0 (0xc4955fc4) [<c01258f0>] migration_task [kernel] 0x0 (0xc4955fe0) [<c01095ad>] kernel_thread_helper [kernel] 0x5 (0xc4955ff0)


<SNIP>

Contains full stack for every process on the system, and lists what each cpu is running

unRaw – [R] – Forces raw terminal mode

Sync – [S] – syncs all mounted file systems, flushes all pending writes

Unmount – [U] – Syncs, unmounts and then remounts all filesystems as read only.

shoWcpus ? [W] (example from dual proc, HT enabled Xeon)SysRq : Show CPUs CPU2: c63f5e74 00000002 c01cea1f 00000000 c03b2d34 00000077 00000006 c01cecaa 00000077 c63f5f7c 00000000 00000000 00000000 00000000 c63f5f7c c01cec0d 00000077 c63f5f7c 00000000 00000000 f66d6000 c03ad438 c63f5f1c f7ee1d80 Call Trace: [<c01cea1f>] sysrq_handle_showcpus [kernel] 0xf (0xc63f5e7c) [<c01cecaa>] __handle_sysrq_nolock [kernel] 0x7a (0xc63f5e90) [<c01cec0d>] handle_sysrq [kernel] 0x5d (0xc63f5eb0) [<c01c5f06>] receive_chars [kernel] 0x1d6 (0xc63f5ed4) [<c0134933>] update_process_time_intertick [kernel] 0x53 (0xc63f5ef0) [<c01c64ca>] rs_interrupt_single [kernel] 0x12a (0xc63f5f04) [<c010dd39>] handle_IRQ_event [kernel] 0x69 (0xc63f5f30) [<c010df79>] do_IRQ [kernel] 0xb9 (0xc63f5f50) [<c010dec0>] do_IRQ [kernel] 0x0 (0xc63f5f74) [<c0109100>] default_idle [kernel] 0x0 (0xc63f5f7c) [<c0109100>] default_idle [kernel] 0x0 (0xc63f5f90) [<c0109129>] default_idle [kernel] 0x29 (0xc63f5fa4) [<c01091c2>] cpu_idle [kernel] 0x42 (0xc63f5fb0) [<c01295e3>] printk [kernel] 0x153 (0xc63f5fcc)
CPU3: c4957f64 00000003 c011c91f 00000000 00001f7c c03f2caa c0109100 00000000 c4956000 c4956000 c4956000 c0109100 00000000 00000068 00000068 fffffffb c0109129 00000060 00000246 c01091c2 0702080b 00000000 00000000 00000000 Call Trace: [<c011c91f>] smp_call_function_interrupt [kernel] 0x2f (0xc4957f6c) [<c0109100>] default_idle [kernel] 0x0 (0xc4957f7c) [<c0109100>] default_idle [kernel] 0x0 (0xc4957f90) [<c0109129>] default_idle [kernel] 0x29 (0xc4957fa4) [<c01091c2>] cpu_idle [kernel] 0x42 (0xc4957fb0) [<c01295e3>] printk [kernel] 0x153 (0xc4957fcc)
CPU0: c03f1f88 00000000 c011c91f 00000000 00001fa0 c03f2caa c0109100 c043b280 c03f0000 c03f0000 c03f0000 c0109100 00000000 00000068 00000068 fffffffb c0109129 00000060 00000246 c01091c2 0002080b 00099800 c0107000 0008e000 Call Trace: [<c011c91f>] smp_call_function_interrupt [kernel] 0x2f (0xc03f1f90) [<c0109100>] default_idle [kernel] 0x0 (0xc03f1fa0) [<c0109100>] default_idle [kernel] 0x0 (0xc03f1fb4) [<c0109129>] default_idle [kernel] 0x29 (0xc03f1fc8) [<c01091c2>] cpu_idle [kernel] 0x42 (0xc03f1fd4) [<c0107000>] stext [kernel] 0x0 (0xc03f1fe0)
CPU1: c63f7f64 00000001 c011c91f 00000000 00001f7c c03f2caa c0109100 c043b280 c63f6000 c63f6000 c63f6000 c0109100 00000000 00000068 00000068 fffffffb c0109129 00000060 00000246 c01091c2 0102080b 00000000 00000000 00000000 Call Trace: [<c011c91f>] smp_call_function_interrupt [kernel] 0x2f (0xc63f7f6c) [<c0109100>] default_idle [kernel] 0x0 (0xc63f7f7c) [<c0109100>] default_idle [kernel] 0x0 (0xc63f7f90) [<c0109129>] default_idle [kernel] 0x29 (0xc63f7fa4) [<c01091c2>] cpu_idle [kernel] 0x42 (0xc63f7fb0) [<c01292b3>] call_console_drivers [kernel] 0x63 (0xc63f7fc4) [<c01295e3>] printk [kernel] 0x153 (0xc63f7ffc)


Twitter Bird Gadget