On Tue, 8 Apr 2008, Peter Kerpedjiev wrote: > Robert P. J. Day wrote: > > # pmap -d 1 > > 1: init [5] > > Address Kbytes Mode Offset Device Mapping > > 00110000 4 r-x-- 0000000000110000 000:00000 [ anon ] > > 00967000 220 r-x-- 0000000000000000 0fd:00000 libsepol.so.1 > > 0099e000 4 rwx-- 0000000000036000 0fd:00000 libsepol.so.1 > > 00a3d000 100 r-x-- 0000000000000000 0fd:00000 libselinux.so.1 > > 00a56000 8 rwx-- 0000000000018000 0fd:00000 libselinux.so.1 > > 00ab0000 108 r-x-- 0000000000000000 0fd:00000 ld-2.7.so > > 00acb000 4 r-x-- 000000000001a000 0fd:00000 ld-2.7.so > > 00acc000 4 rwx-- 000000000001b000 0fd:00000 ld-2.7.so > > ... etc etc ... > > > > so there's my listing of VMAs corresponding to the "init" > > process, and i can see the addresses of each VMA, but what is the > > informational value in the Offset field? > It's the offset into the file being mapped. In other words, the > memory region beginning at the address listed under 'Address' is > mapped to the contents of the file listed under 'Mapping' beginning > 'Offset' bytes after the start of the file. Take a look at > /proc/[pid]/maps for another version of the same information. ok, but here's something i find a little odd: # pmap -d 1 1: init [5] Address Kbytes Mode Offset Device Mapping ... snip ... 00c55000 12 r-x-- 0000000000000000 0fd:00000 libdl-2.7.so 00c58000 4 r-x-- 0000000000002000 0fd:00000 libdl-2.7.so 00c59000 4 rwx-- 0000000000003000 0fd:00000 libdl-2.7.so ... if you look at the second VMA for that shared lib, its address shows that it's 0x3000 higher up in memory, but the Offset field shows an offset of only 0x2000. what does that mean? thanks. rday -- ======================================================================== Robert P. J. Day Linux Consulting, Training and Annoying Kernel Pedantry: Have classroom, will lecture. http://crashcourse.ca Waterloo, Ontario, CANADA ======================================================================== -- To unsubscribe from this list: send an email with "unsubscribe kernelnewbies" to ecartis@xxxxxxxxxxxx Please read the FAQ at http://kernelnewbies.org/FAQ