Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Qt Creator and other tools
  4. Qt Creator is always looking for Ollama since the latest update
Qt 6.11 is out! See what's new in the release blog

Qt Creator is always looking for Ollama since the latest update

Scheduled Pinned Locked Moved Unsolved Qt Creator and other tools
12 Posts 4 Posters 1.0k Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • R Robert Hairgrove

    Using the latest update to Qt Creator 19.0.2 on Linux Ubuntu 24.04 and Qt 6.11.1.

    Every time I open a project or change a *.pro file, I get an error now:

    :-1: error: find: ‘/usr/share/ollama/.nv’: Permission denied
    

    I have Ollama running, but why does Qt Creator need to access it? I had been using the AI translation facility of Qt Linguist, but Qt Creator itself should not be using it if I don't tell it to. I have no AI settings active at all in Preferences.

    What is causing this, and how can I stop it from happening? I am pretty sure that I did NOT get this error until I installed the update today.

    Here is what "About Qt Creator" says:

    Product: Qt Creator 19.0.2
    Based on: Qt 6.10.3 (GCC 11.5.0 20240719 (Red Hat 11.5.0-11), x86_64)
    Built on: Mon May 11 08:32:25 2026
    From revision: 41c25c247e
    
    cristian-adamC Online
    cristian-adamC Online
    cristian-adam
    wrote last edited by
    #2

    @Robert-Hairgrove check under Preferences > AI > Custom Language Models if you have something there.

    This feature was added a while ago to help with error messages, and AFAIK it uses ollama.

    R 1 Reply Last reply
    0
    • cristian-adamC cristian-adam

      @Robert-Hairgrove check under Preferences > AI > Custom Language Models if you have something there.

      This feature was added a while ago to help with error messages, and AFAIK it uses ollama.

      R Offline
      R Offline
      Robert Hairgrove
      wrote last edited by
      #3

      @cristian-adam Thanks, but there is nothing listed there.

      cristian-adamC 1 Reply Last reply
      0
      • R Robert Hairgrove

        @cristian-adam Thanks, but there is nothing listed there.

        cristian-adamC Online
        cristian-adamC Online
        cristian-adam
        wrote last edited by
        #4

        @Robert-Hairgrove https://github.com/qt-creator/qt-creator/commit/e38993883ab52878b85212607f3528522c5c553a was for me the only ollama feature that I knew of in 19.0.2.

        Maybe you can use strace to find out who is trying to access the folder.

        R 1 Reply Last reply
        2
        • cristian-adamC cristian-adam

          @Robert-Hairgrove https://github.com/qt-creator/qt-creator/commit/e38993883ab52878b85212607f3528522c5c553a was for me the only ollama feature that I knew of in 19.0.2.

          Maybe you can use strace to find out who is trying to access the folder.

          R Offline
          R Offline
          Robert Hairgrove
          wrote last edited by
          #5

          @cristian-adam Thanks again. I tried strace but couldn't find anything. Unfortunately, I don't know the right options to use. It looks like the call to find is buried deeply in the parsing of the code base for the project.

          However, I looked at the way ollama installs the directory under /usr/shared . I'm surprised that this could ever work since permissions for the .nv directory are severely restricted::

          bob@laptop:/usr/share/ollama$ ls -al
          total 40
          drwxr-x---   4 ollama ollama  4096 Dec 25 17:23 .
          drwxr-xr-x 377 root   root   16384 May 25 12:17 ..
          -rw-r--r--   1 ollama ollama   220 Mar 31  2024 .bash_logout
          -rw-r--r--   1 ollama ollama  3771 Mar 31  2024 .bashrc
          drwx------   3 ollama ollama  4096 Dec 25 17:23 .nv     <== permissions?
          drwxr-xr-x   3 ollama ollama  4096 Dec 25 17:23 .ollama
          -rw-r--r--   1 ollama ollama   807 Mar 31  2024 .profile
          

          To install ollama, I just followed the instructions given on their website -- nothing special.

          JonBJ 1 Reply Last reply
          0
          • R Robert Hairgrove

            @cristian-adam Thanks again. I tried strace but couldn't find anything. Unfortunately, I don't know the right options to use. It looks like the call to find is buried deeply in the parsing of the code base for the project.

            However, I looked at the way ollama installs the directory under /usr/shared . I'm surprised that this could ever work since permissions for the .nv directory are severely restricted::

            bob@laptop:/usr/share/ollama$ ls -al
            total 40
            drwxr-x---   4 ollama ollama  4096 Dec 25 17:23 .
            drwxr-xr-x 377 root   root   16384 May 25 12:17 ..
            -rw-r--r--   1 ollama ollama   220 Mar 31  2024 .bash_logout
            -rw-r--r--   1 ollama ollama  3771 Mar 31  2024 .bashrc
            drwx------   3 ollama ollama  4096 Dec 25 17:23 .nv     <== permissions?
            drwxr-xr-x   3 ollama ollama  4096 Dec 25 17:23 .ollama
            -rw-r--r--   1 ollama ollama   807 Mar 31  2024 .profile
            

            To install ollama, I just followed the instructions given on their website -- nothing special.

            JonBJ Offline
            JonBJ Offline
            JonB
            wrote last edited by
            #6

            @Robert-Hairgrove
            Since Google/AI says:

            Yes, you can delete the .nv folder. It is simply a temporary cache. However, the very next time you run a heavy model on your NVIDIA GPU, Ollama and the CUDA driver will automatically regenerate the folder to store the necessary computational kernels.

            have you tried deleting it or changing its permissions?

            R 1 Reply Last reply
            0
            • JonBJ JonB

              @Robert-Hairgrove
              Since Google/AI says:

              Yes, you can delete the .nv folder. It is simply a temporary cache. However, the very next time you run a heavy model on your NVIDIA GPU, Ollama and the CUDA driver will automatically regenerate the folder to store the necessary computational kernels.

              have you tried deleting it or changing its permissions?

              R Offline
              R Offline
              Robert Hairgrove
              wrote last edited by
              #7

              @JonB said in Qt Creator is always looking for Ollama since the latest update:

              have you tried deleting it or changing its permissions?

              No. Why should I have to do that? If Ollama sets those permissions by default, then there must be a reason for that, IMHO.

              JonBJ 1 Reply Last reply
              0
              • R Robert Hairgrove

                @JonB said in Qt Creator is always looking for Ollama since the latest update:

                have you tried deleting it or changing its permissions?

                No. Why should I have to do that? If Ollama sets those permissions by default, then there must be a reason for that, IMHO.

                JonBJ Offline
                JonBJ Offline
                JonB
                wrote last edited by JonB
                #8

                @Robert-Hairgrove said in Qt Creator is always looking for Ollama since the latest update:

                No. Why should I have to do that?

                Because you would see if that makes a difference and allows it to work. I quoted you where it says it's a temporary directory and can be deleted anyway. But instead of trying that you are welcome to live with the warning message you do not like.

                If Ollama sets those permissions by default, then there must be a reason for that, IMHO

                The permissions look like they may be fine if/when Ollama runs as ollama user. Your problem seems to be Creator (if that is what is issuing the message) choosing to run some find command, for whatever reason, which may be nothing to do with Ollama itself.

                1 Reply Last reply
                0
                • Z Offline
                  Z Offline
                  ziller
                  wrote last edited by ziller
                  #9
                  :-1: error: find: ‘/usr/share/ollama/.nv’: Permission denied
                  

                  Does the .pro file that you open in Qt Creator contain some $$system command or such that triggers find? These might be executed whenever Qt Creator parses the project. You can turn that off in "Preferences > Build & Run > Qmake > Ignore qmake's system() function", but that might also break project loading if that does something essential for your .pro file. The find command might also be triggered by some other included .pri file, or .prf file or by some other tool that is run (no idea what e.g. pkg_config might do for finding packages, though I'd assume that that doesn't do a global find....)

                  If you can reproduce the issue when running qmake for the project from the command line, you can try running qmake with the "-d" option (possibly multiple 'd's to increase verbosity) to find out what calls find.

                  R 1 Reply Last reply
                  0
                  • Z ziller
                    :-1: error: find: ‘/usr/share/ollama/.nv’: Permission denied
                    

                    Does the .pro file that you open in Qt Creator contain some $$system command or such that triggers find? These might be executed whenever Qt Creator parses the project. You can turn that off in "Preferences > Build & Run > Qmake > Ignore qmake's system() function", but that might also break project loading if that does something essential for your .pro file. The find command might also be triggered by some other included .pri file, or .prf file or by some other tool that is run (no idea what e.g. pkg_config might do for finding packages, though I'd assume that that doesn't do a global find....)

                    If you can reproduce the issue when running qmake for the project from the command line, you can try running qmake with the "-d" option (possibly multiple 'd's to increase verbosity) to find out what calls find.

                    R Offline
                    R Offline
                    Robert Hairgrove
                    wrote last edited by
                    #10

                    @ziller Thanks for the suggestions. But I got along fine without ollama until I started using Qt Linguist's AI translation feature. I can just ignore the error since it doesn't seem to have any side effects. But it seems like a bug to me -- not one I am presently motivated to find, however.

                    1 Reply Last reply
                    0
                    • R Offline
                      R Offline
                      Robert Hairgrove
                      wrote last edited by
                      #11

                      I changed the permissions on the .nv folder and the (empty) subfolder ComputeCache it contains. The error was not reported by Qt Creator any more, but I'm not sure it is a good idea to leave the permissions this way. The ollama service can run as a different user than ollama. In order to be able to connect to the service using Qt Linguis, I need to either start the service configured to use a different user, i.e. my own user, or else stop the service and start it from a terminal. Then I can use Qt Linguist. I'm not sure why this is, because if I let ollama run as the ollama user, I can send requests through localhost without any probem (I also have Apache running in the background, BTW).

                      I noticed that when ollama is running as my own user, I get a folder .nv in my home directory which has my user listed as owner and group. Presumably, Qt Creator is just checking to see whether it can access Ollama as my user or not, and uses the find command to locate the .nv folder -- perhaps without ever actually needing to use it. If this is the case, "Permission denied" errors should be ignored and not propagated to Qt Creator application output. This is the offending behavior.

                      1 Reply Last reply
                      0
                      • R Offline
                        R Offline
                        Robert Hairgrove
                        wrote last edited by
                        #12

                        I would like to add that I haven't been able to reproduce the issue when creating and opening "Hello World"-type projects. I do have some $$system() calls in the .pro file where it happens, but these are necessary (many are for finding programs like pkg-config, which was mentioned).

                        But none of the external system calls have anything to do with ollama, and I really only use it in Qt Linguist which is referenced through the External Tools menu in Qt Creator. Maybe over the weekend I will have time to investigate further.

                        1 Reply Last reply
                        0

                        • Login

                        • Login or register to search.
                        • First post
                          Last post
                        0
                        • Categories
                        • Recent
                        • Tags
                        • Popular
                        • Users
                        • Groups
                        • Search
                        • Get Qt Extensions
                        • Unsolved