Linux installation is related to software configuration.

Source: Internet
Author: User
Tags cairo pscp secure copy yum repolist

Linux installation is related to software configuration.
Precautions for installing CentOS

CentOS is the best choice for servers.

  • After strong shutdown, the system cannot be started normally after restart, and the system will not be able to constantly beep. If the memory problem is identified, use another memory stick to solve the problem;
  • Boot Disk selection:
    Be sure to find out the disk on which it is located. Sda or sdb. Note that the hard drive on your computer is not necessarily sda.
  • Select a mount point:
    To be familiar with common Linux configurations, you must have space; otherwise, you cannot load the configurations;
  • Do not install bootloader on a USB flash drive. You must manually select the boot sequence;
  • Software source selection:
    Configuration as needed; desktop edition, server, workstation ......
  • Install in VMware:
    During initial configuration before installation, pay attention to centos 64 as the operating system type. Otherwise, no network may exist. You can set the network in the network configuration during installation, you can also directly set the network during installation.
  • Linux primary/extended/logical partitions
    3 + 1: a maximum of four partitions are allowed. The primary partition must be greater than or equal to one. Linux boot partitions cannot be placed in the primary partition. This is different from windows, however, it is still placed in the primary partition.
  • Clock problems:
    After Linux and Windows are installed, the time in windows is eight hours slower than the actual time. The reason is that Linux uses UTC time, and the hardware time plus the time zone (UTC + 8) is the computer time. In Windows, the hardware time is used as the current system time, which slows down by eight hours.
  • Not in the sudoers file
    Go to root and change the/etc/sudoers file:
    Add a row under root ALL = (ALL) ALL,
    Xxx ALL = (ALL) ALL
    Finally, remove the write permission of the file (the sudoers file permission must be 440; otherwise, an error will be reported using the sudo command ).
New installation of LinuxMint

Based on Ubuntu, but the interface is more fresh and similar to Windows, is a good choice for Linux Desktop.

  • Uninstall the libreoffice/openjdk that comes with the system, and replace it with wps office/oracle jdk (Debian installation command: dpkg-I packagename ), in addition, IntelliJ idea/Pycharm (run the sh file in the bin directory, and the shortcut will be automatically added to the menu), Anaconda2 (bash runs the sh file, and then conda install some libraries, note that the python that comes with the system should not be cleared, otherwise it will affect the running of some software ),
  • Install Chrome;
  • Install WPS and go to the official website to download the deb package. when the package is opened, the system prompts that some fonts are missing. Download the corresponding fonts and install them;
  • Install MySQL:sudo apt-get install mysql-serverIn the middle, enter the root password and skip it. Then, view the service.sudo netstat –tap |grep mysqlIf the listener port is displayed, the installation is successful;
  • Install Apache:sudo apt-get install Apache2Enter 127.0.0.1 in the browser to view the Apache homepage;
  • No package is found for installing PHP5, so replace it with xampp and run the run file directly. However, because port 3306 is occupied by mysql separately installed, MySQL in xampp cannot be enabled. After port 3307 is changed, it can be enabled normally;
  • Set to automatically mount windows partitions at startup, and edit the/etc/fstab file. Make sure to back up the file before editing,sudo apt-get install cairo-dock cairo-dock-plug-ins
Vim Configuration
  • Modify color
    vi ~/.vimrc# This file does not exist
    Add the following content to the file:
    Hi Comment ctermfg = blue
    This method can also modify the color of other keywords.
  • Add row number
    Set nu
  • Modify the topic to sublime Color Scheme
    Github address: https://github.com/sickill/vim-monokai
    Put monokai. vim file in your ~ /. Vim/colors/directory and add the following line to your ~ /. Vimrc:
    Syntax enable
    Colorscheme monokai
    Note that files starting with "." in linux are invisible by default, and all files can be seen through the ls-a command.
Configuration ~ /. Bashrc

The username @ path is highlighted, so that you can easily see where the first output of each command is. Otherwise, the chaos cannot be distinguished.
Refer:
Http://blog.csdn.net/vactivx/article/details/62219349

Samba

For Windows and Linux file sharing servers, the original Virtual Machine with VMware can use VM tools to set shared folders, but Hyper-V does not seem to have this tool, so instead use Samba. Here is the shared folder for Linux to access Windows, and vice versa.
-First, set the shared folder in windows and right-click share;
-Install Samba in Linux and set the mount point

Yum install samba-client samba-common # install Sambarpm-qa | grep samba # view the related package mount-t cifs-o username = ***, password = *** // ip/dirdir/mountpoint # mount the shared directory # You can also modify the/etc/fstab file and add the following content below: # // ip/sharedir/mnt/share cifs username = xxx, password = passwd 0 0
MySQL

If MySQL is not in the CentOS7yum source, run it directly.yum install -y mysqlMariaDB is installed to install MySQL:

$ Wget http://dev.mysql.com/get/mysql57-community-release-el7-8.noarch.rpm # download repo source $ sudo rpm-ivh mysql-community-release-el7-5.noarch.rpm # Install get repo source $ yum localinstall mysql57-community-release-el7-8.noarch.rpm # Install source, version 5.7 $ yum repolist enabled | grep "mysql. *-community. * "# Check whether the source is successfully installed $ sudo yum install mysql-server # install $ mysql-V # Check the version, note V Capital $ service mysqld start # start the service $ mysql-u root-p # connect to the service $. /mysqladmin-u root-p password # change the password, cd to/bin

Note that the default root password of a newer version of mysql is not blank. Someone on the internet says that the root password is viewed by viewing the file, but this file does not exist. Finally, it enters the security mode.mysqld --skip-grant-tablesThen change the root password.

Use pscp to transfer files between windows and Linux

PSCP (PuTTY Secure Copy client) is a File Transfer tool provided by PuTTY. It is connected through SSH to transmit files securely between two machines, it can be used on any SSH (including SSH v1 and SSH v2) server.

  • Windows --> Linux

    Download putty for windows and install it in the command line:pscp C:\Users\zhang\Desktop\putty-0.70.tar.gz robin@192.168.8.50:/home/robinEnter the linux Password as prompted to upload the compressed package on the desktop to the/home/robin directory of linux.

  • Linux --> Windows
    Run the command linepscp robin@192.168.8.50:/home/robin/test C:\Users\zhang\Desktop\Copy the test file under the/home/robin directory of the Linux server to the Windows desktop. Note that windows paths do not contain spaces.

    If you want to transfer files in large batches, use tools like FlashFXP.

Install pip

Sometimes many of the Python packages that come with them do not exist. You must use pip for installation. The following is the command for installing pip. Pay attention to the permission.

$ Wget https://bootstrap.pypa.io/get-pip.py$ sudo python get-pip.py $ pip-V # view pip version $ sudo pip install Faker
Install the telnet Service
yum install telnet-serveryum install telent systemctl enable telnet.socket  systemctl start telnet.socket  systemctl enable xinetd  systemctl start xinetd  

Different from other versions, the/etc/xinetd. d/telnet file is not generated when telnet is installed under centos7.
If the connection fails, check whether the firewall is disabled.
In Windows, the telnet function may need to be enabled in the control panel.

References:
Http://www.linuxidc.com/Linux/2016-09/135288.htm

Top
0
Step on
0
View comments

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.