summaryrefslogtreecommitdiff
path: root/log_environment
diff options
context:
space:
mode:
Diffstat (limited to 'log_environment')
-rwxr-xr-xlog_environment20
1 files changed, 9 insertions, 11 deletions
diff --git a/log_environment b/log_environment
index 724b9750..ee072043 100755
--- a/log_environment
+++ b/log_environment
@@ -109,19 +109,17 @@ sub report_machine {
if ($sysname eq 'Linux') {
report_linux_libc();
- }
- my ($npstat, @npout) = get_status_and_output('nproc');
- if ($npstat == 0) {
- chomp @npout;
- print '$(nproc) = ', $npout[0], "\n";
- } elsif ($npstat == -1) {
- print "nproc: command not found\n";
- } else {
- print "nproc: exit $npstat\n";
- for my $line (@npout) {
- print '> ', $line;
+ my $npstat = get_status('nproc');
+ if ($npstat != 0) {
+ print "nproc: exit $npstat\n";
}
+
+ } elsif ($sysname eq 'FreeBSD') {
+ run('sysctl', 'kern.sched.topology_spec');
+
+ } else {
+ print "WARNING: don't know how to probe #CPUs on this OS\n";
}
print "\n";