Solved How to install Wine in Ubuntu 24.04?

Solved issue

lymphor

Member
Joined
Jul 16, 2023
Messages
91
Reaction score
47
Credits
897
Hello everybody :)

I've recently done a fresh install of Ubuntu 24.04 and wanted to install Wine. I opened the App Center but couldn't find Wine among the Snap packages. So I looked into Debian packages and found 3 results: Wine, Winetricks and Q4Wine. I installed them all but I still could not run my Windows applications: when I double clicked on the exe file nothing happened.


So I removed all 3 Debian packages and started to google it, and found this very promising guide: https://www.liberiangeek.net/2024/04/install-wine-ubuntu-24-04/
I started to follow Method 1 (Install Wine on Ubuntu 24.04 from the Default Repository) and used the following commands in Terminal:
sudo apt update && sudo apt upgrade
sudo apt install wine64

Afterwards I ran wine --version and got the following message:
Command 'wine' not found, but can be installed with:
sudo apt install wine

Therefore I ran sudo apt install wine with success.
Afterwards I ran wine --version again and got a new message:
it looks like wine32 is missing, you should install it.
as root, please execute "apt-get install wine32:i386"
wine-9.0 (Ubuntu 9.0~repack-4build3)

So I ran sudo apt-get install wine32:i386 with success.
Afterwards I used command wine --version one last time and got this output:
wine-9.0 (Ubuntu 9.0~repack-4build3)

I thought everything is fine, so I tried to run my Windows exe file, but the behaviour did not change: nothing happened.

At this point I don't know what to do. I could try to use Method 2 from the giude I mentioned, and try to install Wine on Ubuntu 24.04 from the WineHQ Repository. But I thought maybe it would be wiser to first ask help and advice here.

I hope someone will help me, thank you in advance! ;)
 


One quick and easy way to install wine is to install playonlinux
Code:
sudo apt install playonlinux.
It will also pull the 32 libs needed. and you can install any version of wine from very old to newest using it.
I'm not sure if it will work with wayland yet so you may need x11 to run it. good luck.
 
Have you just installed wine, or have you installed it with a front end [play on Linux/Q4 Linux & etc] as they all install slightly differently

without a front end, go to your windows download, right click select open with other application, scroll down to Windows installer and open [wording may varie by distribution]
 
Hello everybody :)

I've recently done a fresh install of Ubuntu 24.04 and wanted to install Wine. I opened the App Center but couldn't find Wine among the Snap packages. So I looked into Debian packages and found 3 results: Wine, Winetricks and Q4Wine. I installed them all but I still could not run my Windows applications: when I double clicked on the exe file nothing happened.


So I removed all 3 Debian packages and started to google it, and found this very promising guide: https://www.liberiangeek.net/2024/04/install-wine-ubuntu-24-04/
I started to follow Method 1 (Install Wine on Ubuntu 24.04 from the Default Repository) and used the following commands in Terminal:


Afterwards I ran wine --version and got the following message:


Therefore I ran sudo apt install wine with success.
Afterwards I ran wine --version again and got a new message:


So I ran sudo apt-get install wine32:i386 with success.
Afterwards I used command wine --version one last time and got this output:


I thought everything is fine, so I tried to run my Windows exe file, but the behaviour did not change: nothing happened.

At this point I don't know what to do. I could try to use Method 2 from the giude I mentioned, and try to install Wine on Ubuntu 24.04 from the WineHQ Repository. But I thought maybe it would be wiser to first ask help and advice here.

I hope someone will help me, thank you in advance! ;)
Don't install debian packages on ubuntu. It is not set up for that. You are mixing things and will likely cause a problem. First off, avoid installing wine because you do not want to carry over windows vulnerabilities to linux. Find the proper native linux version for your distro. ubuntu has a software catalog, while you didn't find wine I know it is there somewhere but again, you will not need it. How about tell us what you think you need wine for and let us help you find native linux alternatives.
I think I saw your post in another forum and I and many others told you that you can't install exe files in linux. You downloaded the wrong thing.
 
@lymphor :-

Well, for a start......just ignore all these people who suffer from the strange misconception that running WINE suddenly makes you as vulnerable as Windows. It's all tosh.....because each and every WINE prefix you create is fully sand-boxed, and has been since the very early days.

(While APTI is certainly correct about NOT mixing Debian repos with Ubuntu, you probably know - as well as I do myself - that there are certain Windows apps that simply don't have any kind of equivalent under Linux.....or if they do, then it often involves running multiple apps to get the same degree of functionality. Just occasionally, running a Windoze app under WINE is the only viable alternative.)

As for actually installing/running WINE, I haven't bothered with all that twaddle involved in installing from the repositories for years. Ever since WINE became available as a fully self-contained AppImage on Github, I've used 'em.....because all that's involved is linking the AppImage into /usr/bin THREE times; once as 'wine', once as 'wine32', and once as 'wineserver'. Then all ya do is run

Code:
wine winecfg

.....in the terminal and let it run through to create the 'prefix' (this is where the virtual Windows install lives, usually in $home/user). Once this is done, you can run any Windows app on your system, either by installing it OR running it as a Windows PortableApp, and running

Code:
wine /path/to/your/app's/.exe file

That's all there is to it.

I get my AppImage WINE builds from here:-


However; given thatI haven't used Ubuntu since 14.04 'Trusty', I rather doubt the AppImage method would work with 'Noble's' current Snap-centric set-up.....but it couldn't hurt to try.


Mike. :p
 
Last edited:
I install wine by running this command...
Code:
sudo apt install wine

I don't think much or wine...playonlinux or bottles as they are a hit and miss. I have a win 7 VM which runs some windoze software but it's not connected to the internet.
1721779732668.gif

My version of wine...
1721779827603.png

I've been running wine in Linux for 9 years without problems.
1721779937070.gif
 
most people misuse wine. It is meant for windoze software that there are no linux native programs for. Most people do not bother looking.... IE They need wine to install M$ office, not having looked to see there are several great replacements to it such as libre office and open office among others. And they read and write the office files seamlessly.
that is just the start. so many linux alternatives to windoze.... Open your eyes, you will find them.
 
Install Wine on Ubuntu 24.04

Add 32 Bit Architecture

sudo dpkg --add-architecture i386

Download and add the repository key:

sudo mkdir -pm755 /etc/apt/keyrings
sudo wget -O /etc/apt/keyrings/winehq-archive.key https://dl.winehq.org/wine-builds/winehq.key

Add Source


Install Wine

sudo apt install --install-recommends winehq-stable
Now configure Wine
You will get a prompt to install Mono
wine iexplore
You will get a prompt to install Gecko after that Iexplore should open to the WineHQ home page
you be done
 
@APTI :-

Oh, you'll get no arguments from me on that one. As you say, most people don't even bother to try the alternatives.....or even look for them.

I use WINE myself for a couple of items I've never really found direct equivalents for in Linux.....one being a graphic design app called PhotoScape, by a Korean outfit called MooiTech (this is the one I use for designing my highly-customized desktops). I've used it ever since 2008 when it first came out, and got very, very used to it.

Which isn't to say I don't use these sorts of things under Linux; I do.....plenty of them! But in order to get the same degree of functionality under Linux with native apps, I need to have at least 3 or 4 running simultaneously.......and that, to me, just seems kinda daft.

(Funnily enough, we were discussing this just the other night, and one of the other regulars - I forget who now - linked me to a 'SnapCraft' page. Seems Canonical now do a Snap for this very app.....running - naturally! - under a built-in, self-contained version of WINE... I had to laugh, because I'd built an almost identical Puppy-portable for this exact same app myself a couple of years ago, making use of a WINE AppImage along with the 'portable' version of PhotoScape from PortableApps.com......just for the hell of it, and to prove it COULD be done.

Which works very, very well.)


EDIT:- It was @Alexzee , and some digging eventually led me here:-



Mike. :)
 
Last edited:
Hello, I would like to start by thanking all of you for your replies and support, much appreciated :)

I'll first let you know what worked to fix the issue. I used the guide I mentioned (https://www.liberiangeek.net/2024/04/install-wine-ubuntu-24-04/) to completely remove Wine from my system, then I used Method 2 of the same guide to install back Wine. And it worked!
I still have to figure out how to change Wine font size, because right now texts of Windows apps are very small and hard to read (maybe it's worth mentioning that I'm using 4k resolution).

@kc1di
: I tried the method you suggested, I installed playonlinux, but it didn't launch. I investigated the x11 topic and found out I have to text edit a file each time I want to switch between windowing systems. Not the most comfortable procedure in my opinion, and considering it's 2024 they could have implemented a much simpler GUI solution. But thanks, maybe I'll need x11 in the future and now I know what I have to do ;)

@Brickwizard : I did nothing more than what I wrote. I also tried to right click on the Windows exe file and select "Open with..." as you said, but Wine was not displayed among the options.

@APTI
: I need Wine mainly to use game emulators (MAME, Fusion and Snes9x). I know there are Linux alternatives, and I tried to use them several times during the years, but I either failed to configure them properly or they failed to load the Roms properly. As an example, I currently have MAME installed from Ubuntu's App Center and although games look better compared to the Wine emulator, the Linux App doesn't run many of the games because it says it's missing some rom files.
Regarding Debian packages, I had no idea I must not use them, thank you very much for the information! And I wonder: If they're not to be used, why do they show up in the App Center? I was so happy because Debian versions of certain Apps fixed all the issues I had with the Snap versions. I'm talking about trying to install G'MIC in GIMP, or MediaInfo's inability to read files from other drives (mainly NTFS ones), or the fact that AvideMux doesn't have a Snap version. I will now have to remove these Debian Apps, troubleshoot these topics and open different threads in this Forum. I have to say: Ubuntu is becoming not so friendly to use for an average user like me :rolleyes:
Ah, and regarding the other user that posted in another forum: it's not me.

@MikeWalsh : I heard about AppImage but as I said to APTI I'm an average user, not very experienced in Linux, looking for the simpler and most comfortable solution. I'm not lazy, and if I'll have to I'll use AppImage, X11 and whaterver else is needed. But as we all probably noticed in our lives one of the most precious thing these days is time, so I am making sure I waste as little of it as possible.
I also think you're right about Windows apps, there's simply no valid Linux alternative for some of them (I'm thinking now, for instance, at Adobe After Effects). And I'm sorry about this because I like the idea of free software and I try to use Linux over Windows every time I can.

@GatorsFan : thank you very much for your help. Unfortunately by the time you posted I already found a solution that worked for me, but thank you nonetheless for your time ;)

Ok, next steps for me are to find a way to increase font size in Wine, remove debian apps, reinstall snap versions of these apps and troubleshoot them. It will take some time but in the end I will succeed!

Thank you again to all of you, I am very grateful for your help!
 
Tiny update: small font size in Wine fixed! ;)
Glad you got it working :)
As far as x11 goes many distros do give you a choice at log in. Wayland is the wave of the future for sure but, It still has a ways to go and not all apps support it yet. In any event enjoy the journey!
 
@lymphor :-

Font size is one thing that IS easily fixed. Simply bring up the WINE control panel, then on the 'Graphics' tab, just move the slider till it shows the font size needed. Easy-peasy!

As for Avidemux, again that's simple. They produce Avidemux as an AppImage. Just download it, make it executable, rename it for ease of use (this doesn't affect AppImages, because the act of clicking on them 'transfers' this action to the executable within. I just rename mine to 'Avidemux64', removing the .appimage suffix, too. It'll still work, trust me).

Then, simply click on it to launch it. It wants to be in your user directory to keep permissions correct...


For "AfterEffects", have you taken a look at Natron?



Mike. :p
 
Last edited:
@MikeWalsh : I don't know how to bring up the Wine Control Panel. I opened "Show Apps" in Dock and searched for keyword "wine" but no results. I ended up using the solution described here: https://askubuntu.com/questions/131...-for-programs-running-on-wine-in-ubuntu-20-10

Regarding Avidemux, sorry for not using AppImage but I already installed it using this guide: https://ubuntuhandbook.org/index.php/2021/12/install-avidemux-ppa-ubuntu/

Regarding Natron... KABOOOOOOOOOOM! (sound of my mind exploding) Looks like exactly what I needed, and it even supports GMIC! This is F.A.N.T.A.S.T.I.C.! Thank you very much for the info, I can bring my AMVs (and other productions) to another level!
(by the way, I installed Natron from App Center as a snap package and guess what? It doesn't want to launch :eek:
Will open a seprate thread for this... and for GMIC in GIMP... and for MediaInfo...).

Thanks! ;)
 
@lymphor :-

Actually, the method I was referring to is directly below the one you say you used!

To bring up the WINE Control Panel is very easy. Open a terminal, then simply type

Code:
wine winecfg

.....then hit 'Enter'. That's all there is to it. I've long since written a wee script to launch this, which is then called by a menu entry .desktop file I also wrote (I've built so MANY of these I can do 'em with my eyes shut!)

Keep us posted as to your experiences with Natron, please.....assuming you manage to get it running, that is. Thanks!


Mike. :)
 
@MikeWalsh : thank you for the wine tip, your command is much more complete and comfortable to use than the solution I found. As for Natron, thank you very much for mentioning this app to me, I'm confident it will change both my personal and professional life in better :) And yes, I finally managed to use it, full topic here: https://www.linux.org/threads/natron-doesnt-launch-in-ubuntu-24-04.51077/
But I have to investigate its settings, because when I play video files in it, it consumes all my CPU and after a while my PC freezes. The video files are not even so challenging, I mean here's the specs of one of them:
File extension: mkv
File size: 1.2 GB
Duration: 1h 36min <-- but I set the range to only 20 frames
Resolution: 720 × 406
Video Codec: H.264 (High Profile)
Video Bit Rate: 1238 kbps
Frame Rate: 23.98 fps
Audio Codec: AC3 (ATSC A/52)
Audio Bit Rate: 192 kbps
Sample Rate 48.00 kHz

And I don't think my hardware is an issue either:
CPU: AMD Ryzen 7 5700G with Radeon Graphics
SSD: Crucial P3 2TB PCI Express 3.0 x4 M.2 2280

I will investigate. In the meantime... THANK YOU! ;)
 
Follow up regarding Natron: I also installed it in Windows 11 to check how it behaves, and the results are almost the same. The only differences are that Windows also uses all the RAM I have (and I only have 8GB. I know, it's not enough, I already planned an upgrade to 64GB but I'm currently short on cash) and the PC doesn't freeze but the app shuts down itself.
I managed to play a very small video file, and I was even able to add 2 GMIC filters to it. These are the specs of the file:
General
Format : MPEG-4
Format profile : Base Media / Version 2
Codec ID : mp42 (isom/mp42)
File size : 11.7 MiB
Duration : 4 min 31 s
Overall bit rate mode : Variable
Overall bit rate : 362 kb/s
Frame rate : 25.000 FPS
Encoded date : 2014-01-30 23:52:04 UTC
Tagged date : 2014-01-30 23:52:04 UTC

Video
ID : 1
Format : AVC
Format/Info : Advanced Video Codec
Format profile : Constrained [email protected]
Format settings : 1 Ref Frames
Format settings, CABAC : No
Format settings, Reference frames : 1 frame
Format settings, GOP : M=1, N=60
Codec ID : avc1
Codec ID/Info : Advanced Video Coding
Duration : 4 min 31 s
Source duration : 4 min 31 s
Bit rate : 264 kb/s
Maximum bit rate : 671 kb/s
Width : 352 pixels
Height : 264 pixels
Display aspect ratio : 4:3
Frame rate mode : Constant
Frame rate : 25.000 FPS
Color space : YUV
Chroma subsampling : 4:2:0
Bit depth : 8 bits
Scan type : Progressive
Bits/(Pixel*Frame) : 0.113
Stream size : 8.53 MiB (73%)
Source stream size : 8.53 MiB (73%)
Tagged date : 2014-01-30 23:52:06 UTC
Codec configuration box : avcC

Audio
ID : 2
Format : AAC LC
Format/Info : Advanced Audio Codec Low Complexity
Codec ID : mp4a-40-2
Duration : 4 min 31 s
Bit rate mode : Variable
Bit rate : 96.0 kb/s
Maximum bit rate : 102 kb/s
Channel(s) : 2 channels
Channel layout : L R
Sampling rate : 44.1 kHz
Frame rate : 43.066 FPS (1024 SPF)
Compression mode : Lossy
Stream size : 3.11 MiB (27%)
Title : IsoMedia File Produced by Google, 5-11-2011
Encoded date : 2014-01-30 23:52:05 UTC
Tagged date : 2014-01-30 23:52:06 UTC
I checked Natron's settings but I wasn't able to spot anything relevant. At this point I think I'll have to ask for support in the Natron forum (still have to look for it). My fear is the problem is related to my hardware:
  • I'm short on RAM.
  • I don't have a dedicated GPU.
  • Both my CPU & GPU are AMD brand.

I'll keep you posted, ciao! ;)
 
And they read and write the office files seamlessly.

Well, in most cases, however, historically, both Apache OpenOffice and LibreOffice (through Writer and Calc) have difficulties in converting the macros written under MS Word and Excel.

Cheers

Wiz
 
@lymphor :-

  • I'm short on RAM.
  • I don't have a dedicated GPU.
  • Both my CPU & GPU are AMD brand.
Uh-huh. Fair comment; 2 out of the above 3 I'd agree with:-

  • "I'm short on RAM" - Unfortunately, many modern multimedia/video apps ARE "RAM hogs".......most of 'em tend to recommend a minimum of 16GB, preferably 32GB if ya can run to it. It's just the way of the world, I'm afraid.

  • "I don't have a dedicated GPU" - Mm-hm. Again, many of them are also written nowadays to 'offload' rendering & other related processor-intensive stuff TO your dedicated GPU (if you have one). Simple reason is that a GPU is far better suited to what's termed "massively parallel processing" than a CPU is; it's all to do with the architectures used by the two different types of hardware. GPUs are designed specifically for parallel processing of large numbers of threads simultaneously (this is ideal for video-rendering); CPUs, on the other, are optimized to be "general workhorses".....able to handle all sorts of stuff.

  • "Both my CPU and GPU are AMD brand" - This is where we differ. Ever since Ryzen - and subsequent variants thereof - hit the scene, the differences between Intel and AMD have become so miniscule as to be irrelevant (and Intel know it!).......and AMD's GPUs are every bit as good as Nvidia's these days. This should make zero difference to your projects; your biggest current 'issue' is mainly a lack of 'working memory', i.e., the amount of RAM. No getting away from it; Lisa Su was the best thing that ever happened to AMD....

I use 2 video editors. Openshot for day-to-day stuff ('cos I'm very used to it).....and for bigger projects, when I want to make a really good job of something, I use Lightworks. The latter CAN run up to between 18-24 GB when rendering a big project; it's a good job I maxed this HP out to the full 32GB during the first year of COVID! Puppy itself doesn't even need a gig to be fully-functional...so that leaves me plenty of overhead. Why d'you think I use such a small, lightweight OS? 'Cos she leaves almost all of my RAM for what I want to do..!

Yeah; if you're serious about your multimedia stuff, you ARE going to need at least 16GB. If your PC will support 32GB - or even 64GB - and you can afford to do so, I would "go for it".

It'll make a world of difference, it really will. Especially for this kinda stuff......I speak from experience.


Mike. ;)
 
Last edited:
It' worth pointing out that the wine daemon runs as root. Cybersecurity researchers continue to find new bugs in software. It's best to be careful with anything running as root. Don't be too trusting. I haven't tested wine with Metasploit yet. It's still on my to do list.

Signed,

Matthew Campbell
 

Members online


Top