三种操作系统开发环境的搭建
| 命令 | 备注 |
|---|---|
| pwd | 当前目录的绝对路径(print working directory) |
| env | 列出所有环境变量 |
| echo $PATH | 列出环境变量中PATH的值 |
| cat [file_path] | 打印一个文件的内容 |
| xdg-open ./ | 从bash打开文件窗口 |
| top | 查系统状况 |
| cp -r [direction_a] [direction_b] | 循环复制 |
环境变量文件及加载顺序
https://www.cnblogs.com/youyoui/p/10680329.html
用了zsh之后,配置在~/.zshrc里
双系统Ubuntu22.04
Section titled “双系统Ubuntu22.04”https://blog.csdn.net/Flag_ing/article/details/121908340
/etc/apt/source.list
deb http://mirrors.aliyun.com/ubuntu/ jammy main restricted universe multiverse deb-src http://mirrors.aliyun.com/ubuntu/ jammy main restricted universe multiverse deb http://mirrors.aliyun.com/ubuntu/ jammy-security main restricted universe multiverse deb-src http://mirrors.aliyun.com/ubuntu/ jammy-security main restricted universe multiverse deb http://mirrors.aliyun.com/ubuntu/ jammy-updates main restricted universe multiverse deb-src http://mirrors.aliyun.com/ubuntu/ jammy-updates main restricted universe multiverse deb http://mirrors.aliyun.com/ubuntu/ jammy-proposed main restricted universe multiverse deb-src http://mirrors.aliyun.com/ubuntu/ jammy-proposed main restricted universe multiverse deb http://mirrors.aliyun.com/ubuntu/ jammy-backports main restricted universe multiverse deb-src http://mirrors.aliyun.com/ubuntu/ jammy-backports main restricted universe multiverse
Nvidia driver
Section titled “Nvidia driver”https://blog.csdn.net/Perfect886/article/details/119109380
安装nvidia驱动后 网卡丢失
Section titled “安装nvidia驱动后 网卡丢失”Sudo lshw -c network显示 *-network UNCLAIMED
要用其他电脑下载了拷贝过来
https://askubuntu.com/questions/1437477/22-04-1-network-unclaimed
下载地址
http://mirrors.edge.kernel.org/ubuntu/ubuntu/ubuntu/ubuntu/ubuntu/pool/main/l/linux-hwe-5.19/
https://blog.csdn.net/qq_19331985/article/details/125998219
V2Ray gui
Section titled “V2Ray gui”https://github.com/v2rayA/v2rayA
Clash for windows
Section titled “Clash for windows”github ssh key
Section titled “github ssh key”// check if configured beforegit config user.name和git config user.email
git config --global user.name ‘xxxxx’git config --global user.email ‘xxx@xx.xxx’ssh-keygen -t rsa -C ‘上面的邮箱’
// 把rsa.pub的内容复制到githubOh my ZSH
Section titled “Oh my ZSH”https://blog.csdn.net/weixin_42326144/article/details/121957795
cat /etc/shells
sudo apt-get install zsh
sudo curl -L https://raw.github.com/robbyrussell/oh-my-zsh/master/tools/install.sh | sh
// 设置为默认shellchsh -s $(which zsh) // 然后注销重新登录如果要用到bash(比如配置source .bashrc)
切换shell exec bash exec zsh
配置
https://github.com/ohmyzsh/ohmyzsh/
乱码
搜索powerline 最后在bash窗口设置里换字体 如果配置没能成功 注销试试
用了zsh之后配置在 ~/.zshrc里
# CLionCLION_PATH=/home/chenhui/App/clion-2023.1.2/binPATH=$PATH:$CLION_PATHHoudini
Section titled “Houdini”linux版本官网下载说明
遇到qt问题
https://www.sidefx.com/forum/topic/81990/?page=1#post-376619
OpenGL
Section titled “OpenGL”https://crainyday.gitee.io/Ubuntu_004.html
sudo apt-get install build-essential libgl1-mesa-devsudo apt-get install libglew-dev libsdl2-dev libsdl2-image-dev libglm-dev libfreetype6-devsudo apt-get install libglfw3-dev libglfw3sudo apt-get install libtbb-dev在已经安装好nvdia driver的基础上,只需要安装cuda-toolkit
查看driver版本
nvidia-smiThu Jun 29 12:15:02 2023+-----------------------------------------------------------------------------+| NVIDIA-SMI 525.116.04 Driver Version: 525.116.04 CUDA Version: 12.0 ||-------------------------------+----------------------+----------------------+| GPU Name Persistence-M| Bus-Id Disp.A | Volatile Uncorr. ECC || Fan Temp Perf Pwr:Usage/Cap| Memory-Usage | GPU-Util Compute M. || | | MIG M. ||===============================+======================+======================|| 0 NVIDIA GeForce ... Off | 00000000:01:00.0 On | N/A || 0% 51C P8 19W / 200W | 337MiB / 8192MiB | 0% Default || | | N/A |+-------------------------------+----------------------+----------------------+
+-----------------------------------------------------------------------------+| Processes: || GPU GI CI PID Type Process name GPU Memory || ID ID Usage ||=============================================================================|| 0 N/A N/A 1325 G /usr/lib/xorg/Xorg 249MiB || 0 N/A N/A 1607 G /usr/bin/gnome-shell 28MiB || 0 N/A N/A 2220 G ...mviewer/tv_bin/TeamViewer 14MiB || 0 N/A N/A 296705 G ...182476128516229679,262144 41MiB |+-----------------------------------------------------------------------------+google “cuda 12.0 download”
注意最后不要sudo apt-get -y install cuda那会重新下载驱动,而应该sudo apt-get -y install cuda-toolkit
修改env path
# chenhui's env variables# CLionCLION_PATH=/home/chenhui/App/clion-2023.1.2/bin# CudaCUDA_PATH=/usr/local/cuda-12.0/binPATH=$PATH:$CLION_PATH:$CUDA_PATH安装错版本怎么办
- cuda 路径
$ ll /usr/local | grep cudalrwxrwxrwx 1 root root 22 6月 29 10:43 cuda -> /etc/alternatives/cudalrwxrwxrwx 1 root root 25 6月 29 10:43 cuda-12 -> /etc/alternatives/cuda-12drwxr-xr-x 15 root root 4.0K 6月 29 12:12 cuda-12.0- 把下错的版本先删掉
mv cuda-12.2 /.trash
- 把软连接都改了
sudo ln -sf /usr/local/cuda-12.0 cuda
-sf 表示修改ln -sf <A> <B>B指向A- 修改env path
nvcc --version