[Linux] Install Linux on a virtual machine, client tools and common Linux commands (detailed tutorial)

Table of contents

1. Introduction

1 Introduction

2. Usage scenarios

2. Linux installation

1. Installation

2. Network configuration

2.1. View network configuration

2.2. Change network configuration

3. Install client tools

1 Introduction

2. Install MobaXterm

3. Change source

4.Photography function

4. Commonly used commands


1. Introduction

1 Introduction

        Linux is an open source operating system kernel that was originally developed by Finnish computer scientistLinus Torvalds Developed in 1991. Linux is different from traditional commercial operating systems. It is commonly used on various platforms such as servers, embedded systems and personal computers.

        Linux has many advantages, includingstability, security and customizability etc. Itsupports multi-user, multi-tasking and multi-threading and has compatibility with a wide range of hardware devices and software applications. These features make Linux widely used in various scenarios.

2. Usage scenarios

        Linux has wide applicability and can be used in a variety ofdifferent fields and scenarios, and is continuously improved through the support of the open source community and perfection.

Here are some common Linux usage scenarios:

  1. Server: Linux is widely used in Web servers, database servers and file servers. For example, many well-known Internet companies use Linux as their server operating system.

  2. Embedded system: Due to its compact and flexible nature, Linux is widely used in various embedded devices, such as smartphones, routers, smart home devices, etc.

  3. Personal Computer: Linux provides many desktop environments and applications, such as Ubuntu, Fedora, and Linux Mint, making it an alternative operating system to Windows and Mac OS choose.

  4. Scientific Research and Education: Many researchers in the fields of scientific computing, numerical simulation, and data analysis use Linux to perform high-performance computing and scientific experiments.

2. Linux installation

1. Installation

  1. First create a new virtual machine, you can view[Linux] Install VMWare virtual machine (installation configuration) and configure Windows Server 2012 R2 (installation configuration to connect vm virtual machine) and environment configuration (Detailed tutorial for Windows version) , select the corresponding version , select Linux .
  2. choiceanzou road diameter.
  3. Edit and configure our system image file.
  4. Use the up and down keys to select the second one.
  5. Wait for the language selection interface,Select the language, click Continue
  6. Selection盘区、Next pointCompleteUnused setting .
  7. During installationSet a password. If the password is too simple, justclick twice in succession a> Complete.
  8. After completion, I will do itJonghui.
  9. You need to log in after restarting. The username will basically be:root; the password is the password to change the settings;If the password is incorrect, it will jump back tolocalhost login:.

The installation is complete!

2. Network configuration

2.1. View network configuration

The system you just installed will not connect to the network. ifconfig can set the status of network devices or display the current settings. The ip addr command can also view network configuration information.

//只显示具体网卡的详细信息
ifconfig 具体网卡名称   
//显示所有网卡包括没有启动的网卡
ifconfig -a 
//表示开启或关闭网卡
ifconfig 网卡名称 [up/down]  
//临时设置网卡地址
ifconfig 网络接口 IP地址[/子网掩码长度]
//新建虚拟网卡
ifconfig 网卡名称:数字  地址  
//查看通讯消息
ifconfig -s  

进入cd /ect/sysconfig/network-script/

Check out the articlell, somels.

2.2. Change network configuration

We edit ourifcfg-ens33file

vi: Edit. :q!: Exit statement not saved; cat: View;< /span>: Save exit;:wq

Instruction:vi ifcfg-ens33

comprehensionONBOOTpurposenoour own reform< /span>. :wq, then leaveyes

Restart network service

命令:server network restart

Wetest whether we can connectto the network.

Instruction:ping www.baidu.com

3. Install client tools

1 Introduction

        Tools are for the convenience of usersRemote loginandManage Linux serverorother network devices, providing convenient terminal operation and file transfer. They provide a visual interface and rich functions, allowing users to efficiently connect and manage remotely. Users can choose the tool that suits them based on their needs and preferences.

Common tools include the following:

  1. FinalShell : A powerful SSH, Telnet and SFTP client tool for remote login and management of Linux servers. It has an intuitive user interface and rich features, including multi-tab, session management, automatic login, script execution, file transfer, etc. FinalShell supports the Windows platform and provides a good terminal experience and convenient remote operation.
  2. Xshell: A terminal emulator that supports SSH, SFTP, Telnet, Serial and other protocols, and can be used to remotely log in and manage network devices and Linux servers. It provides rich features, including multi-tagging, session management, script customization, public key verification, port forwarding and file transfer, etc. Xshell is an easy-to-use, powerful tool for Windows operating systems.
  3. MobaXterm: A full-featured remote computing and network toolbox that integrates X11 server, SSH client, SFTP client, RDP client and a variety of network tools. It supports the Windows platform and provides a terminal-like user interface to facilitate users to perform operations such as remote connection, file transfer, and network management. MobaXterm also has additional functions, such as X11 forwarding, remote desktop, remote command execution, etc., making remote operations more convenient.

2. Install MobaXterm

  1. Enter the official website to downloadMobaXterm free Xserver and tabbed SSH client for Windows (mobatek.net)icon-default.png?t=N7T8https://mobaxterm.mobatek.net/
  2. After startup, we create a newfolder for resolution.
  3. We enterifconfig in Linux to check the IP.
  4. Customer connectionConnection.
  5. Enter the password to log in.

3. Change source

  1. Check out the source here it is a foreign source not domestic.
  2. 下载插文;
    INSTRUCTION: yum install wget.
  3. Wait for the download to complete!
  4. Renewal text
    Instruction:mv CentOS-Base.repo CentOS-Base.repo.bak
  5. Generate the Alibaba source and you can see that there is a new one.
    wget -O CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-7.repo

  6. Command:cat CentOS-Base.repoYou can see that our source has become the Alibaba source.
  7. Command:yum install vim Load vim plug-in.
  8. Import:y etc.
  9. Usingvim we can see that our text style is more beautiful than the original style.

4.Photography function

A virtual machine is a tool that runs another operating system on top of an existing operating system. It can simulate a complete hardware system and run a virtual operating system on it. Using a virtual machine in a Linux operating system makes it easier to test and develop Linux applications. On this basis, the Linux operating system in the virtual machine environment can provide a more reliable camera function, which has the following advantages:

  1. Controllable system configuration: The virtual machine environment can provide a unified and controllable system configuration, which is not restricted by hardware devices. This can ensure the stable operation of the Linux operating system, thus ensuring the reliability of the camera function.

  2. Application independence: The Linux operating system in the virtual machine environment is independent and is not affected by other operating system applications. Therefore, the camera function in the virtual machine can be performed in an independent environment without being interfered by other applications, thereby improving the efficiency and accuracy of the camera function.

  3. Better compatibility: Using a virtual machine environment can solve the compatibility problem between the Linux operating system and hardware devices. This makes it more convenient to use Linux systems on different hardware platforms for photography operations without worrying about device compatibility issues.

4. Commonly used commands

Commonly used Linux commands:

  1. lsSequence appearanceText item summe 录.

  2. cdcuttingmemories.

  3. pwd:Displays the name of the current working directory.

  4. mkdir:Create a new directory.

  5. rm删取删文品或目录.

  6. cp复法文品或目录.

  7. mv:transferarticle or menu.

  8. catViewSentence content.

  9. grep: Find the specified text in the file.

  10. chmodRevisedText item or eye referenceConfinement.

  11. chown:RepairText item or eye storyOwner.

  12. ssh: Remote login to another computer via secure shell protocol.

  13. sudo:Heresuperlative usepersonal servicetravel instruction.

  14. tarconstruction, 压缩or 解压tarexisting档文品.

  15. wget: Download files from the network.

This is just a small selection of commonly used Linux commands, there are many others available. You can view the detailed information and usage of each command through the man command. For example, man ls can view the manual page about the ls command. .

Guess you like

Origin blog.csdn.net/weixin_74383330/article/details/134088759