Jekyll2022-04-22T20:29:01-05:00https://e-leclercq.github.io/feed.xmlHomepersonal descriptionEvan LeClercqSetting up the Nvidia Driver and Optimus Manager2020-06-03T00:00:00-05:002020-06-03T00:00:00-05:00https://e-leclercq.github.io/posts/2020/06/blog-post-2<h2 id="step-1-installing-the-nvidia-driver-and-optimus-manager-packages">Step 1: Installing the Nvidia Driver and Optimus Manager Packages</h2>
<p>Before we begin, be sure to check if the desktop manager (or DM) you use is supported.
This information can be found <a href="https://github.com/Askannz/optimus-manager#optimus-manager">here</a>.</p>
<p>Install the proper nvidia driver and utilities with the following command:</p>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>$ sudo pacman -S nvidia nvidia-utils lib32-nvidia-utils lib32-nvidia-libgl
</code></pre></div></div>
<p>If you are unable to install <code class="language-plaintext highlighter-rouge">lib32-nvidia-utils</code> or <code class="language-plaintext highlighter-rouge">lib32-nvidia-libgl</code>, don’t worry as these may not be required unless you plan on using Steam.</p>
<p>Once the driver packages are done installing, you can install the <code class="language-plaintext highlighter-rouge">optimus-manager</code> package from the AUR.
To do this, you can use an AUR helper.
If you don’t have one already, I would recommend <a href="https://github.com/Jguer/yay">yay</a>.
So, I install the package with this command:</p>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>$ yay -S optimus-manager
</code></pre></div></div>
<h2 id="step-2-configuring-the-driver">Step 2: Configuring the Driver</h2>
<p>Be sure to remove any previous Xorg configurations, you may have stored in <code class="language-plaintext highlighter-rouge">/etc/X11</code> as these may interfere with Optimus Manager.</p>
<p>Copy the default configuration file to <code class="language-plaintext highlighter-rouge">/etc/optimus-manager/optimus-manager.conf</code> with this command:</p>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>$ sudo cp /usr/share/optimus-manager.conf /etc/optimus-manager/optimus-manager.conf
</code></pre></div></div>
<p>Then open the new file in your favorite text editor:</p>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>$ sudo vim /etc/optimus-manager/optimus-manager.conf
</code></pre></div></div>
<p>You can set whatever options you would like here, just make sure to set <code class="language-plaintext highlighter-rouge">startup_mode=nvidia</code> or <code class="language-plaintext highlighter-rouge">startup_mode=auto</code> if you plan on using GPU switching.</p>
<p>If you are not using a DM, be sure to put the following line into your <code class="language-plaintext highlighter-rouge">~/.xinitrc</code> file near the top:</p>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>xrandr --setprovideroutputsource modesetting NVIDIA-0
</code></pre></div></div>
<p>If you did not set the DPI option in <code class="language-plaintext highlighter-rouge">optimus-manager.conf</code>, then add the following line after the previous one in the same file:</p>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>xrandr --dpi 96
</code></pre></div></div>
<h2 id="step-3-starting-optimus-manager">Step 3: Starting Optimus Manager</h2>
<p>Now that you have the drivers installed and Optimus Manager configured, you need to enable the Optimus Manager service and start it.
You can do this with the following commands:</p>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>$ sudo systemctl enable optimus-manager.service
$ sudo systemctl start optimus-manager.service
</code></pre></div></div>
<p>Now that the service is running and set to run on startup, the driver should be setup and ready to go.
If you are in a graphical session, you may have to reboot.</p>
<p>Once you have rebooted, you can check if the driver is running with the command:</p>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>$ sudo lspci -v | grep -i "nvidia"
</code></pre></div></div>
<p>You should see the following in the output:</p>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>Kernel driver in use: nvidia
</code></pre></div></div>
<p>If you do not see this, then be sure to checkout the links below to troubleshoot the problems.</p>
<h2 id="conclusion">Conclusion</h2>
<p>Your system should now be using your Nvidia GPU.
You will likely notice a major increase in performance upon rebooting.
I hope this post was helpful.</p>
<h2 id="references">References</h2>
<p><a href="https://github.com/Askannz/optimus-manager">GitHub: Askannz/optimus-manager</a></p>
<p><a href="https://wiki.mnjaro.g/index.php?title=Optius_Manager">Manjaro Wiki: Optimus Manager</a></p>
<p><a href="https://wiki.archlinux.org/index.php/NVIDIA">Arch Wiki: NVIDIA</a></p>
<p><a href="https://wiki.archlinux.org/index.php/NVIDIA_Optimus">Arch Wiki: NVIDIA Optimus</a></p>
<p><a href="https://wiki.archlinux.org/index.php/NVIDIA_Optimus#Tearing/Broken_VSync">Arch Wiki: #Tearing/Broken VSync</a></p>Evan LeClercqStep 1: Installing the Nvidia Driver and Optimus Manager PackagesHow to Set up a Window Manager on Arch Linux2020-03-18T00:00:00-05:002020-03-18T00:00:00-05:00https://e-leclercq.github.io/posts/2020/03/blog-post-3<h1 id="a-quick-window-manager-install-guide-for-arch-linux">A Quick Window Manager Install Guide for Arch Linux</h1>
<p>The steps for setting up most window managers are the same.
Choosing what window manager to use can be difficult, as there are so many options; however, I find that I always make my way back to i3-gaps (a verion of the i3 window manager that supports gaps) and cannot recommend it enough to those interested in using a window manager.
The amount of configuration and the simplicity of it is quite nice.
So, let’s use i3 as example in this tutorial.</p>
<h2 id="step-1-install-the-window-manager-xorg-and-xinit">Step 1: Install the Window Manager, Xorg, and Xinit</h2>
<p>If you have installed Arch Linux, then this step may seem trivial; however, with window managers (and more often desktop environments) you will likely run into a few otions and i3 is no exception.
Simply type the following command to install i3:</p>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>$ sudo pacman -S i3 xorg-server xorg-xinit
</code></pre></div></div>
<p>You will be given some choices of packages to install.
Personally, I prefer i3-gaps, so I type <code class="language-plaintext highlighter-rouge">1 3 4 5</code> and hit <code class="language-plaintext highlighter-rouge">enter</code>.</p>
<p>This is the same for most window managers that use X server.
Others, like sway, may use Wayland.
In that case, you would just need to install Wayland.</p>
<h2 id="step-2-copy-and-edit-xinitrc">Step 2: Copy and Edit .xinitrc</h2>
<p>Now that you have i3, xorg, and xinit installed, you are gonna have to set up xinit.
To do this simply copy the xinitrc file from <code class="language-plaintext highlighter-rouge">/etc</code> into your user’s home directory:</p>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>$ cp /etc/X11/xinit/xinitrc /home/<USER>/.xinitrc
</code></pre></div></div>
<p>Since this is a configuration file, you probably don’t want it being displayed every time you check your home directory, so you can include a dot at the front of the file name.</p>
<p>Now, you just have to configure Xinit so that when X starts it executes i3.
You may wish to sign in as your user for this as there may be some issues
This can be done by appending <code class="language-plaintext highlighter-rouge">exec i3</code> to the bottom of your user’s <code class="language-plaintext highlighter-rouge">.xinitrc</code> file.
So, open the file with your favorite text editor:</p>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>$ nvim /home/<USER>/.xinitrc
</code></pre></div></div>
<p>And append the following line:</p>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>exec i3
</code></pre></div></div>
<h2 id="step-3-start-x-server">Step 3: Start X Server</h2>
<p>Whenever you sign in as this user, you can now type the command <code class="language-plaintext highlighter-rouge">startx</code> to start the X server.
When X server starts, it will automatically execute i3 and you should see the window manager.
From here you can hit <code class="language-plaintext highlighter-rouge">Mod+Enter</code> to open up a terminal, then use the <code class="language-plaintext highlighter-rouge">i3-config-wizard</code> command to generate a basic i3 configuration.
Personally, I store mine in <code class="language-plaintext highlighter-rouge">.config/i3/config</code>, but you may want this file to be located at <code class="language-plaintext highlighter-rouge">.i3</code> in your home directory (for easy access).</p>
<h2 id="conclusion">Conclusion</h2>
<p>That is all there is.
Really, setting up a window manager is that easy, now all thats left is configuring it to your heart’s desire.
As mentioned before, i3 and other window managers offer a lot of customizability, and as a result of this they may seem a bit <em>lacking</em> at first.</p>
<p>So, here is a list of some programs I would recommend using to help spruce up whatever window manager you decide to use:</p>
<ul>
<li><a href="https://github.com/polybar/polybar">polybar</a> - A highly configurable status bar</li>
<li><a href="https://wiki.archlinux.org/index.php/Rxvt-unicode">urxvt</a> - An incredibly fast and customizable terminal emulator</li>
<li><a href="https://github.com/neovim/neovim">neovim</a> - An absolutely fantastic text editor that has a plugin for just about everything you can imagine</li>
<li><a href="https://github.com/ranger/ranger">ranger</a> - A terminal based filemanager, perfect for those who don’t want to install all of KDE or Gtk just to move some files around</li>
<li><a href="https://wiki.archlinux.org/index.php/Zathura">zathura</a> - A vim-like document viewer that supports many types of files including EPUBs, PDFs, and even Comic Books</li>
<li><a href="https://github.com/dylanaraps/pywal">pywal</a> - A program that can generate and apply color schemes all over your system</li>
</ul>
<p>I hope this post was helpful and wish you the best with using i3 or whatever window manager you prefer.</p>
<h2 id="references">References</h2>
<p><a href="https://wiki.archlinux.org/index.php/I3https://wiki.archlinux.org/index.php/i3">Arch Wiki: i3</a></p>Evan LeClercqA Quick Window Manager Install Guide for Arch LinuxInstalling Arch Linux2020-02-09T00:00:00-06:002020-02-09T00:00:00-06:00https://e-leclercq.github.io/posts/2020/02/blog-post-1<h1 id="how-to-install-arch-linux">How to install Arch Linux</h1>
<p>Before we begin with the installation process, there are a few things I would like to get out of the way.
I will be assuming that you have some knowledge of Linux; however, I will be explaining each step in full detail.
If you are not using a Linux system, then you can search for a tutorial on how to make a bootable USB or SD card on Windows or macOS systems and skip to step 2.
Finally, you will need some things for this endeavor including the USB or SD card you will use to install the operating system, the computer in which you would like to install Arch Linux, an Ethernet connection, and a lot of patience.</p>
<p>Now, lets start installing Arch Linux.</p>
<h2 id="step-1-prepare-the-installation-medium">Step 1: Prepare the Installation Medium</h2>
<p>To install Arch you must first prepare the USB or SD card with the ISO image.
Go to https://www.archlinux.org/download/, and select which region you would like to download the file from.
Once you have selected the mirror, download the file called archlinux-<em>version</em>-x86_64.iso.
This is the disk image that you will be installing on the USB or CD.</p>
<p>Next, you will need to verify the download.
You can do this from a terminal by typing the following command:</p>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>$ echo "b4294ad607d3df9bf71775484accff133a77fdae *archlinux-2020.01.01-x86_64.iso" | sha1sum --check
</code></pre></div></div>
<p>You should receive the following output:</p>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>archlinux-2020.01.01-x86_64.iso: OK
</code></pre></div></div>
<p>If you do not receive this output, then try downloading the ISO file and checking it again.</p>
<p>Now that we have verified our ISO image, we can burn it to the USB or SD card.
Simply format the drive that you wish to burn the ISO to.
Then, type the following command (be sure to replace the X below with the letter of the drive you want to burn the ISO to):</p>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>$ sudo dd bs=1M if=archlinux-2020.01.01-x86_64.iso of=/dev/sdX conv=fsync
</code></pre></div></div>
<p>This should take quite a while, so sit back, relax, and drink a lot of coffee, cause the next step is where things start to get interesting.</p>
<h2 id="step-2-boot-into-the-arch-linux-iso">Step 2: Boot Into the Arch Linux ISO</h2>
<p>Now that you have your installation medium ready to go, stick the USB or SD card in the computer in which you would like to install Arch Linux.
Boot up the computer and enter the BIOS configuration (for most computers you hit <code class="language-plaintext highlighter-rouge">f12</code>, <code class="language-plaintext highlighter-rouge">del</code>, <code class="language-plaintext highlighter-rouge">esc</code>, or a similar key while the computer is booting up.)
Next, choose to boot from your installation medium.</p>
<p>Once the device has booted successfully, you will see a black screen with a few options.
Then, select the first option.
You should now have a prompt that looks like this:</p>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>root@archiso ~ #
</code></pre></div></div>
<p>If you see this, then you are good to go and can begin the installation.</p>
<h2 id="step-3-setup-for-the-installation">Step 3: Setup for the Installation</h2>
<p>Before we begin installing things, it’s a good idea to check the status of your network.
You can type the following command to check this:</p>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code># ping -c 1 google.com
</code></pre></div></div>
<p>This command should return the following output:</p>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>PING google.com (172.217.4.78) 56(84) bytes of data.
64 bytes from google.com (172.217.4.78): icmp_seq=1 ttl=54 time=5.72 ms
--- google.com ping statistics ---
1 packets transmitted, 1 received, 0% packet loss, time 0ms
rtt min/avg/max/mdev = 5.721/5.721/5.721/0.000 ms
</code></pre></div></div>
<p>This means that you are connected to the internet and ready to move on to the next part of this step; however, if you recieve an output that looks like this:</p>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>ping: google.com: Temporary failure in name resolution
</code></pre></div></div>
<p>then check to make sure that your ethernet cable is connected correctly.</p>
<p>Next, you need to update the system clock.
You can do this with this simple command:</p>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code># timedatectl set-ntp true
</code></pre></div></div>
<h2 id="step-4-partition-the-hard-drive">Step 4: Partition the Hard Drive</h2>
<p><strong>WARNING:</strong> What you are about to do will wipe the data on your computer’s drive.
If you have not backed up all of your files and data, then this is your last chance to turn back and do so.</p>
<p>Now that you know what you are about to do, you can start partitioning the drive.
First, check if you are using a UEFI system by running the command:</p>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code># ls /sys/firmware/efi/efivars
</code></pre></div></div>
<p>If it returns the contents of that directory, then you have an EFI system.
If it does not return any output, then you are using BIOS.</p>
<p>Run fdisk to check your devices:</p>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code># fdisk -l
</code></pre></div></div>
<p>Note the device in which you wish to install Arch.</p>
<p>Now run cfdisk to partition the hard drive.
Replace the X below with the letter of the device you noted earlier:</p>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code># cfdisk /dev/sdX
</code></pre></div></div>
<p>Then, select <code class="language-plaintext highlighter-rouge">gpt</code>.</p>
<p>You will need to create three partitions:</p>
<ol>
<li>An EFI partition</li>
<li>The root partition</li>
<li>A swap partition</li>
</ol>
<p><strong>Note:</strong> <em>If you do not see the <code class="language-plaintext highlighter-rouge">gpt</code> option and your drive has a <code class="language-plaintext highlighter-rouge">dos</code> partition table, you may have to use <code class="language-plaintext highlighter-rouge">fdisk</code> to set a new partition table on the device.</em></p>
<p>Once you have done this, create a partition that is <code class="language-plaintext highlighter-rouge">512 M</code> in size, label it as <code class="language-plaintext highlighter-rouge">EFI System</code>, and give it the <code class="language-plaintext highlighter-rouge">boot</code> flag if needed.
Next up, make the swap partition and the root partition.
The swap partition should be two times the size of your computer’s RAM and the root partition can be whatever size you would like so long as you have room.
Label the swap partition as <code class="language-plaintext highlighter-rouge">Linux swap</code> and the root partition as <code class="language-plaintext highlighter-rouge">Linux filesystem</code>, then write the changes to disk (again see warning above).</p>
<p>Now that you have succesfully written the changes to the disk, you can setup the filesystem with (where X is the drive letter and Y is the drive number of your root partition):</p>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code># mkfs.ext4 /dev/sdXY
</code></pre></div></div>
<p>To get the swap space working use the commands (where X is the drive letter and Y is the drive number of your swap partition):</p>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code># mkswap /dev/sdXY
# swapon /dev/sdXY
</code></pre></div></div>
<p>Finally, the EFI partition needs to use the FAT32 filesystem, so use the command (where X is the drive letter and Y is the drive number of your EFI partition):</p>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code># mkfs.fat -F32 /dev/sdXY
</code></pre></div></div>
<h2 id="step-5-mounting-and-installing-arch">Step 5: Mounting and Installing Arch</h2>
<p>You must now mount the root partition to <code class="language-plaintext highlighter-rouge">/mnt</code>:</p>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code># mount /dev/sdXY /mnt
</code></pre></div></div>
<p>Go ahead and edit the mirrorlist, selecting which mirrors you would like to use when installing packages:</p>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code># nano /etc/pacman.d/mirrorlist
</code></pre></div></div>
<p>You can delete mirrors that are not from your respective country as these will result in slower downloads.</p>
<p>Now you can use pacstrap to download the essentials for your system:</p>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code># pacstrap /mnt base base-devel linux linux-firmware nano vim man-db networkmanager dhcpcd
</code></pre></div></div>
<p>Once those packages have been installed, use the following command to generate an fstab:</p>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code># genfstab -U /mnt >> /mnt/etc/fstab
</code></pre></div></div>
<h2 id="step-6-configuring-your-system">Step 6: Configuring Your System</h2>
<p>This step is fairly long; however, the tasks are fairly basic and rely mostly on your preferences.</p>
<p>Start by <code class="language-plaintext highlighter-rouge">chroot</code>ing into the new Arch installation with:</p>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code># arch-chroot /mnt
</code></pre></div></div>
<p>List out the available time-zone regions and cities with:</p>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code># ls /usr/share/zoneinfo/
# ls /usr/share/zoneinfo/<YOUR REGION>
</code></pre></div></div>
<p>Then, create a symbolic link to set your <code class="language-plaintext highlighter-rouge">localtime</code>:</p>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code># ln -sf /usr/share/zoneinfo/Region/City /etc/localtime
</code></pre></div></div>
<p>Finally, set your <code class="language-plaintext highlighter-rouge">adjtime</code> with:</p>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code># hwclock --systohc --utc
</code></pre></div></div>
<p>Use <code class="language-plaintext highlighter-rouge">nano</code> or <code class="language-plaintext highlighter-rouge">vim</code> to uncomment any locales you wish to use in <code class="language-plaintext highlighter-rouge">/etc/locale.gen</code> with (for the US this is <code class="language-plaintext highlighter-rouge">en_US.UTF-8 UTF-8</code>):</p>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code># nano /etc/locale.gen
</code></pre></div></div>
<p>Once the locale is uncommented, run the following command to set your locale:</p>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code># locale-gen
</code></pre></div></div>
<p>You can set your language in the file <code class="language-plaintext highlighter-rouge">/etc/locale.conf</code> (I use en_US.UTF-8 as an example below):</p>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code># echo "LANG=en_US.UTF-8" > /etc/locale.conf
</code></pre></div></div>
<p>Create a hostname for your device and use the following command to set it:</p>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code># echo "<HOSTNAME>" > /etc/hostname
</code></pre></div></div>
<p>Then use <code class="language-plaintext highlighter-rouge">nano</code> or <code class="language-plaintext highlighter-rouge">vim</code> to edit <code class="language-plaintext highlighter-rouge">/etc/hosts</code>, making it look like the following:</p>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code># nano /etc/hosts
127.0.0.1 localhost
::1 localhost
127.0.1.1 <HOSTNAME>.localdomain <HOSTNAME>
</code></pre></div></div>
<p>Set your root password with:</p>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code># passwd
</code></pre></div></div>
<p>Install sudo:</p>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code># pacman -Syu
# pacman -S sudo
</code></pre></div></div>
<p>Next, make a user with a home directory and add them to the necessary groups:</p>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code># useradd -m <USERNAME> -G wheel,audio,optical,storage,video
</code></pre></div></div>
<p>Set a password for your new user:</p>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code># passwd <USERNAME>
</code></pre></div></div>
<p>Finally, give the user the permission to execute commands as a part of the wheel group:</p>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code># visudo
</code></pre></div></div>
<p>Uncomment the following line by pressing the <code class="language-plaintext highlighter-rouge">del</code> key over the pound symbol (“#”):</p>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>%wheel ALL=(ALL) ALL
</code></pre></div></div>
<p>Then type <code class="language-plaintext highlighter-rouge">:wq</code> and hit <code class="language-plaintext highlighter-rouge">enter</code> to write the changes and quit out of vim.</p>
<h2 id="step-7-grub">Step 7: GRUB</h2>
<p>This step is fairly short and is the final step before you can boot into your installation of Arch Linux.</p>
<p>Start by installing <code class="language-plaintext highlighter-rouge">grub</code> and a few packages that are required:</p>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code># pacman -S grub efibootmgr os-prober dosfstools
</code></pre></div></div>
<p>Mount the EFI partition you made earlier to the /boot/efi partition on your drive:</p>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code># cd /boot
# mkdir EFI
# mount /dev/sdXY /boot/EFI
</code></pre></div></div>
<p>Now that you have the grub package and other necessary packages, run <code class="language-plaintext highlighter-rouge">grub-install</code>:</p>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code># grub-install --target=x86_64-efi --bootloader-id=grub_uefi --efi-directory=/boot/EFI --recheck
</code></pre></div></div>
<p>Then configure grub with the following command:</p>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code># grub-mkconfig -o /boot/grub/grub.cfg
</code></pre></div></div>
<p>You should now be able to boot into your Arch Linux installation.
So, go ahead and exit from your current shell, unmount all of the mounted devices (where ABCD are the drive letters and numbers corresponding to your mounted partitions i.e. root and EFI), and reboot your system:</p>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code># exit
# umount /dev/sdAB
# umount /dev/sdCD
# reboot
</code></pre></div></div>
<p>Once the grub menu appears, you may remove the installation medium.</p>
<h2 id="conclusion">Conclusion</h2>
<p>Congrats, you have successfully installed Arch Linux!</p>
<p>By using Arch Linux, you have almost infinite control over the configuration of your system from here.
I will be posting some more guides soon on some of the things that you can do with Arch and cool ways to customize it to your liking.</p>
<h2 id="references">References</h2>
<p><a href="https://wiki.archlinux.org/index.php/Installation_guide">The Arch Wiki Installation Guide</a></p>Evan LeClercqHow to install Arch Linux