Search the FAQ Archives

3 - A - B - C - D - E - F - G - H - I - J - K - L - M
N - O - P - Q - R - S - T - U - V - W - X - Y - Z
faqs.org - Internet FAQ Archives

comp.unix.aix Frequently Asked Questions (Part 5 of 5)
Section - 8.04: How can I find out the machine type?

( Part1 - Part2 - Part3 - Part4 - Part5 - Single Page )
[ Usenet FAQs | Web FAQs | Documents | RFC Index | Sex offenders ]


Top Document: comp.unix.aix Frequently Asked Questions (Part 5 of 5)
Previous Document: 6.11: How can I access the comp.unix.aix newsgroup via email (or Web)?
Next Document: 8.05: Updating to 3.2.5
See reader questions & answers on this topic! - Help others by sharing your knowledge

[ formerly in section 1.126 ]

#!/bin/ksh
# Determine machine type
# Jim O'Quinn  2/28/93
# AIX Software Support
# This does not represent my employer, use at own risk.....
# Changed to report newer machines and unknown ids. /Fred
# More new machines. /David

MachType=`uname -m | cut -c9-10`
case $MachType
in
  02)  nMachType="7015/930";;
  10)  nMachType="7013/530 or 7016/720 or 7016/730";;
  11|14)  nMachType="7013/540";;
  18)  nMachType="7013/53H";;
  1C)  nMachType="7013/550";;
  20)  nMachType="7015/930";;
  2E)  nMachType="7015/950 or 7015/950E";;
  30)  nMachType="7013/520 or 7018/740 or 7018/741";;
  31)  nMachType="7012/320";;
  34)  nMachType="7013/52H";;
  35)  nMachType="7012/32H or 7012/320E";;
  37)  nMachType="7012/340 or 7012/34H";;
  38)  nMachType="7012/350";;
  41)  nMachType="7011/220 or 7011/22W or 7011/22G or 7011/230";;
  42)  nMachType="7006/41T or 7006/41W";;
  43)  nMachType="7008/M20";;
  45)  nMachType="7011/220 or 7011/M20 or 7011/230 or 7011/23W";;
  46)  nMachType="7011/250";;
  47)  nMachType="7011/230";;
  48)  nMachType="7009/C10";;
  49)  nMachType="7011/250";;
  4C)  nMachType="604/43P";;
  4D)  nMachType="601/40P";;
  57)  nMachType="7012/390 or 7012/3BT or 7030/3BT or 7032/3AT or 7011/390";;
  58)  nMachType="7012/380 or 7012/3AT or 7030/3BT";;
  59)  nMachType="3CT or 39H";;
  5C)  nMachType="7013/560";;
  63)  nMachType="7015/970 or 7015/97B";;
  64)  nMachType="7015/980 or 7015/98B";;
  66)  nMachType="7013/580 or 7013/58F or 7015/580";;
  67)  nMachType="7013/570 or 7013/770 or 7013/771 or 7013/R10 or 7015/570";;
  70)  nMachType="7013/590";;
  71)  nMachType="7013/58H";;
  72)  nMachType="7013/59H or 7013/R12 or 7013/58H";;
  75)  nMachType="7012/370 or 7012/375 or 7012/37T";;
  76)  nMachType="7012/360 or 7012/365 or 7012/36T";;
  77)  nMachType="7012/315 or 7012/350 or 7012/355 or 7012/510 or 7012/55H or 7012/55L";;
  78)  nMachType="7012/315 or 7013/510";;
  79)  nMachType="7013/590";;
  80)  nMachType="7015/990";;
  82)  nMachType="7015/R00 or 7015/R24";;
  90)  nMachType="IBM C20";;
  91)  nMachType="604/42T";;
  A0)  nMachType="7013/J30 or 7013/R30";;
  A3)  nMachType="7013/R30";;
  A6)  nMachType="7012/G30";;
  C4)  nMachType="F40";;
  E0)  nMachType="603/MOTOROLA PowerStack";;
  *)  nMachType="Unknown($MachType)"
esac
echo "Machine type: "$nMachType"

From: Jan Just Keijser <KeijserJJ@logica.com> 

I've attached a C program which determines the model and the amount of
memory installed in C code (by querying the ODM directly). It can be
compiled using
  cc -o model model.c -lcfg -lodm

#include <stdio.h>
#include <sys/utsname.h>
#include <unistd.h>

#include <string.h>
#include <cf.h>
#include <sys/cfgodm.h>
#include <sys/cfgdb.h>

void main (void)
{
  struct utsname	name;
  int			memsize;

  char         s[3];
  int          model;

  struct CuAt *odm_obj;
  int          how_many;

  uname(&name);

  printf( "sysname  = %s\n", name.sysname );
  printf( "nodename = %s\n", name.nodename );
  printf( "release  = %s\n", name.release );
  printf( "version  = %s\n", name.version );
  printf( "machine  = %s\n", name.machine );

  printf( "model    = " );
   /* On AIX, the model is encoded in the last 2 non-zero digits
      of the model code (uname -m)
   */
   s[0] = name.machine[ strlen( name.machine ) - 4 ];
   s[1] = name.machine[ strlen( name.machine ) - 3 ];
   s[2] = '\0';
   model = strtol(s, NULL, 16);
  
   switch (model)
   {
      case 0x10:  puts ( "Model 530/730" );
                  break;
      case 0x11:
      case 0x14:  puts ( "Model 540" );
                  break;
      case 0x18:  puts ( "Model 530H" );
                  break;
      case 0x1C:  puts ( "Model 550" );
                  break;
      case 0x20:  puts ( "Model 930" );
                  break;
      case 0x2E:  puts ( "Model 950/950E" );
                  break;
      case 0x30:  puts ( "Model 520 or 740/741" );
                  break;
      case 0x31:  puts ( "Model 320" );
                  break;
      case 0x34:  puts ( "Model 520H" );
                  break;
      case 0x35:  puts ( "Model 32H/320E" );
                  break;
      case 0x37:  puts ( "Model 340/34H" );
                  break;
      case 0x38:  puts ( "Model 350" );
                  break;
      case 0x41:  puts ( "Model 220/22W/22G/230" );
                  break;
      case 0x42:  puts ( "Model 41T/41W" );
                  break;
      case 0x43:  puts ( "Model M20" );
                  break;
      case 0x45:  puts ( "Model 220/M20/230/23W" );
                  break;
      case 0x46:
      case 0x49:  puts ( "Model 250" );
                  break;
      case 0x47:  puts ( "Model 230" );
                  break;
      case 0x48:  puts ( "Model C10" );
                  break;
      case 0x4C:  puts ( "PowerPC 603/604 model" );
                  break;
      case 0x4D:  puts ( "Model 40P" );
                  break;
      case 0x57:  puts ( "Model 390/3AT/3BT" );
                  break;
      case 0x58:  puts ( "Model 380/3AT/3BT" );
                  break;
      case 0x59:  puts ( "Model 39H/3CT" );
                  break;
      case 0x5C:  puts ( "Model 560" );
                  break;
      case 0x63:  puts ( "Model 970/97B" );
                  break;
      case 0x64:  puts ( "Model 980/98B" );
                  break;
      case 0x66:  puts ( "Model 580/58F" );
                  break;
      case 0x67:  puts ( "Model 570/770/R10" );
                  break;
      case 0x70:  puts ( "Model 590" );
                  break;
      case 0x71:  puts ( "Model 58H" );
                  break;
      case 0x72:  puts ( "Model 59H/58H/R12/R20" );
                  break;
      case 0x75:  puts ( "Model 370/375/37T" );
                  break;
      case 0x76:  puts ( "Model 360/365/36T" );
                  break;
      case 0x77:  puts ( "Model 315/350/355/510/550H/550L" );
                  break;
      case 0x79:  puts ( "Model 591" );
                  break;
      case 0x80:  puts ( "Model 990" );
                  break;
      case 0x81:  puts ( "Model R24" );
                  break;
      case 0x82:  puts ( "Model R00/R24" );
                  break;
      case 0x89:  puts ( "Model 595" );
                  break;
      case 0x90:  puts ( "Model C20" );
                  break;
      case 0x91:  puts ( "Model 42T" );
                  break;
      case 0x94:  puts ( "Model 397" );
                  break;
      case 0xA0:  puts ( "Model J30" );
                  break;
      case 0xA1:  puts ( "Model J40" );
                  break;
      case 0xA3:  puts ( "Model R30" );
                  break;
      case 0xA4:  puts ( "Model R40" );
                  break;
      case 0xA6:  puts ( "Model G30" );
                  break;
      case 0xA7:  puts ( "Model G40" );
                  break;
      case 0xC4:  puts ( "Model F30" );
                  break;
      default:    printf( "Model code: %s\n", s );
                  break;
   }

/* Get the amount of installed memory */
  odm_set_path("/etc/objrepos");
  /* Get a single ODM object */
  odm_obj = getattr("sys0", "realmem", 0, &how_many);
  memsize = atoi(odm_obj->value) / 1024;
  odm_terminate();
  printf( "Memory   = %d MB\n", memsize );

/* Print the number of processors */
  printf("#processor configured = %d\n", sysconf(_SC_NPROCESSORS_CONF));
  printf("#processor online     = %d\n", sysconf(_SC_NPROCESSORS_ONLN));

}

User Contributions:

But remnants' crop burning hits harvesting hard

This sunday, quite possibly 28, 2019 snapshot, Provided by the city service group, jointly for Jarniyah, contains been authenticated based on its contents and other AP reporting, Shows Syrians lifetime extinguish a fire in a field of crops, wearing Jaabar, Raqqa state, Syria. Thousands of acres of wheat and barley fields in both Syria and Iraq have been scorched by the fires within harvest season, that typically runs until mid June. "The life that we live here is already bitter, " stated Hussain Attiya, A farmer from Topzawa Kakayi in upper Iraq. "If the outcome continues like this, I would say that no one will continue to be here. I plant 500 to 600 acres on a yearly basis. still, I won't be able to do that because I can't stay here and guard the land day and night. "ISIS militants have a history of working with a "Scorched earth insurance coverage " In areas from that they can retreat or where they are defeated. Ahmed al Hashloum thoughts Inmaa, Arabic for benefits, A local civil group that supports farming. all it takes is a cigarette butt to set haystacks on fire, He brought up. Said the fires are threatening to disrupt normal food production cycles and potentially reduce food to protect months to come. The crop burning remains localized and can't be compared to pre war devastation, Beals considered that. "suffice to say, It is only the beginning of the summer and if the fires continue it could lead to a crisis, " Beals recounted,AlternativeHeadline,prepared crop burning blamed on ISIS remnants compounds misery in war torn Iraq and Syria"}

But good news is short lived in this part of the world, Where residents of the two countries struggle to face seemingly never ending violence and turmoil amid Syria's civil war and attacks by remnants of the Islamic State of Iraq and Syria (ISIS) social groups. of course, Even in locations where conflict has subsided, Fires currently raging in farmers' fields, depriving them of valuable crops.

The blazes have been blamed also consider on defeated ISIS militants seeking to avenge their losses, Or on Syrian regime forces battling to rout other armed groups. Thousands of acres of wheat and barley fields in both Syria and Iraq have been scorched by the fires within harvest season, what kind runs until mid June.

ISIS militants have a history of implementing a "Scorched earth guideline" In areas from which retreat or where they are defeated. this "A means of inflicting a collective punishment on those put aside, said Emma Beals, a completely independent Syria researcher.

ISIS militants claimed obligations for burning crops in their weekly newsletter, al Nabaa, Saying they targeted farms owned by senior officials in six Iraqi provinces and in Kurdish administered eastern Syria, sending the persistent threat from the group even after its territorial defeat.

ISIS said it burned the farms of "The apostates in Iraq together with the Levant" And required more.

"It seems that it'll be a hot summer that will burn the pockets of the apostates as well as their hearts as they burned the Muslims and their homes in the past years, this great article said.

countless acres of wheat fields around Kirkuk in northern Iraq were set on fire. Several wheat fields in the Daquq district in southern Kirkuk burned for three days straight yesterday.

In eastern Syria's Raqqa state, Farmers battled raging fires with items of cloth, bags and water trucks. Piles of hay burned and black smoke billowed above the job areas.

The Syrian Observatory for Human Rights said through 74,000 acres (30,000 hectares) linked farmland in Hassakeh, Raqqa and completely to Aleppo province to the west, Were scorched.

Activist Omar Abou Layla said local Kurdish led forces failed to react to the fires in the province of Deir el Zour, Where ISIS was uprooted from its last property in March, (...)

Comment about this article, ask questions, or add new information about this topic:




Top Document: comp.unix.aix Frequently Asked Questions (Part 5 of 5)
Previous Document: 6.11: How can I access the comp.unix.aix newsgroup via email (or Web)?
Next Document: 8.05: Updating to 3.2.5

Part1 - Part2 - Part3 - Part4 - Part5 - Single Page

[ Usenet FAQs | Web FAQs | Documents | RFC Index ]

Send corrections/additions to the FAQ Maintainer:
bofh@mail.teleweb.pt (Jose Pina Coelho)





Last Update March 27 2014 @ 02:11 PM