From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from relay.hostedemail.com (smtprelay0012.hostedemail.com [216.40.44.12]) by sourceware.org (Postfix) with ESMTPS id 9C4813858D20 for ; Mon, 29 Jan 2024 08:32:18 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 9C4813858D20 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=SystematicSW.ab.ca Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=SystematicSW.ab.ca ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 9C4813858D20 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=216.40.44.12 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1706517141; cv=none; b=FezVKeMSauQadSO2i7rrlFQiHpPhB+ZxLfxsFbVxtvx5nweSjzgnD+74YMmm8g6XiG27F91b43H/XtTozwa6XJCXWUsE1cMW2gELU+HBAt/6wqzc/WGGI1aaBvCmRoaoDZQZLl2opI1QOnCJiuxnimuI7VUbHrHVOAiVKdmTRfo= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1706517141; c=relaxed/simple; bh=9TzPJBTwtVxctuUydaIeQsObNAGAKbu3zxU6bM+od94=; h=Message-ID:Date:MIME-Version:Subject:To:From; b=kvvaem7rWfUwKp7eMKUcQha/Ae95zCzxcgVa3BMIRnE3muFfg0lo3ceYAaXrlD/Cxp32Oei0p/UmyHD3G1WDqHFD6dXPDzkgwOQn10ePoCuqOHdkIRWX6bN2OaDWNWoHLShLWWXI12QaU67l7GKwPFWKDXenKvGQawVDj2dT0kA= ARC-Authentication-Results: i=1; server2.sourceware.org Received: from omf07.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay10.hostedemail.com (Postfix) with ESMTP id 3F6E7C01CF for ; Mon, 29 Jan 2024 08:32:17 +0000 (UTC) Received: from [HIDDEN] (Authenticated sender: Brian.Inglis@SystematicSW.ab.ca) by omf07.hostedemail.com (Postfix) with ESMTPA id A7D8B2002C for ; Mon, 29 Jan 2024 08:32:14 +0000 (UTC) Message-ID: Date: Mon, 29 Jan 2024 01:32:13 -0700 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Reply-To: cygwin@cygwin.com Subject: Re: /usr/bin/fallocate -v -d -l 2 myfile takes forever Content-Language: en-CA To: cygwin@cygwin.com References: From: Brian Inglis Organization: Systematic Software In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-Rspamd-Queue-Id: A7D8B2002C X-Spam-Status: No, score=-2.3 required=5.0 tests=BAYES_00,KAM_DMARC_STATUS,RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H3,RCVD_IN_MSPIKE_WL,SPF_HELO_PASS,SPF_PASS,TXREP,T_SCC_BODY_TEXT_LINE,UNPARSEABLE_RELAY autolearn=ham autolearn_force=no version=3.4.6 X-Stat-Signature: dwmaok6i8kgt86u1a7gzxa35icge3sh7 X-Rspamd-Server: rspamout05 X-Session-Marker: 427269616E2E496E676C69734053797374656D6174696353572E61622E6361 X-Session-ID: U2FsdGVkX19YgMGi8d5q9Jmb2MIFA+SBZ1/A51sAg7w= X-HE-Tag: 1706517134-449299 X-HE-Meta: U2FsdGVkX1/aRleDFItr9w7pTslhrkDVIbnkFqqeyXao4QPsQvS+zNbHQfy8DvbCwZfRIdGOU4zWzNC3PDEU/cXN8MFDxtd4urBd/kPC7zSHpyLudRs3GI8oFiTJyR07+2vnwQ/1ZE0udtEuN6MVtUGOc3y5yYGxYpsrT6tJFQewHXlw+WciTEzPpGZYu0OunrcHFUGTsvmzrrK+bJRZQz0YIL1Rue28vLfOdAzswJV3nYEz8u9pMypQj4xjxvZHGqbGPskw5uxmV8UFAu8t2JLKN2W1NUfsYHeJ2Ip+X19VBgmtCpBhc1sBtya25ZpLSgv4SNxFyMhQvOeJEzMB+afxH5ef/oKoz4asM/qWTFvVEn2Tn/0pHSaQNlmSelCZ X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: On 2024-01-28 23:44, Cedric Blancher via Cygwin wrote: > rm -f myfile > touch myfile > /usr/bin/fallocate -v -d -l myfile takes forever with latest Cygwin 3.5 It takes much longer without Cygwin 3.5! Your fallocate(1) option -l has no length numeric argument and no -o offset numeric argument to specify the start of the range. Takes no time on my system when used properly: $ uname -srvmo CYGWIN_NT-10.0-19045 3.5.0-0.613.g2c5433e5da82.x86_64 2024-01-24 15:14 UTC x86_64 Cygwin $ smartctl -i /dev/sda smartctl 7.4 2023-08-01 r5530 [x86_64-pc-cygwin-w10-22H2] (cygwin-7.4-1) Copyright (C) 2002-23, Bruce Allen, Christian Franke, www.smartmontools.org Warning: Limited functionality due to missing admin rights === START OF INFORMATION SECTION === Model Family: Seagate BarraCuda 3.5 (CMR) Device Model: ST1000DM010-2EP102 Serial Number: W9AAWPXN Firmware Version: CC43 Device is: In smartctl database 7.3/5528 ATA Version is: [No Information Found] Local Time is: Mon Jan 29 01:11:59 2024 MST SMART support is: Available - device has SMART capability. Enabled status cached by OS, trying SMART RETURN STATUS cmd. SMART support is: Enabled $ rm -f myfile; touch myfile; llgo myfile removed 'myfile' -rw-r--r-- 1 0 Jan 29 00:50 myfile $ time fallocate -v -o 0 -l 64MiB myfile; llgo myfile real 0m0.049s user 0m0.000s sys 0m0.015s -rw-r--r-- 1 64M Jan 29 00:50 myfile $ time fallocate -v -o 0 -l 64MiB -d myfile; llgo myfile myfile: 64 MiB (67108864 bytes) converted to sparse holes. real 0m0.146s user 0m0.015s sys 0m0.078s -rw-r--r-- 1 64M Jan 29 00:50 myfile Now perhaps the fallocate(1) design, option checking, diagnostics, defaults, and output, could use some work: using SI multipliers for data sizes (see ls --si!) Perhaps show some useful commands and output that demonstrate your claim, including the actual test release used from `uname -srvmo` and provide some information about your drive (type, speed, size) and system, like output from `cygcheck -hrsv` attached as a text file? -- Take care. Thanks, Brian Inglis Calgary, Alberta, Canada La perfection est atteinte Perfection is achieved non pas lorsqu'il n'y a plus rien à ajouter not when there is no more to add mais lorsqu'il n'y a plus rien à retirer but when there is no more to cut -- Antoine de Saint-Exupéry