[comp.unix.aix] Q: Patching Binaries under AIX 1.1

ji@close.cs.columbia.edu (John Ioannidis) (01/05/90)

Does anyone have adb for AIX 1.1? I need to be able to patch things in
the running kernel, and also patch the unix executable, and the only
thing I know that can do both is adb (superzap was never ported to the
Unix world :-) ). Why oh why did the powers-that-be remove adb from the
distribution? 

/ji

In-Real-Life: John "Heldenprogrammer" Ioannidis
E-Mail-To: ji@cs.columbia.edu
V-Mail-To: +1 212 854 5510
P-Mail-To: 450 Computer Science \n Columbia University \n New York, NY 10027

jsw@xhead.SGI.COM (Jeff Weinstein) (01/05/90)

In article <6693@columbia.edu>, ji@close.cs.columbia.edu (John
Ioannidis) writes:
> Why oh why did the powers-that-be remove adb from the
> distribution? 

I believe that the reasoning went something like this:

	"why would anyone want to use adb when we have such a swell dbx?"

	"I can't think of any reason off the top of my head"

	"OK, lets just leave it out"

	"OK"

There is a version of adb for AIX PS/2 that does exist within
the development groups, but I suspect that it will never be
released.  Remember, users don't patch the kernel.  :-)

	--Jeff

Jeff Weinstein
Silicon Graphics, Inc., Entry Systems Division, Window Systems
jsw@xhead.esd.sgi.com
Any opinions expressed above are mine, not sgi's.

mowat@pyrshadow (Eric Mowat) (01/06/90)

In article <6693@columbia.edu>, ji@close.cs.columbia.edu (John Ioannidis) writes:
> Does anyone have adb for AIX 1.1? I need to be able to patch things in
> the running kernel, and also patch the unix executable, and the only
> thing I know that can do both is adb (superzap was never ported to the
> Unix world :-) ). Why oh why did the powers-that-be remove adb from the
> distribution? 
> 

Adb was removed from AIX 1.1 because the only version Locus had contained
AT&T code.  Fortunately there is a workaround.  Use ldminit.  It is contained
in /usr/sys/bin.  Say you want to patch the variable flpdebug in the
kernel.  Edit a file and insert the following line:

flpdebug:1:4:

and run:
ldminit -c <your config file containing flpdebug> -l /local/<name of unix>

This will set the variable flpdebug to 1.  The 4 means that the variable
is 4 bytes long.  You can also use ldminit to patch the running system
as well as the binary, provided you have permissions of course.  The -p 
option will patch /dev/kmem as well.

	Eric Mowat
	mowat@pyrshadow.pyramid.com

dyer@spdcc.COM (Steve Dyer) (01/08/90)

In article <97241@pyramid.pyramid.com> mowat@pyrshadow (Eric Mowat) writes:
>Adb was removed from AIX 1.1 because the only version Locus had contained
>AT&T code.

In that case, IBM should simply be shipping blank floppy disks.
OF COURSE it contains AT&T code, as do every shred of those
applications which are not unique to IBM, and much of the kernel.  

I've heard rumors that adb will be included with the next release.
We'll see.

-- 
Steve Dyer
dyer@ursa-major.spdcc.com aka {ima,harvard,rayssd,linus,m2c}!spdcc!dyer
dyer@arktouros.mit.edu, dyer@hstbme.mit.edu

jackv@turnkey.gryphon.COM (Jack F. Vogel) (01/09/90)

In article <1162@ursa-major.SPDCC.COM> dyer@ursa-major.spdcc.COM (Steve Dyer) writes:
>In article <97241@pyramid.pyramid.com> mowat@pyrshadow (Eric Mowat) writes:
>>Adb was removed from AIX 1.1 because the only version Locus had contained
>>AT&T code.
>
>In that case, IBM should simply be shipping blank floppy disks.
>OF COURSE it contains AT&T code, as do every shred of those
>applications which are not unique to IBM, and much of the kernel.  
 
Yes, well Eric was mistaken. The reason that I have been told is quite
simply that adb is not part of the SysV release. So in a sense Eric is
right, it is AT&T code that is not part of the license.

>I've heard rumors that adb will be included with the next release.
>We'll see.
 
Now, now Steve, don't go and start unfounded rumors :-} ! If you mean the
1.2 release then I will have to nip this in the proverbial bud, no it
definitely is not included, nor do I believe it ever will be. Sorry
about that guys, I would like to see it around as much as anyone, sure
makes debugging panics easier! Guess we'll just have to live with dbx
and crash.

Disclaimer: These opinions are mine, not necessarily IBM's or LCC's.



-- 
Jack F. Vogel			jackv@seas.ucla.edu
AIX Technical Support	              - or -
Locus Computing Corp.		jackv@ifs.umich.edu