Merge pull request #5190 from rusking/master

20170117 Arch Linux on a Lenovo Yoga 900
This commit is contained in:
Flynn 2017-02-25 20:38:10 +08:00 committed by GitHub
commit b155e4616f
2 changed files with 311 additions and 311 deletions

View File

@ -1,311 +0,0 @@
#rusking translating
# Arch Linux on a Lenovo Yoga 900
_Warning: this is about 5,500 words with plenty of interesting links, so wait till youve got something to drink and some time._
After 3 years running Arch Linux on a [Lenovo Yoga 2][2], I decided to upgrade to a Yoga 900:
![](http://keithcu.com/wordpress/wp-content/uploads/2017/01/Yoga900-1.jpg)
_Lenovo Yoga 900 [Amazon special][1] for $925 8GB RAM, 256GB SSD, 3200×1800, Intel Skylake 3.2GHz + Iris Graphics_
Dell charges $1650 for a [similar XPS 13][3] albeit with the next generation of Intel chip. The current model of Yoga is the 910, and that laptop costs $1300\. However, I didnt even consider it because they screwed the pooch on the keyboard. Lots of reviews start with the color and feel of the materials on the outside, but Im going to start on the keyboard layout.
### Keyboard
The Yoga 2 Pro and the Yoga 900 have the same design. It is inferior in several ways compared to the traditional and well-regarded IBM Thinkpad keyboards, but not the worst keyboard out there and I got used to it over the 3 years. Unfortunately, Lenovo made things worse in the 910.
![](http://keithcu.com/wordpress/wp-content/uploads/2017/01/Yoga900-2.png)
_Yoga 2 and Yoga 900 keyboard layout _
![](http://keithcu.com/wordpress/wp-content/uploads/2017/01/Yoga900-3.png)
_Yoga 910 keyboard_
The problem with the 910 keyboard is that the right-shift key is in the wrong place, and impossible to reach without moving your hand. It is in a different position than every keyboard Ive ever used going back to 9<sup>th</sup> grade typing class on the IBM Selectric. Id expect such a mistake from a company like Asus or Dell, not a company with the legacy of building typewriters that generations of Americans learned and worked on.
Every year the Yoga team has made changes to the layout. Imagine if every year in the 20<sup>th</sup> century, IBM had changed the layout of their typewriters, and then bragged about the “[efficiency][4]” gains. The company wouldnt even be around today!
I probably could get used to the Yoga 910 page up / page down overloaded with arrow keys, and some of the other changes, but the shift-key is a deal breaker and Id rather not bother with the others.
There are many ways for Lenovo to truly improve their keyboard, such as making the volume-up key not so close to application-close. And re-thinking whether they really need an easy way to (accidentally) turn off the screen given there is already a way to dim it. And figuring out how to put in an overloaded number pad. Does Lenovo think only businesses deal with numbers?
The 910 keyboard has so many changes, they might not ever go back to their old layouts again. Im hoping this hardware will last me years. Id rather have a great keyboard than a computer 10 times faster.
I see in the Yoga 910 reviews on the Lenovo website that some people are returning the computer because of the keyboard. Lenovo should have a policy: if an employee wanted to make an alteration to the keyboard, they should have to write down a **very ****good** reason, and then sacrifice one of their fingers in solidarity with the pain it will cause customers. A rule like that would decrease this needless churn. Lenovo went through a lot of work make the Yoga 910, but f*cked it up with the input mechanism.
### Overall
The Yoga 2 was generally fast enough for everything I needed to do. An SSD is nice for various reasons, but it is almost overkill on Arch. People who only use Windows might not realize how bloated it is:
![](http://keithcu.com/wordpress/wp-content/uploads/2017/01/Yoga900-4.png)
In the late 90s, youd get a new computer every few years because the processors were doubling in speed every 18 months, and the software was doubling in size frequently as well. Things are very different now. The new Yoga is 30% faster than my Yoga 2 running integer benchmarks. This is a 3.2 GHz machine whereas the old one maxed out at 2.6 GHz so most of the difference is the faster frequency.
Haswell was introduced in 2013, and Skylake was introduced in 2015 so two years of advancement is the other part of the improvements. The big benefit of the new processor is that it is built in 14nm instead of 22nm which means less heat and longer battery life. My old Yoga 2 battery was still giving me about 3.5 hours of battery life with moderate brightness, but this should give me 7.
The Yoga 2 hinge is starting to weaken and fall apart, and there is no way to tighten it, only to try to find one on the Internet or mail it to Lenovo:
![](http://keithcu.com/wordpress/wp-content/uploads/2017/01/Yoga900-5.png)
The hinge on Yogas is designed to let you lay the device flat, and even fold it back as a tablet, but I found it a heavy and awkward and so never bothered. Im just happy if Ill be able to open and close it daily for years.
The Yoga 900 hinge is a more solid watchband design and should last longer:
![](http://keithcu.com/wordpress/wp-content/uploads/2017/01/Yoga900-6-1.jpg)
The only very minor downside is that if you shake it, it sounds like youve got broken parts rattling around inside, which usually is something to be worried about for electronics! However, its just a false alarm of the 800 pieces sliding.
The Yoga 2 Pro was overall a quite well-built device, but if I hold it in one hand with the screen open, it sags a bit, and sometimes the keyboard backlight goes out. Both Yogas are thin and light, but the 900 feels more solid.
### Clickpad
The biggest problem with the Yoga 2 was the Synaptics Clickpad it used. It actually wasnt the hardware, it was the driver, which is basically unmaintained, and of course had some bugs. Its a shame because Synaptics could easily afford one engineer to help maintain a few thousand lines of code. They actually wrote another driver, they just never released it freely so it could be included with the kernel.
However, a new library called [Libinput][5] was created, and they support Clickpads and things work well out of the box now. The best thing about Libinput is that they fixed the bug where if you have your left finger touching in the mouse-click area, it will now register pointer movements by your right finger. Its hard to believe, but that basic functionality was broken for many years with Synaptics hardware on Linux.
The Clickpad hardware was still working fine, but it didnt give any audible click sound anymore. That actually isnt a problem, but it did make me wonder if it was going to wear out at some point. The old Thinkpads had multiple left and right mouse buttons, so if one broke, you could use the other while you ordered a new part, but since theres only one button here, there is no backup except to plug a mouse in. (Lenovo expects you to mail in the computer to get a new mouse.)
### Kernel Support
When I bought the Haswell laptop, the hardware design was brand new, so I ran into a lot of Linux driver problems initially that took months to resolve. In this generation, Skylake crashing bugs were still being fixed [8 months after the architecture was introduced,][6] but now it appears theyve all been resolved. And even when those were fixed, there were still problems with [power management support,][7] but today these also appear to be improved. The laptop will settle into the lower power C6-C10 states if nothing is going on. (This is verifiable with **powertop**.)
The power management features are important not only for battery life, but because these very small circuits eventually wear out because of something known as [electromigration][8]. Intel even warns that: “Long term reliability cannot be assured unless all the Low-Power Idle States are enabled.” By running in lower power mode, and therefore using the circuits less, they will last longer.
Linuxs Haswell support is very reliable now, but it was definitely flakey for a long time. I wrote about some of the issues at the beginning and after the first year, but I can say finally that things are great for Haswell and Skylake.
### Lenovo BIOS Linux Incompatibility
Before I could install Linux on the Yoga 900, I had to flash a new BIOS in Windows. In fact, I had to install 2 BIOSes. The latest Yoga 900 BIOS didnt [include][9] the necessary fix I needed, so after scratching my head for a while I eventually discovered and [installed][10] a separate “Linux-only” BIOS update, which also says that Windows is no longer supported by Lenovo: “Are we not [merciful][11]?”
As people who followed the Linux news are aware, the Yoga 900 and certain other recent models of Lenovo laptops were impossible to install Linux on, because it couldnt even [detect the hard drive][12]. Lenovos first reply was that the laptops didnt work on Linux because it uses a [new RAID controller mode][13]. However, RAID is meant for multiple disks, and this laptop only has one hard drive, and there isnt even room to install another.
Heres some more of Lenovos [official explanation][14]:
> “To support our Yoga products and our industry-leading 360-hinge design in the best way possible we have used a storage controller mode that is unfortunately not supported by Linux and as a result, does not allow Linux to be installed.”
I found it funny that the reason for their different storage controller is because of their hinge! It would be like a car company saying they had to change their rims because of their new radio.
This turned into a controversy thanks to the efforts of [Baron][15][H][16][K][17] on Reddit who wrote about it, provided information to the media, and contacted his local Attorney General in Illinois. Searching for “[Lenovo Yoga ][18][L][19][inux compatibility][20]” turns up 300,000 results. Lenovo could be criminally liable for selling a “general purpose” PC that didnt let you install your own operating system. The default OS is meaningless on a machine that is truly mine.
Hackers got involved, and they eventually discovered via playing with the UEFI settings, that the machine still supported the AHCI controller mode, it was just disabled. In short, Lenovo took away Linux compatibility for no good purpose. Because of all the information people learned, if this case had ever gone to court, Lenovo would have gotten their ass handed to them.
Fortunately, all the news got their attention, and they eventually updated the BIOS. I type this on a Yoga 900 running Linux, so we should celebrate this victory. Lets hope they learn a lesson, but Im not optimistic. They ought to offer you an option to choose the operating system for your machine. They would have found this bug long before any customers did. Id wait an extra week to get a custom computer. They could also do a better job setting up the partitions and letting people customize lots of things, and grabbing all the latest software, rather than using a generic old image which needs lots of updates.
Some people like Lenovo said it was Linuxs fault for not supporting this new RAID driver mode. However, AHCI is a very popular standard, and the Linux kernel team rejected Intels code for this hardware as “[too ugly to live][21]”! The team also asked Intel for a specification describing the devices behavior, but wasnt given this information.
### Heat Dissipation
The Yoga 2 could get hot when pushing the CPUs hard. I charred the bottom of the plastic case while compiling LibreOffice on a blanket, which was an eyesore and made me look like a homeless programmer. I tried a metal brush and some turpentine to get the worst of it off, but it didnt really improve the situation:
![](http://keithcu.com/wordpress/wp-content/uploads/2015/04/20150327_135649-2.jpg)
This new computer has a metal case which shouldnt get discolored, and Skylake definitely runs cooler than Haswell. It also seems to do better job of pushing heat out sideways through the hinge, instead of down which could easily be obstructed.
One of the annoying things about the Yoga 2 over time is that the fan blades had collected dust over the years, but it sounded like sand! It was uneven and distracting and made it much louder. I did take the laptop apart and vacuum everything, but the blades are hidden. Id have to replace the fans. They dont run on the Yoga 2 for typical tasks of word processing and web browsing, but when they do spin up its annoying if Im not wearing headphones.
The Yoga 900 fans are higher pitch, but it is just a smooth whir and not distracting. The Yoga 900 fans seem to run all the time, but at a low speed that is quiet. The sound of my refrigerator and air filter are louder unless the fans crank up under load, and even then it is not a big deal.
### Graphics
The Yoga 2 had a great screen, but it also had widely reported issues because the yellow looked like orange. However, everything looked so crisp and all the other colors looked fine. The Yoga 900 screen has fixed the yellow issue. Its not true 4K, being only 3200×1800, but the pixels are smaller than 4K on a 15.6” monitor, so that it looks very sharp.
When I first got the Yoga 2, Haswell was still a new chipset, so I saw various Intel graphics display glitches which went away within a couple of months. However, I eventually discovered a memory leak that could crash Linux, and this bug was in there for years.
My computer ran out of RAM a number of times skipping through video in VLC (shift + arrow). The memory didnt show up as in use by VLC, but my computer ran out of RAM, so clearly it was kernel memory. Eventually I setup a swap file which gave more time, but even then a couple of times it filled up when I wasnt keeping track. Eventually the bug disappeared, and Linux is very stable right now, but it was there for years.
Everyone says Intel has the best Linux drivers, but they seem like a skunkworks project inside Microsoft. The driver developers working on Linux at Intel are good, there just arent enough of them. They should be perfecting the drivers before they release the hardware! Intel produced [1][22][13][23] [processors][24] as part of Skylake, with subtle feature differences. That sounds like a lot, but they released 256 chips during the [Haswell generation][25], so maybe things are getting more focused. I was told 10 years ago by an Intel employee that they invested 1% into Linux compared to Windows, and today that still seems to be true.
The only performance issue I ran into with the Yoga 2 was that it couldnt play 4K video reliably. It would often show screen glitches, or just do around 5 frames per second:
![](http://keithcu.com/wordpress/wp-content/uploads/2017/01/VlcGlitch.jpg)
The Yoga 2 would even sometimes struggle playing 1920×1080 video, which it was supposed to be able to handle at 60fps. Part of this is probably because I always have other applications like Firefox and LibreOffice running.
The Skylake processor is speced to do 4K video at 60 fps for H.264, VP9, and other codecs. In fact, the processor has a lot of hardware accelerated [multimedia][26][capabilities][27]. I tried out hardware encoding of H264 with **ffmpeg** and found it was 4 times faster while using just 1 CPU. Its cool to see this feature. Unfortunately, it is a little annoying to setup because you have to use a number of additional command line parameters:
“**-threads 1 -vaapi_device /dev/dri/renderD128 -vcodec h264_vaapi -vf format=nv12|vaapi,hwupload**”
I tried to find a way to have **ffmpeg** remember these for me so I wouldnt have to type it in every time, but couldnt. I cant just pass those in automatically either, as other things need to go before and after. I also discovered that it wont resize video while using the hardware, and will just ignore the request, so only sometimes can it be used. It would be really great if **ffmpeg** could figure this out automatically. There is a lot of unused hardware because users dont know or cant be bothered. Unfortunately [its kind of a mess][28] for video encoding and decoding as there are multiple APIs for Linux and Windows.
Skylake does a much better job playing 4K video, but it will still glitch sometimes and briefly drop down to 10 fps. I think part of it is X. I tried playing 4K videos in Wayland, and it was smoother, so Im hopeful. It is great to see that the OpenGL support has improved. On this hardware, Intel supports version 4.5 which is the latest version from 2014.
My Yoga 900 (-13ISK2) is actually a revised version of the original offering with an Iris 540 graphics co-processor which is supposed to be [faster][29] than the stock 520 because of 24 more shader units. However, it can only play SuperTuxKart with moderate settings running 1600×900 at 20 fps, so I wouldnt say its anything to brag about yet. Speaking of which, the game has improved tremendously over the years and is beautiful now:
![](http://keithcu.com/wordpress/wp-content/uploads/2017/01/Screenshot-from-2017-01-10-17-03-57.png)
There is an Intel team in China working on [enabling][30] support OpenCL using the graphics card. However, I dont see any mention of people using it in Blender yet, so I wonder the status and whether it is just demoware. Intels OpenCL support has been missing for so long, people doing serious work with Blender already use NVidia or AMD cards, and even when Intel finally writes the code, theres not much testing or interest.
One thing that was surprising to me is that I did some experiments on another machine, and found that a quad-core processor is faster than the NVidia 960M for ray-tracing with the Cycles engine. Apparently the 640 CUDA cores arent enough to beat 4 Intel CPUs on that task. Newer processors have 2000+ cores and those provide faster performance.
### HiDPI
The situation has gotten better for Linux on these high-res screens over the last 3 years, but it still has a ways to go. The good news is that Gnome is almost perfect with HiDPI in current versions. Firefox generally looks great if you set the **layout.css.devPixelsPerPx** to 2\. However because this 13.3” screens pixels are so small, I also install a No-Squint Plus plugin and have it render everything at 120% to make it a bit easier to read.
I was happy to help LibreOffice look better on these screens with [some patches][31] that were shipped in April, 2014, and the work has continued since. The biggest issue remaining is that LibreOffice is still doubling toolbar icons. A number of themes have SVG icons, but they arent packaged and shipped with the product. SVGs are much slower to load compared to PNGs and need to be cached. [Tomaž Vajngerl has done some more work][32] in this area, but it hasnt released yet. Even so, LibreOffice looks better than many other Linux apps which dont have recognizable icons.
Applications are generally improving with regards to detecting and being usable on high-res screens, but even some of the most popular such as Gimp and Audacity and Inkscape are still hard to use. I installed a large custom theme for Gimp, but all the icons are different so even though they are bigger, it takes time to recognize them.
The unfortunate thing about Linuxs 1.5% marketshare is that these sorts of issues dont get much priority. Many codebases are moving to GTK 3, but in Audacitys case, it seems to be [stalled][33]. I talked in my first review about a long tail of applications that will need improvements but 3 years later, even some of the most popular apps still need work.
### SSD
The old hard drive was doing fine because of the various optimizations I did, especially to Firefox. I also kept in mind that the **/tmp** directory had automatically been setup as a RAM drive, and so I would usually save downloads there first. Sometimes Id find a 500 MB video I want to grab a short 20 MB clip from, or convert to another format, so by doing it in /tmp I saved a lot of writes. It is more work, and possibly unnecessary, but its faster to work in RAM.
I had written to each cell 25 times over the 3 years, which meant the drive could last for 350 years. The vast majority of the writes were for Arch updates. It gets new LibreOffice builds every month, and a new “stable” kernel release every week. It was great to be up to date all the time, but it did cost 100 times more writes compared to running Debian stable. However, given that each component has their own release cycle, it was necessary.
The new Samsung drive diagnostics dont tell the number of times it has written to each cell. In fact, I cant even find out what cell type it is and how many writes it is specified to handle. I believe the “Percentage Used” value will me the age of the drive, but perhaps it relates only to the number of spare cells. I havent found any documentation so I can only guess:
|||
|--|--|
| **Model Number:** | **SAMSUNG MZVLV256HCHP-000L2** |
| **Firmware Updates (0x06):** | **3 Slots** |
| **Available Spare:** | **100%** |
| **Available Spare Threshold:** | **10%** |
| **Percentage Used:** | **0%** |
| ****Data Units Written:**** | **198,997 [101 GB]** |
| **Data Units Written:** | **305,302 [156 GB]** |
| **Host Read Commands:** | **3,480,816** |
| **Host Write Commands:** | **10,176,457** |
| **Error Information Log Entries:** | **5** |
### Broken Left-Ctrl Key
One thing I noticed after just a few hours of use is that the left-control key pops off if pressed in the upper-left corner:
![](http://keithcu.com/wordpress/wp-content/uploads/2017/01/Yoga900-7-1.png)
_Broken Yoga 900 key: Note the tiny cylinder missing in the left box vs the right
_
The layout of the Yoga 900 keyboard is the same as the Yoga 2 Pro, but the internals are different. The keys of the Yoga 2 Pro cannot be removed and replaced individually, and there is no way to pop off any of the keys without doing permanent damage. The Yoga 900 has the old style Thinkpad keys: which can be detached, and replaced individually.
However, there is a defect and one of the 4 tiny cylinder notches in the hinge was missing so that it only connects to the key top at 3 points, and if you dont press the key in the middle, it will slip off.
I contacted Lenovo about this. Even though the keys are replaceable and serviceable, they will only replace the entire keyboard, and refuse to mail out any parts. They recommend I mail the computer in, or take it to the Geek Squad service center. I knew that mailing it in would take 2 weeks, so I called my local store to ask if they had Yoga keyboard parts in stock. They told me they dont take the computers apart, they just mail them to Atlanta. There used to be places that could make many repairs to IBM laptops, and stocked the common parts, but that industry is apparently gone.
I noticed this mistake within a couple of hours of using the computer, so Im pretty sure it was a manufacturing defect. It is such a tiny piece of plastic that was deformed or broke off during assembly.
Even though the computer is under warranty and could be fixed for free, I didnt want to wait for something so minor, so I just went on the Internet and found a website called laptopkey.com and ordered a replacement key and hinge. It was actually tricky because there are 3 types of hinges! It took me several minutes to figure out which one my computer has because yall look the same to me:
![](http://keithcu.com/wordpress/wp-content/uploads/2017/01/BigHinges-2.jpg)
So I ordered the part, but I read it would arrive in about a week. It was very frustrating because I use left-Ctrl all the time when doing copy/paste, skipping through video or by word in text editors, etc. so I thought maybe I could swap the hinge from the right-ctrl, which I never use.
So I tried to remove this key following instructions I found on the Internet: I got my fingernail under the upper left corner, and lifted till it clicked. And then I put my nail under the upper right corner, and did the same thing. But another one of those tiny pieces of plastic broke off, so now I have two broken hinges. It might not be possible to remove the keys without breaking these very tiny clips. These keyboards are serviceable perhaps only in theory.
So I decided to go old-school and use superglue. Id rather have the damn key stay on and have no urgent plans to replace them. It was tricky because I needed a small dab of glue about 1mm in diameter: too much in there it could gum up the works.
My experience building R/C airplanes came in handy and I fixed it and now the left-Ctrl key is holding on. The right one still slips off but I hardly use it. I was happy again! This is a long sidetrack, but it is important to keep in mind maintenance of a machine.
### Antergos vs. Arch
After 3 years with Arch Linux, I had no interest in trying anything else. The Intel drivers had regressions, but otherwise Arch has been painless to run on a daily basis, and it got a little better every week. Its exciting to be up to date with everything. I often had packages newer than what was in Ubuntu on their release date. Ubuntu users can find newer software in custom PPAs, but there isnt any testing or coordination across them, so that people who use multiple run into problems.
People also complain about Ubuntu upgrades hosing the machine and forcing a re-install, so even though their installation process is quicker, the ongoing maintenance isnt. Every time Ive read about someone borking an Arch installation, they would always admit it was a user error or something like btrfs corruption.
I wanted to install [Antergos][34], which provides a GUI installer for Arch. However, the setup looked unreadable on my screen, and it didnt recognize the Clickpad in their minimal install, which is the only one I had space for on my old 1GB USB key. So I decided to just install Arch old-school again. Thankfully, the Yoga still supports legacy BIOS, so I didnt have to mess with [UEFI][35].
I was sorry I didnt try out Antergos, because I think it could be a great distro for less technical people or those who want to quickly get into Arch Linux. The Arch wiki is filled with tips for best running Linux. Id love to have something which setup weekly TRIM for my SSD, [Profile-Sync-Daemon][36], Android support, hardware-accelerated video playback, etc. There are quite a few things that nearly all users would want, and are just a few lines to detect and enable.
Manjaro is a very popular Arch-based distribution with a GUI installer, but having run Arch for 3 years, I trust their packagers to work out issues between components. Ive read a number of comments on Reddit from people who found their Manjaro installation broken after an update.
My only complaint about my Arch installation now is the ugly unreadable bootloader screen. I just need to copy over the **grub.cfg** from my old machine.
### Arch Install
At first I just wanted to just move the hard drive from one laptop to the next so that I wouldnt even have to install anything, but after taking the computers apart, I noticed the M.2 SSDs are a different shape. I could have done a low-level block copy, but just decided to start from scratch because it would be a good refresher. It had been 3 years. I had installed a lot of random crap over the years, and even when I remembered to un-install it there were all kinds of digital remnants.
The Arch install went quite smoothly this time because the hardware had been around for so long. I still needed to do **rfkill unblock wifi**, but other than that everything else just worked. Apparently Linux still doesnt know how to properly read the rfkill information from this model. Fortunately **systemd** has the ability to restore rfkill values on startup.
### Kernel Buglist
One of the things that continues to surprise me is that the Linux buglist is a mess. I know there are all of these people and this great rate of change, but what isnt changing is the worst case scenario for a bug report. I dont know why bugs sit around for years, but there clearly is no escalation process.
I wrote an analogy in my last review I think is useful. Imagine if it took an airline 1-2 years to return your lost luggage. Would you use trust that company? In fact, whats the point of making a new release if youve still got thousands of known bugs and hundreds of regressions? If 1% of every Boeing airplane crashed, would they just keep continuing like that for years?
Maybe the Linux Foundation should hire some engineers to work on all the bugs that everyone else seems to be ignoring. There are a lot of people paid to work on Linux, and there are a lot of old bugs which is usually what amateurs do. In my opinion the kernel would be better off not releasing anything for months until the bug count was under 50\. Right now it is 4672\. That would be a good reason to increment the major release number.
There is something contradictory about making a new stable release every week, but theyve been doing it that way for years, and they have critical fixes every time, so they are clearly doing something valuable. The kernel gets better at a great rate, so far be it for me to criticize, but I do think they should try something different.
At least, bugs should get resolved within a specific timeframe. If that is exceeded, than it should escalate up to the maintainer and eventually to Linus. If there is a problem area with a lot of old bugs in a place that no one is working on, then Linus can point this out and crack the whip on the relevant parties. They need to think more like Boeing.
### Lenovo
Many Linux users hammer Lenovo for their lack of support on their consumer laptops, but they build quality hardware at a good price. As I wrote years ago, it was obvious not one person at Lenovo had bothered to install Linux on the Yoga 2 before they released it, and it is true for the Yoga 900 because it was impossible.
I think everyone in their company should be dual-booting. It isnt that hard to setup, and their customers might want that. Lenovo has 60,000 employees. At least, they need to hire a few people on their Yoga team willing to try out this thing called **Linux**. Windows is painful to use compared to Linux in various ways. Windows runs more applications, but I think perhaps half of their users would be happier with a properly configured Linux installation.
While it is bad how Lenovo is still ignoring Linux, their problems apply to more than the software. On many models, the RAM chips are soldered on. In some devices, there are whitelists and only pre-approved cards can be installed. The Yogas dont have a discrete graphics card, but even Lenovos that do provide no mechanism to upgrade the card, like you can with a desktop. I think someone needs to put a horse head in the bed of the Lenovo CEO.
### Conclusion
This Yoga 900 is an amazing laptop for the price, and its a definite step up from the Yoga 2 with the improvements. A similar Apple Macbook Pro is $1500, but it has 40% less pixels.
Windows is adopting some of the best features of Linux, but they still dont have native support for a package manager with all of the interesting free software components pre-compiled. Installing **ffmpeg** on Windows is a huge pain because of all the [dependent libraries][37] it uses.
Microsoft built a Windows store, which is sort of like a repository, but it doesnt handle inter-package dependencies, and isnt setup to manage individual libraries. Microsoft also has a new package manager called [NuGet][38], but it seems to be used mostly for .Net software. It did have a package for ffmpeg, but it didnt have any dependencies for the codecs so even after installing it, it wont do anything useful yet.
Last March, [Microsoft demonstrated][39] the ability to run Ubuntu command-line applications, which is quite a revolution. (They should have [started with Debian][40].) Theres even [a discussion][41] in their buglist to add support for more distros which could be quite tempting.
For me at least, I have no need for Windows apps, and the extra maintenance time. Fixing issues in Windows involves hunting down things in lots of different places. Linux still has a fair number of places to configure a system, but overall its much simpler.
I have friends who install 3<sup>rd</sup> party software on Windows just to keep their drivers up to date, because it grabs code from many more websites than just Microsofts. Windows has gotten better over the years, and it has more games and desktop applications, but it is an aging, closed system.
I find Gnome classic a streamlined experience. I wish it wasnt written in the clunky [fad Javascript][42], and they re-enabled a community around custom themes and color schemes. Its also still missing some nice features from Gnome 2 and Windows 10, and could be a bit more stable. Gnome 3.0 in 2011 was a step backwards, but six years later were up to Gnome 3.22, and things are mature again.
Gnome Classic is one of the best GUIs, but there are a [number of good ones][43] and all are getting better. This machine is working quite well now and Im just going to sit back and keep waiting for the HiDPI and other improvements! Im looking forward to deep learning inside the grammar checker of LibreOffice.
--------------------------------------------------------------------------------
via: http://keithcu.com/wordpress/?p=3739
作者:[keithccurtis][a]
译者:[译者ID](https://github.com/译者ID)
校对:[校对者ID](https://github.com/校对者ID)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]:http://twitter.com/keithccurtis
[1]:https://www.amazon.com/Lenovo-13-3-inch-Multitouch-Convertible-Platinum/dp/B01NA6ANNK/
[2]:http://keithcu.com/wordpress/?p=3270
[3]:http://configure.us.dell.com/dellstore/config.aspx?oc=cax13w10ph5122&model_id=xps-13-9360-laptop&c=us&l=en&s=bsd&cs=04
[4]:http://blog.lenovo.com/en/blog/why-you-should-give-in-to-the-new-thinkpad-keyboard
[5]:https://www.freedesktop.org/wiki/Software/libinput/
[6]:https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=762ce4458974534a2407cc924db05840c89105df
[7]:https://mjg59.dreamwidth.org/41713.html
[8]:https://en.wikipedia.org/wiki/Electromigration
[9]:http://support.lenovo.com/us/en/products/Laptops-and-netbooks/Yoga-Series/yoga-900-13isk2/80UE/downloads/DS112754
[10]:http://support.lenovo.com/us/en/products/laptops-and-netbooks/yoga-series/yoga-900-13isk2/downloads/ds119354
[11]:https://linux.slashdot.org/comments.pl?sid=9861381&cid=53241071
[12]:https://www.reddit.com/r/linux/comments/54gtpc/letter_to_the_federal_trade_commission_regarding/
[13]:http://venturebeat.com/2016/09/21/lenovo-confirms-that-linux-wont-work-on-yoga-900-and-900s-laptops/
[14]:http://venturebeat.com/2016/09/21/lenovo-confirms-that-linux-wont-work-on-yoga-900-and-900s-laptops/
[15]:https://www.reddit.com/user/baronhk/
[16]:https://www.reddit.com/user/baronhk/
[17]:https://www.reddit.com/user/baronhk/
[18]:https://duckduckgo.com/?q=lenovo+yoga+linux+compatibility&t=hs&ia=web
[19]:https://duckduckgo.com/?q=lenovo+yoga+linux+compatibility&t=hs&ia=web
[20]:https://duckduckgo.com/?q=lenovo+yoga+linux+compatibility&t=hs&ia=web
[21]:https://www.spinics.net/lists/linux-ide/msg53370.html
[22]:http://ark.intel.com/products/codename/37572/Skylake
[23]:http://ark.intel.com/products/codename/37572/Skylake
[24]:http://ark.intel.com/products/codename/37572/Skylake
[25]:http://ark.intel.com/products/codename/42174/Haswell#@All
[26]:http://www.anandtech.com/show/9562/intels-skylake-gpu-analyzing-the-media-capabilities
[27]:http://www.anandtech.com/show/9562/intels-skylake-gpu-analyzing-the-media-capabilities
[28]:https://trac.ffmpeg.org/wiki/HWAccelIntro
[29]:http://www.game-debate.com/gpu/index.php?gid=3295&gid2=3285&compare=iris-graphics-540-mobile-vs-intel-hd-graphics-520-mobile
[30]:https://www.freedesktop.org/wiki/Software/Beignet/
[31]:http://keithcu.com/wordpress/?p=3444
[32]:https://cgit.freedesktop.org/libreoffice/core/log/?qt=grep&q=hidpi
[33]:http://wiki.audacityteam.org/wiki/Linux_Issues#Hi-DPI
[34]:https://antergos.com/
[35]:https://wiki.archlinux.org/index.php/Unified_Extensible_Firmware_Interface
[36]:https://wiki.archlinux.org/index.php/Profile-sync-daemon
[37]:https://ffmpeg.zeranoe.com/builds/
[38]:https://www.nuget.org/
[39]:https://blogs.windows.com/buildingapps/2016/03/30/run-bash-on-ubuntu-on-windows/
[40]:http://keithcu.com/wordpress/?page_id=558
[41]:https://github.com/Microsoft/BashOnWindows/issues/992
[42]:http://notes.ericjiang.com/posts/751
[43]:https://wiki.archlinux.org/index.php/Desktop_environment

View File

@ -0,0 +1,311 @@
# Arch Linux on a Lenovo Yoga 900
联想 Yoga 900 笔记本安装 Arch Linux 系统后的感悟
_注意这篇文章比较长有将近 5500 多个单词而且还有很多非常有意思的链接因此你最好还是先给自己准备点喝的吧然后再花时间来阅读。_
![](http://keithcu.com/wordpress/wp-content/uploads/2017/01/Yoga900-1.jpg)
在 [联想 Yoga 2 笔记本电脑][2] 上使用了 3 年多的 Arch Linux 系统后,我决定换个新的 Yoga 900 笔记本电脑来安装 Arch Linux 系统:
_联想 Yoga 900 笔记本电脑在[亚马逊网站上的特价][1] 为 925 美元 —— 8GB 内存, 256 GB 固态硬盘, 3200×1800 的分辨率,处理器为 Skylake 3.2GHz Iris Graphics 显卡。_
同等配置的戴尔笔记本电脑 [XPS 13][3] 搭载新一代 Inter 处理器,售价 1650 美元。 Yoga 910 为当前最新款,价格为 1300 美元。但是,我压根就不会考虑这一款,因为它的键盘设计得太狗屎了。很多评论都从其外观颜色及材质方面大作文章,但是我偏偏从它的键盘设计上来挑刺。
### 键盘
Yoga 2 Pro 和 Yoga 900 这两款笔记本电脑从外观上看没啥区别。它的键盘设计跟曾经光鲜亮丽的 IBM Thinkpad 的键盘比起来可真是差远了,但是这还不算是最狗屎的键盘,好歹我还用了三年多的 Yoga 2 ,而且早已经习惯了。不幸的是,新款 Yoga 910 的键盘设计更是糟糕透了。
![](http://keithcu.com/wordpress/wp-content/uploads/2017/01/Yoga900-2.png)
_Yoga 2 和 Yoga 900 的键盘布局_
![](http://keithcu.com/wordpress/wp-content/uploads/2017/01/Yoga900-3.png)
_Yoga 910 的键盘_
Yoga 910 键盘的问题是它的 右-shift 按键位置不合理,你不挪动手根本就按不到那个键。这个键的位置非常特殊,可以说是跟我上 9 年级打字课时所用的 IBM 打字机键盘到目前为止用过的所有键盘都不一样。我更愿意看到这个失误出现在华硕或是戴尔公司的电脑上,而不是来自于曾经让一代代美国人学习和工作并且创造了打印机传奇历史的 IBM 公司。
Yoga 团队每一年都会更改键盘布局。想象一下,如果 IBM 公司在 20 世纪的时候也不断改变他们的打印机键盘布局,而且还吹嘘这是为了提高"[工作效率]"[4]。那么这个公司可能早就倒闭了!
我基本上还能习惯 Yoga 910 的向上/向下翻页键跟方向键整合到一起,其它的一些改变也无大碍,但是 shift 键就是设计上的一个败笔,我太讨厌因为某些东西而改变自己的使用习惯了。
其实,联想笔记本电脑在键盘的设计上还有很多地方需要改进,比如说,让音量增加键与应用程序关闭键不要靠得太近。尽管目前已经有一个降低亮度的开关了,他们也可以重新考虑设计一个更简单的方式来快速关闭显示器。他们还应该设计一个重叠式的数字小键盘。难道联想的工程师觉得只有在商务工作中才会使用到数字小键盘吗?
Yoga 910 的键盘布局改变得太多了,也许再也回不到曾经的老式键盘了。我希望 Yoga 的键盘不要再随便改了。我更愿意拥有一个比电脑更高效 10 倍的键盘。
我在联想官网的评论中看到有些用户由于对 Yoga 910 的键使用不习惯的原因而申请退货。我觉得联想公司应该制定这样一条规定:如果革个工程师想更改键盘布局,他们必须给出一个***非常充分***的理由,如果这种设计给用户在使用方面造成了巨大的不便,那么将以剁其一根手指的代价来让他也体会下这种痛苦。如果真有这样一条规则,那么将会大大减少那些毫无意义的更改键盘的行为。 Yoga 910 笔记本电脑可以说是联想公司呕心沥血之杰作了,但是其输入系统却是一大败笔。
### 总体评价
Yoga 2 对于我的任何操作,其反应速度都非常快。它的固态硬盘也非常给力,但是用在 Arch Linux 系统下就有些大材小用了。那些只使用 Windows 系统的用户就不会体会到他们的系统有多么的庞大臃肿:
![](http://keithcu.com/wordpress/wp-content/uploads/2017/01/Yoga900-4.png)
在 90 年代时期,由于处理器的性能每隔 18 个月翻一倍,并且软件的大小也经常成倍的增长,因此,一款新的电脑每隔几年就会发布出来。现在早已发生了翻天覆地的变化。新款的 Yoga 900 笔记本电脑在运行性能测试的过程中,速度比我的 Yoga 2 还要快 30% 。 Yoga 900 的 CPU 主频为 3.2 GHz ,老款的 Yoga 2 主频为 2.6 GHz ,因此, Yoga 900 最大的亮点是更快的 CPU 处理频率。
Haswell 处理器架构于 2013 年发布了,而 Skylake 处理器架构在 2015 年才发布,因此,经过两年的发展,处理器性能有了很大的改善。新一代的处理器最大的改进是采用 14 纳米工艺制造技术来代替原先的 22 纳米工艺技术,这意味着新款笔记本电脑散热更小,电池使用时间更长。我的老款的 Yoga 2 笔记本在中等亮度的情况下,电池使用时长只有 3 个半小时左右,但是新款 Yoga 900 的电池使用时长高达 7 小时。
Yoga 2 的转轴已经开始松动和裂开了,我也没有一个好的办法来拧紧,只能从网上找新的配件来更换或者发给联想售后进行维修了。
![](http://keithcu.com/wordpress/wp-content/uploads/2017/01/Yoga900-5.png)
Yoga 的转轴用于将笔记本电脑放平,甚至是将电脑合起来作为平板电脑使用,但是我觉得这样用起来很笨重,所以也就不想去自找麻烦。这么多年来,只要它在日常工作中能够正常打开和合拢,我就已经很高兴了。
Yoga 900 坚固的表链式铰链应该更耐用:
![](http://keithcu.com/wordpress/wp-content/uploads/2017/01/Yoga900-6-1.jpg)
有一个很明显的小毛病就是如果你摇晃笔记本电脑时,其格格作响的声音会让你误以为是内部的零部件损坏了,你自然会担心电子器件短路的危险!然而,这只不过是 800 多片钢片构成的仿表带铰链发出的声音。
Yoga 2 总的来说是一款设计精良的产品,但是如果我将显示器展平,然后单手拖住的时候,它会有一点向下弯曲,而且有时候键盘背光灯也会熄灭。两款 Yoga 笔记本电脑都很轻薄,但是 Yoga 900 看起来更坚固耐用一些。
### 触摸板
Yoga 2 最严重的问题出现在触摸板上。这不是硬件导致的,而是驱动程序自身的问题,由于触摸板驱动程序本身没人在维护,因此存在很多缺陷。很遗憾, Synaptics 公司本来可以很轻易地安排一个工程师来维护这几千行的代码,但是联想重新写了另外一个版本的与系统内核集成在一起的驱动程序,而且还没有公开发布出来。
然而,为了让触摸板设备和其它输入设备的管理和使用更加方便简捷,一个叫做 [Libinput][5] 的新软件库被建立起来。 Libinput 最好的一点就是,维护人员会修复各种缺陷。还有一个很适用的功能就是如果你左指尖触摸鼠标单击区域,它现在会通过你的右指尖记录指针移动轨迹。但是,让人难以接受的事情是, Synaptics 的这个基本的功能在 Linux 系统中很多年前就无法使用了。
触摸板设备一直运行正常,但是它不再像以前那样发出敲击声了。实际上这也不是什么问题,但是这会让我担心我在触摸板上的操作是否正确。老款的 Thinkpad 笔记本电脑有好几个左右按键,因此,如果其中一个损坏了,你可以使用另外一个,但是 Yoga 笔记本只有一个鼠标左右按键,如果损坏了就只能插入鼠标来代替使用了。(联想还巴不得你的电脑赶紧坏了好换新的。)
### 内核支持
当年我购买 Haswell 处理器的笔记本电脑时,硬件都是最新的,因此,我折腾了好几个月才把 Linux 驱动程序相关的问题解决了。而现在我使用的新一代的 Skylake 处理器的笔记本电脑,在[处理器发布 8 个多月后][6],其内核崩溃的问题才被修复了。以前老款笔记本电脑的 [电源管理][7] 一直运行不正常,但是从新款笔记本电脑使用来看,以前的问题大都不存在了,而且有了很大的改善。如果用户不进行任何操作,这个笔记本电脑会自动进入到低功耗 C6-C10 状态。(这个功能是由 Linux 系统中的  **powertop 省电工具** 进行控制的。)
电源管理这个功能非常重要,它不仅会影响到电池的使用寿命,而且由于[电解迁移][8]的原因,那些非常小的电路板会逐渐耗尽。英特尔公司甚至发出公告:”电池使用的长期可靠性是无法保障的,除非所有程序都运行在低功耗的空闲状态。“通过让程序运行在低功耗模式下,以使用更小的电源回路,从而让电池使用寿命更长。
现在 Haswell 处理器架构对 Linux 系统的支持性已经非常好了,但是之前的很长一段时间,它的支持性都很差。刚开始那一年,我提出了很多 Haswell 处理器相关的问题,但是现在可以看出这两款处理器在对 Linux 系统的支持上都有了很大的改善。
### 联想笔记本的 BIOS 不兼容 Linux 系统
在 Yoga 900 电脑上安装 Arch Linux 系统之前,我得在 Windows 系统中再格式化出一个新的 BIOS 分区来。实际上,我的电脑中得有 2 个 BIOS 系统。最新版本的 Yoga 900 BIOS [不包括][9]我需要的必备修补程序,犹豫了一会之后,我恍然大悟,然后我 [安装][10]了一个单独的 "仅 Linux 系统" 的 BIOS 更新,这样我的联想电脑就不再支持 Windows 系统了:"你不可怜下我吗?“
那些经常关注 Linux 系统的用户就很清楚, Yoga 900 和其它最新款的联想笔记本电脑无法安装 Linux 系统,因为它不会[检测硬件驱动程序][12]。联想回复其笔记本电脑已不再支持 Linux 系统了,因为它使用的是[新型的 RAID 控制器模式][13] 。然而,实现 RAID 机制就意味着需要更多的磁盘,而笔记本电脑只有一个硬盘,并且也没有多余的空间来安装另外一块磁盘了。
下面是联想给出的[官方解释][14]
>“为了更好地支持 Yoga 系列产品以及整个行业领先的 360 度铰链转轴设计技术的发展,我们采用了一种存储控制器模式,很遗憾,这种模式不支持 Linux 系统,也不允许安装 Linux 系统。”
我觉得很搞笑,为了转轴而采用特殊的存储控制器!这就好比一个汽车制造公司宣称由于新型的广播设备,他们必须改变汽车的轮胎一样。
这引发了巨大的争议,感谢 Reddit 网站的 [Baron][15][H][16][K][17] 的努力,他为媒体提供了大量的信息,并联系了伊利诺斯州检查院。搜索 "[联想 Yoga][18][L][19][inux 兼容性][20]" 出现 300000 条结果。联想或许会因为销售不允许用户安装自己的操作系统的”通用“ PC 而触犯法律。对于我来说,为电脑设置默认的操作系统是毫无意义的。
黑客也被卷入到这场”战争“中进来,他们最终发现通过设置 UEFI ,这款笔记本也能够支持 AHCI 控制器模式,只是默认被禁用了。简单来说,联想故意取消对 Linux 系统的支持没啥好处。因为大家都已经明白事实真相了,如果这件事闹到法庭上,联想也只能自取其辱。
幸运的是,这些新闻引起了他们的关注,并且他们也逐渐地更新了 BIOS 。这篇文章就是在运行着 Linux 系统的 Yoga 900 笔记本电脑上写的,因此,我们应该庆祝下这个伟大的胜利。大家都希望联想从中受到教训,但是我并不看好。他们本来就应该为你的电脑提供一个选择操作系统的机会。他们应该在用户之前就发现了这个缺陷了。我将等待一个周左右的时间才能拿到定制化的电脑。他们应该把分区设置好,并且让用户定制很多东西,安装最新版的软件,而不是使用一个需要很多更新的老镜像文件。
一些钟爱联想电脑的用户认为这是 Linux 系统自己的问题,是 Linux 系统本身就不支持最新的 RAID 驱动模式导致的问题。然而, AHCI 控制器模式本来是一个非常流行的标准,但是由于英特尔公司为这种硬件写的代码"[太糟糕][21]"而被 Linux 系统内核开发团队拒绝了。该团队要求英特尔公司提供这种硬件的详细设计说明,但是他们一直没有给出任何答复。
### 散热
当 CPU 占用很高时, Yoga 2 笔记本会变得很烫。有一次我把笔记本放到毯子上编译 LibreOffice 软件时就把底部的塑料壳烧焦了,这实在是太丑陋了,这让我看上去像是一个很穷酸的程序员。我试着用铁刷子和松脂油来擦除烧售的部分,但是也没什么鸟用。
![](http://keithcu.com/wordpress/wp-content/uploads/2015/04/20150327_135649-2.jpg)
新款的笔记本电脑使用金属外壳,不容易褪色,并且 Skylake 处理器架构比 Haswell 的要强劲得多。把散热口设计了跟转轴融合在一起,这是一个非常明智及巧妙的做法,如果散热口在其它位置则可能被堵塞住。
用了很多年的 Yoga 2 ,我觉得最烦人的一件事就是它的风扇里累积了厚厚的尘埃,运行时听上去就像是沙子摩擦的声音!这些尘埃分布得很广,使用时产生的声音也大,让人容易分心。我把笔记本电脑拆开来清除里面的尘埃,但是风扇的叶片是隐藏的,无法进行清除。我只能把整个风扇替换掉了。在 Yoga2 上完成简单的工作,比如文字处理和浏览器上网时,风扇不会旋转,但是当它旋转时,如果不带耳机会感到很烦人。
Yoga 900 的风扇叶片密度很高,而且运行的很平稳,也不会让人分心。 Yoga 900 的风扇好像一直都在旋转,但是速度非常慢,而且声音很小也很安静。我家里电冰箱和空气净化器的声音都要比它大得多,除了笔记本电脑在负载的情况下声音有点大,不过那也不影响我工作。
### 显示器
Yoga 2 的显示屏很大气,但是也同样存在大家所熟知的问题,比如屏幕上的黄色看上去更像是橙色。然而,整体画质看起来还算细腻,其它颜色方面也不错。 Yoga 900 的屏幕已经修复了那个黄颜色的问题。它不是一个真正的 4K 屏,实际上仅有 3200×1800 的分辨率,但是从 15.6 寸的显示屏上看,它的像素要比真正的 4K 屏要细腻得多,所以显示效果超级锐利。
当年我购买 Yoga 2 笔记本电脑时,由于其使用的是当时最新的 Haswell 处理器架构,所以我遇到很多英特尔显卡显示异常的问题,这些问题过了几个月后才被解决。之后,我还发现了一个会导致 Linux 系统崩溃的内存泄漏问题,并且这个缺陷好多年都没被处理。
我在 VLC 播放器中使用( shift + 箭头键)快进视频时,遇到了好几次内存耗尽的问题。系统也没显示 VLC 播放器占用了多少的内存,但是电脑内存却耗尽了。很明显这是内核导致的内存泄漏问题。我创建了一个 swap 文件作为虚拟内存使用,以减少内存耗尽的时间,但是有好几次我没注意时,这个文件又被占满了。几年后,这个问题逐渐消失了,而且现在 Linux 系统也运行得很稳定。
大家都认为英特尔公司为 Linux 系统开发的驱动程序是最好的,但是他们更像是微软内部的一个实验项目。英特尔 公司的驱动程序开发人员都很专业,只是 Linux 系统的驱动开发人员都不够多。在发布硬件之前,他们都竭力让驱动程序做得更完美。 英特尔公司生产的 [1][22][13][23] [这些处理器][24] 都是基于 Skylake 处理器架构的,只是在特性上有细微的区别。听起来你会觉得有很多类型的处理器,但是在 [Haswell 处理器][25] 时期,英特尔公司生产出高度集成的 256 核芯片处理器。10 年前我听一个 Inter 公司的员工说过,相对于 Windows 来说,他们仅投入了 1% 到 Linux 系统上,从现在的情形来看,确实是那样的。
在我使用 Yoga 2 的过程中唯一遇到的性能问题是无法正常播放 4K 视频。屏幕经常出现卡顿,或是出现每秒跳跃 5 帧的现象:
![](http://keithcu.com/wordpress/wp-content/uploads/2017/01/VlcGlitch.jpg)
Yoga 2 甚至是在播放 1920×1080 分辨率的视频时有时候也显得很吃力,看样子它最多只能以 60fps 的速度来播放视频。出现这样的情况也可能是因为我一直在运行着其它的应用程序,比如 Firefox 浏览器和 LibreOffice 办公软件。
Skylake 处理器主要用于在 60 fps 的速度下使用 H.264 、 VP9 以及其它解码方式来播放 4K 视频。实际上这款处理器中有很多硬件专门用于加速[多媒体][26][特性][27]。我尝试使用 **ffmpeg 软件** 来处理 H264 格式的硬件编码,我发现即使只使用一个 CPU 的情况下,其处理速度也比原来的处理器快 4 倍。这种性能太棒了。不爽的是,在设置的过程中有点麻烦,因为你必须使用很多命令行参数:
“**-threads 1 -vaapi_device /dev/dri/renderD128 -vcodec h264_vaapi -vf format=nv12|vaapi,hwupload**”
我尝试找到一种方法让 **ffmpeg 软件** 保存这些命令,这样我就不用每次都手动输入这么多参数了,但是最后发现根本行不通。而且无论怎样,在整个过程中也不能自动传递这些参数。我还发现在使用这个硬件的的过程中不能重置视频大小,只能忽略或接受,因此,我很少会用这个工具。如果 **ffmpeg 软件** 可以实现这一点就完美了。由于很多用户都不了解,或者是不想太麻烦,所以还有很多未使用的硬件资源。这个软件有很多跟 Linux 系统和 Windows 系统相关的应用接口,如果要进行视频编码和解码,将会是[一件麻烦事][28]。
Skylake 处理器架构在播放 4K 视频方面表现得更出色,但是有时候它也会出现卡顿现象,然后瞬间降到 10 fps 的播放速度。我想起其中一部分卡顿现象就是在播放《X 战警》的过程中。我尝试在 Wayland 下播放 4K 视频时却很流畅,这让我非常满意。很高兴看到 OpenGL 给予的大力支持。在硬件方面, Inter 公司 2014 年以来支持的最新版本是 4.5 。
我的 Yoga 900 (-13ISK2) 笔记本电脑实际上是一个升级版,使用比 520 [更快][29] 的 Iris 540 图像协同处理器,而且它的流处理器多达 24 个。然而,它只能用来玩 SuperTuxKart 游戏,而且还得将游戏显示效果设置为中等,分辨率调整为 1600×900 ,速度为 20 fps ,我也不想在这里吹什么牛。说真的,这款游戏比前几年改善了很多,而且游戏界面也漂亮得多。
![](http://keithcu.com/wordpress/wp-content/uploads/2017/01/Screenshot-from-2017-01-10-17-03-57.png)
英特尔公司在中国有一个从事[使能][30]的团队,专门支持 OpenCL 对显卡的使用。但是,我从未看到 Blender 的任何用户使用它,因此我怀疑这个团队是不是作摆设用的。英特尔公司已经很长时间都没有支持 OpenCL 了,那些使用 Blender 软件处理重要工作的用户早已换成 Nvidia 或者 AMD 显卡,即使英特尔公司后来重新写了代码,大家也没太多的兴趣做测试。
有一件事让我感到非常意外,我在另外一台机器上做光线追踪测试时发现,一个四核的处理器比使用循环引擎的 NVidia 960M 的处理器要快得多。很明显,在处理那个任务时, 640 CUDA 多核心处理器也比不上 4 个英特尔公司的 CPU 。更高级的英特尔处理器有 2000 多个核心,性能更强悍。
### HiDPI
最近这几年, Linux 系统在高分辨率屏幕方面已经做得越来越好了,但是仍然有很长的路要走。还好目前的 Gnome 版本对 HiDPI 的支持也算完美。如果你把火狐浏览器的 **layout.css.devPixelsPerPx** 这个参数值设置为 2\ ,其显示效果更美观。然而这个 13.3 寸的屏幕分辨率还是显得略小了些,我还安装了一个无斜视加强版插件,这让屏幕在 120 度范围内看起来更方便。
很高兴地看到 LibreOffice 办公软件的界面在当前设置的屏幕下变得更加美观,因为我安装了 2014 年 4 月份发布的[一些补丁][31],而且这些功能还一直在不断的完善中。最大的问题是 LibreOffice 软件界面的工具图标重叠起来了。有很多主题都包括 SVG 图标,但是这些图标不会跟产品一起发布出来。跟 PNG 类型的图标相比, SVG 图标加载更慢,而且还要占用缓存。[Tomaž Vajngerl 在这方面投入很多的精力][32],但是还未发布出来。尽管这样, LibreOffice 比那些没有易识别图标的 Linux 系统应用程序要漂亮得多。
应用程序在高分辨率屏幕中的检测与应用方面正在不断的完善,但是还有其它一些很流行的小程序,比如 Gimp Audacity 和 Inkscape 仍然不能使用。我为 Gimp 软件安装了一个很强大的定制化主题,但是所有的图标都变得大不一样,尽管这些图标已经显示得够大了,但是也很难识别出来。
Linux 系统仅占了 1.5% 的市场份额,然而,遗憾的是其相关负责人也没有对这些问题给予更多的重视。虽然很多应用软件逐步使用 GTK 3 工具来开发它们的图形界面,但是 Audacity 这款音频处理软件好像是已经[终止][33]开发了。在第一次调查中我发现,那些提供长期支持的应用程序仍然有很多地方需要改进,但是 3 年多过去了,即使是那些很出名的软件也没做到位。
### SSD 固态硬盘
由于我平时对系统做了各种各样的优化,尤其是对火狐浏览器做的优化,因此我的老款电脑的硬盘仍然可以正常工作。还记得我的 **/tmp** 目录被我设置成自动作为 RAM 设备,因此,我经常把文件默认下载到那里。有时候我会在 /tmp 目录下把一个 500 MB 的视频剪辑成 20 MB 的小视频,或者是转换成另外的格式,因此我对硬盘的写操作做得比较频繁。这样做的工作量很大,也可能没必要,但是在 RAM 存储中运行速度更快。
在这三年里,我几乎对每个硬盘的存储单元做了 25 次写入,这意味着这块硬盘可以使用 350 年左右。极大部分的写操作都用于 Arch Linux 系统的更新。我每个月都会构建新的 LibreOffice 软件,每周都会更新“稳定”版系统内核。实时把系统升级到最新棒真的让人很爽,但是与 Debian 的稳定版系统相比起来,这将会进行 100 多次写入操作。然后,能够让每一个系统组件都升级到最新版,这也是值得的。
新的三星硬盘诊断工具也无法检测出每个硬盘存储单元的写次数。事实上,我也不能确定这个硬盘的存储单元类型是什么以及在处理任务的过程中写了多少次。我相信从“占用率“这个数据可以看到硬盘的使用时长,但是也许这只跟空闲的存储单元有关。我没有找到任何相关文档,因此我只能猜测到大致跟下面的数据差不多了:
|||
|--|--|
| **型号:** | **SAMSUNG MZVLV256HCHP-000L2** |
| **固件版本(0x06)** | **3 Slots** |
| **可用空间:** | **100%** |
| **可用的空闲阈值:** | **10%** |
| **已用百分比:** | **0%** |
| ****存储单元写数据:**** | **198,997 [101 GB]** |
| **存储单元写数据:** | **305,302 [156 GB]** |
| **主机读命令:** | **3,480,816** |
| **主机写命令:** | **10,176,457** |
| **错误日志条目信息:** | **5** |
### 损坏的左 Ctrl 键
在使用了几个小时之后,我发现一个问题,如果我按键盘左上角时,左 Ctrl 键会弹起来:
![](http://keithcu.com/wordpress/wp-content/uploads/2017/01/Yoga900-7-1.png)
_损坏的 Yoga 900 按键注意跟右侧对比下你会发现左侧少了个小圆柱体形状的东西_
Yoga 900 键盘布局跟 Yoga 2 Pro 版一致,但是内部结构不同。 Yoga 2 Pro 版的键盘不能单独移除和替换按键,而且你也没有办法撬起任何按键,除非那个按键被你彻底搞坏了。 Yoga 900 的按键跟老款的 Thinpad 笔记本一样的:每个按键都是分开的,你可以单独取下来进行更换。
然而,还有一个小毛病,每个键轴有 4 个小圆筒状的凹槽部件,如果不小心丢失了一个,那么该按键就只有三个接触点了,如果你不敲击到按键的中间位置,那么这个按键的键帽将会逐渐脱落下来。
我把这个问题反馈给联想。尽管这些按键还能使用,也可以替换成新的,但是他们只替换整个键盘,不会寄送任何零散部件。他们建议我把笔记本电脑寄给联想售后中心进行维修,或者是送到极客小组服务中心。我知道寄到联想售后的话至少要 2 周的时间,因此我咨询了当地的商店,看他们是否有 Yoga 笔记本的键盘配件。他们告诉我,他们不维修电脑,只负责把它寄到亚特兰大。那里曾经有很多地方可以维修 IBM 的各种笔记本电脑,而且也有各种配件,但是现在已经是不可能的了。
我用了好几个小时后才注意到了这个问题,我确信那是生产笔记本电脑过程中的疏忽导致的。这是一块非常小的塑料块,在装配的过程中就早已变形或损坏了。
尽管这个电脑还在保修期,可以免费进行维修,我可不想为这些小事情耽搁太多时间,因此我在网上找到一个叫做 laptopkey.com 的网站,然后订购了一个换键和转轴。真是太诡异了,竟然有三种类型的转轴!我花了好一会才搞明白我的电脑适合哪一种类型,因为这三种类型太难区分了:
![](http://keithcu.com/wordpress/wp-content/uploads/2017/01/BigHinges-2.jpg)
因此我预定了这个配件,但是还得花费至少一个星期的时间才到收到。这真是太让我抓狂了,因为我每次使用复制粘贴、视频跳跃或者是在编辑器里按单词移动及其它相关操作时,只能使用右 Ctrl 键。我觉得我可以把右边的 Ctrl 键更换到左边来,但是我从未这么弄过。
因此,我尝试跟着网上找到的视频步骤把这个键弄下来:我先用指甲扣起左上角到一定高度。然后用同样的方式操作右上角,但是另外一个小塑料片被折断了,因此我弄坏了两个键轴。如果不损坏这些非常细小的塑料夹片,根本不可能把按键撬下来。这种类型的键盘只不是理论上可以进行更换吧。
因此,我决定采用笨办法,使用强力胶。我情愿让这个该死的按键就这样固定死了,我暂时没有一个紧急的方法来替换它们。这真是太折腾了,因为我只需要大概直径 1mm 的胶水:如果弄太多的胶水可能会让情况变得更糟糕。
我维修小型遥控飞机的经验在维修电脑上也非常有帮助,我修好它了,而且左边的 Ctrl 键也固定好了。右边的那个 Ctrl 键还处于分离状态,但是我几乎用不到。我的心情又好起来了,真是柳暗花明又一村啊,但是懂得如何维修电脑也是个非常重要的技能。
### Antergos 与 Arch Linux 系统对比
在我使用了 3 年多的 Arch Linux 系统之后,我再也没兴趣去尝试其它操作系统了。虽然英特尔公司更新驱动程序的步伐有些落后,但是无论怎样,在日常工作中使用 Arch Linux 系统还是挺让人愉快的,而且每一个星期都有所进步。实时更新任何程序真的让人很爽。我经常使用比 Ubuntu 系统发布时间还要新的软件包。虽然 Ubuntu 用户可以在自定义的 PPA 中找到更新的软件包,但是这种软件包都没有经过任何测试或修复,因此用户在使用过程中会遇到各种各样的问题。
也有用户抱怨 Ubuntu 系统升级时会导致机器自动重启或者强制用户重新安装软件,因此,即使安装的过程很快,之后却需要很长的时间来维护。我每次听到有人抱怨 Arch 系统的安装过程时,最终的原因还不是他们自己操作不当或是文件系统损坏的问题。
我曾经想尝试安装 [Antergos 系统][34],那是一款基于 Arch Linux 并搭载了桌面环境的 Linux 发行版。然而,安装过程中的设置界面在显示器上看不清楚,而且最小化安装后也识别不到触摸板,那是我仅有的 1 GB 存储空间了。因此,我决定还是重新安装原来的 Arch Linux 系统。还好 Yoga 笔记本仍然支持传统的 BIOS 启动方式,这样我就不用再去折腾 [UEFI][35] 了。
很遗憾我没能试用 Antergos 系统,因为我觉得对于那些技术水平一般的用户或是想快速入门 Arch Linux 系统的用户来说, Antergos 算是一个非常强大的 Linux 发行版了。 Arch 在维基上有丰富的文档新资料教你如何完美地使用这个 Linux 系统。我喜欢每周定时对固态硬盘做优化,包括调试[用户配置文件-同步-进程][36]脚本、对安卓系统的支持以及在视频播放中使用硬件加速等等。在 Linux 系统中有很多大家都需要去折腾的功能特性,只需要输入几行命令就可以搞定了。
Manjaro 也是一款非常流行的基于 Arch Linux 并搭载了桌面环境的 Linux 发行版,但是用了 3 年多的 Arch Linux 系统后,我更信任使用 Arch 系统中的软件包来解决组件之间的问题。我在 Reddit 网站看到一些评论,有用户反映说 Manjaro 系统升级后就崩溃了。
我对 Arch Linux 系统唯一不爽的一点就是它又难看又不可读的引导加载界面。还好我只需要使用老电脑中的 **grub.cfg** 配置文件来替换掉就可以了。
### 安装 Arch Linux 系统
起初我只想简单地把硬盘从老的笔记本电脑移植到新的笔记本电脑上,这样我就不用安装任何东西了,但是拆开电脑后,我发现 M.2 接口的固态硬盘形状很特殊。本来我也可以使用一个简单的块复制方法来完成移植,但是这一次是一个很好的回顾安装过程的机会,所以我决定从头再来一遍。 3 年多的时间里,我安装了很多没用的应用程序,即使有些被我卸载了,系统中还存在很多的遗留文件。
由于 Arch 900 笔记本电脑已经发布出来一段时间了,其硬件也不是最新的,所以安装 Arch Linux 系统的过程进行得很顺利。我还要使用 **rfkill 工具来开启无线上网** 功能,除此之外,系统都正常运行了。显然, Linux 系统下还不能正常使用 rfkill 工具。幸运的是在启动 rfkill 工具时, **systemd** 会自动恢复rfkill 的数据。
### Kernel Buglist内核故障列表
有一件事让我非常惊讶, Linux 操作系统的缺陷列表太混乱了。我知道有很多的用户参与其中,其变化频率也很高,但是,一成不变的最糟糕的事情却是系统缺陷报告。我搞不懂为什么有些系统缺陷已经存在好多年了,但是却丝毫没有修复的迹象。
我在上次的审查中打过一个很好的比方。假设航空公司花了一两年的时间才把你丢失的行李找回来了。还你会信任那家公司吗?实际上,如果你还有几千个已知的系统缺陷和上百次系统回归,那么你发布新的发行版有什么意义呢?如果波音公司的每一架飞机都有 1% 的坠机概率,那他们会这么多年都置之不理吗?
也许 Linux 系统基金会应该雇佣一些专职的工程师来修复那些看似被遗忘的系统缺陷问题。有很多人从事 Linux 系统工作,大家都清楚该系统有很多历史缺陷未修复——通常情况下,这些问题都是普通用户自己处理的。我觉得目前的 Linux 系统就不要发布任何更新了,先花几个月的时间去修复那些系统缺陷,直到缺陷数量小于 50\ 个时,再发布新版本,这样的系统内核会更稳定。现在还有 4672 个系统缺陷问题未解决。这将会是一个非常好的改变发行版主版本号的理由。
有些东西跟每周发布一个新的稳定发行版是相悖的,但是这种方式还持续了这么多年了,而且他们每次都发布一些重要补丁,因此他们也算是做了一些非常有意义的工作。内核的开发速度很快,也变得越来越好,因此早已超出我吐槽的范围了,但是我还是觉得他们应该尝试一些新的东西。
至少,系统缺陷问题应该在规定的时间内处理。如果超出指定时间,这个系统缺陷应该提交给到维护工程师并逐渐发送给 Linux 本人。如果某个领域内存在很多的历史缺陷也没人去修复,那么 Linus 应该公开并严厉批评相关组织机构。他们更应该像波音公司那样去思考解决问题。
### Lenovo
很多 Linux 用户都痛击联想公司对定制化的笔记本缺少支持,好在他们创造了性价比较高的硬件。正如我多年前写的一样,很明显,联想公司在发布 Yoga 2 之前就没人安装过 Linux 系统来进行测试, Yoga 900 笔记本也是如此,因为这是根本不可能的事情。
我觉得他们公司的每个员工都应该安装双系统。这在设置上并不难,用户也更希望他们这样做。联想有 60000 多员工。至少他们应该在公司内部成立一个 Yoga 团队,然后招一些人来着手处理 **Linux 系统** 问题。
Windows 系统在很多方面比 Linux 系统更难用。Windows 系统虽然能够运行更多的应用程序,但是我觉得也许他们公司的大部分员工还是更乐于使用自定义的 Linux 系统吧。
尽管现在联想对 Linux 系统很不屑,他们制造的麻烦比软件方面还多。在很多型号的笔记本电脑中, RAM 芯片被焊接固定了。他们只允许白名单设备和预授权的插件安装到联想笔记本电脑中。 Yoga 笔记本也没有独立显卡,而且联想公司本来也不支持更新主板上的插件。我想有人会把这些矛头指向联想公司的 CEO 。
### 总结
Yoga 900 笔记本电脑的售价确实让人激动不已,而且相对于前一款 Yoga 2 来说,其改进方面也是有目共睹的。相近配置的苹果 Macbook Pro 笔记本电脑价格为 1500 美元,但是像素却比 Yoga 900 少了 40% 。
Windows 系统从 Linux 系统中汲取了很多特性,但是 Windows 系统一直没有一个包管理器来对那些非常有趣的且免费的预编译软件组件提供本地支持。因为 ffmpeg 工具使用很多的[依赖包][37],所以在 Windows 系统中安装 **ffmpeg ** 工具就是一件很头疼的事,
微软建立了 Windows 应用商店,这有点类似 Linux 系统中的软件仓库,但是它不会处理软件包之间的依赖性,而且也不允许用户设置个人软件仓库。微软还开发了一个新的包管理器,叫做 [NuGet][38],但是它主要用于 .Net 语言开发的软件。也包括 ffmpeg 工具的安装包,但是没有与该代码相关的任何依赖包,因此即使安装完成后也没啥用。
去年 3 月份,[微软公司宣布][39] Windows 系统支持运行 Ubuntu 的命令行及应用程序,这的确是一个革命性的转折点。([他们本应该先支持 Debian 系统][40]。)甚至还有[热议][41]声称 Windows 系统将会支持更多的 Linux 发行版,这真是太让人激动了。
至少对于我来说,我不需要使用任何 Windows 的应用程序,也不需要浪费额外的时间去维护了。在 Windows 系统中修复问题时,你可以到很多不同的地方查询解决问题的方法。 Linux 系统有很多的地方要进行配置,但是总的来说,这已经很简单了。
我有个朋友为了更新驱动程序,需要在 Windows 下安装第三方软件,因为更新这种操作需要从微软网站以及其它更多的网站来抓取源代码。 Windows 系统已经比前几年做得更好了,有更多的游戏和桌面应用程序,但是它仍然是一个封闭式老系统。
我发现 Gnome Classic 桌面给人一种简洁性的体验。我希望它不是使用很繁杂的[流行 Javascript 脚本][42]语言编写的,他们还要重新建立一个关于定制化主题和颜色主题的社区。 Gnome 2 和 Windows 10 系统中的有些非常有用的功能也消失了,而且也没有老版本的稳定。 2011 年发布的 Gnome 3.0 完全就是走回头路,但是 6 年后的 Gnome 3.22 终于再续辉煌。
Gnome Classic 桌面环境是最优秀的图形化界面之一,[很多优秀的特性][43]都变得越来越好了。已安装完成 Arch Linux 系统的 Yoga 900 笔记本电脑现在都运行正常了,我期待着 Linux 系统对 HiDPI 模式和其它方面的改进!我迫不及待地想深入学习 LibreOffice 办公软件里的语法检查特性。
--------------------------------------------------------------------------------
via: http://keithcu.com/wordpress/?p=3739
作者:[keithccurtis][a]
译者:[rusking](https://github.com/rusking)
校对:[校对者ID](https://github.com/校对者ID)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]:http://twitter.com/keithccurtis
[1]:https://www.amazon.com/Lenovo-13-3-inch-Multitouch-Convertible-Platinum/dp/B01NA6ANNK/
[2]:http://keithcu.com/wordpress/?p=3270
[3]:http://configure.us.dell.com/dellstore/config.aspx?oc=cax13w10ph5122&model_id=xps-13-9360-laptop&c=us&l=en&s=bsd&cs=04
[4]:http://blog.lenovo.com/en/blog/why-you-should-give-in-to-the-new-thinkpad-keyboard
[5]:https://www.freedesktop.org/wiki/Software/libinput/
[6]:https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=762ce4458974534a2407cc924db05840c89105df
[7]:https://mjg59.dreamwidth.org/41713.html
[8]:https://en.wikipedia.org/wiki/Electromigration
[9]:http://support.lenovo.com/us/en/products/Laptops-and-netbooks/Yoga-Series/yoga-900-13isk2/80UE/downloads/DS112754
[10]:http://support.lenovo.com/us/en/products/laptops-and-netbooks/yoga-series/yoga-900-13isk2/downloads/ds119354
[11]:https://linux.slashdot.org/comments.pl?sid=9861381&cid=53241071
[12]:https://www.reddit.com/r/linux/comments/54gtpc/letter_to_the_federal_trade_commission_regarding/
[13]:http://venturebeat.com/2016/09/21/lenovo-confirms-that-linux-wont-work-on-yoga-900-and-900s-laptops/
[14]:http://venturebeat.com/2016/09/21/lenovo-confirms-that-linux-wont-work-on-yoga-900-and-900s-laptops/
[15]:https://www.reddit.com/user/baronhk/
[16]:https://www.reddit.com/user/baronhk/
[17]:https://www.reddit.com/user/baronhk/
[18]:https://duckduckgo.com/?q=lenovo+yoga+linux+compatibility&t=hs&ia=web
[19]:https://duckduckgo.com/?q=lenovo+yoga+linux+compatibility&t=hs&ia=web
[20]:https://duckduckgo.com/?q=lenovo+yoga+linux+compatibility&t=hs&ia=web
[21]:https://www.spinics.net/lists/linux-ide/msg53370.html
[22]:http://ark.intel.com/products/codename/37572/Skylake
[23]:http://ark.intel.com/products/codename/37572/Skylake
[24]:http://ark.intel.com/products/codename/37572/Skylake
[25]:http://ark.intel.com/products/codename/42174/Haswell#@All
[26]:http://www.anandtech.com/show/9562/intels-skylake-gpu-analyzing-the-media-capabilities
[27]:http://www.anandtech.com/show/9562/intels-skylake-gpu-analyzing-the-media-capabilities
[28]:https://trac.ffmpeg.org/wiki/HWAccelIntro
[29]:http://www.game-debate.com/gpu/index.php?gid=3295&gid2=3285&compare=iris-graphics-540-mobile-vs-intel-hd-graphics-520-mobile
[30]:https://www.freedesktop.org/wiki/Software/Beignet/
[31]:http://keithcu.com/wordpress/?p=3444
[32]:https://cgit.freedesktop.org/libreoffice/core/log/?qt=grep&q=hidpi
[33]:http://wiki.audacityteam.org/wiki/Linux_Issues#Hi-DPI
[34]:https://antergos.com/
[35]:https://wiki.archlinux.org/index.php/Unified_Extensible_Firmware_Interface
[36]:https://wiki.archlinux.org/index.php/Profile-sync-daemon
[37]:https://ffmpeg.zeranoe.com/builds/
[38]:https://www.nuget.org/
[39]:https://blogs.windows.com/buildingapps/2016/03/30/run-bash-on-ubuntu-on-windows/
[40]:http://keithcu.com/wordpress/?page_id=558
[41]:https://github.com/Microsoft/BashOnWindows/issues/992
[42]:http://notes.ericjiang.com/posts/751
[43]:https://wiki.archlinux.org/index.php/Desktop_environment