装了个debian但没装桌面,进去乱码,就用ssh访问,默认NAT情况下只需要在虚拟机设置,网络,高级,端口转发里添加22端口就行了,就可以直接通过127.0.0.1:22进去了
至于乱码
apt update
apt install -y locales
sed -i ‘s/# zh_CN.UTF-8 UTF-8/zh_CN.UTF-8 UTF-8/’ /etc/locale.gen
cat >/etc/default/locale <<-‘EOF’
LANG=”zh_CN.UTF-8″
LANGUAGE=”zh_CN:zh”
EOF
locale-gen
ref: https://www.v2ex.com/t/647598