CenterOS environment setup

In daily work, many students' intranet working environment is not allowed to connect to the Internet. When it is necessary to build an intranet development environment, they always need to download the required file package in the extranet environment and install it on the intranet. At this time, if the environment of the intranet and the extranet is different, the files copied into the intranet may be unusable or prone to bug s. Therefore, we need to pull the file package on the Internet according to the environment version of the intranet. This article mainly introduces how to build the same virtual machine system as the internal network on the external network, pull the required file package on the external network and copy it into the internal network for environment construction.

View the version of Intranet linux Environment

Take centerOS as an example

[root@www ~]# lsb_release -a
LSB Version:    :base-4.0-amd64:base-4.0-noarch:core-4.0-amd64:core-4.0-noarch
Distributor ID:    CentOS
Description:    CentOS release 6.7 (Final)
Release:    6.7
Codename:    Final
[root@www ~]# uname
Linux
[root@www ~]# uname -r
2.6.32-431.23.3.el6.x86_64
[root@www ~]# uname -a
Linux www 2.6.32-431.23.3.el6.x86_64 #1 SMP Thu Jul 31 17:20:51 UTC 2014 x86_64 x86_64 x86_64 GNU/Linux

Both methods can view version information.

Virtual machine environment construction

Image download

It is recommended to use Alibaba cloud sites in China https://mirrors.aliyun.com/centos-vault Downloading images is faster. You can also download centerOS images on the official website.

The IOS folder is the image download path

Description of each version of ISO image file:

CentOS-7-x86_64-DVD-1708.iso standard installation version (recommended)

CentOS-7-x86_64-Everything-1708.iso full version, integrating all software (to supplement the software of the system or populate the local image)

CentOS-7-x86_64-LiveGNOME-1708.iso GNOME desktop

CentOS-7-x86_64-LiveKDE-1708.iso KDE desktop

CentOS-7-x86_64-Minimal-1708.iso compact version with the least software

CentOS-7-x86_64-NetInstall-1708.iso network installation version (install from network or rescue system)

Download the corresponding version number compact version.

vmware installing centerOS images

Super detailed vmware installation centerOS tutorial The author provides a nanny tutorial

Basic configuration of centerOS environment

System operation and maintenance | 30 things to do after installing RHEL/CentOS 7 (I) (linux.cn)

The server configures static IP addresses, routes, and DNS

yum install net-tools 

Install command line web browser

yum install links

Install apache http server

yum install httpd

The minimized CentOS7 system does not have nano, VIM, wget, curl, ifconfig, lsof, zip and unzip commands installed, so you need to install them here (command explanation: nano is a text editor of character terminal, which is much simpler than vi/vim and is more suitable for Linux beginners; VIM is a multi-mode editor; wget is a tool for downloading files; curl is a file transfer tool that uses URL rules to work on the command line; ifconfig is used to display or configure network devices (network interface cards) in Linux lsof(list open files) is a tool to list the open files of the current system; zip and unzip are compression and decompression command tools

yum -y install nano vim wget curl  lsof zip unzip

Minimize installation network configuration

[root@localhost ~]: vi /etc/sysconfig/network-scripts/ifcfg-ens33

TYPE=Ethernet
PROXY_METHOD=none
BROWSER_ONLY=no
BOOTPROTO=dhcp
DEFROUTE=yes
IPV4_FAILURE_FATAL=no
IPV6INIT=yes
IPV6_AUTOCONF=yes
IPV6_DEFROUTE=yes
IPV6_FAILURE_FATAL=no
IPV6_ADDR_GEN_MODE=stable-privacy
NAME=ens33
UUID=c02aadee-742b-40f7-aa65-8dece35b4eae
DEVICE=ens33
ONBOOT=no

Press i to enter the insert mode, and change ONBOOT=no to ONBOOT=yes, Press esc to return to command mode, enter: wq save to exit.

service network restart restart the network service

[root@localhost ~]: service network restart
Restarting network (via systemctl):                        [  OK  ]
[root@localhost ~]:

Finally, check the network information to see the assigned IP

How to backup VMware virtual disk files or migrate to other virtual machines - Baidu experience (baidu.com)

Posted by paulb on Thu, 04 Nov 2021 05:37:33 -0700