[Proposal for] an article on different commands that start ls such as ls, lscpu, lsmem, lsblk and such. The focus is the commands that start with ls many are hardware related and provide views into the system. Give a little about each command and what you can do or get from the use of it.
https://discussion.fedoraproject.org/t/article-proposal-the-power-of-ls-type-commands/33487
Metadata Update from @rlengland: - Issue tagged with: article, needs-image
This issue is a replacement for Pagure article #394. Same title, same description
Metadata Update from @rlengland: - Custom field preview-link adjusted to https://fedoramagazine.org/?p=34935&preview=true
@zexcon Hope your new year is off to a good start. Do you have a status or ETA on this article?
When you have it ready for review, please leave a comment on this card.
Thanks and Happy New Year
@zexcon Are you still working on this article? No hurry. We just want to make sure you haven't forgotten about it. 🙂
@zexcon Any update on this article?
Sorry guys, busy new year. I'm logged in.
On Wed, Feb 16, 2022 at 11:18 AM Richard England pagure@pagure.io wrote:
rlengland added a new comment to an issue you are following: @zexcon Any update on this article? To reply, visit the link below or just reply to this email https://pagure.io/fedora-magazine-newsroom/issue/59
rlengland added a new comment to an issue you are following: @zexcon Any update on this article?
To reply, visit the link below or just reply to this email https://pagure.io/fedora-magazine-newsroom/issue/59
Hey @zexcon, are you still working on this?
Hi @zexcon,
I would be happy to take over if you did not find the time, ok/CC @rlengland ?
Basic idea:
Short introduction about how to combine tool output / why it is cool to determine something about the system on the terminal and the family of "ls" tools?
Fedora (and most common Linux setups out there) offers you an array of tools for managing, monitoring, and understanding the system. Among these tools are a series of commands that begin with ls (for "list"). There are more than just the basic ls command to listing directory contents, providing insights into various aspects of the system's hardware and resources. This article (series) gives you an insight [...]
ls
Listing of commands in the form: 1. Description 2. Basic Example 3. Advanced Example 4. Optional hints (e.g lesser known JSON output options and so on)
Example:
lscpu - Display CPU Architecture Information
lscpu
The lscpu command gathers and displays information about the CPU architecture. It is provided by the util-linux package. It gathers CPU information from multiple sources like/proc/cpuinfo and architecture-specific libraries (e.g. librtas on PowerPC).
util-linux
/proc/cpuinfo
librtas
This command outputs information like the number of CPUs, threads per core, cores per socket, and the CPU family and model.
Advanced Example:
lscpu --extended --json
Outputs detailed CPU information in JSON format, providing a structured view that is particularly useful for scripting and automation.
So you can do things like extract the current MHz for each CPU from the JSON output of lscpu --json using jq (which is worth an article on its own), you can use the following command:
lscpu --json
jq
lscpu --json --extended | jq '.cpus[] | {cpu: .cpu, mhz: .mhz}'
Let's look at the single parts:
lscpu --json --extended
| jq '.cpus[]'
{cpu: .cpu, mhz: .mhz}
cpu
mhz
[...] And so on for at least lsblk, lshw, lsmem,lspci,lsusb`
lsblk
lshw
lsmem,
,
@andreashaerter I would say that after 2 years elapsed time you can probably safely assume that the original proposer will let the topic go.
Here is a link to some tips for writing. https://docs.fedoraproject.org/en-US/fedora-magazine/writing-guidelines/ When you have your article in WordPress leave a comment on this ticket with a preview link and the editors will review it.
We can address any questions or issues that arise via comments on this ticket.
Thanks
Metadata Update from @rlengland: - Issue assigned to andreashaerter (was: zexcon)
Hi,
Sorry a lot going on. If you would like I have no issues with you taking over.
On Wed, Apr 24, 2024 at 1:48=E2=80=AFPM Andreas Haerter pagure@pagure.io = wrote:
andreashaerter added a new comment to an issue you are following: `` Hi @zexcon, I would be happy to take over if you did not find the time, ok/CC @rlengland ? Basic idea: Short introduction about how to combine tool output / why it is cool to determine something about the system on the terminal and the family of "l= s" tools? Fedora (and most common Linux setups out there) offers you an array of tools for managing, monitoring, and understanding the system. Among these tools are a series of commands that begin with ls (for "list"). There a= re more than just the basic ls command to listing directory contents, providing insights into various aspects of the system's hardware and resources. This article (series) gives you an insight [...] Listing of commands in the form: 1. Description 2. Basic Example 3. Advanced Example 4. Optional hints (e.g lesser known JSON output options and so on) Example: lscpu - Display CPU Architecture Information The lscpu command gathers and displays information about the CPU architecture. It is provided by the util-linux package. It gathers CPU information from multiple sources like/proc/cpuinfo and architecture-specific libraries (e.g. librtas on PowerPC). bash lscpu This command outputs information like the number of CPUs, threads per core, cores per socket, and the CPU family and model. Advanced Example: bash lscpu --extended --json Outputs detailed CPU information in JSON format, providing a structured view that is particularly useful for scripting and automation. So you can do things like extract the current MHz for each CPU from the JSON output of lscpu --json using jq (which is worth an article on it= s own), you can use the following command: bash lscpu --json --extended | jq '.cpus[] | {cpu: .cpu, mhz: .mhz}' Let's look at the single parts: lscpu --json --extended generates the detailed CPU information in JSO= N format. | jq '.cpus[]' will iterate over each entry in the cpus array. {cpu: .cpu, mhz: .mhz} constructs a new JSON object for each CPU entr= y showing the CPU number (cpu) and its current frequency in MHz (mhz). [...] And so on for at least lsblk, lshw, lsmem,lspci,lsusb` `` To reply, visit the link below or just reply to this email https://pagure.io/fedora-magazine-newsroom/issue/59
andreashaerter added a new comment to an issue you are following: `` Hi @zexcon,
Short introduction about how to combine tool output / why it is cool to determine something about the system on the terminal and the family of "l= s" tools?
Fedora (and most common Linux setups out there) offers you an array of tools for managing, monitoring, and understanding the system. Among these tools are a series of commands that begin with ls (for "list"). There a= re more than just the basic ls command to listing directory contents, providing insights into various aspects of the system's hardware and resources. This article (series) gives you an insight [...]
bash lscpu This command outputs information like the number of CPUs, threads per core, cores per socket, and the CPU family and model.
bash lscpu
bash lscpu --extended --json Outputs detailed CPU information in JSON format, providing a structured view that is particularly useful for scripting and automation.
bash lscpu --extended --json
So you can do things like extract the current MHz for each CPU from the JSON output of lscpu --json using jq (which is worth an article on it= s own), you can use the following command:
bash lscpu --json --extended | jq '.cpus[] | {cpu: .cpu, mhz: .mhz}' Let's look at the single parts:
bash lscpu --json --extended | jq '.cpus[] | {cpu: .cpu, mhz: .mhz}'
[...] And so on for at least lsblk, lshw, lsmem,lspci,lsusb` ``
I created a first draft for two commands lscpu and lsusb. Sure: It is a simple article but was ideal to get into the system (I never used WordPress before) and the jq example should be useful and took a bit of time: https://fedoramagazine.org/?p=40503&preview=true&preview_id=40503
If this goes into the right direction I would do a last typo check and preparing for review with a feature pic.
@rlengland I guess it makes sense to split these into different articles (next one eg: dmidecode and lspci? What do you think after having a look at the current draft?
Metadata Update from @rlengland: - Custom field preview-link adjusted to https://fedoramagazine.org/?p=40503&preview=true&preview_id=40503 (was: https://fedoramagazine.org/?p=34935&preview=true)
@andreashaerter We will let you know when we've done a review.
Do you have suggestion or ideas for the featured image?
Doing two articles sounds like a good idea. Shall I change the title of this card to "Commands providing views into the system Part 1" ?
Metadata Update from @rlengland: - Custom field editor adjusted to rlengland - Issue tagged with: needs-series
@andreashaerter I've reviewed and edited your article. Only minor wording changes and some long sentences were broken up for easier reading. I've added a possible featured image as well. If you give it another reading and approve, we will get it scheduled for publication.
Thank you.
Metadata Update from @rlengland: - Custom field image-editor adjusted to rlengland - Custom field publish adjusted to 2024-05-27 - Issue untagged with: needs-image
Metadata Update from @rlengland: - Custom field publish reset (from 2024-05-27)
@rlengland sure, thanks for
From my POV: publish it whenever it fits.
Regarding ticket: sure, change the tiltel as needed. Shall I open new ones for the next article(s)?
Re: #1 and #2 you are welcome
We will proceed with publishing and let you know the target date.
There is a ticket for Part 2: https://pagure.io/fedora-magazine-newsroom/issue/296
@andreashaerter ( @glb ) Your article is scheduled for publication 29 May 0800 UTC
Thanks for your contribution and we are looking forward to Part 2. :-)
Metadata Update from @glb: - Custom field publish adjusted to 2024-05-29
Issue status updated to: Closed (was: Open) Issue close_status updated to: published
Log in to comment on this ticket.