X-Recipient: archive-cygwin AT delorie DOT com DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 1EAC03858424 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cygwin.com; s=default; t=1702882224; bh=VyQM3GPSWr49XkjDOcLAbTOazeiO3BmbI84TSN+mA4I=; h=Date:Subject:To:References:In-Reply-To:List-Id:List-Unsubscribe: List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To: From; b=g66IsQMiK5EPdEiNMeOgQHamUzGQjBe3smFHBydYQz8nxzrwp7t3Yig+ES2X0NIyk s1KzKyPPtSBz6Y1yn3inv9IXRBJ0bIVh2yXS1CJUc6pGUIqZiNuuwogebPtITJAo7t 4334Ct4zvFCBRpYnhmUd6nfLVmuElZRWTAQ94bso= X-Original-To: cygwin AT cygwin DOT com Delivered-To: cygwin AT cygwin DOT com DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org C918D3858424 ARC-Filter: OpenARC Filter v1.0.0 sourceware.org C918D3858424 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1702882187; cv=none; b=cmRSYX17O3v41OAFuAxyztQEnxCcVbuA2RcNChbDqX+1eRgU23z+ofcQ7BLeFb944G/c6F7j5cTgrL2zTIMp9MyrIhBrdhfYimtmjSj9wTwUfmBqRlQ0Q/VN33l97MSJJd9s6c7fQXNTJEUsytuueS8HwfUzJOQzMtzLwr+rUg4= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1702882187; c=relaxed/simple; bh=pQjmMM8KHpEMWJ/v42iVtO2SnurtRdyZjCzq0y1dUzI=; h=DKIM-Signature:Message-ID:Date:MIME-Version:Subject:To:From; b=ZY9mZuiVQR2VSd5JmEFv5X0Ap0GbLJ5QdtGuppFsa3PEYAMONuWORqrto8ksUCr8//SMTDrIW9RBP1084EEi/y+2NFH+z7Ib1+ZoEm/wbpfPs+T6+aS7alNtHfGZSuGgok0O3S9C53A6a+ujLejUC20SXkmo4FPtssKL0BZV6Jk= ARC-Authentication-Results: i=1; server2.sourceware.org X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1702882183; x=1703486983; h=content-transfer-encoding:in-reply-to:from:references:to :content-language:subject:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=6YE+q7NDmszJwYzdUH/t+VhcBrZaTb3TCLF7+JHz4YI=; b=l7G1CTZzXk6uCXn2IcnSBj4St06p/C/wGkxHsDSFqgFMFtYJqRdbAOZhHqT4Nbdhpb f3cu7/aEI7CulL33LOz38dQXepXSbRphCysOu0WFq0E1ixBFETnBlLJGeVKGnozk1lVU fdDAbXUM5i35ZaIQ+dGSpa5Q2FUi8tfTLCmU+ElPD/SeRbg27ltG4c+C8fHalZaGdZdr oNqHbOyEQYkl4R7wRZplDIecB0JtI9SwIHJpf5ct/2TGl7+UpoNUOnMf8K6dUu7WrHn6 XYwa/lvkN3cIGZ0dJ7M/lkNb7ifsarnHwxuNKhEtJuMvPkvNPigdgsIVDowpSUUU2+lr 4BJw== X-Gm-Message-State: AOJu0Yybhbhn0P4iHaU3ivCQgRk/lcwPZ4E+fWB9Rf/jb4cR0PIa7tCf FBEKtmSVCJVzQr+H7fZYk1Y85KrI/+Y= X-Google-Smtp-Source: AGHT+IGX+IP9AB8R72hbSeg7yQxn4yoxFHhe2nw2XxWS7kctfqtjmkRgTj6qkjfW2x4AAqp9RvLDdA== X-Received: by 2002:ac2:5969:0:b0:50e:3827:20c8 with SMTP id h9-20020ac25969000000b0050e382720c8mr556090lfp.55.1702882182943; Sun, 17 Dec 2023 22:49:42 -0800 (PST) Message-ID: <2dca96f8-77ab-4e14-a9a1-4a6f543ca16e@gmail.com> Date: Mon, 18 Dec 2023 07:49:42 +0100 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: Catastrophic Cygwin find . -ls, grep performance on samba share compared to WSL&Linux Content-Language: en-US To: cygwin AT cygwin DOT com References: In-Reply-To: X-Spam-Status: No, score=-1.4 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, FREEMAIL_FROM, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, TXREP, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: cygwin AT cygwin DOT com X-Mailman-Version: 2.1.30 List-Id: General Cygwin discussions and problem reports List-Archive: List-Post: List-Help: List-Subscribe: , From: Marco Atzeri via Cygwin Reply-To: Marco Atzeri Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset="us-ascii"; Format="flowed" Sender: "Cygwin" On 18/12/2023 07:22, Dan Shelton via Cygwin wrote: > On Wed, 6 Dec 2023 at 05:08, Dan Shelton wrote: >> >> Hello! >> I am unhappy to report a severe performance issue with find -ls, ls -R >> and grep -r, with Cygwin 3.4.9 and Cygwin 3.5.0 when samba shares are >> involved. >> >> Imagine a directory with 256 subdirs, and each has 256 files per >> subdir, all on a samba share, samba server is on Linux with tmpfs. >> >> mkdir dir1 >> for ((i=0;i<256;i++)) ; do >> mkdir "dir1/subdir$i" >> for ((j=0; j < 256;j++));do >> echo "j=$j" >"dir1/subdir$i/j$j.txt" >> done >> done >> >> Time comparisations then show a dramatic difference, Debian Linux >> accessing the samba share, WSL accessing the samba share, and Cygwin >> accessing the samba share: .. >> Why does that happen? > > It would be nice if someone from the Cygwin authors could assist me in > figuring out why this happens. > > My working theory is that the extra file and dir lookup calls are for > soft- and hardlink emulation for file systems which do not have soft- > or hardlinks? > If this is correct, then a fix might be to 1) determinate the > filesystem type (cached, per process lifetime in absence of > /etc/mnttab) and its boundaries (mount point, and whether other muont > points are below it) 2) Only use the emulation for FAT filesystems, > and for NTFS, REFS, SMBFS the native filesystem link is used. > > Help! > > Dan Is your cygserver running ? -- Problem reports: https://cygwin.com/problems.html FAQ: https://cygwin.com/faq/ Documentation: https://cygwin.com/docs.html Unsubscribe info: https://cygwin.com/ml/#unsubscribe-simple