48 comments

[ 1.9 ms ] story [ 81.1 ms ] thread
Hi, small fix:

$ hdparm -tT /dev/sdN - partition reading & writing benchmark

It will just benchmark reading, not writing, perfectly safe to run it on a disk with data.

For lsusb and lspci you might need sudo for more detailed output.
I have to say the title is a bit clickbaity.

Since when were uname,dmesg,fdisk,gdisk,parted,blkid,lsblk,mount,df and /proc "advanced" commands ?

A newbie will likely need to use all of them within the first week of them ever using Linux.

"A newbie will likely need to use all of them within the first week of them ever using Linux."

And then some people wonder, why the year of the linux desktop still has not arrived. But luckily no, unless things went very wrong, a newbie will not have to invoke those commands - and if he indeed has to, he or she will likely just give up anyway.

(Btw. I use linux since years and so far only had to use half of the listed commands.)

I concur. I've been using GNU/Linux on the desktop (and server) for 20 years, I don't think I ever used blkid or lsblk.

fdisk, on the other hand, was a thing in the DOS/Windows world, too, back in the day, and dealing with partitioning is something you are going to do regardless of the OS you are using.

lsblk is super helpful and I've used it many, many times since I found it about 5 years ago.

inxi is a new one for me.

Command usage / knowledge depends on what you need and why.

> inxi is a new one for me.

For me, too. I was surprised to find it already installed on my system. :)

> I concur. I've been using GNU/Linux on the desktop (and server) for 20 years, I don't think I ever used blkid or lsblk.

How do you write disk images (like, if you're installing a new machine and you need to write the installer to a USB drive)? I always use lsblk to find the right device name, then dd to write it.

I use dd, too. But I usually know what device corresponds to the USB drive. If my laptop only has one HDD/SSD, it's /dev/sda, so a USB drive will show up as /dev/sdb. My desktop has two internal SSDs, sda and sdb, so the USB drive is going to be sdc.
> (like, if you're installing a new machine and you need to write the installer to a USB drive

I just make sure I point at the right device letter.

For all it worth in the last 10 years I never need to bother with it, because in the worst case I write the installer in Windows environment and when I install it on the machine (be it a hardware or a virtual machine) it doesn't matter.

The DOS fdisk was a very different beast to its Linux/UNIX counterpart.
You’re already advanced then.

Your claim about “within the first week” is a bit silly. I’ve used Linux on and off for the last 15-20 years. Just occasionally, to get certain things done in my development work. And I couldn’t tell you what any of those commands do (although I’ve probably used them a few times by copying and pasting). Advanced is subjective.

I think I disagree. I stumbled on lspci specifically, because I built my new PC with dual gpu ( to use real gpu in VMs ). I do not consider myself an advanced user ( maybe intermediate ).

I basically agree with OP. Advanced does mean advanced. It does not mean using couple of simple commands picked from one google search. To me it means being able to think a little beyond the basics and putting things together.

Advanced is subjective, but we should not water it down to basically a list of basic commands...

It may be true that people don't need to use these commands in the first week. Still doesn't make them advanced. Perhaps intermediate but I think even that is a stretch.

You can drive a car and never open the hood if you want. Opening the hood to change the oil still doesn't make you advanced in any way shape or form. Doing your own breaks is a step further but it's still pretty basic.

Swapping your engine, is advanced, redoing your suspension is advanced. You can't just call using an oil pan and a wrench advanced because most people don't it.

I’d settle for intermediate.
I'm also using Linux for ~20 years, and used these commands periodically on my personal systems and at work daily.

None of these commands are advanced. Yes, they might not be "very beginner level", but listing your partitions, PCI/USB/SCSI/FireWire devices, and learning other stuff about your system is not advanced level stuff.

Most of these commands equals to right clicking something and opening "Properties" panel, nothing more. Parted is a partition editor though. You might wipe your system accidentally if you don't know what you're doing.

The advanced stuff starts with interrupt tables, CPU frequency hysteresis settings, writing custom governors for cqufreqd or starting to isolate your services under cgroups for resource management.

Edit: Just used lsblk & mount to see where a disk is and what filesystem it has, literally 3 minutes after writing this comment.

It depends on what the person was trying to accomplish in their first week of using Linux. Did they see a certification book for LPIC or Linux+ and get interested to go through it? They will for sure hit these commands in the first week of using Linux than.

Using Linux for objectives that are not Linux administration you will probably not hit these commands. You probably won't be dealing with the partitioning of your hard disk if you use a graphical installer and let it partition things automatically. That knocks - fdisk, gparted, parted, lsblk, and blkid off the list.

I wouldn't even expect someone that uses Linux as an alternative to Windows to use ps, netstat, or top. I would expect them to encounter the package management commands though: apt, pacman, yum, dnf.

I have interviewed "senior devops" candidates that didn't know what procfs was.

edit: We didn't consider them for the role.

Hopefully they didn't get the green light..
Either we have abstracted away the operating system so this is a non-issue or those candidates are simply not qualified.

If you’re senior then I would definitely expect you to know those commands, if you’re senior you’ve been around long enough that they were relevant. Even if they’re not now.

I know what it is, do I qualify for at least a junior position? :D
> I have interviewed "senior devops" candidates that didn't know what procfs was.

We've all had our fair share of encountering dishonest interviewees/resumes.

Actually, a lot of the people new to DevOps who come from the Dev side don't know the Linux internals. All they know is TF/CF, k8s, Docker and either AWS or GCP. If you asked them to set up a raid array they'd look at you like you just grew a second head. If you asked them how to tell what modules the kernel was running, they wouldn't be able to find out without a lot of googling.

The fact that DevOps does encompass a lot of fundamental Linux system knowledge is glossed over by a lot of people. Then again, some of them don't know any other way to package and deploy software except in containers.

If you install Ubuntu or any other user friendly distro you might not ever use any of them.

I know what they are, obviously, but I don't think I've needed any of them other than uname because I don't know where Ubuntu prints the kernel version.

> If you install Ubuntu or any other user friendly distro you might not ever use any of them.

Maybe if you install Ubuntu and then never use any program other than your browser to check email and whatever the built-in office suite is, and also never change any settings.

But then again that type of user will never Google for "advanced Linux commands" in the first place. They're just going to ask the person who installed Ubuntu for them.

I've been using Linux since 1995.

I had never heard of `inxi`. 21k lines of Perl, not Bash....

> 21k lines of Perl

GLORIOUS

$10 says this was made by someone who worked at an ISP.

Since everyone is mentioning experience, I have administered from 1 to a dozen linux servers since 1994.

df, mount, dmesg are basic ones for someone who uses a command prompt.

fdisk and friends are for the ones who added a disk after installation

The rest is for those who had a problem and found a solution on askununtu.com or serverfault. Or are actually advanced.

I think there is a big difference between the users who work on the command line and those with a GUI. I do not even know what GUIs are used, except that I heard the names gnome and kde. Troubleshooting those would be a real challenge for me as they are very complex software.

Same for the sound. I recently had to attach a small loundspeaker to a rpi. Oh god, what an experience to make it make a sound. All this with nearly 30 years of Linux.

So experience is very relative, you may know how to write an inode table from scratch and google basic stuff you do not use.

hdparm is an "okay" tool for a quick read speed benchmark, but if you really want to benchmark Linux storage, its hard to beat fio[0]

[0] https://github.com/axboe/fio

> lsscsi - print attacked SCSI devices into

appropriate typo

Dang. I thought I found that 8 hours later.
They should have mentioned udevadm too. How do they debug their udev rules without it?

Overall a low quality article IMHO, it's just basic knowledge in a fancy dress.

Something I miss about IRIX: hwgfs. Nowadays, /sys mostly makes up for that, I like the fact that I mess with my leds from a simple filesystem, but it is nowhere near as tidy was IRIX' hwgfs was.
For display chips in GPUs, there is drm_info. For GL/Vulkan, eglinfo/glinfo/vulkaninfo.
glxinfo is also handy, especially if you aren't sure which driver the system is using.
numactl is missing there. Information about memory topology is quite important.
It is not available in some distributions and one needs to install it (e.g., on Ubuntu/Debian: # apt install numact).
`lstopo` is cool too for bigger servers
The article picture almost had a Droste effect, almost.

https://en.wikipedia.org/wiki/Droste_effect

… and is really weird; who has have a picture of themselves, taken from behind, as a desktop background?

I realize it's pointless splash art. Also do which articles wouldn't bother with pointless splash that has nothing to do with the article. Half the screens feature … macOS.

> For Advanced Hardware and System Info

This first command is literally `uname`, one of the most basic and known commands...

Roll up! Roll up! Decode your Intel model/"stepping" (model/version) into a precise SKU name here: https://github.com/torvalds/linux/blob/master/arch/x86/inclu...

No, I do not know why every single ICELAKE processor is commented as Sunny Cove.

> No, I do not know why every single ICELAKE processor is commented as Sunny Cove.

Wikipedia can clarify that for you:

> Ice Lake is Intel's codename for the 10th generation Intel Core mobile and 3rd generation Xeon Scalable server processors based on the Sunny Cove microarchitecture

https://en.wikipedia.org/wiki/Ice_Lake_(microprocessor)

Thanks. I figured Sunny Cove was a post-Ice-Lake iteration, but for some reason wasn't being listed by itself in the .h.