diff --git a/learning-linux/Linux_ACELI.md b/learning-linux/Linux_ACELI.md index c85c2d3c19b95e731f4f54f62e9a4a31291e1a42..bd4bb8817c3af2411a062457c05a9a72ab481c02 100644 --- a/learning-linux/Linux_ACELI.md +++ b/learning-linux/Linux_ACELI.md @@ -5,7 +5,7 @@ author: P.Y. Barriat description: https://dev.to/nikolab/complete-list-of-github-markdown-emoji-markup-5aia backgroundImage: url('assets/back.png') _backgroundImage: url('assets/garde.png') -footer: 13/04/2023 | An introduction to Linux | PY Barriat +footer: 10/04/2025 | An introduction to Linux | PY Barriat _footer: "" paginate: true _paginate: false @@ -14,12 +14,12 @@ _paginate: false An introduction to Linux<!--fit--> === -https://forge.uclouvain.be/barriat/learning-linux +https://forge.uclouvain.be/elic/learning.git  **Pierre-Yves Barriat** -ACELI Training Sessions `April 13th, 2023` +ACELI Training Sessions `April 10th, 2025` --- @@ -44,6 +44,18 @@ ACELI Training Sessions `April 13th, 2023` --- +- **Core Components** + The "Linux Kernel" is the core of the operating system, which interacts directly with the hardware. + > Others kernels before Linux: Minix, GNU Hurd, BSD, etc + +- **GNU Tools** + Linux is often used with tools from the GNU project (like compilers, shell, and libraries), making it a complete operating system when combined with the kernel. + +- **Open Source** + The source code for Linux is freely available, meaning you can modify and distribute it. + +--- + # What is a Linux distribution ? - Many versions of Linux @@ -59,9 +71,44 @@ ACELI Training Sessions `April 13th, 2023` --- -# Why Linux ? +## Popular Linux Distributions + + - **Ubuntu**: User-friendly, ideal for beginners. + - **Fedora**: Cutting-edge features and software. + - **Debian**: Stable and reliable, popular in scientific environments. + - **Rocky**: Enterprise-focused, ideal for servers. + - **Arch Linux**: Lightweight and customizable (for advanced users). + +## Why Multiple Distros ? + +Different distributions cater to different needs: some are easier for beginners, while others are tailored to performance, security, or customization. + +--- + +# Why Linux for scientists ? + +As a scientist, your workflow involves complex simulations, data analysis, and working with scientific tools. + +Linux provides a stable, powerful, and open environment tailored for research purposes. + +Here's why it's better than Windows for scientific work. + +--- + +- **Performance and Efficiency** + Linux is known for being fast and efficient. It handles large computational tasks better than Windows, making it ideal for simulations and data-heavy research. + +- **Flexibility** + You can customize Linux to meet the specific needs of your research, from installing specific software to adjusting the environment. + +- **Better Use of System Resources** + Unlike Windows, Linux runs with minimal overhead, giving you more resources for your tasks. + +--- + +# Why Linux for all ? -- **Linux is free** +- Linux is **free** and open-source - Linux is supported on older computers (perf & updates) - Linux has many more free applications @@ -102,6 +149,32 @@ ACELI Training Sessions `April 13th, 2023` --- +# Robust software support + +- **Scientific Software** + Many popular scientific tools (e.g., ROOT, MATLAB, Python, R, and SciPy) work seamlessly on Linux. + +- **Package Management** + Linux distributions offer package managers like APT, YUM, and Pacman, making it easy to install, update, and manage software. + +- **Compilers and Libraries** + Linux has native support for most programming languages and compilers (e.g., GCC for C/C++, Fortran) and scientific libraries. + +--- + +# Better for High-Performance Computing (HPC) + +- **Parallel Computing** + Linux is optimized for high-performance computing, supporting parallel processing and multi-core usage that is crucial for simulations and data analysis. + +- **Supercomputing** + The majority of the world's supercomputers run Linux, making it the go-to operating system for large-scale simulations and scientific research. + +- **Cluster Management** + Tools like OpenMPI and SLURM work flawlessly on Linux for managing distributed computing environments, common in physics research. + +--- + # Why not Linux ? 1. Hardware compatibility (printers, etc) @@ -112,7 +185,7 @@ ACELI Training Sessions `April 13th, 2023` 1. Many devices "Linux compatible" 2. Emulation (eg virtualbox), online usage, alternatives (GIMP) -3. Difficult, but it exists emulation and Steam +3. More and more games on Linux (Steam OS) and emulation --- @@ -127,7 +200,7 @@ ACELI Training Sessions `April 13th, 2023` - better driver support - LTS and staging releases available as per user needs -> get the latest Ubuntu LTS : [ubuntu-22.04.2-desktop-amd64.iso](https://releases.ubuntu.com/jammy/ubuntu-22.04.2-desktop-amd64.iso) +> Get Ubuntu LTS : [ubuntu-22.04.5-desktop-amd64.iso](https://releases.ubuntu.com/jammy/ubuntu-22.04.5-desktop-amd64.iso) --- @@ -137,19 +210,24 @@ Using a virtual machine: test Linux without changing anything to your computer You need to install a VM and then install the Linux inside -- Get a Virtual Machine: https://www.virtualbox.org/wiki/Downloads - > VirtualBox + Extension Pack +Take a look in the `learning-vscode` folder in: +https://forge.uclouvain.be/elic/learning.git -- Install Linux in a VM: [Install Linux Inside Windows Using VirtualBox](https://itsfoss.com/install-linux-in-virtualbox/) - > Step by Step Guide +> Using WSL in Windows 11 in order to use Linux --- # Linux GUI +Most Linux distributions come with a desktop environment (e.g., GNOME, KDE) that provides a graphical interface similar to Windows. + +You can interact with files, applications, and settings using windows, icons, and menus. + +--- +  -A Linux distribution contains a [display server](https://www.google.com/search?tbm=isch&q=display+manager), a [window manager](https://www.google.com/search?tbm=isch&q=windows+manager) (manage windows, panel, menus, dash interfaces and core applications), and a [desktop environment](https://www.google.com/search?tbm=isch&q=graphical+interface) (eg status bars, drag-and-drop capabilities, etc) +A desktop environment contains a [display server](https://www.google.com/search?tbm=isch&q=display+manager), a [window manager](https://www.google.com/search?tbm=isch&q=windows+manager) (manage windows, panel, menus, dash interfaces and core applications), and a [desktop environment](https://www.google.com/search?tbm=isch&q=graphical+interface) (eg status bars, drag-and-drop capabilities, etc) These 3 items are **bundled together** to make what is known as a `GUI environment` @@ -159,34 +237,38 @@ These 3 items are **bundled together** to make what is known as a `GUI environme **Using Linux through a GUI environment is similar to Windows or MacOSX** -Linux users do not install software the same way that Windows users do: Linux has a tool known as a `package manager` +Linux users do not install software the same way that Windows users do: +Linux has a tool known as a `package manager` A package manager provides a way to search for software, install software, keep the software up to date and remove the software > Similar to Google or Apple store --- -# Linux CLUI +# Linux CLI -Using Linux with GUI, it's already great ! -**Using CLUI = unlock the power of Linux !** +Using Linux with **GUI**, it's already great ! +Using **CLI = unlock the power of Linux !** -Each Linux system contains a terminal +**CLUI** = **C**ommand **L**ine **U**ser **I**nterface (= **CLI**) -A terminal is where you enter Linux commands + - It is one of the many strengths of Linux and can be more efficient than using the GUI -It's called the **C**ommand **L**ine **U**ser **I**nterface + - The CLI allows you to interact with the system by typing text-based commands into a terminal. -CLUI is one of the many strengths of Linux and can be more efficient than using the GUI + - While more intimidating at first, the CLI is extremely powerful for advanced operations, automation, and performance. --- -# Linux CLUI +## Which to Use ? + +GUI is great for beginners or tasks that require minimal technical knowledge. +CLI is essential for advanced users, system administration, and scripting. -- CLUI allows users to be independent of distros (or UNIX systems like OSX) -- CLUI saves system resources which are consumed by GUIs -- CLUI allows users to easily work at distance (SSH) -- CLUI allows developers to join together simple (and less simple) commands to do complex things and automate... whatever you want to +- CLI allows users to be independent of distros (or UNIX systems like OSX) +- CLI saves system resources which are consumed by GUIs +- CLI allows users to easily work at distance (SSH) +- CLI allows developers to join together simple (and less simple) commands to do complex things and automate... whatever you want to > People tend to think command line is difficult. It's not. @@ -236,7 +318,7 @@ mmv '*.JPG' '#1.jpg' Download a youtube video ? ```bash -youtube-dl https://www.youtube.com/watch?v=G7KNmW9a75Y&ab_channel=MileyCyrusVEVO +yt-dl https://www.youtube.com/watch?v=G7KNmW9a75Y&ab_channel=MileyCyrusVEVO ``` Convert color pictures in BW at once ? @@ -250,6 +332,8 @@ do done ``` +<!-- _footer: "" --> + --- # Online Linux Demo @@ -267,13 +351,13 @@ done # What you'll learn - Navigating the File System - > Get up and running with the CLUI by navigating directories and files + > Get up and running with the CLI by navigating directories and files - Viewing and Changing Files and Directories - > Learn to manipulate directories and files from the CLUI + > Learn to manipulate directories and files from the CLI - Configuring the Environment - > Learn to configure the environment using the CLUI + > Learn to configure the environment using the CLI - Accessing Linux remotely > Learn to use SSH (basics) @@ -475,14 +559,11 @@ ssh -X -i ~/.ssh/id_rsa.ceci pbarriat@gwcism.cism.ucl.ac.be Using a SSH client to reach a distant Linux Workstation -**mobaXTerm** is free and easy to use -> allow you to test a Linux environmment but in CLUI only - -Get a SSH client -https://mobaxterm.mobatek.net/download-home-edition.html +Take a look in the `learning-vscode` folder in: +https://forge.uclouvain.be/elic/learning.git -How to use a SSH client -https://support.ceci-hpc.be/doc/_contents/QuickStart/ConnectingToTheClusters/MobaXTerm.html +> see "VS Code nice extensions" +> `Remote - SSH` : lets you use any remote machine with a SSH server --- @@ -493,7 +574,7 @@ https://support.ceci-hpc.be/doc/_contents/QuickStart/ConnectingToTheClusters/Mob - nedit (simple text editor available in most distributions) - Kate, Gedit (KDE, Gnome) -### CLUI +### CLI - vi (available in all Unix systems) and **vim** (vi improved) > Difficult to learn for beginners used to graphical text editors @@ -527,7 +608,7 @@ Backup on external drive ? | Advantages of Linux | Disadvantages of Linux | | --------------------- | ---------------------------------- | -| Cost | Not easy to master ( **CLUI only** ) | +| Cost | Not easy to master ( **CLI only** ) | | Security and robustness | Hardware compatibility issues ( sometimes ) | | Freedom | Not compatible with some Windows software | | Software || diff --git a/learning-linux/Linux_ACELI.pdf b/learning-linux/Linux_ACELI.pdf index c8bdba679000653c3b500eb7aa0bb32cd619c3ba..389f9b5719aaf1dda45571ca3bf6a00b9c9d4ef0 100644 Binary files a/learning-linux/Linux_ACELI.pdf and b/learning-linux/Linux_ACELI.pdf differ