From owner-freebsd-current@freebsd.org Tue Oct 6 20:29:11 2020 Return-Path: Delivered-To: freebsd-current@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id DFCB743B173 for ; Tue, 6 Oct 2020 20:29:11 +0000 (UTC) (envelope-from grahamperrin@gmail.com) Received: from mail-wm1-x32d.google.com (mail-wm1-x32d.google.com [IPv6:2a00:1450:4864:20::32d]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "GTS CA 1O1" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4C5TZv19ZCz3df5 for ; Tue, 6 Oct 2020 20:29:10 +0000 (UTC) (envelope-from grahamperrin@gmail.com) Received: by mail-wm1-x32d.google.com with SMTP id 13so170611wmf.0 for ; Tue, 06 Oct 2020 13:29:10 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:to:from:subject:message-id:date:user-agent :mime-version:content-transfer-encoding:content-language; bh=7isIQ4zlBWO8zmH8RmfL5txGuvZVGb+afFGwPwEZPtY=; b=CSwkGWsqvpfyA0n8iZESlEsEU0vMJYNYewIT8SWFI66LvKWE2B7N48xAczTYbwn9bo jc5Iv11fa2I/PiectcSvYphchkl5ATSLRNC3G6KEjvn0xNXJf+5vH/XLQmAPJTbgv47O RiAPLSs/Z465FzGgJbEc4rh77LoEOZ8jyLXd0p0OEGuX8jVYClcVL6eibCyPtRN3aHmx vXmMhxRQwbqiRuUYr5sHFbZf6hobrtQf7gfr3+23rx03vZoTVMmzSRaMJCUmqfUZ/oEW 8H7w3QvNugGrcVu5mj2T6fs/udGxO5+Fk/iUEn/UMlxef8kHDezcMEsSldwwIzl7oG89 Ehyg== X-Gm-Message-State: AOAM533kPlplYtIbLtCEcs2JMH+PK22C7MWoSajNkVOPJEE4JlCMwdOA eVXHUqxfdZt+lA/MGz8OexMqrlna3nEOWg== X-Google-Smtp-Source: ABdhPJwufXf/6iPr4ESYwThJPCuN75FzPR6RksqVT/YjnVb6xMNez+TLYHSZxogfvmxcocTrGl2Cdw== X-Received: by 2002:a05:600c:2241:: with SMTP id a1mr6998635wmm.49.1602016148292; Tue, 06 Oct 2020 13:29:08 -0700 (PDT) Received: from [192.168.1.11] (79-66-147-78.dynamic.dsl.as9105.com. [79.66.147.78]) by smtp.gmail.com with ESMTPSA id u63sm5827975wmb.13.2020.10.06.13.29.07 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 06 Oct 2020 13:29:07 -0700 (PDT) To: freebsd-current@freebsd.org From: Graham Perrin Subject: zpool export: umount failed, device inexplicably busy Message-ID: Date: Tue, 6 Oct 2020 21:29:06 +0100 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:78.0) Gecko/20100101 Thunderbird/78.3.1 MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit Content-Language: en-US X-Rspamd-Queue-Id: 4C5TZv19ZCz3df5 X-Spamd-Bar: --- X-Spamd-Result: default: False [-3.33 / 15.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; R_SPF_ALLOW(-0.20)[+ip6:2a00:1450:4000::/36:c]; FREEMAIL_FROM(0.00)[gmail.com]; TO_DN_NONE(0.00)[]; RCVD_COUNT_THREE(0.00)[3]; DKIM_TRACE(0.00)[gmail.com:+]; DMARC_POLICY_ALLOW(-0.50)[gmail.com,none]; NEURAL_HAM_SHORT(-0.32)[-0.317]; RECEIVED_SPAMHAUS_PBL(0.00)[79.66.147.78:received]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; FREEMAIL_ENVFROM(0.00)[gmail.com]; MID_RHS_MATCH_FROM(0.00)[]; ASN(0.00)[asn:15169, ipnet:2a00:1450::/32, country:US]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-0.98)[-0.981]; R_DKIM_ALLOW(-0.20)[gmail.com:s=20161025]; FROM_HAS_DN(0.00)[]; DWL_DNSWL_NONE(0.00)[gmail.com:dkim]; TO_MATCH_ENVRCPT_ALL(0.00)[]; NEURAL_HAM_LONG(-1.04)[-1.036]; MIME_GOOD(-0.10)[text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-current@freebsd.org]; RCPT_COUNT_ONE(0.00)[1]; RCVD_IN_DNSWL_NONE(0.00)[2a00:1450:4864:20::32d:from]; RCVD_TLS_ALL(0.00)[]; MAILMAN_DEST(0.00)[freebsd-current] X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 06 Oct 2020 20:29:11 -0000 lsof finds no open file. How else might I tell why the device is busy? Mobile hard disk drive, USB. -- root@momh167-gjp4-8570p:~ # zpool export Transcend cannot unmount '/Volumes/t500': umount failed root@momh167-gjp4-8570p:~ # lsof /Volumes/t500 root@momh167-gjp4-8570p:~ # zpool export Transcend cannot unmount '/Volumes/t500': umount failed root@momh167-gjp4-8570p:~ # zpool export Transcend cannot unmount '/Volumes/t500': umount failed root@momh167-gjp4-8570p:~ # umount /Volumes/t500/ umount: unmount of /Volumes/t500 failed: Device busy root@momh167-gjp4-8570p:~ # lsof /Volumes/t500 root@momh167-gjp4-8570p:~ # zfs version zfs-0.8.0-1 zfs-kmod-0.8.0-1 root@momh167-gjp4-8570p:~ # zpool iostat Transcend 3               capacity     operations     bandwidth pool        alloc   free   read  write   read  write ----------  -----  -----  -----  -----  -----  ----- Transcend    126G   338G      0      0  3.29K  1.45K Transcend    126G   338G      0      0      0      0 Transcend    126G   338G      0      0      0      0 Transcend    126G   338G      0      0      0      0 Transcend    126G   338G      0      0      0      0 Transcend    126G   338G      0      0      0      0 ^C root@momh167-gjp4-8570p:~ # umount /Volumes/t500/ umount: unmount of /Volumes/t500 failed: Device busy root@momh167-gjp4-8570p:~ # ls -ahl /Volumes/t500 total 10 drwxr-xr-x  3 root          wheel            3B Sep  2 19:02 . drwxr-xr-x  4 root          wheel            4B Sep  5 09:15 .. drwxr-xr-x  6 grahamperrin  grahamperrin     6B Sep 11 17:54 VirtualBox root@momh167-gjp4-8570p:~ # zpool status Transcend   pool: Transcend  state: ONLINE   scan: scrub repaired 0B in 00:28:07 with 0 errors on Tue Oct  6 00:03:13 2020 config:         NAME        STATE     READ WRITE CKSUM         Transcend   ONLINE       0     0     0           da0p1     ONLINE       0     0     0 errors: No known data errors root@momh167-gjp4-8570p:~ # umount /Volumes/t500/ umount: unmount of /Volumes/t500 failed: Device busy root@momh167-gjp4-8570p:~ # lsof /Volumes/t500 root@momh167-gjp4-8570p:~ # date ; uname -v Tue Oct  6 21:20:17 BST 2020 FreeBSD 13.0-CURRENT #67 r366424: Sun Oct  4 19:54:32 BST 2020 root@momh167-gjp4-8570p:/usr/obj/usr/src/amd64.amd64/sys/GENERIC-NODEBUG root@momh167-gjp4-8570p:~ # ls /dev/da* /dev/da0        /dev/da0p1 root@momh167-gjp4-8570p:~ # zfs get all Transcend Transcend/VirtualBox NAME                  PROPERTY VALUE                     SOURCE Transcend             type filesystem                - Transcend             creation              Wed Sep  2 18:31 2020     - Transcend             used 126G                      - Transcend             available 324G                      - Transcend             referenced 126G                      - Transcend             compressratio 1.66x                     - Transcend             mounted yes                       - Transcend             quota none                      default Transcend             reservation none                      default Transcend             recordsize 128K                      default Transcend             mountpoint /Volumes/t500             local Transcend             sharenfs off                       default Transcend             checksum on                        default Transcend             compression zstd                      local Transcend             atime on                        default Transcend             devices on                        default Transcend             exec on                        default Transcend             setuid on                        default Transcend             readonly off                       default Transcend             jailed off                       default Transcend             snapdir hidden                    default Transcend             aclmode discard                   default Transcend             aclinherit restricted                default Transcend             createtxg 1                         - Transcend             canmount on                        default Transcend             xattr on                        default Transcend             copies 1                         default Transcend             version 5                         - Transcend             utf8only off                       - Transcend             normalization none                      - Transcend             casesensitivity sensitive                 - Transcend             vscan off                       default Transcend             nbmand off                       default Transcend             sharesmb off                       default Transcend             refquota none                      default Transcend             refreservation none                      default Transcend             guid 6806553549477274436       - Transcend             primarycache all                       default Transcend             secondarycache all                       default Transcend             usedbysnapshots 0B                        - Transcend             usedbydataset 126G                      - Transcend             usedbychildren 47.2M                     - Transcend             usedbyrefreservation 0B                        - Transcend             logbias latency                   default Transcend             objsetid 54                        - Transcend             dedup off                       default Transcend             mlslabel none                      default Transcend             sync standard                  default Transcend             dnodesize legacy                    default Transcend             refcompressratio 1.66x                     - Transcend             written 126G                      - Transcend             logicalused 210G                      - Transcend             logicalreferenced 210G                      - Transcend             volmode default                   default Transcend             filesystem_limit none                      default Transcend             snapshot_limit none                      default Transcend             filesystem_count none                      default Transcend             snapshot_count none                      default Transcend             snapdev hidden                    default Transcend             context none                      default Transcend             fscontext none                      default Transcend             defcontext none                      default Transcend             rootcontext none                      default Transcend             relatime off                       default Transcend             redundant_metadata all                       default Transcend             overlay on                        default Transcend             encryption off                       default Transcend             keylocation none                      default Transcend             keyformat none                      default Transcend             pbkdf2iters 0                         default Transcend             special_small_blocks 0                         default Transcend/VirtualBox  type filesystem                - Transcend/VirtualBox  creation              Wed Sep  2 19:02 2020     - Transcend/VirtualBox  used 200K                      - Transcend/VirtualBox  available 324G                      - Transcend/VirtualBox  referenced 200K                      - Transcend/VirtualBox  compressratio 1.00x                     - Transcend/VirtualBox  mounted no                        - Transcend/VirtualBox  quota none                      default Transcend/VirtualBox  reservation none                      default Transcend/VirtualBox  recordsize 128K                      default Transcend/VirtualBox  mountpoint /Volumes/t500/VirtualBox  inherited from Transcend Transcend/VirtualBox  sharenfs off                       default Transcend/VirtualBox  checksum on                        default Transcend/VirtualBox  compression zstd                      inherited from Transcend Transcend/VirtualBox  atime off                       local Transcend/VirtualBox  devices on                        default Transcend/VirtualBox  exec on                        default Transcend/VirtualBox  setuid on                        default Transcend/VirtualBox  readonly off                       default Transcend/VirtualBox  jailed off                       default Transcend/VirtualBox  snapdir hidden                    default Transcend/VirtualBox  aclmode discard                   default Transcend/VirtualBox  aclinherit restricted                default Transcend/VirtualBox  createtxg 375                       - Transcend/VirtualBox  canmount on                        default Transcend/VirtualBox  xattr on                        default Transcend/VirtualBox  copies 1                         default Transcend/VirtualBox  version 5                         - Transcend/VirtualBox  utf8only off                       - Transcend/VirtualBox  normalization none                      - Transcend/VirtualBox  casesensitivity sensitive                 - Transcend/VirtualBox  vscan off                       default Transcend/VirtualBox  nbmand off                       default Transcend/VirtualBox  sharesmb off                       default Transcend/VirtualBox  refquota none                      default Transcend/VirtualBox  refreservation none                      default Transcend/VirtualBox  guid 11240822048258000557      - Transcend/VirtualBox  primarycache all                       default Transcend/VirtualBox  secondarycache all                       default Transcend/VirtualBox  usedbysnapshots 0B                        - Transcend/VirtualBox  usedbydataset 200K                      - Transcend/VirtualBox  usedbychildren 0B                        - Transcend/VirtualBox  usedbyrefreservation 0B                        - Transcend/VirtualBox  logbias latency                   default Transcend/VirtualBox  objsetid 76                        - Transcend/VirtualBox  dedup off                       default Transcend/VirtualBox  mlslabel none                      default Transcend/VirtualBox  sync standard                  default Transcend/VirtualBox  dnodesize legacy                    default Transcend/VirtualBox  refcompressratio 1.00x                     - Transcend/VirtualBox  written 200K                      - Transcend/VirtualBox  logicalused 49.5K                     - Transcend/VirtualBox  logicalreferenced 49.5K                     - Transcend/VirtualBox  volmode default                   default Transcend/VirtualBox  filesystem_limit none                      default Transcend/VirtualBox  snapshot_limit none                      default Transcend/VirtualBox  filesystem_count none                      default Transcend/VirtualBox  snapshot_count none                      default Transcend/VirtualBox  snapdev hidden                    default Transcend/VirtualBox  context none                      default Transcend/VirtualBox  fscontext none                      default Transcend/VirtualBox  defcontext none                      default Transcend/VirtualBox  rootcontext none                      default Transcend/VirtualBox  relatime off                       default Transcend/VirtualBox  redundant_metadata all                       default Transcend/VirtualBox  overlay on                        default Transcend/VirtualBox  encryption aes-256-gcm               - Transcend/VirtualBox  keylocation prompt                    local Transcend/VirtualBox  keyformat passphrase                - Transcend/VirtualBox  pbkdf2iters 350000                    - Transcend/VirtualBox  encryptionroot Transcend/VirtualBox      - Transcend/VirtualBox  keystatus unavailable               - Transcend/VirtualBox  special_small_blocks 0                         default root@momh167-gjp4-8570p:~ # zpool get all Transcend NAME       PROPERTY VALUE                          SOURCE Transcend  size 464G                           - Transcend  capacity 27%                            - Transcend  altroot -                              default Transcend  health ONLINE                         - Transcend  guid 8076233369858608335            - Transcend  version -                              default Transcend  bootfs -                              default Transcend  delegation on                             default Transcend  autoreplace off                            default Transcend  cachefile -                              default Transcend  failmode wait                           default Transcend  listsnapshots off                            default Transcend  autoexpand off                            default Transcend  dedupratio 1.00x                          - Transcend  free 338G                           - Transcend  allocated 126G                           - Transcend  readonly off                            - Transcend  ashift 0                              default Transcend  comment -                              default Transcend  expandsize -                              - Transcend  freeing 0                              - Transcend  fragmentation 12%                            - Transcend  leaked 0                              - Transcend  multihost off                            default Transcend  checkpoint -                              - Transcend  load_guid 15610592478404149099           - Transcend  autotrim off                            default Transcend  feature@async_destroy enabled                        local Transcend  feature@empty_bpobj active                         local Transcend  feature@lz4_compress active                         local Transcend  feature@multi_vdev_crash_dump enabled                        local Transcend  feature@spacemap_histogram active                         local Transcend  feature@enabled_txg active                         local Transcend  feature@hole_birth active                         local Transcend  feature@extensible_dataset active                         local Transcend  feature@embedded_data active                         local Transcend  feature@bookmarks enabled                        local Transcend  feature@filesystem_limits enabled                        local Transcend  feature@large_blocks enabled                        local Transcend  feature@large_dnode enabled                        local Transcend  feature@sha512 enabled                        local Transcend  feature@skein enabled                        local Transcend  feature@userobj_accounting active                         local Transcend  feature@encryption active                         local Transcend  feature@project_quota active                         local Transcend  feature@device_removal enabled                        local Transcend  feature@obsolete_counts enabled                        local Transcend  feature@zpool_checkpoint enabled                        local Transcend  feature@spacemap_v2 active                         local Transcend  feature@allocation_classes enabled                        local Transcend  feature@resilver_defer enabled                        local Transcend  feature@bookmark_v2 enabled                        local Transcend  feature@redaction_bookmarks enabled                        local Transcend  feature@redacted_datasets enabled                        local Transcend  feature@bookmark_written enabled                        local Transcend  feature@log_spacemap active                         local Transcend  feature@livelist enabled                        local Transcend  feature@device_rebuild enabled                        local Transcend  feature@zstd_compress active                         local root@momh167-gjp4-8570p:~ #