Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1760071AbcJ1M7h (ORCPT ); Fri, 28 Oct 2016 08:59:37 -0400 Received: from mail-lf0-f47.google.com ([209.85.215.47]:36353 "EHLO mail-lf0-f47.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752629AbcJ1M7f (ORCPT ); Fri, 28 Oct 2016 08:59:35 -0400 MIME-Version: 1.0 In-Reply-To: <20161028125620.uusbhlcwncmicvab@home.ouaza.com> References: <1477380887-21333-1-git-send-email-mszeredi@redhat.com> <1477380887-21333-4-git-send-email-mszeredi@redhat.com> <20161025115748.ydhkkp5cfcdnjzwn@home.ouaza.com> <20161028125620.uusbhlcwncmicvab@home.ouaza.com> From: Miklos Szeredi Date: Fri, 28 Oct 2016 14:59:32 +0200 Message-ID: Subject: Re: [PATCH 3/3] ovl: redirect on rename-dir To: Raphael Hertzog Cc: Miklos Szeredi , "linux-unionfs@vger.kernel.org" , Guillem Jover , linux-fsdevel , lkml Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1369 Lines: 32 On Fri, Oct 28, 2016 at 2:56 PM, Raphael Hertzog wrote: > Hi, > > On Wed, 26 Oct 2016, Miklos Szeredi wrote: >> On Tue, Oct 25, 2016 at 1:57 PM, Raphael Hertzog wrote: > > [ redirect feature enabled by default ] > >> I think it would be safe to make it the default if upperdir is empty. >> Nonempty implies that it was created with old kernel (or it was >> crafted by hand). But there should be a way to explicitly turn it >> off; either because of the need for backward compatibility or because >> the old format is simply easier to work with for humans. >> >> How about: >> >> - If upper is nonempty, then leave redirect feature alone except when >> mount option "-oredirect=on" is used to force enabling it. >> - If upper is empty, then enable redirect feature except when mount >> option "-oredirect=off" is used to force disabling it. > > Looks good, but is there some stickyness of the setting? My use case is > schroot and it always starts with an empty upperdir when I create a > temporary/throw-away chroot but if I reboot the machine, then it's possible > that schroot will remount the overlayfs with a non-empty upperdir > (the temporary chroot is preserved until I explicitly end the chroot). Yes, there is stickiness (it stores the "redirect_dir" feature in an extended attribute on upperdir). Thanks, Miklos