Lenovo Yoga Slim 7 14

Mini Review:

In 2021 its very hard to find a laptop under £1000 with a decent screen. Most have 45% NTSC Colour Gamut. Most reviews will tell you this is ok as long as you are not gaming or photo editing. It is NOT ok. At 45% NTSC colours are washed out. Especially the red. This is noticable even just browsing the web, let alone looking at photos. A 45% NTSC screen is just not good enough, yet this is what most laptops come with. The minimum for a usable laptop is 72% NTSC or 100% sRGB.

Laptop hinges are another area which can be difficult. Most laptops now come with a hinge that uses the lid/screen to prop the body off the ground. The reasoning behind this is that it creates a gap between the laptop and desk for airflow because modern laptops get so hot. This is no good if you are actually using the laptop on your lap. Also the jury is out on the reliability and durability of these hinges. The Lenovo has a traditional hinge and little feet that keep the case off the desk. That said it does not seem to get hot under normal operation.

Ports:

Ports are another issue on laptops. Its hard to find one with a decent array of ports. Trackpads are usually awful so first thing I do is plug a USB mouse in, thats one port gone straight away. The Lenovo has a decent amount of ports.

AMD Ryzen 4700U Processor:


Good Stuff:

Bad Stuff:


Hard Drive Layout

Like all machines now, the laptop comes with Windows pre-installed and a recovery partition and no CD/DVDs. I have no plns to use Windows at all, so I backed up the whole disk via dd to a file image on a spare USB hard drive. I then installed Ubuntu Budgie 20.10 using full disk encryption and the whole hard drive.

Disk /dev/nvme0n1: 476.94 GiB, 512110190592 bytes, 1000215216 sectors
Disk model: SAMSUNG MZVLB512HBJQ-000L2              
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: gpt
Disk identifier: 885501F8-62CB-459A-86D0-A69CBBB64903

Device             Start        End    Sectors   Size Type
/dev/nvme0n1p1      2048    1050623    1048576   512M EFI System
/dev/nvme0n1p2   1050624    2549759    1499136   732M Linux filesystem
/dev/nvme0n1p3   2549760  1000214527 997664768   475G Linux filesystem

Linux is installed in an encrypted partion which contains two LVMs, one for swap and one for root.

nvme0n1
│                                                                             
├─nvme0n1p1
│    vfat   FAT32       44BA-16B5                                  /boot/efi
├─nvme0n1p2
│    ext4   1.0         5e7309a6-6f5b-44e3-aff7-e92b969bdb97       /boot
├─nvme0n1p3
│    crypto 2           b6a7071a-e553-4e95-9544-9dc9ddcfed61                  
│ └─nvme0n1p3_crypt
│    LVM2_m LVM2        T25pQf-qlNw-pwNV-5dvg-xOTO-KoKG-tW3CjD                
│   ├─vgubuntu--budgie-swap_1
│   │  swap   1           b02b828e-f0bf-4ecb-910a-b88392056049     [SWAP]
│   └─vgubuntu--budgie-root
│      ext4   1.0         108f19e8-9b45-48b1-9eb6-d20fd8f011d4     /

There are two issues with the above layout. Ubuntu only installs 1GB of swap, which is not enough if S4 Hibernate is required. Also I am not keen on everything being in one large root partition.


See separate disk encryption notes...


Relayout Hard Drive

There are two issues with the above layout. Ubuntu only installs 1GB of swap, which is not enough if S4 Hibernate is required. Also I am not keen on everything being in one large root partition.

The first task is to mount and backup the root filesystem. To do this we use a spare USB drive with atleast 30GB of free space, and boot from an Ubuntu Live USB stick.

Mount the encrypted volume:

root@ubuntu-budgie:~# cryptsetup open /dev/nvme0n1p3 linux
Enter passphrase for /dev/nvme0n1p3: 

Scan for volume groups:

root@ubuntu-budgie:~# vgscan
  Found volume group "vgubuntu-budgie" using metadata type lvm2

root@ubuntu-budgie:~# vgchange -ay
  2 logical volume(s) in volume group "vgubuntu-budgie" now active
 

Scan for volume groups and logical volumes:

root@ubuntu-budgie:~#  lvscan 
  ACTIVE            '/dev/vgubuntu-budgie/swap_1' [980.00 MiB] inherit
  ACTIVE            '/dev/vgubuntu-budgie/root' [473.00 GiB] inherit

Mount the root partition:

root@ubuntu-budgie:~# mkdir /media/root
root@ubuntu-budgie:~# mount /dev/vgubuntu-budgie/root /media/root

Mount a USB drive with atleast 30GB of space:

root@ubuntu-budgie:~# cd /media/data
root@ubuntu-budgie:/media/data# mkdir BACKUP

Backup / to the USB drive:

root@ubuntu-budgie:/media/data# cd BACKUP
root@ubuntu-budgie:/media/data/BACKUP# cp -a /media/root/. .

Unmount the root filesystem:

umount /media/root

The next step is DESCRUCTIVE. It will delete the Linux installation. All data will be LOST. Only do this on a new install, if you know what you are doing, and if you have backed up the data following the steps above!

Delete the logical volumes:

lvremove /dev/vgubuntu-budgie/swap_1
lvremove /dev/vgubuntu-budgie/root

Note at this stage if you only want to increase swap, at the expense of the root volume there is no need to change the disk partition and volume group. You can skip straight to recreating the logical volumes. LINK here STEVE.

Delete the logical volumes:

cryptsetup remove /dev/mapper/linux

Change the size of the /dev/nvme0n1p3 partion using your favourite disk utility tool:

fdisk /dev/nvme0n1

Create smaller partition /dev/nvme0n1p3. I shrunk it to 75GB and created a new 400GB /dev/nvme0n1p4 which will be an encrypted LUKS volume and hold all my data.

Device             Start        End   Sectors   Size Type
/dev/nvme0n1p1      2048    1050623   1048576   512M EFI System
/dev/nvme0n1p2   1050624    2549759   1499136   732M Linux filesystem
/dev/nvme0n1p3   2549760  159836159 157286400    75G Linux filesystem
/dev/nvme0n1p4 159836160 1000214527 840378368 400.7G <--New partion to hold data

Create an encrypted volume on the 75GB /dev/nvme0n1p3 partition:

cryptsetup -y -v luksFormat /dev/nvme0n1p3

cryptsetup open /dev/sda3 linux

Create physical and logical volumes:

pvcreate /dev/mapper/linux

vgcreate vgubuntu-budgie /dev/mapper/linux

Create two logical volumes in the 75GB partition. I used 9GB to match the memory, use smaller if you do not need to hubernate.

lvcreate -L 9G vgubuntu-budgie -n swap_1    

lvcreate -l 100%FREE vgubuntu-budgie -n root

Create the filesystems on the two new logical volumes:

mkswap /dev/vgubuntu-budgie/swap_1 

mkfs.ext4 /dev/vgubuntu-budgie/root 

The layout should look something like this now:

lsblk --fs

├─nvme0n1p3 crypto 2           b6a7071a-e553-4e95-9544-9dc9ddcfed61
│ └─linux
│           LVM2_m LVM2        T25pQf-qlNw-pwNV-5dvg-xOTO-KoKG-tW3CjD 
│   ├─vgubuntu--budgie-swap_1
│   │       swap   1           b02b828e-f0bf-4ecb-910a-b88392056049
│   └─vgubuntu--budgie-root
│           ext4   1.0         108f19e8-9b45-48b1-9eb6-d20fd8f011d4

Mount the newly created empty root partition:

mount /dev/vgubuntu-budgie/root  /media/root

Copy back the root filesystem from the USB backup created earlier:

cd /media/root
cp -a /media/data/BACKUP/* .

Next we need to adjust the luksUUID of /dev/nvme0n1p3 to match what was in /etc/crypttab:

cat /media/root/etc/crypttab

nvme0n1p3_crypt UUID=6b1a9ade-99a7-4778-baf0-106bd2f21254 none luks,discard

Change the luksUUID of /dev/nvme0n1p3 to match the output above:

cryptsetup luksUUID /dev/nvme0n1p3 --uuid "6b1a9ade-99a7-4778-baf0-106bd2f21254"

Now reboot and the new disk layout should be effective!


Suspend and Hibernate

Use the following command to see which suspend modes are supported:

dmesg | grep ACPI:\ \(

[    0.341638] ACPI: (supports S0 S4 S5)

The laptop does not support S3 Suspend. When it goes into suspend it actually uses S0, s2idle, which uses quite a bit of power.

Hibernate will save the RAM to swap (disk), and power down the machine completely. Note to support Hibernate Secure Boot has to be disabled.

Use the following command to test Hibernate:

systemctl hibernate

To check the logs:

sudo journalctl | grep -Ei "PM: |hibernation" 

To change the laptop to hibernate when the lid is closed edit the login.conf file:

/etc/systemd/login.conf

HandleLidSwitch=hibernate

Change the GRUB config to resume from the swap partion:

/etc/default/grub

GRUB_CMDLINE_LINUX_DEFAULT="quiet splash resume=/dev/mapper/vgubuntu--budgie-swap_1"

Update grub:

sudo update-initramfs -u -k all
sudo update-grub

I have found the lid switch on the Lenovo pretty sensitive. This means even if you catch the lid it will boot the laptop. I tried a few Linux option to disable booting when the laptop starts:

None of these worked for me.

What did work for me was disabling "Flip to Boot" in the laptop BIOS.

We still have the problem that after 15 minutes in Ubuntu Budgie that the laptop will suspend (to S0) and not hibernate.

If we disable AllowSuspend in sleep.conf the option will disappear completely. I ofen wander away from my latop, so would like some sort of suspend/hibernate. To work around this I changed the definition of suspend to be hibernate:

/etc/systemd/sleep.conf

AllowHybridSleep=no
AllowHibernation=yes
SuspendMode=platform shutdown
SuspendState=disk

There is probably a better way of doing this, but it works for me.

That said it will occasionally fail to wake from hibernate due to a graphics issue:

WARNING: CPU: 4 PID: 10460 at drivers/gpu/drm/amd/amdgpu/../display/dc/core/dc_link.c:2546 dc_link_set_backlight_level+0x92/0xf0 [amdgpu]
...
Feb 09 14:57:01 stealth kernel: amdgpu 0000:03:00.0: [drm:amdgpu_ring_test_helper [amdgpu]] *ERROR* ring kiq_2.1.0 test failed (-110)
Feb 09 14:57:01 stealth kernel: [drm:amdgpu_gfx_enable_kcq.cold [amdgpu]] *ERROR* KCQ enable failed
Feb 09 14:57:01 stealth kernel: [drm:amdgpu_device_ip_resume_phase2 [amdgpu]] *ERROR* resume of IP block  failed -110
Feb 09 14:57:01 stealth kernel: [drm:amdgpu_device_resume [amdgpu]] *ERROR* amdgpu_device_ip_resume failed (-110).
Feb 09 14:57:01 stealth kernel: PM: dpm_run_callback(): pci_pm_restore+0x0/0xf0 returns -110
Feb 09 14:57:01 stealth kernel: PM: Device 0000:03:00.0 failed to restore async: error -110

For more inflormation see here


Packages

To suit my requirements I removed these packages and installed my usual software.

Remove packages:

apt remove rhythmbox
apt remove gnome-2048
apt remove aisleriot
apt remove gnome-mines 
apt remove gnome-sudoku 

Add packages:

apt install gnome-terminal
apt install net-tools
apt install python3-pip
apt install geany (problem with geany freezing when typing)
apt install handbrake
apt install clementine
apt install openssh-server
apt install python3-acoustid
apt install php-getid3
apt install flac
apt install lame
apt install inkscape
apt install pdfjam
apt install php-cli
apt install sigil
apt install evince
apt install audacity
apt install mediainfo
apt install mkvtoolnix-gui
apt install rclone
apt install libgl1-mesa-glx 
apt install syslinux-utils
apt install librsvg2-bin
apt install exiftool
apt install gpsbabel
apt install php-xml
apt install mediainfo-gui
apt install isync

Add other packages:

XnViewMP-linux-x64.deb
Signal
Puddletag

Specs: