Received: by 2002:a05:6a10:af89:0:0:0:0 with SMTP id iu9csp193125pxb; Thu, 27 Jan 2022 18:56:30 -0800 (PST) X-Google-Smtp-Source: ABdhPJzT7OULbfLCldkye5kVwnbf97lCfdiauZwF0l9G6FnpUskS6RdC17PMZBlqRYak4Cjfq7xN X-Received: by 2002:a50:cccb:: with SMTP id b11mr6260876edj.57.1643338589901; Thu, 27 Jan 2022 18:56:29 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1643338589; cv=none; d=google.com; s=arc-20160816; b=L35PsE19Uo2nXUl7d7VlQzMkk4VXAVD+iM8VwTtYNEwXmJEb5tHyJ23BcuB52greEB ioaQImUf/LRFxdoM8VGLIvKBztev1Zfqn+Cui1jnydSJhUcMPSvpTcUF9FQ08pGSyvPf racVSn5qIrGf532tdiIVQfHiIfNMB3FzwZS6rVnLjYvhqN8aH8ovWV4hgiWc0+3loTxZ Tv8xke5UC9ogT4SkRVMu6+crCsvRt1mZ/UTWYsiSiNSpnxX/yHYQ56HrM6INGxd71ohm XjflRPE8XNvWu0TPQ998JkRLgHmcHMP4RPR+2Eedr2+cL+PoeynfTDxuLXueDhNLrIwX NS8w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=A7isk/AEvohb1CbSlaMW9h+R22AoDLQSD18pleOQ9gk=; b=k5b8PRyYRoetdb+WR3XyTQ4g2eWpCt5991qTITniwiO0U30MO+YuzynHmXfmPXH/O9 R+Sn5iT+OTpTnEwmKGKT/uhmBaFiPG45tP0vnQaUoS5D4cUENGh+wKd5Bs1CludrUUqf eXZxybTGbYxqNjBKeb0UmEkzYsn/hHewG1BYxuv2erPmS7iTKgkLLWi+ZNroVP63g8M+ 3D5S3NIZ6/TA+lUJqNZH0/yTNZ5WgmkvN95xa+3I6RYVJ2mYSfkVJWgu52foqb5tqOr9 bO9rNfNL2mCTRfrBP+gnM6IgQXsnTPtR+9xe3tj1sNtp8bjpoqj9cxRvEYKi5EEX+ssp moqg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@infradead.org header.s=casper.20170209 header.b="aX4qtRm/"; spf=pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-ext4-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id hp33si2943268ejc.701.2022.01.27.18.55.58; Thu, 27 Jan 2022 18:56:29 -0800 (PST) Received-SPF: pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@infradead.org header.s=casper.20170209 header.b="aX4qtRm/"; spf=pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-ext4-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231289AbiA0Nks (ORCPT + 99 others); Thu, 27 Jan 2022 08:40:48 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38004 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233541AbiA0Nkr (ORCPT ); Thu, 27 Jan 2022 08:40:47 -0500 Received: from casper.infradead.org (casper.infradead.org [IPv6:2001:8b0:10b:1236::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5EF5AC061714; Thu, 27 Jan 2022 05:40:47 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=casper.20170209; h=In-Reply-To:Content-Type:MIME-Version: References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=A7isk/AEvohb1CbSlaMW9h+R22AoDLQSD18pleOQ9gk=; b=aX4qtRm/T0//lNN04V2OMgxdqo 8ektTwVtWz21G87TzkQSTFKx7wdt7Rj95eTekvC+mB8/sn5aTfH5MaOnP8YNQM0BQ1P6/XzqjGAjF eDbKH1UmDhawMM+aRAVjauoh6MsVpDi1E5izKgBAMHQXp2zZ+qDbUgJVUSGB4FBq/3h6hk5w8Hann EsEXmTeG1QdTc7waSxqJiyS0nvRNvEiQL8V/eA7h6p+vIh/xnYCJ2cRdsVXoKebZAaxhNZ/jvWSZC LeD6kb+fdx0svTTpjCnGLMTkHF2wrk5Cp780oE0+jk/mTff7jQTyHA46aGJkequpYnWBsxb5Z1sIV QAqy1kLQ==; Received: from willy by casper.infradead.org with local (Exim 4.94.2 #2 (Red Hat Linux)) id 1nD512-005HO2-OX; Thu, 27 Jan 2022 13:40:44 +0000 Date: Thu, 27 Jan 2022 13:40:44 +0000 From: Matthew Wilcox To: Ritesh Harjani Cc: Maxim Blinov , linux-ext4@vger.kernel.org, linux-fsdevel Subject: Re: Help! How to delete an 8094-byte PATH? Message-ID: References: <20220127122039.45kxmnm3s7kflo6h@riteshh-domain> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20220127122039.45kxmnm3s7kflo6h@riteshh-domain> Precedence: bulk List-ID: X-Mailing-List: linux-ext4@vger.kernel.org On Thu, Jan 27, 2022 at 05:50:39PM +0530, Ritesh Harjani wrote: > On 22/01/27 07:06AM, Maxim Blinov wrote: > > $ for i in $(seq 999999); do echo "im $i levels deep"; cd confdir3; done; > > > > It then ran for a while, and eventually I got to the bottom: > > > > ``` > > ... > > im 892 levels deep > > im 893 levels deep > > im 894 levels deep > > im 895 levels deep > > im 896 levels deep > > bash: cd: confdir3: File name too long > > $ ls > > > > ``` > > > > So then, I `cd ../`, and `rmdir confdir3`, but even here, I get > > > > rmdir: failed to remove 'confdir3/': File name too long > > > > I would be very grateful if someone could please help suggest how I > > might get this infernal tower of directories off of my precious ext4 > > partition. > > > > I was thinking maybe there's some kind of magic "forget this directory > > inode ever existed" command, but I am out of my depth with filesystems. here's an idea: while true; do mv confdir3/confdir3 tmpd; rmdir confdir3; mv tmpd confdir3; done