home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.sys.apollo
- Path: sparky!uunet!mcsun!sun4nl!relay.philips.nl!cazander
- From: cazander%serigate@phcoms.seri.philips.nl (Koos Cazander)
- Subject: Re: Apollo program to give System Type?
- Message-ID: <1993Jan11.105915.2426@phcomgw.seri.philips.nl>
- Originator: news@phcoms.seri.philips.nl
- Sender: news@phcomgw.seri.philips.nl
- Organization: SERI-CEN Network Services, Philips C&P, Eindhoven, The Netherlands
- X-Newsreader: TIN [version 1.1 PL8]
- References: <BRI.93Jan8113408@pegasus.mit.edu>
- Distribution: comp
- Date: Mon, 11 Jan 1993 10:59:15 GMT
- Lines: 41
-
- Brian D. Carlstrom (bri@athena.mit.edu) wrote:
- : is there a program i can run on the apollo that will return
- : a short answer system type such as just 'apollo' or even
- : 'sau7' or 'sau8'? sorta like machtype or hosttype or
- : arch on the sun.
-
- : -bri
-
- We use something like the script below, to detemine the machine type:
-
- --
- #!/bin/sh
- # Determine the machine type and architecture.
-
- if [ -d '`node_data' ]; then # Apollo
- echo apollo.${ISP=m68k}
- exit 0
- fi
- if [ -f /bin/arch ]; then # Sun
- echo `/bin/arch | sed -e s/Sun/sun/`
- exit 0
- fi
- if [ -f /bin/uname ]; then # Others
- sysname=`/bin/uname -m`
- case $sysname in
- 9000/[678]*) echo hp.pa;;
- 9000/[34]*) echo hp.m68k;;
- *) echo $sysname;;
- esac
- exit 0
- fi
- echo Unknown
- exit 1
- --
- ----------------------------------------------------------------------
- -- If you want to send EMAIL, include a subject line in the header: --
- -- 'Subject: <cazander:pasichva>' (without the quotes :-) --
- -- and send it to 'serigate@phcoms.seri.philips.nl'. --
- ----------------------------------------------------------------------
- -- J. Cazander, Philips Electronic Design & Tools, The Netherlands. --
- ----------------------------------------------------------------------
-