Linux Basics Practice Test: Shared Libraries — Flashcards | Linux | FatSkills

Linux Basics Practice Test: Shared Libraries — Flashcards

Fast review mode: answers are shown by default so you can skim quickly. Hide them if you want to self-test.

Shared libraries, also known as Dynamic Shared Objects (DSOs), are files that contain executable modules that can be used by multiple programs to perform a function. In Linux, shared libraries are loaded into memory before an application starts, and when multiple processes require the same library, it will only be loaded once. This feature saves memory usage by the application. 

Shared libraries can be used to:
Update libraries while still supporting programs that want to use older, non-backward-compatible versions of those libraries
Override specific libraries or even specific functions in a library when executing a particular program 
Shared libraries are loaded by programs when they start. Linux systems use a program loader named /lib/ld-linux.so.X to find and load all libraries. 

Shared libraries are named in two ways:
Library name:
Also known as soname
Filename: The absolute path to the file that stores the library code 

For example, the soname for libc is libc.so.6 and the filename for libc is /lib64/libc.so.6. By default, libraries are located in /usr/local/lib. 
You can use the ldd utility to get a list of all shared library dependencies for a binary file.

Related Test: Linux Basics Practice Test: Static Libraries

1 of 10 Ready
In linux shared libraries has the extension of
.so
Shortcuts
Prev Space Show / hide Next
Turn this into a study set.
Sign in with Google to save tricky questions to your reminder list and resume on any device.
Sign in with Google Free • no extra password