lrwxrwxrwx 1 root root 25 Jun 25 19:38 pyspark -> /etc/alternatives/pyspark
lrwxrwxrwx1 root root 34 Jul 24 20:49 python -> /usr/local/python362/bin/python3.6lrwxrwxrwx1 root root 6 Oct 28 2016 python2 ->python-rwxr-xr-x 2 root root 4864 Aug 18 2016python_2-rwxr-xr-x 2 root root 4864 Aug 18 2016 python2.6
#!/usr/bin/python_2
importsystry:importyumexceptImportError:print >> sys.stderr, """\
There was a problem importing one of the Python modules
required to run yum. The error leading to this problem was:
%s
Please install a package which provides this module, or
verify that the module is installed correctly.
It's possible that the above module doesn't match the
current version of Python, which is:
%s
If you cannot solve this problem yourself, please go to
the yum faq at:
http://yum.baseurl.org/wiki/Faq""" %(sys.exc_value, sys.version)
sys.exit(1)
sys.path.insert(0,'/usr/share/yum-cli')try:importyummain
yummain.user_main(sys.argv[1:], exit_code=True)exceptKeyboardInterrupt, e:print >> sys.stderr, "\n\nExiting on user cancel."sys.exit(1)~
~
~
~
~
~
~
"/usr/bin/yum" 32L, 803C
en.wikipedia.org/wiki/Yum_(.rpm)
The Yellowdog Updater, Modified (yum) is an open-source command-line package-management utility for computers running the Linux operating system using the RPM Package Manager.graphical user interfaces to yum functionality.
Yum allows automatic updates, package and dependency management, on RPM-based distributions.Advanced Package Tool (APT) from Debian, yum works with software repositories (collections of packages), which can be accessed locally
Under the hood, yum depends on RPM, which is a packaging standard for digital distribution of software, which automatically uses hashes and digisigs to verify the authorship and integrity of said software; unlike some app stores, which serve a similar function, neither yum nor RPM provide built-in support for proprietary restrictions on copying of packages by endusers. Yum is implemented as libraries in the Python programming language, with a small set of programs that provide a command-line interface.DNF is currently being developed and replaced yum as the default package manager in Fedora 22.
【学习路径】
https://dev.mysql.com/doc/refman/5.7/en/linux-installation-yum-repo.html#yum-repo-installing-mysql
【初始化】
lsb_release -d
Description: CentOS Linux release 7.3.1611 (Core)
yum update
cd usr
mkdir mysql
cd mysql
#https://dev.mysql.com/doc/refman/5.7/en/linux-installation-yum-repo.html#yum-repo-installing-mysql
#https://dev.mysql.com/downloads/repo/yum/
#mysql57-community-release-el7-11.noarch.rpm
wget https://dev.mysql.com/get/mysql57-community-release-el7-11.noarch.rpm
md5sum mysql57-community-release-el7-11.noarch.rpm
【安装】
sudo yum localinstall mysql57-community-release-el7-11.noarch.rpm
【版本选5.6】
cat /etc/yum.repos.d/mysql-community.repo
For example, to install MySQL 5.6, make sure you have enabled=0 for the above subrepository entry for MySQL 5.7, and have enabled=1 for the entry for the 5.6 series:
# Enable to use MySQL 5.6
[mysql56-community]
name=MySQL 5.6 Community Server
baseurl=http://repo.mysql.com/yum/mysql-5.6-community/el/6/$basearch/
enabled=1
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-mysql
【校验】
yum repolist enabled | grep "mysql.*-community.*"
【安装】
sudo yum install mysql-community-server
【启动】
sudo service mysqld start
【校验】
sudo service mysqld status
mysql -uroot -p