全 blog

不搞后端的后端开发

0%

1
2
3
4
# 一次性代理  
git clone -c http.proxy="http://127.0.0.1:10809" url;
# 全局设置代理
git config --global http.https://gitlab.com.proxy socks5://127.0.0.1:10808

重新安装驱动

dkms remove -m nvidia -v 510.73.06 –all

vGPU version

如果使用的版本是14.1vGPU Version 14.1
https://github.com/VGPU-Community-Drivers/NV-VGPU-Driver/releases
新增:驱动下载可与查看这里(未测试)
https://cloud.google.com/compute/docs/gpus/grid-drivers-table?hl=zh-cn

vGPU激活

安装服务

一般情况下使用,特殊情况使用venderid伪装成正常显卡
 fastapi-dls 开源项目
 容器地址是:https://hub.docker.com/r/collinwebdesigns/fastapi-dls
 

1
2
3
4
5
6
7
8
9
10
11
12
13
14
# 设定工作目录并创建
WORKING_DIR=/opt/docker/fastapi-dls/cert
mkdir -p $WORKING_DIR

# 生成相关证书
cd $WORKING_DIR
openssl genrsa -out $WORKING_DIR/instance.private.pem 2048
openssl rsa -in $WORKING_DIR/instance.private.pem -outform PEM -pubout -out $WORKING_DIR/instance.public.pem
openssl req -x509 -nodes -days 3650 -newkey rsa:2048 -keyout $WORKING_DIR/webserver.key -out $WORKING_DIR/webserver.crt

# 创建容器的官方建议命令
docker run -e LEASE_EXPIRE_DAYS=1825 -e DLS_URL=192.168.10.85 -e DLS_PORT=443 -p 443:443 -v $WORKING_DIR:/app/cert collinwebdesigns/fastapi-dls:latest

docker run -e LEASE_EXPIRE_DAYS=1825 -e DLS_URL=192.168.11.84 -e DLS_PORT=443 -p 443:443 -v $WORKING_DIR:/app/cert collinwebdesigns/fastapi-dls:latest

安装完成后检查地址https://192.168.10.85/-/readme

Linux

!!!安装dkms后启动驱动程序,使用dkms安装

1
sudo ./NVIDIA-Linux-***.sh --dkms
1
2
3
4
sudo curl --insecure -X GET https://192.168.10.85/-/client-token -o /etc/nvidia/ClientConfigToken/client_configuration_token.tok

sudo curl --insecure -X GET https://192.168.11.87/-/client-token -o /etc/nvidia/ClientConfigToken/client_configuration_token.tok
nvidia-smi -q | grep "License"

windows

放置文件到:
C:\Program Files\NVIDIA Corporation\vGPU Licensing\ClientConfigToken

1
nvidia-smi -q |findstr License

删除pve节点

ceph manager,monitor,osd,等服务

使用gui destory manager,monitor,OSD,medatdata Servers;

清理clush mapper

1
ceph osd crush remove <hostname>

删除节点

1
2
3
4
5
6
7
8
9
10
# pvecm nodes

Membership information
----------------------
Nodeid Votes Name
1 1 pve-node-5 (local)
2 1 pve-node-4
3 1 pve-node-3
4 1 pve-node-2
5 1 pve-node-temp

关闭需要删除的节点

1
# pvecm delnode pve-node-temp
  • 此时,您可能会收到一条错误消息,指出Could not kill node (error = CS_ERR_NOT_EXIST)。这并不意味着删除节点的实际失败,而是 corosync 试图杀死离线节点的失败。因此,可以安全地忽略它。

添加pve节点

  • 安装时请确认pve-node的名称,更改名称事件麻烦事!!!
  • 复制集群中 cluster->Join Information
  • 在待添加的节点GUI中Cluster->Join Cluster->Join Cluster中粘贴信息

安装ZFS 日志盘和缓存盘

格式化硬件,使用gpt格式

1
2
parted /dev/sdf
mklabel gpt
1
2
3
4
5
# 运行以下命令创建第一个 128GB 的分区:
(parted) mkpart primary ext4 0% 50%
# 运行以下命令创建第二个 128GB 的分区:
(parted) mkpart primary ext4 50% 100%
(parted) quit

添加到pool

1
zpool add -f <pool> log <device-part1> cache <device-part2>

使用github域名

创建github仓库,使用github域名

安装HEXO

1
2
3
4
# 安装
npm install -g hexo-cli
# 初始化
hexo init blog

安装next主题

1
git submodule add https://github.com/theme-next/hexo-theme-next themes/next

更改 ./_config.yml文件中theme: next
拷贝./themes/_config -> ./_config.next.yml

然后探索了一下_config.next.yml

部署HEXO

1
2
3
4
deploy:  
type: git
repo: https://github.com/QwQuan/qwquan.github.io.git
branch: main
1
2
3
hexo clean 
hexo generate
hexo deploy

搞定了!