Software libraries can be linked in two ways
StaticallyThese are compiled together with a program to produce a single piece of executable code. this can have advantage of producing executable code that runs quickly. However this disadvantage is that the resulting code tends to be long and so uses large amount of system resources.
DynamicallyThese are also shared libraries and are loaded into memory as they are needed. This means that the code compiled with dynamically linked libraries has a smaller memory footprint then if it were linked statically.
Shared libraries are frequently updated. Installing new libraries means that you need to maintain the software that depends on these libraries. We do this in order to avoid or resolve dependencies and conflicts.
To list the shared libraries
# ldd /bin/ls
linux-vdso.so.1 => (0x00007fffa9bff000)
libselinux.so.1 => /lib64/libselinux.so.1 (0x0000003f64600000)
librt.so.1 => /lib64/librt.so.1 (0x0000003f63600000)
libcap.so.2 => /lib64/libcap.so.2 (0x0000003f66e00000)
libacl.so.1 => /lib64/libacl.so.1 (0x0000003f6da00000)
libc.so.6 => /lib64/libc.so.6 (0x0000003f62e00000)
libdl.so.2 => /lib64/libdl.so.2 (0x0000003f62a00000)
libpthread.so.0 => /lib64/libpthread.so.0 (0x0000003f63200000)
libattr.so.1 => /lib64/libattr.so.1 (0x0000003f73200000)
Install a library manually
# ldconfig -n -v /usr/lib
NOTE: if you install library in a non standard directory you need to add this path LD_LIBRARY_PATH for Red Hat Linux and SHLIB_PATH for HP-UX
You can add the path using the below command (path has to be added instead of /usr/lib followed by a colon ":")
For Red Hat Linux
# export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/lib:/usr/local/lib
For HP-UX (Unix)
# export SHLIB_PATH=$SHLIB_PATH:/usr/lib:/usr/local/lib
For making these changes permanent add these path in .bash_profile. For more details follow the below link
How to set environment (PATH) variable permanently in Linux
Follow the below links for more tutorials
Tutorial for Monitoring Tools SAR and KSAR with examples in Linux
How to configure Samba 4 Secondary Domain Controller
How to secure Apache web server in Linux using password (.htaccess)
How to register Red Hat Linux with RHN (Red Hat Network )
Red hat Enterprise Linux 5.5 Installation Guide (Screenshots)
15 tips to enhance security of your Linux machine
Why is Linux more secure than windows and any other OS
What is the difference between "su" and "su -" in Linux?
What is kernel-PAE in Linux?
What is swappiness and how do we change its value?
How to log iptables messages in different log file
What are the s and k scripts in the etc rcx.d directories
How to check all the currently running services in Linux
How to auto start service after reboot in Linux
What is virtual memory, paging and swap space?