On 5/13/06, Warren Wilder <[EMAIL PROTECTED]> wrote:

How do you check whether any of the running processes is using the
shared library xxx.so?
You could just kill all the processes, change to a different runlevel,
or something like that, if you want to install a new version of a
library and be safe about it. But what if you just wanted the information?

Not exactly the answer you want, but you can find out what libraries a
running process is using through pmap.

$ ps -e | grep hald
1284 ?        00:00:10 hald
...
$ pmap 1284
1284:   /usr/sbin/hald
08048000    212K r-x--  /usr/sbin/hald
0807d000      8K rw---  /usr/sbin/hald
0807f000    792K rw---    [ anon ]
b7c06000    384K rw---    [ anon ]
b7c66000     36K r-x--  /lib/libnss_files-2.3.6.so
b7c6f000      4K r----  /lib/libnss_files-2.3.6.so
b7c70000      4K rw---  /lib/libnss_files-2.3.6.so
b7c71000      4K rw---    [ anon ]
b7c72000   1136K r-x--  /lib/libc-2.3.6.so
b7d8e000      8K r----  /lib/libc-2.3.6.so
b7d90000      8K rw---  /lib/libc-2.3.6.so
b7d92000     12K rw---    [ anon ]
b7d95000    120K r-x--  /usr/lib/libexpat.so.0.5.0
b7db3000      8K rw---  /usr/lib/libexpat.so.0.5.0
b7db5000    140K r-x--  /lib/libm-2.3.6.so
b7dd8000      4K r----  /lib/libm-2.3.6.so
b7dd9000      4K rw---  /lib/libm-2.3.6.so
b7dda000     72K r-x--  /lib/libnsl-2.3.6.so
b7dec000      4K r----  /lib/libnsl-2.3.6.so
b7ded000      4K rw---  /lib/libnsl-2.3.6.so
b7dee000      8K rw---    [ anon ]
b7df0000    188K r-x--  /usr/lib/libdbus-1.so.2.0.0
b7e1f000      4K rw---  /usr/lib/libdbus-1.so.2.0.0
b7e20000    540K r-x--  /usr/lib/libglib-2.0.so.0.1000.1
b7ea7000      4K rw---  /usr/lib/libglib-2.0.so.0.1000.1
b7ea8000    228K r-x--  /usr/lib/libgobject-2.0.so.0.1000.1
b7ee1000      4K rw---  /usr/lib/libgobject-2.0.so.0.1000.1
b7ee2000      4K rw---    [ anon ]
b7ee3000    104K r-x--  /usr/lib/libdbus-glib-1.so.2.0.0
b7efd000      4K rw---  /usr/lib/libdbus-glib-1.so.2.0.0
b7f09000      4K rw---    [ anon ]
b7f0a000     88K r-x--  /lib/ld-2.3.6.so
b7f20000      4K r----  /lib/ld-2.3.6.so
b7f21000      4K rw---  /lib/ld-2.3.6.so
bf80b000     84K rw---    [ stack ]
ffffe000      4K -----    [ anon ]
total     4240K

--
Dan
--
http://linuxfromscratch.org/mailman/listinfo/blfs-support
FAQ: http://www.linuxfromscratch.org/blfs/faq.html
Unsubscribe: See the above information page

Reply via email to