本文将带领大家,在TrueNAS scale上安装Proxmox VE。实验操作,未证明稳定性,勇者上!
1. 更改源
编辑/etc/apt/sources.list
在原有的基础上,添加下面源
针对基于debian11的truenas,使用下面源
deb https://mirrors.ustc.edu.cn/proxmox/debian bullseye pve-no-subscription
deb https://mirrors.apqa.cn/proxmox/debian/pve bullseye truenas
- 针对基于debian12的truenas,使用下面源
deb https://mirrors.ustc.edu.cn/proxmox/debian bookworm pve-no-subscription
deb https://mirrors.apqa.cn/proxmox/debian/pve bookworm truenas
由于没有pve的key,还需要导入2个key
curl https://mirrors.apqa.cn/proxmox/debian/pveport.gpg -o /etc/apt/trusted.gpg.d/pveport.gpg
wget -P /etc/apt/trusted.gpg.d https://mirrors.ustc.edu.cn/proxmox/debian/proxmox-release-bullseye.gpg
2.更改hosts
编辑/etc/hosts文件,
将第二行的127.0.0.1改成truenas的ip,如下。
3.添加执行权限
chmod +x /usr/bin/*
chmod +x /usr/sbin/*
4.安装软件包
卸载软件包
apt autoremove -y qemu-system-common qemu-system-data qemu-system-gui qemu-system-x86 qemu-utils
先安装pve
apt update && apt --no-install-recommends --no-install-suggests install proxmox-ve openssl
注意返回的页面中,有没有出现remove packages的软件包,如果有,确保没有truenas相关的包,如果有请停止安装。
直到出现有这个为止,否则就循环操作一下。
6.配置网桥
安装ifupdown2
apt install ifupdown2 -y
安装完之后,在web上创建网桥,确保自己填了正确的桥接端口。
此时就没有任何问题了。
7.PVE使用truenas的zfs存储
在PVE的数据中心-存储-添加zfs, ID自己定义,zfs池就选自己创建的zfs池。
8.已知问题
8.1 pve服务无法开机自动启动
Truenas每次开机都会更改/etc/hosts文件,导致每次重启PVE服务无法自动启动,
解决方案
复制正常的hosts文件,然后配置开机脚本,进行替换。
cp /etc/hosts /opt
添加一个启动脚本
echo '#!/bin/bash' >>/etc/rc.local
echo 'cp /opt/hosts /etc/hosts && systemctl start pvestatd' >>/etc/rc.local
给脚本执行权限
chmod +x /etc/rc.local
8.2 RRD错误
表现在PVE的监控不正确,如时间异常。
创建一个rrd文件夹,
mkdir -p /var/lib/rrdcached/db/
systemctl restart pvedaemon
反过来pve安装truenas也可以吧
truenas是个傻逼,所以不行,
大佬最新版的truenas+pve还能装吗
安装好truenas最新版本后,在按教程安装pve时,报如下错误,求大佬指导指导,非常感谢
Running hook script 'zz-proxmox-boot'..
Re-executing '/etc/kernel/postinst.d/zz-proxmox-boot' in new private mount namespace..
No /etc/kernel/proxmox-boot-uuids found, skipping ESP sync.
System booted in EFI-mode but 'grub-efi-amd64' meta-package not installed!
Install 'grub-efi-amd64' to get updates.
run-parts: executing /etc/kernel/postinst.d/kdump-tools 6.5.11-5-pve /boot/vmlinuz-6.5.11-5-pve
kdump-tools: Generating /var/lib/kdump/initrd.img-6.5.11-5-pve
mkinitramfs: failed to determine device for /
mkinitramfs: workaround is MODULES=most, check:
grep -r MODULES /var/lib/kdump/initramfs-tools
Error please report bug on initramfs-tools
Include the output of 'mount' and 'cat /proc/mounts'
update-initramfs: failed for /var/lib/kdump/initrd.img-6.5.11-5-pve with 1.
run-parts: /etc/kernel/postinst.d/kdump-tools exited with return code 1
Failed to process /etc/kernel/postinst.d at /var/lib/dpkg/info/proxmox-kernel-6.5.11-5-pve-signed.postinst line 20.
dpkg: error processing package proxmox-kernel-6.5.11-5-pve-signed (--configure):
installed proxmox-kernel-6.5.11-5-pve-signed package post-installation script subprocess returned error exit status 2
dpkg: dependency problems prevent configuration of proxmox-kernel-6.5:
proxmox-kernel-6.5 depends on proxmox-kernel-6.5.11-5-pve-signed | proxmox-kernel-6.5.11-5-pve; however:
Package proxmox-kernel-6.5.11-5-pve-signed is not configured yet.
Package proxmox-kernel-6.5.11-5-pve is not installed.
Package proxmox-kernel-6.5.11-5-pve-signed which provides proxmox-kernel-6.5.11-5-pve is not configured yet.
dpkg: error processing package proxmox-kernel-6.5 (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of proxmox-default-kernel:
proxmox-default-kernel depends on proxmox-kernel-6.5; however:
Package proxmox-kernel-6.5 is not configured yet.
dpkg: error processing package proxmox-default-kernel (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of proxmox-ve:
proxmox-ve depends on proxmox-default-kernel; however:
Package proxmox-default-kernel is not configured yet.
dpkg: error processing package proxmox-ve (--configure):
dependency problems - leaving unconfigured
Errors were encountered while processing:
proxmox-kernel-6.5.11-5-pve-signed
proxmox-kernel-6.5
proxmox-default-kernel
proxmox-ve
E: Sub-process /usr/bin/dpkg returned an error code (1)
失效了。8.1更新了
按照这篇文章,我基于TrueNAS-SCALE-23.10.0.1上安装了pve8.0.4,基本没问题!就是机器配置太差...
已知问题8.1还在,暂时新建启动任务替换hosts搞定,8.2 RRD问题未出现监控不正常、时间异常现象
非生产,就是玩~[f=xiaoku]
Proxmox scale好像不能GVT-G?没有找到/etc/default/grub文件
要是两个系统同时对zfs里的文件进行修改,不知会不会出错
这和windows用notepad++ 和nodepad-- 修改同一文件一个道理。
冲!
问一下TrueNAS scale安装完成后时间不对怎么处理,无法开启ntp服务,时间一直快8个小时。
安装chrony。