Public bug reported: Description: On a fresh Kubuntu 24.04 installation using the Btrfs filesystem, the ls command fails to list all files and directories correctly after extracting tarballs. The find command, however, accurately shows the full count of files and directories. This issue was first observed with zstd compression enabled on Btrfs and persisted unchanged after switching to lzo compression as part of troubleshooting efforts. Steps to Reproduce: Install Kubuntu 24.04 with Btrfs, initially configured with compress=zstd (later changed to compress=lzo during troubleshooting).
Download a tarball, such as the Tor Browser tarball: bash wget https://www.torproject.org/dist/torbrowser/14.0.6/tor-browser- linux-x86_64-14.0.6.tar.xz Extract the tarball: bash tar -xJvf tor-browser-linux-x86_64-14.0.6.tar.xz Compare the outputs of the following commands: ls -l tor-browser/ | wc -l (undercounts files, e.g., shows ~20 instead of ~295). find tor-browser/ -type f | wc -l (shows the correct file count, e.g., ~295). Expected Behavior: The ls command should list all files and directories, matching the contents of the tarball and the output of the find command. Actual Behavior: The ls command lists significantly fewer files than actually exist (e.g., 20 instead of 295), while find correctly identifies all files. System Information: OS Version: Kubuntu 24.04 Kernel Version: 6.8.0-54-generic Btrfs Version: [Run btrfs --version in your terminal and insert the output here, e.g., v6.8] Mount Options: defaults,subvol=@,relatime,discard,compress=lzo (initially compress=zstd, switched to lzo with no effect) Additional Notes: The issue occurs consistently across multiple tarballs (e.g., SQLite, Tor Browser). No relevant errors appear in dmesg or journalctl related to Btrfs or file operations. Switching from zstd to lzo compression was attempted as a troubleshooting step but did not resolve the issue. ** Affects: linux (Ubuntu) Importance: Undecided Status: New -- You received this bug notification because you are a member of Kernel Packages, which is subscribed to linux in Ubuntu. https://bugs.launchpad.net/bugs/2100730 Title: ls Undercounts Files/Directories on btrfs Kubuntu 24.04 Status in linux package in Ubuntu: New Bug description: Description: On a fresh Kubuntu 24.04 installation using the Btrfs filesystem, the ls command fails to list all files and directories correctly after extracting tarballs. The find command, however, accurately shows the full count of files and directories. This issue was first observed with zstd compression enabled on Btrfs and persisted unchanged after switching to lzo compression as part of troubleshooting efforts. Steps to Reproduce: Install Kubuntu 24.04 with Btrfs, initially configured with compress=zstd (later changed to compress=lzo during troubleshooting). Download a tarball, such as the Tor Browser tarball: bash wget https://www.torproject.org/dist/torbrowser/14.0.6/tor-browser- linux-x86_64-14.0.6.tar.xz Extract the tarball: bash tar -xJvf tor-browser-linux-x86_64-14.0.6.tar.xz Compare the outputs of the following commands: ls -l tor-browser/ | wc -l (undercounts files, e.g., shows ~20 instead of ~295). find tor-browser/ -type f | wc -l (shows the correct file count, e.g., ~295). Expected Behavior: The ls command should list all files and directories, matching the contents of the tarball and the output of the find command. Actual Behavior: The ls command lists significantly fewer files than actually exist (e.g., 20 instead of 295), while find correctly identifies all files. System Information: OS Version: Kubuntu 24.04 Kernel Version: 6.8.0-54-generic Btrfs Version: [Run btrfs --version in your terminal and insert the output here, e.g., v6.8] Mount Options: defaults,subvol=@,relatime,discard,compress=lzo (initially compress=zstd, switched to lzo with no effect) Additional Notes: The issue occurs consistently across multiple tarballs (e.g., SQLite, Tor Browser). No relevant errors appear in dmesg or journalctl related to Btrfs or file operations. Switching from zstd to lzo compression was attempted as a troubleshooting step but did not resolve the issue. To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/linux/+bug/2100730/+subscriptions -- Mailing list: https://launchpad.net/~kernel-packages Post to : kernel-packages@lists.launchpad.net Unsubscribe : https://launchpad.net/~kernel-packages More help : https://help.launchpad.net/ListHelp