Bug 868
| Summary: | /etc/rc.d/rc.local generates incorrect /etc/issue on SMP machines | ||
|---|---|---|---|
| Product: | [Retired] Red Hat Linux | Reporter: | David Woodhouse <dwmw2> |
| Component: | initscripts | Assignee: | David Lawrence <dkl> |
| Status: | CLOSED CURRENTRELEASE | QA Contact: | |
| Severity: | medium | Docs Contact: | |
| Priority: | medium | ||
| Version: | 5.2 | ||
| Target Milestone: | --- | ||
| Target Release: | --- | ||
| Hardware: | All | ||
| OS: | Linux | ||
| Whiteboard: | |||
| Fixed In Version: | Doc Type: | Bug Fix | |
| Doc Text: | Story Points: | --- | |
| Clone Of: | Environment: | ||
| Last Closed: | 1999-05-04 19:45:04 UTC | Type: | --- |
| Regression: | --- | Mount Type: | --- |
| Documentation: | --- | CRM: | |
| Verified Versions: | Category: | --- | |
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
| Cloudforms Team: | --- | Target Upstream Version: | |
| Embargoed: | |||
Thank you for the suggestion. It has been noted and will be considered for upcoming releases. This 'bug' still exists in 6.0, and can more realistically be called a bug now that SMP is officially supported. Even though it's only cosmetic, it's the first sign many people will see as to whether Linux is using more than one processor or not - and it gives the wrong impression. I expect that this will lead to much confusion as people wonder 'why is it only using one'. Even if the logic I gave isn't acceptable for some reason, consider changing the message to "Kernel `uname -r` on the `uname -a` architecture", to remove the implication that there's only one processor. Will be fixed in next initscripts release (4.17-1). It will say something along the lines of 'Kernel 2.2.6-14smp on a 4-processor i686' |
The rc.local script generates a line like "Kernel 2.2.0-pre5 on an i686", even on SMP machines which should read "Kernel 2.2.0-pre5 on a pair of i686s". Try something like: arch=$(uname -m) a="a" case "_$arch" in _a*) a="an";; _i*) a="an";; esac NUMPROC=$[`cat /proc/cpuinfo | grep ^processor | wc -l`] if [ "$NUMPROC" = "2" ]; then NUMPROC="a pair of"; fi if [ "$NUMPROC" = "1" ] then TAILBIT="$(uname -r) on $a $(uname -m)" else TAILBIT="$(uname -r) on $NUMPROC $(uname -m)s" fi # This will overwrite /etc/issue at every boot. So, make any changes you # want to make to /etc/issue here or you will lose them when you reboot. echo "" > /etc/issue.net echo "Red Hat Linux $R" >> /etc/issue.net echo "Kernel $TAILBIT" >> /etc/issue.net