How to resolve "This program is blocked by group policy" errors?

451 visualizaciones (últimos 30 días)
How to resolve the following error?
This program is blocked by group policy. For more information, contact your system administrator.
It can occur in different workflows when MATLAB/Simulink tries to:
  • Launch or load external processes or applications (EXE, DLL, MEX, or other binaries)
  • Create or access binaries in the Temp folder (C:\Users\xxxx\AppData\Local\Temp\)
Typical scenarios where this error might arise include:
  • Launching browser-based apps (App Designer, Live Editor)
  • Updating or running a Simulink model
  • Code generation workflows (MATLAB Coder, Simulink Coder, Simulink Real-Time, Rapid Accelerator mode, etc.)
  • Launching standalone applications compiled with MATLAB Compiler (SDK) or Simulink Compiler

Respuesta aceptada

MathWorks Support Team
MathWorks Support Team el 16 de Dic. de 2024 a las 0:00
Editada: MathWorks Support Team el 16 de Dic. de 2024 a las 11:29
The error message "This program is blocked by group policy" typically indicates that your system's group policy settings are restricting certain actions or applications. This is common in environments managed by IT departments, such as corporate or educational institutions. Here are some troubleshooting steps you can take to resolve this issue:

1. Run MATLAB as Administrator

Running MATLAB as an administrator can sometimes bypass group policy restrictions if the issue is related to permissions.

2. Contact Your System Administrator

The next step is to contact your system administrator or IT support team. They have the necessary permissions to modify group policies and can provide a solution tailored to your organization's policies.

3. Check Group Policy Settings

If you have administrative rights on your computer, you can check and modify group policy settings:
  1. Press the Windows + R keys to open the Run dialog. Then you should type gpedit and click OK to open the Group Policy window.
  2. Expand User Configuration > Administrative Templates > System. In the right pane, navigate to Don’t run specified Windows applications and double-click it.
  3. Then click the Show button. Ensure that MATLAB and related binaries (e.g., compilers), as well as specific folders (such as the Windows Temp, and MATLAB/Simulink codegen and cache folders), are not blocked.
  4. Remove the target program or application from the disallowed list and click OK.

4. Check Antivirus and Firewalls

Sometimes antivirus software can interfere with execution. Ensure that MATLAB and related binaries (e.g. compilers) are allowed in your antivirus software. Also check if Windows Defender or any other security software is blocking the execution of MATLAB-related processes.
Note, that e.g. the MinGW compilers are usually installed in the C:\ProgramData directory, not the MATLAB installation folder itself.

5. Modify Temp Folder Permissions and Location

If the error message points to a file located in the temp folder, check that your account has "Full Control" on the "C:\Users\xxxx\AppData\Local\Temp" folder.
If this doesn't help, change the Temp folder location to a safe directory. Run these commands in MATLAB:
setenv('TMP', <path to a safe location>) clear tempdir
Note that "setenv" changes the Temp directory for the current MATLAB session only and does not affect other applications or system-wide environment variables.
After changing the Temp directory, rerun your workflow to confirm the workaround. To automate the execution of the above commands, place them in a startup.m script and add it to your MATLAB path, such as the MATLAB userpath.

5. Reinstall MATLAB/Simulink

In some scenarios, especially if the administrator privileges on your Windows account have changed, reinstalling MATLAB/Simulink can help. If MATLAB was initially installed when you had administrator privileges, it might continue to assume it has certain permissions even after those privileges have been revoked. A reinstallation can potentially resolve this issue by updating the permissions.

Más respuestas (0)

Categorías

Más información sobre Introduction to Installation and Licensing en Help Center y File Exchange.

Productos


Versión

R2022a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by