本文主要是介绍【服务器运维】CentOS7 minimal 离线安装 gcc perl vmware-tools,希望对大家解决编程问题提供一定的参考价值,需要的开发者们随着小编来一起学习吧!
0. 本机在有网的情况下,下载CentOS镜像
https://www.centos.org/download/
1. 取出rpm
有的情况可能不需要net-tools,但是如果出现跟ifconfig相关的错误,就把它安装上。另外如果不想升级内核版本的话,就找对应内核版本的rpm版本安装
perl-Time-Local-1.2300-2.el7.noarch.rpm
perl-Time-HiRes-1.9725-3.el7.x86_64.rpm
perl-threads-shared-1.43-6.el7.x86_64.rpm
perl-threads-1.87-4.el7.x86_64.rpm
perl-Text-ParseWords-3.29-4.el7.noarch.rpm
perl-Storable-2.45-3.el7.x86_64.rpm
perl-Socket-2.010-4.el7.x86_64.rpm
perl-Scalar-List-Utils-1.27-248.el7.x86_64.rpm
perl-Pod-Usage-1.63-3.el7.noarch.rpm
perl-Pod-Simple-3.28-4.el7.noarch.rpm
perl-Pod-Perldoc-3.20-4.el7.noarch.rpm
perl-Pod-Escapes-1.04-292.el7.noarch.rpm
perl-PathTools-3.40-5.el7.x86_64.rpm
perl-parent-0.225-244.el7.noarch.rpm
perl-macros-5.16.3-292.el7.x86_64.rpm
perl-libs-5.16.3-292.el7.x86_64.rpm
perl-HTTP-Tiny-0.033-3.el7.noarch.rpm
perl-Getopt-Long-2.40-3.el7.noarch.rpm
perl-Filter-1.49-3.el7.x86_64.rpm
perl-File-Temp-0.23.01-3.el7.noarch.rpm
perl-File-Path-2.09-2.el7.noarch.rpm
perl-Exporter-5.68-3.el7.noarch.rpm
perl-Encode-2.51-7.el7.x86_64.rpm
perl-constant-1.27-2.el7.noarch.rpm
perl-Carp-1.26-244.el7.noarch.rpm
perl-5.16.3-292.el7.x86_64.rpm
net-tools-2.0-0.22.20131004git.el7.x86_64.rpm
mpfr-3.1.1-4.el7.x86_64.rpm
libmpc-1.0.1-3.el7.x86_64.rpm
kexec-tools-2.0.15-13.el7.x86_64.rpm
kernel-tools-libs-3.10.0-862.el7.x86_64.rpm
kernel-tools-3.10.0-862.el7.x86_64.rpm
kernel-headers-3.10.0-862.el7.x86_64.rpm
kernel-devel-3.10.0-862.el7.x86_64.rpm
kernel-debug-devel-3.10.0-862.el7.x86_64.rpm
kernel-abi-whitelists-3.10.0-862.el7.noarch.rpm
kernel-3.10.0-862.el7.x86_64.rpm
glibc-headers-2.17-222.el7.x86_64.rpm
glibc-devel-2.17-222.el7.x86_64.rpm
gcc-c++-4.8.5-28.el7.x86_64.rpm
gcc-4.8.5-28.el7.x86_64.rpm
cpp-4.8.5-28.el7.x86_64.rpm
2. 上传rpm安装包
scp -r rpm username@server:/path
3. 进入rpm目录下安装
rpm -Uvh *.rpm --nodeps --force
至此,gcc perl ifconfig 都安装好了
4. 创建镜像挂载路径
mkdir /mnt/cdrom
5. 挂载镜像
mount -t iso9660 /dev/cdrom /mnt/cdrom
6. 卸载镜像
umount /dev/cdrom /mnt/cdrom
7. 拷贝
cp /mnt/cdrom/VMwareTools.tar.gz /home
8. 解压
tar -xzf VMwareTools.tar.gz
VMwareTools.tar.gz 也可以自己上传,就不需要挂载光盘了
9. 创建内核软连接
cd /usr/src/kernels/3.10.0-514.21.2.el7.x86_64/
ln -s /usr/src/kernels/3.10.0-514.21.2.el7.x86_64/include/generated/uapi/linux/version.h /usr/src/kernels/3.10.0-514.21.2.el7.x86_64/include/linux/version.h
reboot
9是为了避免出现如下问题,也可以在问题出现时在指定地址
The path "" is not a valid path to the 版本-generic kernel headers.
Would you like to change it? [yes]
Enter the path to the kernel header files for the 版本-generic kernel?
10. 安装vmware-tools.pl
cd vmware-tools-distrib/
./vmware-install.pl
11. 安装完成
当出现 Enjoy, --the VMware team,则说明安装完成
one more thing…
开启网卡
cd /etc/sysconfig/network-scripts/
vi ifcfg-ens33【网卡名称】
ONBOOT=yes
保存
service network restart
yum安装包位置
/etc/yum.conf
cachedir=/var/cache/yum/ b a s e a r c h / basearch/ basearch/releasever
抛开外界的喧嚣,让浮躁的心沉静下来,坚持学习,终将在各种稀奇古怪的业务中,无往而不利。9:30上班,10:30下班,逛西单!
这篇关于【服务器运维】CentOS7 minimal 离线安装 gcc perl vmware-tools的文章就介绍到这儿,希望我们推荐的文章对编程师们有所帮助!