SysInfo: a set of scripts that document your system

Code:
CPU information

Machine class:  i386
CPU Model:      Intel(R) Pentium(R) 4 CPU 3.00GHz
No. of Cores:   2
Cores per CPU:

WARNING: Your CPU supports amd64 architecture, however you are running i386.
WARNING: You may want to switch to amd64 to get a better performance.

Warnings are wrong.... [i ran this script on target pc using ssh]
laptop that i'm using atm (i'm not at home) is in fact amd64

P4 doesn't support AMD64, i bought that computer when 64bit for desktop wasn't around yet


also: does amd64 in 64bit mode run faster than in 32bin mode??????? I'm not sure, i did some research few years ago, and that time it was false.
 
can you please paste the output of # sysinfo -v cpu please? thanks.
 
output of
$ sysinfo -v -c cpu
Code:
CPU information

Machine class:  i386
CPU Model:  Intel(R) Pentium(R) 4 CPU 3.00GHz
No. of Cores:   2
Cores per CPU:


CPU Features:
Features=0xbfebfbff<FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CLFLUSH,DTS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE>
Features2=0x441d<SSE3,DTES64,MON,DS_CPL,CNXT-ID,xTPR>

Interrupt statistics:
interrupt                          total       rate
irq1: atkbd0                           2          0
irq14: ata0                        85824          1
irq15: ata1                          101          0
irq16: uhci0 uhci3                     3          0
irq17: pcm0                          522          0
irq18: rl0 uhci2+               71669446       1125
irq23: ehci0                           1          0
cpu0: timer                    123139964       1934
cpu1: timer                    123139668       1934
Total                          318035531       4995

CPU usage statistics:
CPU:  2.8% user,  0.0% nice,  9.0% system,  4.7% interrupt, 83.5% idle

Number of processor slots on main board: 1
Voltage: 1.3 V
External Clock: 204 MHz
Max Speed: 4000 MHz
Current Speed: 3060 MHz
Upgrade: ZIF Socket

INFO: Run `dmidecode -t processor` to see further information.

perhaps it's because of DTES64


warnings are not included in stdout (they are probably directed to stderr)


P.S.
Max Speed: 4000 MHz
Didn't knew that
Max i have tried was something about 3.45 then it shutdown :D
I was using abit software


EDIT
I've attached full output
 
Can you test with the attached patch applied?
 

Attachments

  • sysinfo.diff
    878 bytes · Views: 294
danger@ said:
Can you test with the attached patch applied?

ok just tell me hot to apply patch (i've never done that :( )


Ok, patched it (hopefully right)
Code:
CPU information

Machine class:  i386
CPU Model:      Intel(R) Pentium(R) 4 CPU 3.00GHz
No. of Cores:   2
Cores per CPU:

WARNING: Your CPU supports amd64 architecture, however you are running i386.
WARNING: You may want to switch to amd64 to get a better performance.

CPU usage statistics:
CPU:  0.9% user,  0.0% nice,  3.2% system,  1.9% interrupt, 94.0% idle

Code:
SysInfo v0.8.2 by Daniel Gerzo for FreeBSD Operating System

EDIT:

modules/cpu wan't pached for some reason
I manually removed !
at line 26 and everything is fine now

Code:
CPU information

Machine class:  i386
CPU Model:      Intel(R) Pentium(R) 4 CPU 3.00GHz
No. of Cores:   2
Cores per CPU:

CPU usage statistics:
CPU:  2.8% user,  0.0% nice,  1.9% system,  3.4% interrupt, 91.9% idle
 
you sure it applied correctly to modules/cpu? :) it should contain the following code now:

Code:
        # Check whether our CPU supports amd64 and if so, tell user about
        # it when it is not yet used
        if [ "$arch" != "amd64" ] &&
                ( grep -qE 'AMD Features.*LM.*' $DMESG ); then
                        echo
                        warn "Your CPU supports amd64 architecture, however you are running $arch."
                        warn "You may want to switch to amd64 to get a better performance."
        fi

BTW I am a bit confused now, because in the output of -a which you have attached in your previous post, there isn't that warning, hm?
 
danger@ said:
you sure it applied correctly to modules/cpu? :) it should contain the following code now:

Code:
        # Check whether our CPU supports amd64 and if so, tell user about
        # it when it is not yet used
        if [ "$arch" != "amd64" ] &&
                ( grep -qE 'AMD Features.*LM.*' $DMESG ); then
                        echo
                        warn "Your CPU supports amd64 architecture, however you are running $arch."
                        warn "You may want to switch to amd64 to get a better performance."
        fi
I'm not sure
plz, tell me what to execute to patch correctly


danger@ said:
BTW I am a bit confused now, because in the output of -a which you have attached in your previous post, there isn't that warning, hm?

warnings are redirected to /dev/stderr what i posted is output of sysinfo -c -a, but i redirected output to file, because i'm doing this with ssh (because i did redirection to file, stderr and stdout were separated, 1 to screen the other one to file).

i suggest that you use echo for warnings as well
 
ok i did
patch < sysinfo.diff
in sysinfo dir

checked, seams now patching was ok
the output seams also ok

Code:
CPU information

Machine class:  i386
CPU Model:      Intel(R) Pentium(R) 4 CPU 3.00GHz
No. of Cores:   2
Cores per CPU:

CPU usage statistics:
CPU:  1.3% user,  0.0% nice,  0.9% system,  1.3% interrupt, 96.4% idle

output copied directly from screen
 
Good to hear that, thanks for verifying. I have also uploaded the full package for 0.8.2 now.
 
sysinfo-0.8.2 tested on FreeBSD 7.1-amd64, 7.1-i386, 7.0-i386 and 6.2-i386.

Code:
RAM information

System memory information
Maximum Capacity: 16 GB
Number Of Devices: 8

could add the number of installed modules (or even the size of each one).

Code:
Basic configuration for currently available NICs:

lo0:
IPv4 addresses:
127.0.0.1 netmask 0xff000000
IPv6 addresses:
::1 prefixlen 128
fe80::1%lo0 prefixlen 64

Input errors: 55624005647
Output errors: 55624323881
Collisions:

Ipkts and Opkts are reported for localhost instead of Ierrs and Oerrs.

Code:
Default route:
147.102.222.200 via em0
fe80::208:7cff:fe63:e400%em0 via

Interface for IPv6 default route is missing. See "netstat -rn" IPv6 output in case you do not have an IPv6 ready box:

Code:
Internet6:
Destination     Gateway                       Flags      Netif Expire
::/96           ::1                           UGRS        lo0 =>
default         fe80::208:7cff:fe63:e400%em0  UGS         em0

Also:

Code:
modules/network:
# TCP Wrappers - they are only useful when inetd is enabled

Not true. A lot of non inetd services use tcp wrappers. See sshd, sendmail, snmpd, mysqld, slapd, bacula, smbd, imapd etc.
 
christias said:
Also:

Code:
modules/network:
# TCP Wrappers - they are only useful when inetd is enabled

Not true. A lot of non inetd services use tcp wrappers. See sshd, sendmail, snmpd, mysqld, slapd, bacula, smbd, imapd etc.

I have understood from http://www.freebsd.org/doc/en/books/handbook/tcpwrappers.html that you need inetd in order to make use of TCP Wrappers. Is Handbook correct or needs fixing?

As of the other stuff in your message - I will look at it tommorrow now it's time to get some sleep :)
 
Code:
Running services

cron is running as pid 540.
devd is running as pid 353.
inetd is running as pid 561.
sendmail_submit is running as pid 528.
sendmail_clientmqueue is running as pid 534.
sshd is running as pid 522.
syslogd is running as pid 400.

Not running services

uuidd is not running.
newsyslog is not running.
wpa_supplicant is not running.

Thank you !!!
And thanks a lot for having implemented some of Mel_Flynn ideas !!!
This is becoming a _must_have_ tool ! :D
Congratulations on an already Great Work!

PS: Just in case, i got that using sysinfo-8.0.2 on a 7.0 REL (my desktop =P) and a 7.1 REL (an internal server).
PS2: "Running services" seems to be sorted by service name but "Not running services" appears not to be sorted .. didn't have time to take a look at your code .. but maybe you forgot to pass a "sort" there .. or maybe sorting not running services wasn't your intention at all .. I don't know .. that just caught my attention and thought maybe you would like to know .. .

Once again .. thanks a lot for your really usefull work =)
 
Code:
Running services

cupsd is running as pid 756.
hpssd is running as pid 743.
cron is running as pid 845.
devd is running as pid 493.
sendmail_submit is running as pid 835.
sendmail_clientmqueue is running as pid 839.
sshd is running as pid 829.
syslogd is running as pid 624.

Not running services

apache is not running.
bsdstats is not running.
dbus is not running.
ffserver is not running.
hald is not running.
mdnsd is not running.
snmpd is not running.
snmptrapd is not running.
svnserve is not running.
tinderd is not running.
uuidd is not running.
xfs is not running.
newsyslog is not running.
wpa_supplicant is not running.

1st post is from my local server. This one is from my desktop (7.1 REL, 7.0 REL, respectively).

Yes ... it does:

Code:
[gonzalo@inferna ~]% grep newsyslog /etc/crontab
0       *       *       *       *       root    newsyslog
[gonzalo@inferna ~]%
 
Okay, I have removed the inetd_enable check and modified the message a bit, thanks.
 
gnemmi said:
Yes ... it does:

Code:
[gonzalo@inferna ~]% grep newsyslog /etc/crontab
0       *       *       *       *       root    newsyslog
[gonzalo@inferna ~]%

Thinking out loud, may be sysinfo should check only rc.d scripts that make use of *enable and/or *pidfile variables.
 
It does. However it has a rc script in /etc/rc.d, that's why it is being checked. I will disable it, however there may be other false-positives.
 
I have checked that now, and it seems like it does not work very well :(
 
Unfortunately that doesn't work either (for example rc.d/nfsd, ezjail, pure-ftpd) :(
 
@danger:

Just stumbled upon your sysinfo script. Pretty nice output with lots of information. Could be great for providing "background info" when asking for help on the forum to see where problems reside.

Keep up the good work and thank you sir.
 
Back
Top