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