吐槽一下:现在教程一搜一大把,一大把一模一样,没错说的就是CSDN
我试图找到最原创,可能是他 : 可能的原创:)
我是参考的他,以及一些其他解答
需求
这是远程安装教程,也就是说完全没有ui界面,只有ssh,也就不能点击teamviwer弹出来的接收用户许可
步骤
1 下载
下载teamviwer.deb
我下的是 teamviewer_12.0.85001_i386.deb
2 安装,以及获取id 和 密码
安装
dpkg -i teamviewer_12.0.85001_i386.deb #非root用户需加 sudo
#此处可能会报错如下,因为64位系统,需添加32位的架构。
dpkg: error processing package teamviewer:i386 (--install):
dependency problems - leaving unconfigured
Processing triggers for gnome-menus (3.13.3-6ubuntu3) ...
Processing triggers for desktop-file-utils (0.22-1ubuntu5) ...
Processing triggers for bamfdaemon (0.5.3~bzr0+16.04.20160415-0ubuntu1) ...
Rebuilding /usr/share/applications/bamf-2.index...
Processing triggers for mime-support (3.59ubuntu1) ...
Processing triggers for hicolor-icon-theme (0.15-0ubuntu1) ...
Errors were encountered while processing:
teamviewer:i386
如果报错则强制安装
apt-get update
apt-get -f install
安装完成后,修改teamviwer的配置文件
vim /opt/teamviewer/config/global.conf
添加如下
[int32] EulaAccepted = 1
[int32] EulaAcceptedRevision = 6
#这是为了确认接收用户许可。因为是命令行,没有ui界面,不能用鼠标点击接收用户许可,故在设置里接收。
之后,重启teamviwer daemon:
teamviwer --daemon restart
要远程登录teamviwer需要一个机器id,一个对应的密码。
此处参考这里
要先设置密码,再获取id
设置teamviwer的登录密码
teamviwer --passwd xxxxx
再重启deamon
teamviwer --daemon restart
然后用命令:
teamviwer info
查看teamviwer的id等信息(最主要的是id,密码已经设置过,有了id后就能远程登录了)
~# teamviewer info
TeamViewer 12.0.85001 (DEB)
teamviewerd status ● teamviewerd.service - TeamViewer remote control daemon
Loaded: loaded (/etc/systemd/system/teamviewerd.service; enabled; vendor preset: enabled)
Active: active (running) since 三 2018-05-30 11:12:22 CST; 1min 13s ago
Process: 4271 ExecStart=/opt/teamviewer/tv_bin/teamviewerd -d (code=exited, status=0/SUCCESS)
Main PID: 4288 (teamviewerd)
CGroup: /system.slice/teamviewerd.service
├─ 4288 /opt/teamviewer/tv_bin/teamviewerd -d
├─ 4391 c:\TeamViewer\TeamViewer.exe
├─ 5997 /opt/teamviewer/tv_bin/wine/bin/wineserver
├─ 6016 C:\windows\system32\services.exe
├─16918 C:\windows\system32\explorer.exe /desktop
├─17168 /opt/teamviewer//tv_bin/TVGuiSlave.64 175 1
└─17348 /opt/teamviewer//tv_bin/TVGuiDelegate 175 1
5月 30 11:12:22 node05 systemd[1]: Starting TeamViewer remote control daemon...
5月 30 11:12:22 node05 systemd[1]: teamviewerd.service: PID file /var/run/teamviewerd.pid not readable (yet?) after start: No such file or directory
5月 30 11:12:22 node05 systemd[1]: Started TeamViewer remote control daemon.
5月 30 11:12:23 node05 su[4413]: Successful su for guest-mb7xvp by root
5月 30 11:12:23 node05 su[4413]: + ??? root:guest-mb7xvp
5月 30 11:12:23 node05 su[4413]: pam_unix(su:session): session opened for user guest-mb7xvp by (uid=0)
TeamViewer ID: 909672xxx
之后,此id也会出现在当初设置的配置文件中:/opt/teamviewer/config/global.conf:
[int32] ClientID = 909672xxx
然后就可以用自己的teamviwer登陆了
网友评论