一、 CentOS7 命令列安裝 TeamViewer
1 、進入官網下載站群軟體包
2 、安裝
# yumyum install -y teamviewer_13.0.5693.x86_64.rpm
或者
# rpm rpm -ivh teamviewer_13.0.5693.x86_64.rpm
3 、啟動
預設會安裝到/opt/teamview 裡面,並且安裝成功會預設啟動
cd /opt/teamviewer/tv_bin/
進入安裝目錄以後,一般使用的常用命令如下:
teamviewer –setup console #設定啟動方式為控制檯啟動 teamviewer –daemon restart #重啟 teamview 服務 teamviewer –info #檢視 teamview 資訊 teamviewer –passwd [PASSWD] #設定密碼 teamviewer –help #檢視幫助
設定固定密碼
# 用 teamviewer –info 命令可檢視 teamview 執行狀態 teamviewer –info# 如果沒有設定密碼,TeamViewer ID: 後面會是空的,# 執行命令 teamviewer –passwd 你的密碼 # 再次執行 teamviewer –info 命令就可以看到 ID 了
4 、刪除、解除安裝 teamviewer
# 以關鍵字檢視服務 rpm -q teamviewer
# 解除安裝 rpm -e 查到的程式名 rpm -e teamviewer_13.0.5693.x86_64.rpm
二、 CentOS7 安裝 teamviewer 遇到依賴包問題
由於 yum 可以自動下載依賴包,而現在依賴包下載不了,這很可能是 yum 安裝或配置的有問題。當然,簡單粗暴的方式,那就是重灌 yum(安裝源在國內的 yum, 親測可行的!)。
但這是剛安裝的最新的 CentOS7 原生系統映象站群啊!yum 怎麼會出問題呢?而且使用 ” rpm -qa|grep yum ” 檢視,yum 確實已經安裝。
排查 yum 的配置檔案(源一定要換為國內的源,比如 http://mirrors.163.com/.help/centos.html ),問題的真正根源在於:CentOS-Base.repo 配置檔案。
在 /etc/yum.repos.d/ 目錄下有個配置 yum 下載源的檔案 CentOS-Base.repo 。由於之前沒有設定好相關的配置源,所以不能正常的使用 yum 工具。
修改之前的 CentOS-Base.repo 檔案:
三、 CentOS7 原生系統不能從網上 yum 源中自動下載依賴包的站群解決方案
首先備份/etc/yum.repos.d/CentOS-Base.repo
mv /etc/yum.repos.d/CentOS-Base.repo /etc/yum.repos.d/CentOS-Base.repo.backup
下載對應版本 repo 檔案, 放入/etc/yum.repos.d/(操作前請做好相應備份)
CentOS7: http://mirrors.163.com/.help/CentOS7-Base-163.repo
執行以下命令生成 WordPress 加速快取
yum clean all
yum makecache
修改以後的 CentOS-Base.repo 檔案:
# CentOS-Base.repo## The mirror system uses the connecting IP address of the client and the# update status of each mirror to pick mirrors that are updated to and# geographically close to the client. You should use this for CentOS updates# unless you are manually picking other mirrors.## If the mirrorlist= does not work for you, as a fall back you can try the # remarked out baseurl= line instead.##[base]name=CentOS-$releasever – Base – 163.com#mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=osbaseurl=http://mirrors.163.com/centos/$releasever/os/$basearch/gpgcheck=1gpgkey=http://mirrors.163.com/centos/RPM-GPG-KEY-CentOS-7#released updates[updates]name=CentOS-$releasever – Updates – 163.com#mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=updatesbaseurl=http://mirrors.163.com/centos/$releasever/updates/$basearch/gpgcheck=1gpgkey=http://mirrors.163.com/centos/RPM-GPG-KEY-CentOS-7#additional packages that may be useful[extras]name=CentOS-$releasever – Extras – 163.com#mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=extrasbaseurl=http://mirrors.163.com/centos/$releasever/extras/$basearch/gpgcheck=1gpgkey=http://mirrors.163.com/centos/RPM-GPG-KEY-CentOS-7#additional packages that extend functionality of existing packages[centosplus]name=CentOS-$releasever – Plus – 163.combaseurl=http://mirrors.163.com/centos/$releasever/centosplus/$basearch/gpgcheck=1enabled=0gpgkey=http://mirrors.163.com/centos/RPM-GPG-KEY-CentOS-7