[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Script to build system information. Guru needed :)



On Thu, Dec 23, 2004 at 09:00:03AM -0500, Wayne Topa wrote:
> Chris Lale(chrislale@untrammelled.co.uk) is reported to have said:
> > Paul E Condon wrote:
> > >On Wed, Dec 22, 2004 at 05:36:17PM -0600, Ron Johnson wrote:
> > >
> > >>On Wed, 2004-12-22 at 14:13 -0800, Karsten M. Self wrote:
> > >>
> > >>>on Tue, Dec 21, 2004 at 04:25:57PM -0600, J.A. de Vries (hdv@jadev.org) 
> > >>>wrote:
> > >>>
> > >>>>On 2004-12-21 @ 18:30:35 (week 52) Bob Alexander wrote:
> > >>>>
> > >>
> > >>[snip]
> > >>
> > >>>>Search Google for a script called system-info by Karsten M. Self. He
> > >>>>posted it a long time ago, but it still is very useful. Start from there
> > >>>>and add the things you want to have that are not already done by it.
> > >>>
> > >>>   http://twiki.iwethey.org/twiki/Main/LinuxSystemInfoScript
> > >>
> > >>Not Found
> > >>The requested URL /twiki/Main/LinuxSystemInfoScript was not found on
> > >>this server.
> > >>
> > >
> > >
> > >I've been lurking on this thread. When I saw mention of Karten's 
> > >system-info
> > >script I googled it and downloaded it without any problem. Your problem is
> > >probably temporary. Maybe, try again.
> > >
> > 
> > Try (thanks to Google)
> > http://twiki.iwethey.org/twiki/bin/view/Main/LinuxSystemInfoScript
> > 
> Resolving twiki.iwethey.org... failed: Host not found.
> 

I do not have a record of the hotlink that I used to get Karsten's script,
but I'm pretty sure it was, as above, twiki.iwethey.org. This site is, indeed,
not available now. (I just tried.) Karsten has been posting to this list
recently. Maybe he will notice this thread and update us on what is happening.

In the mean time, I've included what I got from his site before it went down.
I warn all of you, especially the innocent newbies: 
DO NOT RUN THIS SCRIPT UNLESS YOU HAVE READ AND UNDERSTAND EVERY LINE OF CODE!!!!
I am not sending it over a secure link. I have run it. It needs minor update
to conform with the latest Debian policy, which appears to place lspci in /bin
Otherwise, I see nothing wrong with it, BUT I AM NOT AN EXPERT.
---------------start of stuff from Karsten's site -------------------
#!/bin/bash

# Generate a summary of system information.

PATH=/bin:/usr/bin:/sbin:/usr/sbin

function tabout () { fold -w 70 | sed -e '/^/s//	/'; }
function spaceout () { fold -w 70 | sed -e '/^/s//    /'; }

# init sudo:
sudo -v

cat <<EOF

			System Configuration Summary
			----------------------------

Date:  $( date )
User:  $USER: $( grep karsten /etc/passwd | cut -f 5 -d ':' | cut -f 1 -d , )

Hostname: $( hostname )
$( uname -a | tabout )

Uptime: $( uptime )

$( basename $0 ) version: 1.7, 2002/04/05 20:10:44

========================================================================

Basic Hardware:
------------------------------------

  cpu:
  --------------------
    $( echo; cat /proc/cpuinfo | tabout )

  memory:
  --------------------
    $( echo; cat /proc/meminfo | tabout )

  PCI:
  --------------------
    $( echo; /sbin/lspci | tabout )



Networking:
------------------------------------

  ifconfig:
  --------------------
    $( echo; ifconfig | spaceout )

  route:
  --------------------
    $( echo; route -n | spaceout )

  arp:
  --------------------
    $( echo; arp | spaceout )


Disk:
------------------------------------

  Partitioning:
  --------------------
    $( echo; sudo /sbin/fdisk -l /dev/[hs]d[a-z] | tabout )

  Mount table:
  --------------------
    $( echo; cat /etc/fstab | spaceout )

  Mounted partitions:
  --------------------
    $( echo; cat /proc/mounts | tabout )

  Free space:
  --------------------
    $( echo; df | tabout ; echo; df -h | tabout )



System resources:
------------------------------------

  IO:
  --------------------
    $( echo; cat /proc/ioports | tabout )

  IRQs:
  --------------------
    $( echo; cat /proc/interrupts | tabout )

  Devices:
  --------------------
    $( echo; cat /proc/devices | tabout )

  filesystems:
  --------------------
    $( echo; cat /proc/filesystems | tabout )

  USB devices:
  --------------------
    $( echo; cat /proc/bus/usb/devices | tabout )


Kernel resources:
------------------------------------

  Version: $( cat /proc/version )

  Modules:
  --------------------
    $( echo; cat /proc/modules | tabout )


  Boot Parameters (/proc/cmdline)
  --------------------
   $( echo; cat /proc/cmdline | tabout )


  Boot Kernel Messages (dmesg):
  --------------------
   $( echo; cat /var/log/dmesg | tabout )


  Configuration:
  --------------------
    $( echo; cat /boot/config-$( awk '{ print $3 }' /proc/version ) | tabout)
  

------------------------------------------------------------------------
This is an automatically created summary.
The command is "$( basename $0 )".
Written by Karsten M. Self <kmself@ix.netcom.com>, (c) 2002.

This program may be freely distributed and modified, with attribution
and the following disclaimer.
This program comes with NO WARRANTY and NO LIABILITY FOR DAMAGES.

Revision information:
    Author: karsten
    Version: 1.7
    Last revised: 2002/04/05 20:10:44
EOF
-----------------------------------end of Karsten's work ----------------



-- 
Paul E Condon           
pecondon@mesanetworks.net



Reply to: