Ubuntu Mate / Ubuntu Desktop版本为22.04
官网只能下载最新版22.04:
https://ubuntu-mate.org/raspberry-pi/download/
下载20.04版本无法正常启动:
https://blog.csdn.net/qq_52785580/article/details/122599728
http://www.okey56.com/zb_users/upload/2021/10/202110241635088474188702.torrent
先用balenaEtcher重装系统。设置开机自动登录!首先安装输入法。
不更换也可以。备份软件源文件,以免修改坏了
sudo cp /etc/apt/sources.list /etc/apt/sources.list.bak
打开软件源文件,使用nano进行修改
sudo nano /etc/apt/sources.list
添加对应Ubuntu版本的源,不要在网上随便复制。Ubuntu22.04换成这个:
deb http://mirrors.aliyun.com/ubuntu-ports/ jammy main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu-ports/ jammy main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu-ports/ jammy-security main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu-ports/ jammy-security main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu-ports/ jammy-updates main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu-ports/ jammy-updates main restricted universe multiverse
# deb http://mirrors.aliyun.com/ubuntu-ports/ jammy-proposed main restricted universe multiverse
# deb-src http://mirrors.aliyun.com/ubuntu-ports/ jammy-proposed main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu-ports/ jammy-backports main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu-ports/ jammy-backports main restricted universe multiverse
sudo apt update
sudo apt upgrade
https://blog.csdn.net/qq_52785580/article/details/122599728
The OpenSSH server is not installed by default. Simply install it to to enable SSH.
sudo apt install openssh-server
If you install SSH then you might also want to install sshguard which is highly optimised and well suited for use on the Raspberry Pi to protect from brute force attacks against SSH.
sudo apt install sshguard
https://ubuntu-mate.org/raspberry-pi/
sudo apt install ubuntu-desktop
安装:sudo apt install xrdp
重启Xrdp服务器:sudo service xrdp restart / sudo systemctl start xrdp
查看服务运行状态:sudo service xrdp status / systemctl status xrdp
如果状态像下图一样是Active就可以了:
设置开启自动启动:sudo update-rc.d xrdp defaults / sudo systemctl enable xrdp
以上步骤完成后,即可用PC端的远程桌面连接树莓派,先查看树莓派IP地址:
ifconfig
若报错,安装 net-tools:
sudo apt install net-tools
Windows快捷键win+R,输入mstsc,输入树莓派IP地址即可连接。
https://mp.weixin.qq.com/s/UWgDs0UA_SegAoWl4X5eRg
https://www.freesion.com/article/3137780425/
对于Ubuntu Desktop 22.04:
先执行上述“xrdp方法”,在防火墙中打开3389端口。
要让网络中的其他系统通过 RDP 远程访问 Ubuntu 22.04 Jammy,请在系统防火墙上打开端口号 3389。
sudo ufw allow from any to any port 3389 proto tcp
注销 Ubuntu 22.04
安装完成后,只需注销Ubuntu 22.04 系统,否则在使用 XRDP 远程连接 Ubuntu 时,Windows 遇到黑屏问题。
实测Ubuntu 22.04成功。
https://www.cnblogs.com/pipci/p/16377032.html
1.安装VNC
sudo apt-get install x11vnc
2.创建vnc密码
x11vnc -storepasswd
输入两边密码,回车
3.启动vnc
x11vnc -usepw
4.建立远程连接
https://blog.csdn.net/qq_52785580/article/details/122599728
Ubuntu Mate20.04测试成功。
Ubuntu Mate22.04提示系统不支持VNC。
问题原因:乌班图13.10以后的版本xrdp不支持gnome和unity
解决方法:下载xfce4,重启xrdp即可
sudo apt-get install xfce4
echo "xfce4-session" >~/.xsession
sudo service xrdp restart
https://blog.csdn.net/Hao_ge_666/article/details/123953446
尝试无效。
执行下面代码,删除两个文件目录。
注意:pi 替换为自己的用户名!!!,比如我的用户名是lumuzi。则sudo gpasswd -d lumuzi video
sudo gpasswd -d pi video
sudo gpasswd -d pi render
执行命令,进行系统设置。
sudo raspi-config
依次选择进入System options -> Boot / Auto Login ->Desktop(Desktop GUI, requiring user to login)
然后确定重启。
尝试无效。
https://blog.csdn.net/qq_44696500/article/details/124543039
如果用PC端的远程桌面连接时出现灰屏现象,就需要再进行以下设置:
① 创建一个配置文件:sudo touch ~/.xsession
② 进入文件编辑:sudo nano ~/.xsession
③ 复制以下内容到文件:
unset DBUS_SESSION_BUS_ADDRESS
mate-session
TZ='Asia/Shanghai'; export TZ
④ ctrl+x退出编辑,提示是否保存的时候选择Y,再回车即可保存。
⑤ 重启树莓派,再次连接的时候即可进入桌面。
尝试无效。
https://mp.weixin.qq.com/s/UWgDs0UA_SegAoWl4X5eRg
使用aptitude进行安装,aptitude 会对依赖关系进行智能处理
sudo apt-get install aptitude
sudo aptitude install <package name>
https://blog.csdn.net/weixin_43846270/article/details/103779781?spm=1001.2014.3001.5506
https://blog.csdn.net/qq_52785580/article/details/122599728
https://shumeipai.nxez.com/2022/11/28/ubuntu-server-installs-graphical-interface-and-remote-desktop.html