Windows software installation: Difference between revisions

From 22115
Jump to navigation Jump to search
No edit summary
 
(14 intermediate revisions by the same user not shown)
Line 1: Line 1:
UNDER CONSTRUCTION
These are instructions for how to install software and data used on the course [[22115_-_Computational_Molecular_Evolution|Computational Molecular Evolution (22115)]] when using the Windows operating system.
These are instructions for how to install software and data used on the course [[22115_-_Computational_Molecular_Evolution|Computational Molecular Evolution (22115)]] when using the Windows operating system.


Line 7: Line 5:
== Install Windows Subsystem for Linux + Ubuntu ==
== Install Windows Subsystem for Linux + Ubuntu ==


# Follow [https://www.youtube.com/watch?v=8BTX9mwLcfw this youtube guide] to install WSL2 (Windows Subsystem for Linux 2) and the Ubuntu Linux distribution.
* Follow [https://www.youtube.com/watch?v=8BTX9mwLcfw this youtube guide] to install WSL2 (Windows Subsystem for Linux 2) and the Ubuntu Linux distribution.
# One common issue is that you need to enable "Virtual Machine Platform" on Windows. Check the linked Powerpoint presentation for more details on how to do that: [https://teaching.healthtech.dtu.dk/material/22118/22118_01-WSL2Install.ppt Guide for WSL2 and Linux (Peter Wad Sackett)]
* One common issue is that you need to enable "Virtual Machine Platform" on Windows. Check the linked Powerpoint presentation for more details on how to do that:  
** [https://teaching.healthtech.dtu.dk/material/22118/22118_01-WSL2Install.ppt Guide for WSL2 and Linux (Peter Wad Sackett)]
 
== R + RStudio: install versions for Windows instead of Linux ==
 
* Instead of installing the Linux version of R and RStudio, you should install the Windows versions:
** https://posit.co/download/rstudio-desktop/
* NOTE: this means you will have to access files on the Linux file system from the Windows file system.
** Your Linux files should be accessible at a file path similar to this: <code>\\wsl$\Ubuntu\home\user\whatever</code> (where <code>user</code> is your username, and <code>whatever</code> is the path to where your files are located.
** Also see: https://devblogs.microsoft.com/commandline/whats-new-for-wsl-in-windows-10-version-1903/


== Install Linux Software ==
== Install Linux Software ==


# Start Ubuntu in your Windows Terminal
* Start Ubuntu in your Windows Terminal
# Follow instructions on [[Linux software installation]] page
* Follow instructions for Linux:
** [[Linux software installation]]
 
== Using Linux programs with a graphical user interface in WSL ==
 
* If you are on windows-11 and have installed the most up-to-date version of WSL2 then you should be able to run GUI programs on linux and get the graphical window shown on Windows (this includes for instance aliview and figtree).
* If you have problems (e.g., no GUI window opens when calling command): check the two issues below.
; Update WSL if needed
* If you are not sure whether you are up to date, you can run these commands to ensure you have the newest version of WSL:
 
wsl --update
wsl --shutdown
 
; Make sure .bashrc does not try to set the DISPLAY environment variable
* Also, make sure you have no commands in your .bashrc file attempting to set the DISPLAY environment variable (this environment variable controls which screen to try to show the GUI on, and should be set automatically. If it is set to the wrong value then the GUI won't be shown).
* Open .bashrc in a text editor
* Check if there are any lines containing something like:
 
export DISPLAY=localhost:0.0
 
* If so: delete the line(s), save, and open a fresh terminal window
* The DISPLAY variable should now be automatically set to the correct value for your system.

Latest revision as of 14:54, 11 February 2026

These are instructions for how to install software and data used on the course Computational Molecular Evolution (22115) when using the Windows operating system.

Install Windows Subsystem for Linux + Ubuntu

  • Follow this youtube guide to install WSL2 (Windows Subsystem for Linux 2) and the Ubuntu Linux distribution.
  • One common issue is that you need to enable "Virtual Machine Platform" on Windows. Check the linked Powerpoint presentation for more details on how to do that:

R + RStudio: install versions for Windows instead of Linux

Install Linux Software

Using Linux programs with a graphical user interface in WSL

  • If you are on windows-11 and have installed the most up-to-date version of WSL2 then you should be able to run GUI programs on linux and get the graphical window shown on Windows (this includes for instance aliview and figtree).
  • If you have problems (e.g., no GUI window opens when calling command): check the two issues below.
Update WSL if needed
  • If you are not sure whether you are up to date, you can run these commands to ensure you have the newest version of WSL:
wsl --update
wsl --shutdown
Make sure .bashrc does not try to set the DISPLAY environment variable
  • Also, make sure you have no commands in your .bashrc file attempting to set the DISPLAY environment variable (this environment variable controls which screen to try to show the GUI on, and should be set automatically. If it is set to the wrong value then the GUI won't be shown).
  • Open .bashrc in a text editor
  • Check if there are any lines containing something like:
export DISPLAY=localhost:0.0
  • If so: delete the line(s), save, and open a fresh terminal window
  • The DISPLAY variable should now be automatically set to the correct value for your system.