<div dir="ltr"><div dir="ltr"><br></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">сб, 27 апр. 2019 г. в 20:16, Narcis Garcia <<a href="mailto:informatica@actiu.net">informatica@actiu.net</a>>:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">I responded about OpenVZ/6 vs LXC, and Proxmox doesn't solve the Discard<br></blockquote><div><br></div><div>What do you mean it doesn't solve the issue with discard? It does.</div><div><br></div><div>Discard is perfectly working on Proxmox kernel 4.15.18-12-pve or even on 4.13 kernel on DM-Crypt/LUKS setup.</div><div><br></div><div>I'm using on all my servers DM-Crypt/LUKS + LVM so I know what I'm talking about.</div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
issue for OpenVZ/6 with a LUKS layer.<br>
<br>
With any of Devuan 1, 2, Debian 8, 9 kernels, Discard works fine with<br>
LUKS layer (with or without LXC), and Proxmox doesn't help in this.<br>
<br>
<br>
El 27/4/19 a les 16:39, spameden ha escrit:<br>
> Furthermore there might be issues using old legacy OpenVZ6 kernel on<br>
> modern hardware, e.g. NVMe or any newer NIC cards.<br>
> <br>
> Seeing as you've been using Debian as well as me for quite some time I'd<br>
> recommend - <a href="https://proxmox.com" rel="noreferrer" target="_blank">https://proxmox.com</a> <br>
> <br>
> In proxmox you can use unprivileged LXC containers (for security) as<br>
> well as containers with directory storage though they don't support<br>
> quotas (but you save on precious nvme disk storage).<br>
> <br>
> There is also fancy webui, but I don't use it, mainly sticking to the<br>
> console pct tool and template's system.<br>
> <br>
> There is a bit hassle regarding using external IPs in the containers,<br>
> but it's possible via certain workaround with iptables and routing.<br>
> <br>
> Proxmox also works natively with latest Debian Stretch (with systemd)<br>
> and it's using recent kernel, e.g.:<br>
> <br>
> # uname -r<br>
> 4.15.18-12-pve<br>
> <br>
> and yes discards work just fine on proxmox:<br>
> <br>
> # dmsetup table|grep discards<br>
> ***: 0 123 crypt aes-xts-plain64<br>
> 0000000000000000000000000000000000000000000000000000000000000000 0 9:1<br>
> 4096 1 allow_discards<br>
> <br>
> Migration from OpenVZ6 is also very straightforward to Proxmox: in most<br>
> cases containers just do work (if you've been using simfs before) and<br>
> not requiring any modifications.<br>
> <br>
> <br>
> <br>
> сб, 27 апр. 2019 г. в 17:28, CoolCold <<a href="mailto:coolthecold@gmail.com" target="_blank">coolthecold@gmail.com</a><br>
> <mailto:<a href="mailto:coolthecold@gmail.com" target="_blank">coolthecold@gmail.com</a>>>:<br>
> <br>
> I believe to have fixes and backports like this in to legacy version<br>
> of product will not happen, and you should consider upgrading.<br>
> Personally, I've upgraded to lxc.. it's quite primitive comparing to<br>
> ovz 6, but it's enough for my needs.<br>
> <br>
> On Sat, Apr 27, 2019, 17:49 spameden <<a href="mailto:spameden@gmail.com" target="_blank">spameden@gmail.com</a><br>
> <mailto:<a href="mailto:spameden@gmail.com" target="_blank">spameden@gmail.com</a>>> wrote:<br>
> <br>
> Yes, it's an issue in kernel. <br>
> <br>
> As dm-crypt/luks layer isn't passing TRIM to the underlying device.<br>
> <br>
> /boot is not encrypted that's why it works for you.<br>
> <br>
> сб, 27 апр. 2019 г. в 11:11, Narcis Garcia<br>
> <<a href="mailto:informatica@actiu.net" target="_blank">informatica@actiu.net</a> <mailto:<a href="mailto:informatica@actiu.net" target="_blank">informatica@actiu.net</a>>>:<br>
> <br>
> See in the case that /dev/sda1 (Directly mounted as Ext4 on<br>
> /boot) works with Trim/Discard.<br>
> It's the sda2_crypt (layer over sda2) that is not detected<br>
> to be trimmable. Devuan's stock kernel does.<br>
> <br>
> CentOS issue #6548 may not be this same bug; I've tested now<br>
> with CentOS 6.8 with a similar (but not same) result*:*<br>
> <br>
> $ lsb_release -d<br>
> Description: CentOS release 6.8 (Final)<br>
> <br>
> $ uname -a<br>
> Linux localhost.localdomain 2.6.32-642.el6.x86_64 #1 SMP Tue<br>
> May 10 17:27:01 UTC 2016 x86_64 x86_64 x86_64 GNU/Linux<br>
> <br>
> $ lsblk --discard /dev/sda<br>
> NAME <br>
> DISC-ALN DISC-GRAN DISC-MAX DISC-ZERO<br>
> sda <br>
> 0 512B 2G 0<br>
> ├─sda1 <br>
> 0 512B 2G 0<br>
> └─sda2 <br>
> 0 512B 2G 0<br>
> └─luks-f691f48b-8556-487d-ac64-50daa99ed4c9 (dm-0) <br>
> 0 512B 2G 0<br>
> <br>
> $ cat /etc/crypttab<br>
> luks-f691f48b-8556-487d-ac64-50daa99ed4c9<br>
> UUID=f691f48b-8556-487d-ac64-50daa99ed4c9 none luks,discard<br>
> <br>
> $ mount | grep -e discard<br>
> /dev/mapper/luks-f691f48b-8556-487d-ac64-50daa99ed4c9 on /<br>
> type ext4 (rw,discard)<br>
> /dev/sda1 on /boot type ext4 (rw,discard)<br>
> <br>
> $ sudo fstrim /boot<br>
> # (same result as Devuan/1 and OpenVZ/6 kernel: success)<br>
> <br>
> $ sudo fstrim /<br>
> fstrim: /: FITRIM ioctl failed: Operation not supported<br>
> <br>
> <br>
> El 26/4/19 a les 21:36, spameden ha escrit:<br>
>> Hi.<br>
>><br>
>> I've asked this question years ago (in<br>
>> 2013): <a href="https://lists.openvz.org/pipermail/users/2013-August/005250.html" rel="noreferrer" target="_blank">https://lists.openvz.org/pipermail/users/2013-August/005250.html</a><br>
>><br>
>> Let me know if it helps, but this bug should have been<br>
>> fixed in CentOS and RHEL at<br>
>> least: <a href="https://bugs.centos.org/view.php?id=6548" rel="noreferrer" target="_blank">https://bugs.centos.org/view.php?id=6548</a><br>
>><br>
>> Maybe OpenVZ maintainers didn't pick up this fix in the<br>
>> openvz6 legacy kernel?<br>
>><br>
>> Thanks.<br>
>><br>
>> ср, 10 апр. 2019 г. в 10:45, Narcis Garcia<br>
>> <<a href="mailto:informatica@actiu.net" target="_blank">informatica@actiu.net</a> <mailto:<a href="mailto:informatica@actiu.net" target="_blank">informatica@actiu.net</a>>>:<br>
>><br>
>> Does anybody know how can I solve this?<br>
>><br>
>> $ lsb_release -d<br>
>> Description: Devuan GNU/Linux 1.0 (jessie)<br>
>><br>
>> $ uname -a<br>
>> Linux bell1 2.6.32-openvz-042stab134.8-amd64 #1 SMP<br>
>> Fri Dec 7 17:18:40<br>
>> MSK 2018 x86_64 GNU/Linux<br>
>><br>
>> $ lsblk --discard /dev/sda<br>
>> NAME DISC-ALN DISC-GRAN DISC-MAX DISC-ZERO<br>
>> sda 0 512B 2G 0<br>
>> ├─sda1 0 512B 2G 0<br>
>> └─sda2 0 512B 2G 0<br>
>> └─sda2_crypt 0 0B 0B 0<br>
>><br>
>> $ cat /etc/crypttab<br>
>> sda2_crypt UUID=***** none luks,discard<br>
>><br>
>> $ mount | grep -e discard<br>
>> /dev/mapper/sda2_crypt on / type ext4<br>
>> (rw,noatime,errors=remount-ro,barrier=1,data=ordered,discard)<br>
>> /dev/sda1 on /boot type ext4<br>
>> (rw,relatime,barrier=1,data=ordered,discard)<br>
>><br>
>> $ sudo fstrim /<br>
>> fstrim: /: the discard operation is not supported<br>
>><br>
>> Thank you.<br>
>><br>
>><br>
>> _______________________________________________<br>
>> Users mailing list<br>
>> <a href="mailto:Users@openvz.org" target="_blank">Users@openvz.org</a> <mailto:<a href="mailto:Users@openvz.org" target="_blank">Users@openvz.org</a>><br>
>> <a href="https://lists.openvz.org/mailman/listinfo/users" rel="noreferrer" target="_blank">https://lists.openvz.org/mailman/listinfo/users</a><br>
>><br>
>><br>
>> _______________________________________________<br>
>> Users mailing list<br>
>> <a href="mailto:Users@openvz.org" target="_blank">Users@openvz.org</a> <mailto:<a href="mailto:Users@openvz.org" target="_blank">Users@openvz.org</a>><br>
>> <a href="https://lists.openvz.org/mailman/listinfo/users" rel="noreferrer" target="_blank">https://lists.openvz.org/mailman/listinfo/users</a><br>
> _______________________________________________<br>
> Users mailing list<br>
> <a href="mailto:Users@openvz.org" target="_blank">Users@openvz.org</a> <mailto:<a href="mailto:Users@openvz.org" target="_blank">Users@openvz.org</a>><br>
> <a href="https://lists.openvz.org/mailman/listinfo/users" rel="noreferrer" target="_blank">https://lists.openvz.org/mailman/listinfo/users</a><br>
> <br>
> _______________________________________________<br>
> Users mailing list<br>
> <a href="mailto:Users@openvz.org" target="_blank">Users@openvz.org</a> <mailto:<a href="mailto:Users@openvz.org" target="_blank">Users@openvz.org</a>><br>
> <a href="https://lists.openvz.org/mailman/listinfo/users" rel="noreferrer" target="_blank">https://lists.openvz.org/mailman/listinfo/users</a><br>
> <br>
> _______________________________________________<br>
> Users mailing list<br>
> <a href="mailto:Users@openvz.org" target="_blank">Users@openvz.org</a> <mailto:<a href="mailto:Users@openvz.org" target="_blank">Users@openvz.org</a>><br>
> <a href="https://lists.openvz.org/mailman/listinfo/users" rel="noreferrer" target="_blank">https://lists.openvz.org/mailman/listinfo/users</a><br>
> <br>
> <br>
> _______________________________________________<br>
> Users mailing list<br>
> <a href="mailto:Users@openvz.org" target="_blank">Users@openvz.org</a><br>
> <a href="https://lists.openvz.org/mailman/listinfo/users" rel="noreferrer" target="_blank">https://lists.openvz.org/mailman/listinfo/users</a><br>
> <br>
_______________________________________________<br>
Users mailing list<br>
<a href="mailto:Users@openvz.org" target="_blank">Users@openvz.org</a><br>
<a href="https://lists.openvz.org/mailman/listinfo/users" rel="noreferrer" target="_blank">https://lists.openvz.org/mailman/listinfo/users</a><br>
</blockquote></div></div>