Note: This is a beta release of Red Hat Bugzilla 5.0. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Also email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback here.
Bug 7137 - grep -cl for number of processors in /etc/rc.d/rc.local
Summary: grep -cl for number of processors in /etc/rc.d/rc.local
Alias: None
Product: Red Hat Linux
Classification: Retired
Component: initscripts
Version: 6.1
Hardware: All
OS: Linux
Target Milestone: ---
Assignee: Bill Nottingham
QA Contact:
Depends On:
TreeView+ depends on / blocked
Reported: 1999-11-19 11:18 UTC by Hans Ginzel
Modified: 2014-03-17 02:11 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Last Closed: 1999-11-19 15:41:50 UTC

Attachments (Terms of Use)

Description Hans Ginzel 1999-11-19 11:18:09 UTC
There is
              NUMPROC=`grep -cl "^cpu[0-9]+" /proc/stat`
in /etc/rc.d/rc.local,
but manual page of grep says:
     -l, --files-with-matches
              Suppress  normal  output; instead print the name of
              each input file from which  output  would  normally
              have  been  printed.  The scanning will stop on the
              first match.

So it will stop on the first ^cpu line and print also the filename
Why is there -l?

initscripts 4.48
grep (GNU grep) 2.3

Comment 1 Bill Nottingham 1999-11-19 15:41:59 UTC
This is fixed in the errata initscripts release. :)

Note You need to log in before you can comment on or make changes to this bug.