1.install anydesk
lsb_release -a
sudo -i
wget -qO - https://keys.anydesk.com/repos/DEB-GPG-KEY | apt-key add -
echo "deb http://deb.anydesk.com/ all main" > /etc/apt/sources.list.d/anydesk.list
sudo apt-get install libcanberra-gtk-module; sudo apt install anydesk
apt --fix-broken install
anydesk &
wget https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb
sudo apt install ./google-chrome-stable_current_amd64.deb
https://download.anydesk.com/linux/ 5.5.6.1-amd64 https://forum.kde.org/viewtopic.php?f=309&t=173204
change default boot OS: https://www.psychocats.net/ubuntu/bootmenu
2.VNCserver
https://serverspace.us/support/help/install-tightvnc-server-on-ubuntu-20-04/
sudo apt-get install xfonts-75dpi
sudo apt-get install xfonts-100dpi
vncserver -geometry 1630x930banyan
3.grep
grep . -name
grep -Ril "text-to-find-here"
grep -R string ./
4.Compare and merge: sudo apt-get install meld
5.Linux on windows10/11
https://ubuntu.com/tutorials/install-ubuntu-on-wsl2-on-windows-11-with-gui-support#1-overview
https://ubuntu.com/tutorials/install-ubuntu-on-wsl2-on-windows-10#1-overview
可以忽略链接,先用task manager|process看虚拟机已enabled,再admin运行powershell,wsl --install -d ubuntu(W11用wsl --install ubuntu)。wsl --set-default-version 2
https://docs.microsoft.com/en-us/windows/wsl/tutorials/gui-apps
X11 missing font: 是因为缺了export LC_ALL=C,要永久解决需加文件:
$ vi /home/[username]/.bash_profile
LC_ALL=C
export LC_ALL
$ echo $LC_ALL //看到显示C而非空白就可以了
C
wsl2还是有许多错误,但是它确实运行了linux发行版。wsl1就不要用了,垃圾。
6.Ckermit
sudo apt install build-essential -y
sudo apt-get install manpages-dev -y
sudo apt-get install libncurses5-dev libncursesw5-dev -y
sudo apt-get install libpam0g-dev -y
sudo apt install megatools -y
mkdir kermit;cd kermit
wget https://src.fedoraproject.org/lookaside/pkgs/ckermit/cku302.tar.gz/eac4dbf18b45775e4cdee5a7c74762b0/cku302.tar.gz
tar xzvf cku302.tar.gz
https://mega.nz/file/DL4nnZhD#1-Wr-QnywqsjNFxMstz4L0b8cf3eBPv6vt9DycpGoUY 的kermit.zip下载转换为此命令:
megadl 'https://mega.nz/#!DL4nnZhD!1-Wr-QnywqsjNFxMstz4L0b8cf3eBPv6vt9DycpGoUY'
unzip kermit.zip
make clean; make linux
sudo mv wermit /usr/local/bin/kermit
which kermit
7.几个命令
7.1 升级
sudo apt update && sudo apt upgrade
sudo do-release-upgrade #会升级到比旧版高一的版本
7.2 创建可加装并带存储的Ubuntu live USB
sudo add-apt-repository ppa:mkusb/ppa
sudo apt update
sudo apt install --install-recommends mkusb mkusb-nox usb-pack-efi
lsblk #plugin 16GB USB, 用此命令看设备名例如
下载好Ubuntu lts 20.04.iso,运行mksub,选install,Persistent live,traditiona模式(此项上面链接没有是新功能,第二项),选iso文件,upefi,指定persistence的比例 (除iso外剩余空间做为Ubuntu系统存储的比例,若选20%则大概有2G分区名为casper-rw 类型ext4,其余为usbdata分区类型ntfs),Go。完成后会显示Done,若出错需冷启动linux PC重新运行mkusb。https://www.howtogeek.com/howto/14912/create-a-persistent-bootable-ubuntu-usb-flash-drive/
成功后运行USB上的Ubuntu live,安装:
sudo apt install ntfs-3g #Fodora/Centos/RHEL是sudo dnf install ntfs-3g
用lsblk看盘设备名,编辑/etc/fstab增加开机安装命令如:
mount /dev/sda3 /mnt/media/drive_location_here
https://www.makeuseof.com/mount-ntfs-windows-drives-in-linux/