/debug (again and again and again...)

Dave Ciemiewicz ciemo at bananapc.wpd.sgi.com
Sat Sep 30 11:10:25 AEST 1989


In article <42352 at sgi.sgi.com>, ciemo at bananapc.wpd.sgi.com (Dave Ciemiewicz) writes:
> In article <42340 at sgi.sgi.com>, daveh at xtenk.sgi.com (David A Higgen) writes:
> 
> > > But the burning question is...
> > > If your disk is partitioned so that /debug gets, say, 53meg, does that mean
> > > that you only have 53meg of swap space, maximum?
> > 
> > > || Tom Stockfisch, UCSD Chemistry	tps at chem.ucsd.edu
> > 
> > Tom, didn't you READ the article you were appending to?
> > Repeat After Me, 500 times: "/debug is NOT my swap space".
> > 
> > /debug is simply an informational window to processes' virtual space, used
> > by debuggers (eg dbx). IT NEITHER CONSUMES NOR PROVIDES PHYSICAL RESOURCES.
> > 
> > /debug is not "on" a disk partition. Your swap space IS on one or more
> > disk partitions reserved for the purpose, normally partition 1 on the
> > root disk. Other partitions can be added to the swap space; try
> > 'man swap' for details.
> > 
> > Incidentally, is anyone from Tech Pubs here reading this group? I would
> > guess that the continuing confusion on the /debug issue is a strong
> > suggestion that documentation on the point needs to be improved...
> > 
> > 
> > 				Dave Higgen
> > 
> 
> /debug is an file interface to system processes.  Unmounting /debug to
> not unmount the swap space; unmounting only removes access to the interface
> which SGI's dbx can access and debug processes.
> 
> However, playing out /debug's affectation of a real file system, many
> of the standard IRIX(TM) file and filesystem commands present information
> about the /debug interface and the swap partion AS THOUGH they were real
> live IRIX(TM) file systems though they are not.
> 
> As part of of this, df of /debug reveals the size of your swap partion.
> Thus yes, if "df -k /debug" says /debug imitation file system has
> 51048 kbytes, your swap partion has been partioned for approximately
> 51MB of swap space (virtual memory).

It turns out I was wrong on this point.  "df -k /debug" reveals the size
of your virtual memory which is the size of the swap partition plus the
size of physical memory.

If you really want to find out the size of your swap partion, do as root:

	prtvtoc	/dev/rvh

This will print the volume header of your first disk.  If your disk is
of standard configuration, your root partion will be on partition 0,
swap on partition 1, and /usr on partition 6.

I did this on my machine and found out that my swap partion was
72,100 sectors or 36,050 kbytes in size.  My physical memory is 16 MB or
16,384 kbytes.  Add the two together and you get 52,434 KB or approximately
what "df -k /debug" had reported above for my virtual memory size.
(I can't account for the discrepancy.)

> 
> It is wise to take heed from Mr. Higgen and remember that /debug is not
> a real file system but is a file system abstraction of the processes
> executing under IRIX(TM).
> 

Advice I really should have taken myself.

Thanks to Chris Dunlap for pointing out the error of my ways.


--
-------------------------------------------------------------------------------
			Cosmo Ciemo, Silicon Valley Dude

I was traipsing through the fields of my mind when I stepped in something that
smelled rather ripe.
-------------------------------------------------------------------------------



More information about the Comp.sys.sgi mailing list