How To Protect Ubuntu Server Against the GHOST Vulnerability
The GHOST vulnerability can be exploited on Linux systems that use versions of the GNU C Library prior to glibc-2.18. That is, systems that use an unpatched version of glibc from versions 2.2 to 2.17 are at risk.
Check System Vulnerability
You can use the following command to check the glib version
ldd (Ubuntu GLIBC 2.19-10ubuntu2) 2.19
Copyright (C) 2014 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
Written by Roland McGrath and Ulrich Drepper.
The glib version should be above 2.17 and from the output we are running 2.19.If you are seeing glib version between 2.2 to 2.17 then you need to run the following commands
sudo apt-get update
sudo apt-get dist-upgrade
After the installation you need to reboot the server using the following command
After reboot use the same command again and check the glib version.