Mac远程访问Ubuntu

MacOS和Ubuntu连接到同一个网络
使用ping命令可以通信即可。
SSH
使用SSH可以很方便的在MacOS上访问Ubuntu,不过只能用命令行操作,相当于连接了Ubuntu的终端。
1. Ubuntu上安装SSH
  sudo apt-get install openssh-server
2. Ubuntu上启动SSH
  sudo /etc/init.d/ssh start
3. MacOS上连接Ubuntu
  打开Mac上的终端,输入:ssh 用户名@IP
VNC
使用VNC就可以在MacOS上访问Ubuntu的界面了。
1. Ubuntu上安装x11VNC
  sudo apt-get install x11vnc
2. 密码
  命令:x11vnc -storepasswd
  显示并输入密码:
  Enter VNC password: *********
  Verify password: *********
  Write password to /home/USERHOME/.vnc/passwd? [y]/n y
  Password written to: /home/rahul/.vnc/passwd
3. 开启服务
  x11vnc -auth guess -once -loop -noxdamage -repeat -rfbauth /home/USERNAME/.vnc/passwd -rfbport 5900 -shared
  把USRENAME改成自己的用户名。
4. MacOS连接Ubuntu桌面
  Mac上打开屏幕共享,输入IP和密码。

猜你喜欢

转载自www.cnblogs.com/gloria-zhang/p/11075689.html