Method of installing gcc and kernel devel in Linux system

  • 2020-05-14 05:53:51
  • OfStack

gcc: the c/c++ compiler in the liunx environment, which is required to install the software

kernel-devel: linux kernel. You need to compile the kernel when installing the software, so you need to keep the kernel version 1 unchanged

1. After the Linux operating system is installed, check whether gcc has been installed;

# gcc-v // if there is a large 1 segment after it, it is already installed;

2. Check whether the kernel is 1;

#uname -r

#rpm -q kernel-devel

If both commands get version 1, you can install Vmware Tools directly. However, in 1 general case, the two versions are not 1, or it is indicated that kernel-devel is not installed;

3. Install gcc (if gcc is not installed); Make sure the network is connected;

#yum -y install gcc

4. Install kernel-devel (can be found in iso files)

#cd /mnt/

#mkdir cdrom

#mount /dev/cdrom /mnt/cdrom // these three steps mount the drive to the cdrom folder under the /mnt directory;

# cp/mnt cdrom/CentOS/kernel - xen - devel - 2.6.18-164. el5. i686. rpm/tmp / / find kernel xen - devel... File and copy to /tmp directory;

#cd /tmp

# rpm - ivh kernel xen - devel - 2.6.18-164. el5. i686. rpm kervel - devel / / installation


Related articles: