Failed to install Parallels Tools on Ubuntu 20.04 ARM

ThomasS93

Bit poster
Hello,
suddenly my Ubuntu and its Parallels Tools didnt work so i decided to reinstall the Tools again. But this ended up with errors like
modprobe: FATAL: Module prl_tg not found in directory /lib/modules/5.19.0-46-generic
Means the Kernel Module isnt present, i guess. So i tried to compile the Kernel Modules by myself. Unpack the prl_mod.tar.gz to a folder in downloads, and in it i did a make -f Makefile.kmods
This ended up in this:
awk: Kommandozeile:1: Warnung: Die Escapesequenz »\#« ist kein bekannter Operator für reguläre Ausdrücke
Will use compiler CC="cc".
Compiler version "cc (Ubuntu 11.3.0-1ubuntu1~22.04.1) 11.3.0"
cd prl_tg/Toolgate/Guest/Linux/prl_tg && make CC=cc
make[1]: Verzeichnis „/home/thomas/Downloads/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg" wird betreten
1: /lib/modules/5.19.0-46-generic/build
2: /home/thomas/Downloads/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg
3: 20230629
4: 1.10.0
Start compile prl_tg...
make -C /lib/modules/5.19.0-46-generic/build M=/home/thomas/Downloads/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg SRCROOT=/home/thomas/Downloads/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg CC=cc modules
make[2]: Verzeichnis „/usr/src/linux-headers-5.19.0-46-generic" wird betreten
warning: the compiler differs from the one used to build the kernel
The kernel was built by: aarch64-linux-gnu-gcc (Ubuntu 11.3.0-1ubuntu1~22.04.1) 11.3.0
You are using: cc (Ubuntu 11.3.0-1ubuntu1~22.04.1) 11.3.0
1: /lib/modules/5.19.0-46-generic/build
2: /home/thomas/Downloads/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg
3: 20230629
4: 1.10.0
CC [M] /home/thomas/Downloads/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg/prltg.o
In file included from /home/thomas/Downloads/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg/prltg.c:23:
/home/thomas/Downloads/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg/prltg_common.h: In function 'tg_out':
/home/thomas/Downloads/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg/prltg_common.h:179:14: warning: assignment to 'long unsigned int' from 'void *' makes integer from pointer without a cast [-Wint-conversion]
179 | port += dev->base_addr;
| ^~
/home/thomas/Downloads/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg/prltg_common.h:183:24:
warning: passing argument 2 of 'iowrite64' makes pointer from integer without a cast -Wint-conversion]
183 | iowrite64(val, port);

| ^~~~

| |

| long unsigned int

In file included from ./arch/arm64/include/asm/io.h:185,
from ./include/linux/io.h:13,
from ./include/linux/irq.h:20,
from ./include/asm-generic/hardirq.h:17,
from ./arch/arm64/include/asm/hardirq.h:17,
from ./include/linux/hardirq.h:11,
from ./include/linux/interrupt.h:11,
from ./include/linux/pci.h:38,
from /home/thomas/Downloads/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg/prltg.c:7:
./include/asm-generic/io.h:769:64: note: expected 'volatile void *' but argument is of type 'long unsigned int'
769 | static inline void iowrite64(u64 value, volatile void __iomem *addr)
| ~~~~~~~~~~~~~~~~~~~~~~~^~~~
/home/thomas/Downloads/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg/prltg.c:
In function 'prl_tg_initialize':
/home/thomas/Downloads/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg/prltg.c:385:14: error: implicit declaration of function 'pci_set_dma_mask' [-Werror=implicit-function-declaration]
385 | rc = pci_set_dma_mask(pdev, DMA_BIT_MASK(64));
| ^~~~~~~~~~~~~~~~
In file included from ./include/asm-generic/bug.h:22,
from ./arch/arm64/include/asm/bug.h:26,
from ./include/linux/bug.h:5,
from ./arch/arm64/include/asm/cpufeature.h:19,
from ./arch/arm64/include/asm/hwcap.h:9,
from ./arch/arm64/include/asm/arch_timer.h:12,
from ./arch/arm64/include/asm/timex.h:8,
from ./include/linux/timex.h:67,
from ./include/linux/time32.h:13,
from ./include/linux/time.h:60,
from ./arch/arm64/include/asm/stat.h:12,
from ./include/linux/stat.h:6,
from ./include/linux/module.h:13,
from /home/thomas/Downloads/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg/prltg.c:5:
/home/thomas/Downloads/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg/prltg.c: In function 'prl_tg_probe_common':
./include/linux/kern_levels.h:5:25: warning: format '%lx' expects argument of type 'long unsigned int', but argument 3 has type 'void *' [-Wformat=]
5 | #define KERN_SOH "\001" /* ASCII Start Of Header */
| ^~~~~~
./include/linux/printk.h:436:25:
note: in definition of macro 'printk_index_wrap'
436 | _p_func(_fmt, ##__VA_ARGS__); \
| ^~~~
/home/thomas/Downloads/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg/prltg.c:520:9:
note: in expansion of macro 'printk'
520 | printk(KERN_INFO "detected %s, base addr %08lx, IRQ %d\n",
| ^~~~~~
./include/linux/kern_levels.h:14:25:
note: in expansion of macro 'KERN_SOH'
14 | #define KERN_INFO KERN_SOH "6" /* informational */
| ^~~~~~~~
/home/thomas/Downloads/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg/prltg.c:520:16:
note: in expansion of macro 'KERN_INFO'
520 | printk(KERN_INFO "detected %s, base addr %08lx, IRQ %d\n",
| ^~~~~~~~~
/home/thomas/Downloads/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg/prltg.c:
In function 'prl_tg_init_module':
/home/thomas/Downloads/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg/prltg.c:646:13: warning: unused variable 'rc' [-Wunused-variable]
646 | int rc;
| ^~
cc1: some warnings being treated as errors
make[3]: *** [scripts/Makefile.build:257: /home/thomas/Downloads/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg/prltg.o] Fehler 1
make[2]: *** [Makefile:1857: /home/thomas/Downloads/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg] Fehler 2
make[2]: Verzeichnis „/usr/src/linux-headers-5.19.0-46-generic" wird verlassen
make[1]: *** [Makefile:43: prl_tg] Fehler 2
make[1]: Verzeichnis „/home/thomas/Downloads/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg" wird verlassen
make: *** [Makefile.kmods:47: compile] Fehler 2


Running Parallels 17.1.6 on a Mac Mini M1
Kernel in Ubuntu is:
Linux ubuntu-linux-20-04-desktop 5.19.0-46-generic #47~22.04.1-Ubuntu SMP PREEMPT_DYNAMIC Wed Jun 21 15:35:58 UTC 2 aarch64 aarch64 aarch64 GNU/Linux

Why i cant install the Tools?
Regards
Thomas
 
Best answer
Hello!
We've added support for Linux kernel 6.5 in Parallels Desktop 19.1.0 that should be released within a few hours. Please install the latest version of Parallels Desktop and check if the issue is addressed.
fixed by using gcc-12. gcc-11 was the ubuntu default compiler.. so

ln -sf /usr/bin/gcc-12 /usr/bin/gcc

after that the tools installed fine...


Sat Jan 13 11:51:37 EST 2024
Start installation or upgrade of Guest Tools
warning: the compiler differs from the one used to build the kernel
The kernel was built by: aarch64-linux-gnu-gcc-12 (Ubuntu 12.3.0-1ubuntu1~22.04) 12.3.0
You are using: cc (Ubuntu 12.3.0-1ubuntu1~22.04) 12.3.0
Skipping BTF generation for /usr/lib/parallels-tools/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg/prl_tg.ko due to unavailability of vmlinux
warning: the compiler differs from the one used to build the kernel
The kernel was built by: aarch64-linux-gnu-gcc-12 (Ubuntu 12.3.0-1ubuntu1~22.04) 12.3.0
You are using: cc (Ubuntu 12.3.0-1ubuntu1~22.04) 12.3.0
Skipping BTF generation for /usr/lib/parallels-tools/kmods/prl_fs/SharedFolders/Guest/Linux/prl_fs/prl_fs.ko due to unavailability of vmlinux
warning: the compiler differs from the one used to build the kernel
The kernel was built by: aarch64-linux-gnu-gcc-12 (Ubuntu 12.3.0-1ubuntu1~22.04) 12.3.0
You are using: cc (Ubuntu 12.3.0-1ubuntu1~22.04) 12.3.0
Skipping BTF generation for /usr/lib/parallels-tools/kmods/prl_notifier/Installation/lnx/prl_notifier/prl_notifier.ko due to unavailability of vmlinux
warning: the compiler differs from the one used to build the kernel
The kernel was built by: aarch64-linux-gnu-gcc-12 (Ubuntu 12.3.0-1ubuntu1~22.04) 12.3.0
You are using: cc (Ubuntu 12.3.0-1ubuntu1~22.04) 12.3.0
Skipping BTF generation for /usr/lib/parallels-tools/kmods/prl_fs_freeze/Snapshot/Guest/Linux/prl_freeze/prl_fs_freeze.ko due to unavailability of vmlinux
Start installation of prl_tg kernel module
Start installation of prl_fs kernel module
Start installation of prl_fs_freeze kernel module
Start installation of prl_notifier kernel module
DKMS modules were added successfully
DKMS modules for kernel 6.5.0-14-generic were built successfully
DKMS modules for kernel 6.5.0-14-generic were installed successfully
Parallels Guest Tools were installed successfully!
Please, reboot your OS to finish installation of Parallels Guest Tools.
2024-01-13T11:51:58-0500: execCmd: ./install --install [0]
2024-01-13T11:52:03-0500: Guest OS is going to reboot.
 
I can confirm that switching to gcc-12 using command:
ln -sf /usr/bin/gcc-12 /usr/bin/gcc
has solved the issue for installing Parallels Tools in Ubuntu 22.04.3 LTS on MacBook Pro M1
 
I also confirm: Installation of Parallels tools for Ubuntu 22.04.3 guest VM with Kernel 6.5.x and higher only work properly when installing certain deb-packages in the first place and link onto the right gnu compiler library (Version 12 gcc).

https://kb.parallels.com/en/113394 is misleading because gcc-12 and dkms are missing in that KB. That should be taken into account by Parallels Support.

So far my steps to succeed:
1. Make sure to install the following missing packages first in the Ubuntu VM via Terminal
sudo apt get install dkms libelf-dev build-essential linux-headers$(uname -r) gcc-12
2. Relink to gcc Version 12
sudo ln -sf /usr/bin/gcc-12 /usr/bin/gcc
check gcc version with: gcc --version
It should be version 12.x
3. Start to install/mount Parallels Tools and run install using a terminal
Menu -> Action -> Install Parallels Tools
sudo "/media/$USER/Parallels Tools"/install
Optional: Check install, compile log in another terminal session
tail -f /var/log/parallels-tools-install.log
If everythings works out nicely just reboot the VM. Compile errors or missing libraries will be prompted either in the log file or installer.
sudo reboot
and you're done.
 
I also confirm: Installation of Parallels tools for Ubuntu 22.04.3 guest VM with Kernel 6.5.x and higher only work properly when installing certain deb-packages in the first place and link onto the right gnu compiler library (Version 12 gcc).

https://kb.parallels.com/en/113394 is misleading because gcc-12 and dkms are missing in that KB. That should be taken into account by Parallels Support.

So far my steps to succeed:
1. Make sure to install the following missing packages first in the Ubuntu VM via Terminal
sudo apt get install dkms libelf-dev build-essential linux-headers$(uname -r) gcc-12
2. Relink to gcc Version 12
sudo ln -sf /usr/bin/gcc-12 /usr/bin/gcc
check gcc version with: gcc --version
It should be version 12.x
3. Start to install/mount Parallels Tools and run install using a terminal
Menu -> Action -> Install Parallels Tools
sudo "/media/$USER/Parallels Tools"/install
Optional: Check install, compile log in another terminal session
tail -f /var/log/parallels-tools-install.log
If everythings works out nicely just reboot the VM. Compile errors or missing libraries will be prompted either in the log file or installer.
sudo reboot
and you're done.

Hi
I have the same problem.
But...
sa@vm-host-l:~$ gcc --version
Команда «gcc» не найдена, но может быть установлена с помощью:
sudo apt install gcc
sa@vm-host-l:~$ sudo apt install gcc
[sudo] пароль для sa:
Чтение списков пакетов... Готово
Построение дерева зависимостей... Готово
Чтение информации о состоянии... Готово
Уже установлен пакет gcc самой новой версии (4:13.2.0-7ubuntu1).
Следующие пакеты устанавливались автоматически и больше не требуются:
fonts-font-awesome freerdp2-x11 libebur128-1 libfreerdp-client2-2t64 libfreerdp2-2t64 libminiupnpc17
libmusicbrainz5cc2v5 libnatpmp1t64 libneon27t64-gnutls libwinpr2-2t64 transmission-common
Для их удаления используйте «sudo apt autoremove».
Обновлено 0 пакетов, установлено 0 новых пакетов, для удаления отмечено 0 пакетов, и 5 пакетов не обновлено.
sa@vm-host-l:~$
 
Back
Top