<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Vitalii Yulieff</title>
    <description>The latest articles on DEV Community by Vitalii Yulieff (@yulieff).</description>
    <link>https://dev.to/yulieff</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F1759757%2Fd02af7fe-6847-489c-9a5a-f2d98bd79024.jpg</url>
      <title>DEV Community: Vitalii Yulieff</title>
      <link>https://dev.to/yulieff</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/yulieff"/>
    <language>en</language>
    <item>
      <title>Fixing Ollama Installation on Manjaro + NVIDIA</title>
      <dc:creator>Vitalii Yulieff</dc:creator>
      <pubDate>Thu, 11 Jul 2024 11:54:12 +0000</pubDate>
      <link>https://dev.to/yulieff/fixing-ollama-installation-on-manjaro-nvidia-2hdk</link>
      <guid>https://dev.to/yulieff/fixing-ollama-installation-on-manjaro-nvidia-2hdk</guid>
      <description>&lt;p&gt;The current Ollama version in Arch is outdated (&lt;code&gt;0.1.44&lt;/code&gt; vs &lt;code&gt;0.2.1&lt;/code&gt; latest). The official install script doesn't support some Manjaro configurations, but don't worry—I've got the fix!&lt;/p&gt;

&lt;h2&gt;
  
  
  The Problem 🤔
&lt;/h2&gt;

&lt;p&gt;When I tried running the install script, I got hit with this:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl &lt;span class="nt"&gt;-fsSL&lt;/span&gt; https://ollama.com/install.sh | sh
&lt;span class="c"&gt;# sh: line 252: VERSION_ID: unbound variable&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This cryptic error just means you're missing those NVIDIA drivers, and Ollama can't sort that out for you.&lt;/p&gt;

&lt;h2&gt;
  
  
  Step-by-Step Fix 🏌️
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;step 1&lt;/strong&gt;: find your linux kernel verion:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;uname&lt;/span&gt; &lt;span class="nt"&gt;-r&lt;/span&gt;
&lt;span class="c"&gt;# 6.9.5-1-MANJARO&lt;/span&gt;
pamac search &lt;span class="s2"&gt;"linux.*header"&lt;/span&gt;
&lt;span class="c"&gt;# linux69-headers  6.9.5-1 [Installed]&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;step 2&lt;/strong&gt; install everything you need&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;pamac &lt;span class="nb"&gt;install &lt;/span&gt;nvidia nvidia-utils cuda linux69-headers
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;step 3&lt;/strong&gt; you might want to restart your Linux just to be on the safe side&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;step 4&lt;/strong&gt;  Now, run the install script again:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl &lt;span class="nt"&gt;-fsSL&lt;/span&gt; https://ollama.com/install.sh | sh
&lt;span class="c"&gt;# ollama successfully installs on your Manjaro system!&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;🏆 Boom! Done!&lt;/p&gt;

&lt;h2&gt;
  
  
  Troubleshooting  🕵️‍♂️
&lt;/h2&gt;

&lt;p&gt;Here's how you can check the successful installation:&lt;/p&gt;

&lt;p&gt;1) Run &lt;code&gt;nvidia-smi&lt;/code&gt; and your video card should show up.&lt;br&gt;
2) Make sure that your video card and its device ID are in the OLLAMA's logs&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;journalctl &lt;span class="nt"&gt;-u&lt;/span&gt; ollama | &lt;span class="nb"&gt;grep&lt;/span&gt; &lt;span class="s2"&gt;"id=.*NVIDIA"&lt;/span&gt;
&lt;span class="c"&gt;# ollama[2174]: [...] id=GPU-3a31a7cb-e46b-458c-9a92-ea9708b0c7fa library=cuda compute=8.9 driver=12.4 name="NVIDIA GeForce RTX 4090 Laptop GPU" total="15.7 GiB" available="15.5 GiB"&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Quick Note for Wayland + GNOME Users
&lt;/h2&gt;

&lt;p&gt;Even after I installed drivers, my Wayland still uses integrated video graphics.&lt;/p&gt;

</description>
      <category>ollama</category>
      <category>manjaro</category>
      <category>nvidia</category>
    </item>
  </channel>
</rss>
