Difference between revisions of "Airtop: Installing Linux Mint 20"

From fit-PC wiki
Jump to: navigation, search
(Missing Built-in Audio)   (change visibility)
Line 89: Line 89:
 
Click on "Test Sound", then on "Front Left" and "Front Right", check if it hear it from headphones
 
Click on "Test Sound", then on "Front Left" and "Front Right", check if it hear it from headphones
 
</pre>
 
</pre>
</dev>
+
</div>
  
 
== Intel video acceleration drivers ==
 
== Intel video acceleration drivers ==

Revision as of 12:20, 22 July 2020

Supported devices

  • This guide is valid for Airtop, Airtop2, Airtop3

Prepare installation media

LiveUSB installer crash on Quadro RTX 4000

  • In case your machine is configured with Quadro RTX4000 and experience crashes/freezes while LiveUSB installer running, please expand and follow the below:
  • To perform boot into "Safe Graphics" mode, add "nomodeset" parameter to the kernel boot line:
    • Power-on the Airtop3 with LiveUSB installer
    • Boot menu will appear, default entry will be "Start Linux Mint 20 Cinnamon 64-bit"
    • Press [e] to enter edit mode
    • Add "nomodeset" after the "splash", the end of line will look like "quiet splash nomodeset --"
    • Press [F10] to continue the boot
  • You will need to add "nomodeset" option once again, after base installation of Linux Mint and reboot
  • The problem will disappear after installing Nvidia graphics card drivers


Base installation of Linux Mint

  • Follow the standard Linux Mint installation procedure - choose timezone, partitions, username, password etc.
  • Disconnect the installation media and reboot.
  • Login using previously selected username and password.

I3M

  • To install I3M Linux Daemon on Airtop, please expand and follow the below:
  • Download I3M monitoring tools:
$ sudo wget https://fit-iot.com/files/download/airtop/sw/I3M/Linux/airtop-fpsvc -O /usr/local/sbin/airtop-fpsvc
$ sudo wget https://fit-iot.com/files/download/airtop/sw/I3M/Linux/gpu-thermald -O /usr/local/sbin/gpu-thermald
  • Fix dependencies:
$ lib_path="/usr/lib/x86_64-linux-gnu"
$ [ -e $lib_path/libsensors.so.4 ] || sudo ln -s $lib_path/libsensors.so.*.0.0 $lib_path/libsensors.so.4
  • Create file /etc/rc.local with the following content:
#!/bin/bash
modprobe i2c-i801
sleep 1
/usr/local/sbin/airtop-fpsvc
[ "$(lspci -nn | grep VGA | grep 10de:)" ] && /usr/local/sbin/gpu-thermald
exit 0
  • Make it executable:
$ sudo chmod +x /etc/rc.local
  • Ensure I3M panel is working
$ sudo /etc/rc.local
  • Reboot, ensure I3M panel is still working
$ sudo reboot

Missing Built-in Audio

  • There is a audio bug in kernel 5.4 you may encounter on your Airtop

https://bugzilla.kernel.org/show_bug.cgi?id=205959

  • Symptoms: no sound from Built-in analog audio outputs
  • To fix please expand and follow the below:
  • Open file /etc/default/grub for editing
  • Add "snd-intel-dspcfg.dsp_driver=1" to the end of kernel boot line:
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash snd-intel-dspcfg.dsp_driver=1"
  • Update grub settings
$ sudo update-grub2 
Sourcing file `/etc/default/grub'
..
done
$ sudo reboot
  • Test audio output
Menu -> Sound -> Output -> Built-in Audio Analog Stereo (it's not dynamic, nothing changes after plug/unplug headphones)
Click on "Test Sound", then on "Front Left" and "Front Right", check if it hear it from headphones

Intel video acceleration drivers

$ sudo apt update
$ sudo apt install va-driver-all mint-meta-codecs vainfo

Then run vainfo command, you should see list of supported profiles, for example on airtop3:

$ vainfo 
libva info: VA-API version 1.7.0
libva info: Trying to open /usr/lib/x86_64-linux-gnu/dri/iHD_drv_video.so
libva info: Found init function __vaDriverInit_1_7
libva info: va_openDriver() returns 0
vainfo: VA-API version: 1.7 (libva 2.6.0)
vainfo: Driver version: Intel iHD driver for Intel(R) Gen Graphics - 20.1.1 ()
vainfo: Supported profile and entrypoints
      VAProfileMPEG2Simple            :	VAEntrypointVLD
      VAProfileMPEG2Main              :	VAEntrypointVLD
      VAProfileH264Main               :	VAEntrypointVLD
      VAProfileH264Main               :	VAEntrypointEncSliceLP
      VAProfileH264High               :	VAEntrypointVLD
      VAProfileH264High               :	VAEntrypointEncSliceLP
      VAProfileJPEGBaseline           :	VAEntrypointVLD
      VAProfileJPEGBaseline           :	VAEntrypointEncPicture
      VAProfileH264ConstrainedBaseline:	VAEntrypointVLD
      VAProfileH264ConstrainedBaseline:	VAEntrypointEncSliceLP
      VAProfileVP8Version0_3          :	VAEntrypointVLD
      VAProfileHEVCMain               :	VAEntrypointVLD
      VAProfileHEVCMain10             :	VAEntrypointVLD
      VAProfileVP9Profile0            :	VAEntrypointVLD
      VAProfileVP9Profile2            :	VAEntrypointVLD

Nvidia graphics card drivers

$ sudo add-apt-repository ppa:graphics-drivers/ppa
$ sudo apt update
$ nvidia_driver=$(apt-cache search "nvidia-driver-[0-9][0-9][0-9]" | grep -o "nvidia-driver-[0-9][0-9][0-9]" | sort | tail -1)
$ sudo apt install $nvidia_driver vdpauinfo
$ sudo reboot
  • Then run nvidia-smi command, you should see current NVIDIA card status:
$ watch -n1 nvidia-smi
Wed Jul 22 07:03:52 2020       
+-----------------------------------------------------------------------------+
| NVIDIA-SMI 450.57       Driver Version: 450.57       CUDA Version: 11.0     |
|-------------------------------+----------------------+----------------------+
| GPU  Name        Persistence-M| Bus-Id        Disp.A | Volatile Uncorr. ECC |
| Fan  Temp  Perf  Pwr:Usage/Cap|         Memory-Usage | GPU-Util  Compute M. |
|                               |                      |               MIG M. |
|===============================+======================+======================|
|   0  Quadro RTX 4000     On   | 00000000:01:00.0  On |                  N/A |
|  0%   28C    P8    11W / 125W |    354MiB /  7982MiB |      0%      Default |
|                               |                      |                  N/A |
+-------------------------------+----------------------+----------------------+
                                                                               
+-----------------------------------------------------------------------------+
| Processes:                                                                  |
|  GPU   GI   CI        PID   Type   Process name                  GPU Memory |
|        ID   ID                                                   Usage      |
|=============================================================================|
|    0   N/A  N/A       979      G   /usr/lib/xorg/Xorg                344MiB |
|    0   N/A  N/A      1355      G   cinnamon                            8MiB |
+-----------------------------------------------------------------------------+


Using both Intel and Nvidia graphics card

  • Want to connect up 7 displays simultaneously?
- Press [DEL] during boot to enter the BIOS settings
- Set "Chipset -> system Agent (SA) Configuration -> Graphics Configuration -> Internal Graphics"  to  [Enabled]
- Press [F4] to save and exit
- Boot to Linux Mint
- All connected displays will appear in the "Display" section

Noise mitigation on Nvidia graphics card

  • To reduce the noise need to set PowerMizer Mode to "Prefer Consistent Performance"
  • From GUI:
Menu -> NVIDIA X Server Settings -> PowerMizer -> Preferred Mode:  "Prefer Consistent Performance"
  • The same from command line:
$ nvidia-settings -a "[gpu:0]/GPUPowerMizerMode=3"
  • To make the setting permanent:
Menu -> Startup Applications -> "+" -> Custom command
 Name:    NVIDIA PowerMizer Settings
 Command: nvidia-settings -a "[gpu:0]/GPUPowerMizerMode=3"
 Comment: Set working mode "Prefer Consistent Performanse" to reduce noise

MPV media player

  • Well known free and open-source multimedia player
  • Supports GPU accelerated video decoding including CUDA decoding on NVIDIA GPUs and gives excellent playback quality
  • Compatible with the most popular video formats
$ sudo apt install mpv

For example, Airtop3 with Quadro RTX 4000 is capable to play 4K UHD using CUDA video decoding without significant system load:

$ mpv -fs ~/Videos/jellyfish/jellyfish-140-mbps-4k-uhd-hevc-10bit.mkv
 (+) Video --vid=1 (*) (hevc 3840x2160 29.970fps)
 (+) Audio --aid=1 (*) (truehd 6ch 48000Hz)
AO: [pulse] 48000Hz 5.1(side) 6ch s32
VO: [gpu] 3840x2160 yuv420p10
AV: 00:00:30 / 00:00:30 (99%) A-V:  0.000 Cache: 0.0s/2KB

Or the same content directly from the youtube:

$ mpv -fs https://www.youtube.com/watch?v=j4oBg8capW8
 (+) Video --vid=1 (*) (vp9 3840x2160 29.970fps)
 (+) Audio --aid=1 (*) (aac 2ch 44100Hz)
AO: [pulse] 44100Hz stereo 2ch float
VO: [gpu] 3840x2160 yuv420p
AV: 00:00:29 / 00:00:30 (99%) A-V:  0.000 Cache: 0.0s