From unknown Sat Aug 16 18:47:31 2025 X-Loop: help-debbugs@gnu.org Subject: bug#13902: BUG : Option -k / --kibibytes no longer works with ls Resent-From: Sebastien Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-CC: bug-coreutils@gnu.org Resent-Date: Fri, 08 Mar 2013 08:12:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 13902 X-GNU-PR-Package: coreutils X-GNU-PR-Keywords: To: 13902@debbugs.gnu.org X-Debbugs-Original-To: bug-coreutils@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.136273029525019 (code B ref -1); Fri, 08 Mar 2013 08:12:01 +0000 Received: (at submit) by debbugs.gnu.org; 8 Mar 2013 08:11:35 +0000 Received: from localhost ([127.0.0.1]:38059 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UDsOp-0006VP-6b for submit@debbugs.gnu.org; Fri, 08 Mar 2013 03:11:35 -0500 Received: from eggs.gnu.org ([208.118.235.92]:49812) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UDsNm-0006Tf-Mo for submit@debbugs.gnu.org; Fri, 08 Mar 2013 03:10:31 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UDsN2-0008Tb-FI for submit@debbugs.gnu.org; Fri, 08 Mar 2013 03:09:45 -0500 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-2.5 required=5.0 tests=BAYES_00,FREEMAIL_FROM, RCVD_IN_DNSWL_NONE, RP_MATCHES_RCVD autolearn=unavailable version=3.3.2 Received: from lists.gnu.org ([208.118.235.17]:45545) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UDsN2-0008TX-Cb for submit@debbugs.gnu.org; Fri, 08 Mar 2013 03:09:40 -0500 Received: from eggs.gnu.org ([208.118.235.92]:32924) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UDsMy-0000cN-7q for bug-coreutils@gnu.org; Fri, 08 Mar 2013 03:09:40 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UDsMt-0008Rg-Hs for bug-coreutils@gnu.org; Fri, 08 Mar 2013 03:09:36 -0500 Received: from smtp05.smtpout.orange.fr ([80.12.242.127]:30478 helo=smtp.smtpout.orange.fr) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UDsMt-0008RT-Bd for bug-coreutils@gnu.org; Fri, 08 Mar 2013 03:09:31 -0500 Received: from [192.168.1.13] ([90.35.67.31]) by mwinf5d40 with ME id 8w9Q1l00P0gUCgy03w9Up5; Fri, 08 Mar 2013 09:09:29 +0100 Message-ID: <51399CB4.5030209@orange.fr> Date: Fri, 08 Mar 2013 09:09:24 +0100 From: Sebastien User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130219 Thunderbird/17.0.3 MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 208.118.235.17 X-Spam-Score: -4.2 (----) X-Mailman-Approved-At: Fri, 08 Mar 2013 03:11:30 -0500 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -6.9 (------) Hi, This is to tell you that option -k (--kibibytes) no longer works with the ls command. Sample output: $ ls -l total 81644 drwxrwxr-x. 23 root root 4096 Dec 3 20:22 linux-3.7-rc8 -rw-rw-r--. 1 seb seb 83581254 Dec 5 21:26 linux-3.7-rc8.tar.bz2 drwx------. 2 root root 16384 May 9 2012 lost+found $ ls -lk total 81644 drwxrwxr-x. 23 root root 4096 Dec 3 20:22 linux-3.7-rc8 -rw-rw-r--. 1 seb seb 83581254 Dec 5 21:26 linux-3.7-rc8.tar.bz2 drwx------. 2 root root 16384 May 9 2012 lost+found Tested on: Fedora 18 "Spherical Cow" with ls (GNU coreutils) 8.17. Regards, -- Sebastien GODARD sebastien.godard@orange.fr From debbugs-submit-bounces@debbugs.gnu.org Fri Mar 08 08:07:11 2013 Received: (at control) by debbugs.gnu.org; 8 Mar 2013 13:07:11 +0000 Received: from localhost ([127.0.0.1]:38463 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UDx0t-0005wl-1W for submit@debbugs.gnu.org; Fri, 08 Mar 2013 08:07:11 -0500 Received: from mx1.redhat.com ([209.132.183.28]:39189) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UDx0j-0005vu-D4; Fri, 08 Mar 2013 08:07:02 -0500 Received: from int-mx11.intmail.prod.int.phx2.redhat.com (int-mx11.intmail.prod.int.phx2.redhat.com [10.5.11.24]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id r28D6IbS013966 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Fri, 8 Mar 2013 08:06:18 -0500 Received: from [10.3.113.126] (ovpn-113-126.phx2.redhat.com [10.3.113.126]) by int-mx11.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id r28D6HNl005605; Fri, 8 Mar 2013 08:06:18 -0500 Message-ID: <5139E249.5090704@redhat.com> Date: Fri, 08 Mar 2013 06:06:17 -0700 From: Eric Blake Organization: Red Hat, Inc. User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130219 Thunderbird/17.0.3 MIME-Version: 1.0 To: Sebastien Subject: Re: bug#13902: BUG : Option -k / --kibibytes no longer works with ls References: <51399CB4.5030209@orange.fr> In-Reply-To: <51399CB4.5030209@orange.fr> X-Enigmail-Version: 1.5.1 OpenPGP: url=http://people.redhat.com/eblake/eblake.gpg Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="----enig2KFCXDPQPOCILURIUFHVM" X-Scanned-By: MIMEDefang 2.68 on 10.5.11.24 X-Spam-Score: -5.6 (-----) X-Debbugs-Envelope-To: control Cc: 13902-done@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -7.5 (-------) This is an OpenPGP/MIME signed message (RFC 4880 and 3156) ------enig2KFCXDPQPOCILURIUFHVM Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable tag 13902 notabug thanks On 03/08/2013 01:09 AM, Sebastien wrote: > Hi, >=20 > This is to tell you that option -k (--kibibytes) no longer works with > the ls command. Thanks for the report. However, according to NEWS, this was a bug fix of coreutils 8.15: ls's -k option no longer affects how ls -l outputs file sizes. It now affects only the per-directory block counts written by -l, and the sizes written by -s. This is for compatibility with BSD and with POSIX 2008. Because -k is no longer equivalent to --block-size=3D1KiB, a new long option --kibibyte stands for -k. [bug introduced in coreutils-4.5.4] >=20 > Sample output: >=20 > $ ls -l > total 81644 > drwxrwxr-x. 23 root root 4096 Dec 3 20:22 linux-3.7-rc8 > -rw-rw-r--. 1 seb seb 83581254 Dec 5 21:26 linux-3.7-rc8.tar.bz2 > drwx------. 2 root root 16384 May 9 2012 lost+found >=20 > $ ls -lk > total 81644 > drwxrwxr-x. 23 root root 4096 Dec 3 20:22 linux-3.7-rc8 > -rw-rw-r--. 1 seb seb 83581254 Dec 5 21:26 linux-3.7-rc8.tar.bz2 > drwx------. 2 root root 16384 May 9 2012 lost+found This is the correct behavior required by POSIX when using 'ls -k'. You were relying on an alternate behavior, where it was a bug that -k exposed the alternate behavior; but that alternate behavior is still available to you if you use the proper spelling: ls -l --block-size=3Dk Therefore, I'm closing this as not a bug. Feel free to add further comments or questions. --=20 Eric Blake eblake redhat com +1-919-301-3266 Libvirt virtualization library http://libvirt.org ------enig2KFCXDPQPOCILURIUFHVM Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.13 (GNU/Linux) Comment: Public key at http://people.redhat.com/eblake/eblake.gpg Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/ iQEcBAEBCAAGBQJROeJJAAoJEKeha0olJ0NqzRoIAKXsAzFiNMlUjciFgdratWLT 8kaAdojTBZpD9vhPC9sDcIiQm8l/P4PZCo20wsDuBsZvcKK0eOzEmyRjbI3Na2ex aAMvcxasktvN02lXAZII30cwDZxV2NF+6fTGuxmpCMHltpe5xcZCYVqzwRd4KDoV n8LAjN1v9UGslEcS/Gpcs328y6Rt02V/AMne0jYSiQL9o1zKEprvk3RGqYNg+EbN 0f0KsVfBdB2BPn4ERgInA/L/6PLtV2qjmRJfb9lBseNPF4pCu623PqjSO68quvaG VuGRpWDPjzWWsMqd3QhvjjtzXDa/OIlkzij7Fq5acK850VE4qyLHcSyC4YORFs0= =NDVk -----END PGP SIGNATURE----- ------enig2KFCXDPQPOCILURIUFHVM-- From unknown Sat Aug 16 18:47:31 2025 MIME-Version: 1.0 X-Mailer: MIME-tools 5.428 (Entity 5.428) X-Loop: help-debbugs@gnu.org From: help-debbugs@gnu.org (GNU bug Tracking System) To: Sebastien Subject: bug#13902: closed (Re: bug#13902: BUG : Option -k / --kibibytes no longer works with ls) Message-ID: References: <5139E249.5090704@redhat.com> <51399CB4.5030209@orange.fr> X-Gnu-PR-Message: they-closed 13902 X-Gnu-PR-Package: coreutils X-Gnu-PR-Keywords: notabug Reply-To: 13902@debbugs.gnu.org Date: Fri, 08 Mar 2013 13:08:02 +0000 Content-Type: multipart/mixed; boundary="----------=_1362748082-22944-1" This is a multi-part message in MIME format... ------------=_1362748082-22944-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Your bug report #13902: BUG : Option -k / --kibibytes no longer works with ls which was filed against the coreutils package, has been closed. The explanation is attached below, along with your original report. If you require more details, please reply to 13902@debbugs.gnu.org. --=20 13902: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D13902 GNU Bug Tracking System Contact help-debbugs@gnu.org with problems ------------=_1362748082-22944-1 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at 13902-done) by debbugs.gnu.org; 8 Mar 2013 13:07:07 +0000 Received: from localhost ([127.0.0.1]:38461 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UDx0o-0005we-UU for submit@debbugs.gnu.org; Fri, 08 Mar 2013 08:07:06 -0500 Received: from mx1.redhat.com ([209.132.183.28]:39189) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UDx0j-0005vu-D4; Fri, 08 Mar 2013 08:07:02 -0500 Received: from int-mx11.intmail.prod.int.phx2.redhat.com (int-mx11.intmail.prod.int.phx2.redhat.com [10.5.11.24]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id r28D6IbS013966 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Fri, 8 Mar 2013 08:06:18 -0500 Received: from [10.3.113.126] (ovpn-113-126.phx2.redhat.com [10.3.113.126]) by int-mx11.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id r28D6HNl005605; Fri, 8 Mar 2013 08:06:18 -0500 Message-ID: <5139E249.5090704@redhat.com> Date: Fri, 08 Mar 2013 06:06:17 -0700 From: Eric Blake Organization: Red Hat, Inc. User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130219 Thunderbird/17.0.3 MIME-Version: 1.0 To: Sebastien Subject: Re: bug#13902: BUG : Option -k / --kibibytes no longer works with ls References: <51399CB4.5030209@orange.fr> In-Reply-To: <51399CB4.5030209@orange.fr> X-Enigmail-Version: 1.5.1 OpenPGP: url=http://people.redhat.com/eblake/eblake.gpg Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="----enig2KFCXDPQPOCILURIUFHVM" X-Scanned-By: MIMEDefang 2.68 on 10.5.11.24 X-Spam-Score: -5.6 (-----) X-Debbugs-Envelope-To: 13902-done Cc: 13902-done@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -7.5 (-------) This is an OpenPGP/MIME signed message (RFC 4880 and 3156) ------enig2KFCXDPQPOCILURIUFHVM Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable tag 13902 notabug thanks On 03/08/2013 01:09 AM, Sebastien wrote: > Hi, >=20 > This is to tell you that option -k (--kibibytes) no longer works with > the ls command. Thanks for the report. However, according to NEWS, this was a bug fix of coreutils 8.15: ls's -k option no longer affects how ls -l outputs file sizes. It now affects only the per-directory block counts written by -l, and the sizes written by -s. This is for compatibility with BSD and with POSIX 2008. Because -k is no longer equivalent to --block-size=3D1KiB, a new long option --kibibyte stands for -k. [bug introduced in coreutils-4.5.4] >=20 > Sample output: >=20 > $ ls -l > total 81644 > drwxrwxr-x. 23 root root 4096 Dec 3 20:22 linux-3.7-rc8 > -rw-rw-r--. 1 seb seb 83581254 Dec 5 21:26 linux-3.7-rc8.tar.bz2 > drwx------. 2 root root 16384 May 9 2012 lost+found >=20 > $ ls -lk > total 81644 > drwxrwxr-x. 23 root root 4096 Dec 3 20:22 linux-3.7-rc8 > -rw-rw-r--. 1 seb seb 83581254 Dec 5 21:26 linux-3.7-rc8.tar.bz2 > drwx------. 2 root root 16384 May 9 2012 lost+found This is the correct behavior required by POSIX when using 'ls -k'. You were relying on an alternate behavior, where it was a bug that -k exposed the alternate behavior; but that alternate behavior is still available to you if you use the proper spelling: ls -l --block-size=3Dk Therefore, I'm closing this as not a bug. Feel free to add further comments or questions. --=20 Eric Blake eblake redhat com +1-919-301-3266 Libvirt virtualization library http://libvirt.org ------enig2KFCXDPQPOCILURIUFHVM Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.13 (GNU/Linux) Comment: Public key at http://people.redhat.com/eblake/eblake.gpg Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/ iQEcBAEBCAAGBQJROeJJAAoJEKeha0olJ0NqzRoIAKXsAzFiNMlUjciFgdratWLT 8kaAdojTBZpD9vhPC9sDcIiQm8l/P4PZCo20wsDuBsZvcKK0eOzEmyRjbI3Na2ex aAMvcxasktvN02lXAZII30cwDZxV2NF+6fTGuxmpCMHltpe5xcZCYVqzwRd4KDoV n8LAjN1v9UGslEcS/Gpcs328y6Rt02V/AMne0jYSiQL9o1zKEprvk3RGqYNg+EbN 0f0KsVfBdB2BPn4ERgInA/L/6PLtV2qjmRJfb9lBseNPF4pCu623PqjSO68quvaG VuGRpWDPjzWWsMqd3QhvjjtzXDa/OIlkzij7Fq5acK850VE4qyLHcSyC4YORFs0= =NDVk -----END PGP SIGNATURE----- ------enig2KFCXDPQPOCILURIUFHVM-- ------------=_1362748082-22944-1 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at submit) by debbugs.gnu.org; 8 Mar 2013 08:11:35 +0000 Received: from localhost ([127.0.0.1]:38059 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UDsOp-0006VP-6b for submit@debbugs.gnu.org; Fri, 08 Mar 2013 03:11:35 -0500 Received: from eggs.gnu.org ([208.118.235.92]:49812) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UDsNm-0006Tf-Mo for submit@debbugs.gnu.org; Fri, 08 Mar 2013 03:10:31 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UDsN2-0008Tb-FI for submit@debbugs.gnu.org; Fri, 08 Mar 2013 03:09:45 -0500 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-2.5 required=5.0 tests=BAYES_00,FREEMAIL_FROM, RCVD_IN_DNSWL_NONE, RP_MATCHES_RCVD autolearn=unavailable version=3.3.2 Received: from lists.gnu.org ([208.118.235.17]:45545) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UDsN2-0008TX-Cb for submit@debbugs.gnu.org; Fri, 08 Mar 2013 03:09:40 -0500 Received: from eggs.gnu.org ([208.118.235.92]:32924) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UDsMy-0000cN-7q for bug-coreutils@gnu.org; Fri, 08 Mar 2013 03:09:40 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UDsMt-0008Rg-Hs for bug-coreutils@gnu.org; Fri, 08 Mar 2013 03:09:36 -0500 Received: from smtp05.smtpout.orange.fr ([80.12.242.127]:30478 helo=smtp.smtpout.orange.fr) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UDsMt-0008RT-Bd for bug-coreutils@gnu.org; Fri, 08 Mar 2013 03:09:31 -0500 Received: from [192.168.1.13] ([90.35.67.31]) by mwinf5d40 with ME id 8w9Q1l00P0gUCgy03w9Up5; Fri, 08 Mar 2013 09:09:29 +0100 Message-ID: <51399CB4.5030209@orange.fr> Date: Fri, 08 Mar 2013 09:09:24 +0100 From: Sebastien User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130219 Thunderbird/17.0.3 MIME-Version: 1.0 To: bug-coreutils@gnu.org Subject: BUG : Option -k / --kibibytes no longer works with ls Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 208.118.235.17 X-Spam-Score: -4.2 (----) X-Debbugs-Envelope-To: submit X-Mailman-Approved-At: Fri, 08 Mar 2013 03:11:30 -0500 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -6.9 (------) Hi, This is to tell you that option -k (--kibibytes) no longer works with the ls command. Sample output: $ ls -l total 81644 drwxrwxr-x. 23 root root 4096 Dec 3 20:22 linux-3.7-rc8 -rw-rw-r--. 1 seb seb 83581254 Dec 5 21:26 linux-3.7-rc8.tar.bz2 drwx------. 2 root root 16384 May 9 2012 lost+found $ ls -lk total 81644 drwxrwxr-x. 23 root root 4096 Dec 3 20:22 linux-3.7-rc8 -rw-rw-r--. 1 seb seb 83581254 Dec 5 21:26 linux-3.7-rc8.tar.bz2 drwx------. 2 root root 16384 May 9 2012 lost+found Tested on: Fedora 18 "Spherical Cow" with ls (GNU coreutils) 8.17. Regards, -- Sebastien GODARD sebastien.godard@orange.fr ------------=_1362748082-22944-1--