What is the command for dumping memory segment information in Unix/Linux?

  • Thread starter Thread starter waht
  • Start date Start date
  • Tags Tags
    Map Memory
AI Thread Summary
The discussion centers on a memory allocation error in a program, highlighting the memory segments and their privileges from the dump. Key points include the identification of various libraries involved, such as libc, libgcc_s, and libm, along with their respective memory addresses and permissions. Participants express interest in commands that can provide similar memory segment information based on specified start and stop addresses. The command 'pmap' is mentioned as a useful tool for reporting the memory usage of a process, confirming its effectiveness in this context. The conversation emphasizes the need for tools to analyze memory allocation and segment details more thoroughly.
waht
Messages
1,499
Reaction score
4
Here is a small segment that was dumped after an error in a program has occurred - that does a lot of memory allocation.
Code:
b7ee6000-b7ee7000 rw-p 00157000 08:02 72280      /lib/libc-2.9.so             
b7ee7000-b7eea000 rw-p b7ee7000 00:00 0                                       
b7eea000-b7ef7000 r-xp 00000000 08:02 72115      /lib/libgcc_s.so.1           
b7ef7000-b7ef8000 r--p 0000c000 08:02 72115      /lib/libgcc_s.so.1           
b7ef8000-b7ef9000 rw-p 0000d000 08:02 72115      /lib/libgcc_s.so.1           
b7ef9000-b7f20000 r-xp 00000000 08:02 72284      /lib/libm-2.9.so             
b7f20000-b7f21000 r--p 00026000 08:02 72284      /lib/libm-2.9.so             
b7f21000-b7f22000 rw-p 00027000 08:02 72284      /lib/libm-2.9.so

Interestingly, it shows the privileges of different memory segments. I'm wondering if there is a command that dumps this kind information if you provide the start and stop memory address. Or to find out which segments are from the heap, or stack.
 
Technology news on Phys.org
pmap will report the memory usage of a process
 
thanks, it works
 
Thread 'Is this public key encryption?'
I've tried to intuit public key encryption but never quite managed. But this seems to wrap it up in a bow. This seems to be a very elegant way of transmitting a message publicly that only the sender and receiver can decipher. Is this how PKE works? No, it cant be. In the above case, the requester knows the target's "secret" key - because they have his ID, and therefore knows his birthdate.

Similar threads

Back
Top