[sf-lug] Researching hardware (was: My latest NUC adventure)
Rick Moen
rick at linuxmafia.com
Fri Jul 19 12:27:21 PDT 2019
Quoting Akkana Peck (akkana at shallowsky.com):
> I'll be mail ordering. I doubt there's a store in the whole state
> of NM that has these machines in stock, though since I have to be in
> Albuquerque on Saturday I'm going to check some stores there just
> in case (thanks for the reminder to have a live boot USB in my pocket).
Mail order obviously creates challenges. Making sure you have the
contractual right to return merchandise for 100% refund helps.
> That Intel page shows VT-x and "Intel 64" (I'm fairly confident
> all the processors in the machines I'm considering will be 64-bit
> capable), but I don't see anything that looks like VMX. Is that
> different from VT-x? If so, is there a way to find out without
> having access to a running machine? And do I not care about VT-d?
My information on this subject is woefully out of date, I fear -- but
you wouldn't 'see' vmx in Intel's documentation, if that's what you
expected. It's a Linux kernel programming term (I think?), standing for
Virtual Machine Extensions, an umbrella name for ten new CPU
instructions in Intel CPUs able to support VT-x hardware virtualisation.
What I've found suggests that the /proc/cpuinfo CPU flag for VT-x
remains 'vmx', as it was in 2007 when I wrote that mailing list post.
One can programmatically detect VT-x support in a CPU by loading the
'msr' kernel module and running the rdmsr utility with parameter 0x3a
(to read CPU register 0x3a, also known as register
IA32_FEATURE_CONTROL). If that utility returns 3 or 5, then VT-x is
present and enabled.
# modprobe msr
# rdmsr 0x3a
3
#
/usr/bin/rdmsr is often in a package named something like msr-tools,
depending on the distro.
Interesting reading about the MSR bits:
http://www.thomas-krenn.com/en/wiki/Activating_the_Intel_VT_Virtualization_Feature
https://security.stackexchange.com/questions/15555/can-a-hypervisor-rootkit-enable-hardware-assisted-virtualization-when-it-has-bee
https://stackoverflow.com/questions/11116704/check-if-vt-x-is-activated-without-having-to-reboot-in-linux
_Lots_ of valuable stuff in there, e.g., systems that seem unable to
support hardware virtualisation may simply have the 'lock bit' set to
prevent enabling that function in the BIOS, and regain the ability if
you switch the lock bit off.
VT-d seems to concern virtualisation of devices (thus 'd'), specifically
presence and enabling (or not) of an IOMMU. I haven't read the above
very closely, but it seems as if you would want to enable VT-d in the
BIOS (on an Intel system) and pass the booting kernel parameter
'Iommu=on'.
By the way, near as I can tell, when I wrote (in that 2007 mailing list
posting) about the "VT" extensions on Intel, I really should have said
'VT-x", i.e., there is one thing rather than two. Background is here:
https://en.wikipedia.org/wiki/X86_virtualization#Intel_virtualization_(VT-x)
> > One of the reasons I am a bit wary of Dell is that, when you least
> > expect it, they switch a key component to a problematic and usually
>
> Yeah. Dell used to be especially bad for that, but I thought they'd
> gotten better. I guess not.
My information is quite possibly old. I used to test all candidate new
hardware for Linux/Solaris use when I worked at Cadence Design Systems,
and, _back then_, I could tell you a lot about suitability of new and
upcoming computers for Linux, but that was a decade ago.
> Oh, certainly. I'm not blaming linux-on-laptops.com for the 404s!
> Just noting that nobody seems to be adding links there any more, so
> most links there are ancient and crumbling.
It's a shame. Gift economies crumble when people cease participating.
https://en.wikipedia.org/wiki/Gift_economy
> Yep, that can happen. On the other hand, I suspect that if I bought
> a laptop from ZaReason, installed Debian and had trouble getting,
> say, the wi-fi driver to work, I could mail Cathy and say hey, I
> bought this laptop from you, now I want to use Debian testing, how
> do I get this dang wi-fi working? and that I'd get a useful answer.
> Which is definitely not the case if I buy from lenovo.com or
> bhphoto.com or (less likely) dell.com.
Without a doubt, small vendors like ZaReason are great for personal
service. I also wouldn't think it _likely_ that ZaReason or System76
would do a somewhat disreputable Dell-style move of declaring a unit
'fully Linux supported' when it needs proprietary drivers not lawful
for distros to distribute and likely to break at the next major kernel
revision or vanish completely off the Internet. I'm just illustrating
what can go subtly wrong when you outsource determination of Linux
hardware support to a vendor. You are reliant on the vendor's good
judgement. People get burned, and I tend to comment 'pity you didn't
verify proper support for that winmodem on your own, before buying.'
There's IMO really no substitute for researching a unit before buying.
And what I mean is: Let's say I was considering buy a Lenovo ThinkPad
X1 Carbon 7th Gen. The first thing to realise is that is _probably_ the
marketing name, not the model designation in the technical specs, and
it's desirable to acquire the latter. (I say 'probably' because that
was the case before IBM transferred ThinkPad production to Lenovo.
If I were serious about researching, that's one of the things I would
dig deeper into.)
By the way, there's something I should emphasise, and hadn't done so
before now: I would be very reluctant to buy a _new_ laptop. IMO, the
sweet spot for performance vs. price is about 2-3 years old, and open
source coders will then have had plenty of time to crack good support
for problem chipsets, especialy if they're motivated, which generally
occurs if it's a unit popular with Linux coders -- which back in the
1990s inspired Moen's Law of Hardware, which please see:
http://linuxmafia.com/~rick/lexicon.html#moenslaw-hardware
So, if I was shopping today, I'd probably be looking around for
something like a Lenovo ThinkPad X1 Carbon _4th_ Gen, which was
introduced in 2016.
In searching online about such a unit, you quickly learn that most of
the PC Mag / Ziff-Davis / etc. magazines are almost completely useless
as a source of technical information. You also discover that appending
the word 'Linux' to your search strings is often useful, finding you
(for the cited laptop) pages like these:
https://wiki.archlinux.org/index.php/Lenovo_ThinkPad_X1_Carbon_(Gen_4)
https://wiki.debian.org/InstallingDebianOn/Thinkpad/X1%20Carbon%204thGen%20PCIe_SSD/jessie
https://kozikow.com/2016/06/03/installing-and-configuring-arch-linux-on-thinkpad-x1-carbon/
ThinkWiki hasn't caught up. It has details of all X1 Carbon generations
up to 3rd Gen:
https://www.thinkwiki.org/wiki/Category:X1_Carbon_(3rd_Gen)
Anyway, the three links above provide comprehensive information about
chipsets and Linux drivers for a 4th Gen X1 Carbon, and I'd feel very
confident about such a unit based on them.
More information about the sf-lug
mailing list