- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: ls (is the result in bytes)
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-06-2009 08:55 AM
03-06-2009 08:55 AM
Re: ls (is the result in bytes)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-06-2009 08:56 AM
03-06-2009 08:56 AM
Re: ls (is the result in bytes)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-06-2009 08:58 AM
03-06-2009 08:58 AM
Re: ls (is the result in bytes)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-06-2009 09:13 AM
03-06-2009 09:13 AM
Re: ls (is the result in bytes)
Technically speaking now, that is incorrect.
The terminology has been changed by the IEEE in 1998, though it is not common knowledge.
The KB, MB, GB, etc. values are now technically base 10 values. 1 GB = 1000 bytes, 1 MB = 1000 KB, 1 GB = 1000 MB.
The base 2 (binary) values that most of us are used to using are now technically the kibibyte (KiB), mebibyte (MiB), gibibyte (GiB), tebibyte (TiB), etc. So 1024 bytes = 1 KiB, 1024 KiB = 1 MiB, 1024 MiB = 1 GiB, etc.
For more information see:
http://en.wikipedia.org/wiki/MiB
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-06-2009 09:20 AM
03-06-2009 09:20 AM
Re: ls (is the result in bytes)
# ls -l |awk '/^d/ {print $NF}'|xargs du -ks|awk '{printf "%6.2f %s\n",$1/1000,$2}'
will give the output in Mb
where
1MB = 1000Kb
Thanks to James and Patrick..
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-06-2009 09:32 AM
03-06-2009 09:32 AM
Re: ls (is the result in bytes)
as to the IEEE and the redefinition of KB, MB, and GB...IMHO, they should should have continued to use the old terminology w/ the old values, and used the new terminology w/ the "new" names (KiB, MiB....)....after all, "anything that changes form, fit or function requires a new part number"
but that's just me...and i'm grumpy
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-06-2009 09:45 AM
03-06-2009 09:45 AM
Re: ls (is the result in bytes)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-06-2009 01:05 PM
03-06-2009 01:05 PM
Re: ls (is the result in bytes)
http://hpux.connect.org.uk/hppd/hpux/Gnu/coreutils-7.1/
Then run ls from the coreutils bin directory with the -h (human-readbale) switch.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-06-2009 01:07 PM
03-06-2009 01:07 PM
Re: ls (is the result in bytes)
> Court: This is a really long thread for a simple fix. You could just install coreutils.
Agreed, but then Manuales wouldn't have learned so much as he has :-}
Regards!
...JRF...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-06-2009 01:31 PM
03-06-2009 01:31 PM
Re: ls (is the result in bytes)
from a linux "du" man page, regarding the "-h" or "--human-readable" option:
SIZE may be (or may be an integer optionally followed by) one of the following:
kB 1000, K 1024, MB 1000*1000,
M 1024*1024, and so on for....
G, T, P, E, Z, Y.
it's friday, it's getting late, and I don't want to think about Mib -vs- MB any more...
- « Previous
-
- 1
- 2
- Next »