====== 谷歌虚拟机 RDP ====== 项目地址:[[https://colab.research.google.com/notebooks/intro.ipynb?authuser=1#scrollTo=5fCEDCU_qrC0|Google Colaboratory]] Colaboratory(简称 Colab),您可在浏览器中编写和执行 Python 代码。是Google一个机器学习的项目。 打开以上地址之后,左上角 ''%%文件 -> 新建笔记本%%'',然后粘贴以下代码,点击运行箭头。 ! wget https://raw.githubusercontent.com/fsteamID/RDP-Google-Debian/fsteamID/RDP.sh ! chmod +x RDP.sh ! ./RDP.sh 第二步要求在浏览器打开 ''https://remotedesktop.google.com/headless'' 这个地址,一路确认,最后选择自己需要的系统,windows 或者 linux 等。复制其授权代码,粘贴到虚拟机的建立框中。 第三步要求输入一个6位数字的Pin码,将来登录虚拟机时用。最后我申请到的虚拟机号为 2bd6b8dc8c62 。可以立即点击登陆进去,或者下载chromne 远程桌面插件。(([[https://cloud.google.com/solutions/chrome-desktop-remote-on-compute-engine?hl=zh-cn|在 Compute Engine 上设置适用于 Linux 的 Chrome 远程桌面]])) DISPLAY= /opt/google/chrome-remote-desktop/start-host --code="4/0AX4XfWgl8yKc4_cd2WQjDTW9d48A2lPzekHE5SRT1eFkiNV69XUA4IaanO2q2kmjpFOIIg" --redirect-url="https://remotedesktop.google.com/_/oauthredirect" --name=$(hostname) 最后打开虚拟机的地址为。https://remotedesktop.google.com/access/ 中间需要用自己的google账号登录,完成后以用户 ++ User : FSID | Password : 8426 ++ 登录,并通过 ''%%sudo -i%%'' 获取root权限。