FreeCad 0.20 on windows only runs as administrator

Having trouble installing or compiling FreeCAD? Get help here.
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
User avatar
adrianinsaval
Veteran
Posts: 5541
Joined: Thu Apr 05, 2018 5:15 pm

Re: FreeCad 0.20 on windows only runs as administrator

Post by adrianinsaval »

uwestoehr wrote: Fri Jul 01, 2022 5:29 pm Then when you choose to install only for you, it is installed to "C:\Users\%username%\AppData\Roaming\FreeCAD\" (according to the Windows guidelines)
What is wrong with this? Can't you start FreeCAD then (of course you then need to be logged in as admin).
wait, isn't this wrong? shouldn't it install to C:\Users\%username%\AppData\Local\FreeCAD ? Roaming is where the config is placed if I'm not mistaken
User avatar
uwestoehr
Veteran
Posts: 4961
Joined: Sun Jan 27, 2019 3:21 am
Location: Germany
Contact:

Re: FreeCad 0.20 on windows only runs as administrator

Post by uwestoehr »

adrianinsaval wrote: Fri Jul 01, 2022 5:40 pm wait, isn't this wrong? shouldn't it install to C:\Users\%username%\AppData\Local\FreeCAD ? Roaming is where the config is placed if I'm not mistaken
Indeed. When I run the installer an normal user, the default install location is:

Code: Select all

C:\Users\stoehr\AppData\Local\Programs\FreeCAD 0.20
When I run it as admin, the default is to install for all users. When I say to install only for the current user the default install location is:

Code: Select all

C:\Users\Admin\AppData\Local\Programs\FreeCAD 0.20
TWrecks
Posts: 25
Joined: Sun May 28, 2017 6:54 pm

Re: FreeCad 0.20 on windows only runs as administrator

Post by TWrecks »

I have a Samba3 domain server at home which I've been doing for the last 20 years. Normally I log in on my pc as my usual username (which is not *the* administrator but does belong to the local administrators group on my pc). I think it goes to "roaming" as that's what the domain controller sets APPDATA to. Even when I created a local user, that account %APPDATA% was pointing to Appdata\Roaming also. I've tried installing it for all, or just for current user with no difference. When it launches the first time from the installer option it works (I'm guessing installer runs with admin privs and does not drop them before launching FreeCAD?).

I should mention that FreeCAD 0.15 through 0.19 had no issues with this.

I also tried installing FreeCAD on my work laptop (also a domain logon but different domain and run by a windows domain controller) with a user logon (also with local admin group membership) and that worked. It also has %APPDATA% set user\AppData\Roaming\FreeCAD, so I think that is just a domain thing.

Tim
User avatar
adrianinsaval
Veteran
Posts: 5541
Joined: Thu Apr 05, 2018 5:15 pm

Re: FreeCad 0.20 on windows only runs as administrator

Post by adrianinsaval »

TWrecks wrote: Sat Jul 02, 2022 5:21 pm %APPDATA% was pointing to Appdata\Roaming
This is normal, the installer doesn't install to %APPDATA%, it installs to C:\Users\%username%\AppData\Local\Programs\FreeCAD 0.20
there is a FreeCAD folder in %APPDATA% but this just has the config, addons, etc.
User avatar
uwestoehr
Veteran
Posts: 4961
Joined: Sun Jan 27, 2019 3:21 am
Location: Germany
Contact:

Re: FreeCad 0.20 on windows only runs as administrator

Post by uwestoehr »

TWrecks wrote: Sat Jul 02, 2022 5:21 pm I also tried installing FreeCAD on my work laptop (also a domain logon but different domain and run by a windows domain controller) with a user logon (also with local admin group membership) and that worked. It also has %APPDATA% set user\AppData\Roaming\FreeCAD, so I think that is just a domain thing.
I still doesn't understand what the problem is. You can install to a folder you like. You only need to assure that when you call FreeCAD you have the permission to change the installation folder and all its subfolders.

Note that the Windows installer has not changes between FC 0.19 and 0.20.
TWrecks
Posts: 25
Joined: Sun May 28, 2017 6:54 pm

Re: FreeCad 0.20 on windows only runs as administrator

Post by TWrecks »

The issue for some reason with my user account, I have to "run-as-administrator" or it refuses to start with that "unknown runtime error". Is doesn't seem like it matters that the config is kept in AppData\Roaming. I let freecad install into the default directories (I tried both for "all users" and just for "current user"). I gave myself "full control" on both "C:\Program Files\FreeCAD 0.20" and "C:\Users\<username>\AppData\Roaming\FreeCAD", but it still won't run for my user unless I run-a-administrator.

Tim
User avatar
uwestoehr
Veteran
Posts: 4961
Joined: Sun Jan 27, 2019 3:21 am
Location: Germany
Contact:

Re: FreeCad 0.20 on windows only runs as administrator

Post by uwestoehr »

TWrecks wrote: Sun Jul 03, 2022 1:10 am I gave myself "full control" on both "C:\Program Files\FreeCAD 0.20" and "C:\Users\<username>\AppData\Roaming\FreeCAD", but it still won't run for my user unless I run-a-administrator.
Then also need to give your user account full access to

C:\Users\<username>\AppData\Local\Programs\FreeCAD 0.20

because this is the folder that should always exist and where the user settings will be stored.
TWrecks
Posts: 25
Joined: Sun May 28, 2017 6:54 pm

Re: FreeCad 0.20 on windows only runs as administrator

Post by TWrecks »

The folder "C:\Users\<username>\AppData\Local\Programs\FreeCAD 0.20" doesn't exist, though "C:\Users\<username>\AppData\Local\Programs\FreeCAD" does - but that contains only a "cache" folder, and I have "full control" over it. There is a user and system .cfg file in the "C:\Users\<username>\AppData\Roaming\FreeCAD" dir.

Currently I have FreeCAD 0.20 installed for "all users".

Curiously I re-installed FreeCAD 0.19, and it remains quite happy to run w/o administrator privileges.

Tim
User avatar
uwestoehr
Veteran
Posts: 4961
Joined: Sun Jan 27, 2019 3:21 am
Location: Germany
Contact:

Re: FreeCad 0.20 on windows only runs as administrator

Post by uwestoehr »

TWrecks wrote: Thu Jul 07, 2022 1:28 am Curiously I re-installed FreeCAD 0.19, and it remains quite happy to run w/o administrator privileges.
Then something is fishy with your FreeCAD installation because when you look at the logs you can see that for FreeCAD 0.20 I only changed the version numbers, nothing else for the installer:
https://github.com/FreeCAD/FreeCAD/tree ... sInstaller

Please uninstall FreeCAD _completely_, also check the registry afterwards and remove traces. Then log off from Windows, eventually reinstall FreeCAD.
Post Reply