由于已经做了整理计划。所以照例执行一下。今天计划把VPS环境整理一下,之后整理下同步盘。
我的VPS采用的是centos6.7 64位系统。
内存2G,2核心,40G+60G的数据盘。由于跑了非常多的程序,所以目前有点小卡。
之前装了Cuteone,里面环境真的好复杂啊,而且总是出现某些问题,不刷新就会500,我基本已经把所有权限都已经查过了没问题。说实话,这东西没有必要的话,真的不要安装,我计划实施Pyone,由于环境不太相同,所以我先整理系统吧,记录一下说不定以后会用到。
1、卸载docker,因为基本用不到了。虽然这东西很方便,但是对我没用处。
查询docker安装过的包
yum list installed | grep docker
docker-engine.x86_64 1.7.1-1.el6 @/docker-engine-1.7.1-1.el6.x86_64
删除安装包
yum remove docker-engine.x86_64 -y
Loaded plugins: fastestmirror
Setting up Remove Process
Resolving Dependencies
--> Running transaction check
---> Package docker-engine.x86_64 0:1.7.1-1.el6 will be erased
--> Finished Dependency Resolution
Dependencies Resolved
==========================================================================================================================================================================
Package Arch Version Repository Size
==========================================================================================================================================================================
Removing:
docker-engine x86_64 1.7.1-1.el6 @/docker-engine-1.7.1-1.el6.x86_64 19 M
Transaction Summary
==========================================================================================================================================================================
Remove 1 Package(s)
Installed size: 19 M
Downloading Packages:
Running rpm_check_debug
Running Transaction Test
Transaction Test Succeeded
Running Transaction
Erasing : docker-engine-1.7.1-1.el6.x86_64 1/1
Verifying : docker-engine-1.7.1-1.el6.x86_64 1/1
Removed:
docker-engine.x86_64 0:1.7.1-1.el6
Complete!
You have new mail in /var/spool/mail/root
删除镜像及容器,顺便看看还有没有残留东西没搞干净
[root@centos67-x64 ~]# rm -rf /var/lib/docker
[root@centos67-x64 ~]# which docker
/usr/bin/which: no docker in (/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin:/www/wdlinux/mysql/bin:/root/bin:/usr/local/git/bin:/root/bin)
[root@centos67-x64 ~]# find docker
find: `docker': No such file or directory
[root@centos67-x64 ~]#
2、卸载Python-3.6.3,基本也用不上,由于有人说卸载pythone会导致系统奔溃,而且我隐约记得好像linux系统都自带的所以我采取了比较谨慎的做法。
查询版本,看看是不是真的安装了两个版本。
[root@centos67-x64 ~]# python -V
Python 2.6.6
有点小害怕,我看到这东西
还是确认下不要搞错了,因为我已经把进程关了,所以看不见,对centos不懂,所以还是保险一下。
[root@centos67-x64 ~]# whereis python
python: /usr/bin/python2.6 /usr/bin/python /usr/lib/python2.6 /usr/lib64/python2.6 /usr/include/python2.6 /usr/share/man/man1/python.1.gz
试试直接删除python3,网上那些方法还是很不靠谱的,建议大家备份系统再尝试,我还是老老实实的找文件目录把。
[root@centos67-x64 ~]# cd Python-3.6.3
[root@centos67-x64 Python-3.6.3]# ls -l
total 2700
-rw-r--r-- 1 501 501 13335 Oct 3 2017 aclocal.m4
-rwxr-xr-x 1 501 501 44259 Oct 3 2017 config.guess
-rwxr-xr-x 1 501 501 36515 Oct 3 2017 config.sub
-rwxr-xr-x 1 501 501 484734 Oct 3 2017 configure
-rw-r--r-- 1 501 501 160430 Oct 3 2017 configure.ac
drwxr-xr-x 18 501 501 4096 Oct 3 2017 Doc
-rw-r--r-- 1 root root 1709825 Apr 24 2019 get-pip.py
drwxr-xr-x 2 501 501 4096 Oct 3 2017 Grammar
drwxr-xr-x 2 501 501 4096 Oct 3 2017 Include
-rwxr-xr-x 1 501 501 7122 Oct 3 2017 install-sh
drwxr-xr-x 33 501 501 4096 May 6 20:25 Lib
-rw-r--r-- 1 501 501 12757 Oct 3 2017 LICENSE
drwxr-xr-x 8 501 501 4096 Oct 3 2017 Mac
-rw-r--r-- 1 501 501 59746 Oct 3 2017 Makefile.pre.in
drwxr-xr-x 2 501 501 4096 May 6 20:25 Misc
drwxr-xr-x 13 501 501 4096 May 6 20:25 Modules
drwxr-xr-x 4 501 501 4096 May 6 20:25 Objects
drwxr-xr-x 2 501 501 4096 May 6 20:25 Parser
drwxr-xr-x 6 501 501 4096 Oct 3 2017 PC
drwxr-xr-x 2 501 501 4096 Oct 3 2017 PCbuild
drwxr-xr-x 2 501 501 4096 May 6 20:25 Programs
-rw-r--r-- 1 501 501 41453 Oct 3 2017 pyconfig.h.in
drwxr-xr-x 3 501 501 4096 May 6 20:25 Python
-rw-r--r-- 1 501 501 9269 Oct 3 2017 README.rst
-rw-r--r-- 1 501 501 101514 Oct 3 2017 setup.py
drwxr-xr-x 23 501 501 4096 Oct 3 2017 Tools
看到setup我就放心多了。不过运行起来好像有点问题。直接删除即可,但是一定要先把软连接替换回当初,否则无法运行。