5

Нужные страницы

Translate

Search

Показаны сообщения с ярлыком fix. Показать все сообщения
Показаны сообщения с ярлыком fix. Показать все сообщения

пятница, 6 октября 2017 г.

Crashing Solidworks and the threshold of system resources

I think everyone who modeled in Solidworks came across an unexpected program closure. Bouncing solid quite often, but as a rule, when complex models are opened and closed intensively or when they are saved, which is especially unpleasant.
Do not all fall for the curvature of developers, they are trying to create a quality product. The reason for the unexpected collapse of Solidworks is the limitation of Windows that the process can only access 10,000 GDI objects.

What is GDI?

GDI objects are used to draw window elements that are not in the graphics area in SolidWorks. For maximum performance, the graphics area uses OpenGL, which gives more direct access to the equipment for video processing. GDI objects are used for the chrome graphic area, so every time a new document is opened, the number of GDI objects used by SOLIDWORKS will increase. Prior to this, SOLIDWORKS 2011 SP4, if the part was opened in the assembly and its own window, when this window was closed, it would not free these GDI objects. The default behavior is now to release these descriptors, but not all of them are released.

Why is this all due to the failure of SOLIDWORKS? Windows has a default limitation that one process can access only 10,000 GDI objects. Because SolidWorks does not release all objects when the document is closed, the number it uses increases continuously with each new document and gradually approaches the limit set in Windows.




Is it possible to use this knowledge to predict when SOLIDWORKS will knock out? 


Predicting a SOLIDWORKS crashing

As it was written above, this is not technically a failure, if SOLIDWORKS reaches the limit of 10,000 by object, Windows completes the process. This is not caused by a code error or by problems with shared memory access or anything else that causes a crash. It's just that Windows believes that SOLIDWORKS consumes too much resources and closes it to get those resources back. But since there is a certain number at which it closes, you can predict when it will happen. In fact, it's easy to control. Just follow these steps:


  • Open task manager (you can right click on the task bar and click task manager). 
  • Click View, Select Columns…
Select Columns in Windows Task Manager


Check off GDI and User Objects and click OK

Display GDI Objects
Now, the task manager will display the current value of the GDI and USER objects for each process



Display GDI Objects
Display GDI ObjectsIf a part is opened and closed several times the number of GDI objects it uses does not increase. SOLIDWORKS releases all handles every time.  The same applies to assemblies as well.  The problem is only encountered when a part is open in an assembly and it is opened in its own window and then closed.  
How to troubleshoot this crash problems

How can this problem be avoided? Do not keep your assemblies open unless you need them to be, and monitor your task manager periodically to see how many objects you are using.  Closing SOLIDWORKS and opening it will reset this count.  Furthermore you can increase the maximum number of GDI Objects a process can use by following these settings:
  • HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Windows\GDIProcessHandleQuota 

  • Sets the number of GDI objects, the range of values is 256 ~ 65536, the default is 10,000.


  • HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Windows\USERProcessHandleQuota 

  • Sets the number of descriptors, the range of values is 200 ~ 18000, the default is 10 000.
Increase the values and reduce the risk of Solidworks failure. When changing the parameters, switch to the decimal system of the calculus.

P.S.
When writing an article for testing, the parameters were reduced to 1500, after the Solidworks Resource Monitor warning, after some time the Solidworks was crashed. 

The same manipulations apply only to the GDI problem, if SolidWorks Resource Monitor writes that there is not enough memory, then the problem will be to add RAM or unload other programs.



By the materials of the blog javelin-tech

понедельник, 25 сентября 2017 г.

Slow Performance Solidworks

Why is Solidworks slow? Reducing the performance of Solidworks is a very unpleasant situation. And to find the cause is not easy. 

Possible reasons:



A great help in this is provided by Solidworks Rx.


Запуск утилиты Solidworks Rx
Launch the Solidworks Rx


At the bottom of the diagnostic page, there are two safe modes. The choice of the first ignores the video card driver and runs SolidWorks in OpenGL mode for the next SolidWorks session. This can help to eliminate the problem with the video card. If this safe mode resolves the problem, it becomes clear that your problem is related to your card and you need to get a new driver or replace the old video card. Command line of this mode:

"C:\Program Files\SOLIDWORKS Corp\SOLIDWORKS\sldworks.exe" /ForceSoftwareOGL /SWDisableExitApp

Another safe mode is "Ignore Tools / Options" for the next session. It uses the ready-made SolidWorks settings and disables all add-ins. If this security mode fixes the problem, you may need to fix the SolidWorks configuration or add-ons. The command line for this mode is as follows:

"C:\Program Files\SOLIDWORKS Corp\SOLIDWORKS\sldworks.exe" /SWSafeMode /SWDisableExitApp

Use safe modes to narrow the range of possible causes:
  • Driver or video card errors;
  • Errors of settings or additions;
  • Wrong shortcut to start.


If the problem disappears in OpenGL mode, then you need to update the driver. Not the fact that the new driver will solve the problem, in practice very often the older version is a solution to problems. Another option is to replace the video card with a more powerful gaming or professional. List of certified video cards you can see on the site Solidworks


If the second safe mode solves the problem (which disables all add-ons and works with the default settings), you must disable all Solidworks add-ins and test it.




 If the performance is normal, then we include add-ons one at a time and after each test. So if the reason is in the supplement, then including one by one we will find it. If, after disabling all extensions, Solidworks does not restore the performance, then reset to the default settings.



In this way, we set the mode in which Solidworks Rx checks the system.
In this way, we set the mode in which Solidworks Rx checks the system. There is another way to reset all user settings. To do this, start the Registry Editor, browse to "HKEY_CURRENT_USER\Software\SolidWorks\SOLIDWORKS 2016" and rename SolidWorks 2016 to anything you like.The path is specified for Solidworks 2016, find for your version and rename, for example, "Solidworks 2016_old". This will force SW to create a new default SolidWorks key the next time it's launched, which will also mean you'll lose any custom settings.



There are cases when, despite disabling add-ons and resetting parameters, Solidworks slows down, but if you run it through Solidworks Rx in the second safe mode - it works fine.
The reason for this is a wrong shortcut to start.


Sometimes when installing Soliworks, the installer incorrectly determines the installed system and prescribes compatibility with another operating system in the properties of the shortcut. For example, when you install Solidworks 2012 on Windows 7 x64, the shortcut properties have compatibility with Windows Vista. As a result, Solidworks is slow on fairly simple assemblies.


Свойства ярлыка Solidworks 2012 на Windows 7x64
True shortcut Solidworks 2012 on Windows 7x64

Неверный ярлык Solidworks 2012 на Windows 7x64
Wrong shortcut Solidworks 2012 on Windows 7x64

Because of the compatibility with Vista, Solidworks is slowing down. After creating the correct label, the solidworks works normally.

The following reasons for the slow work of Solidworks can be reflected in the tab: "Diagnostics"




You can see whether the system parameters are recommended. After these problems are resolved, click the Update Results button to restart the diagnostics.


 "Troubleshoot"



Using the tools in this tab implies the presence of a valid Solidworks serial number and a valid contract for subscription services.

This tab contains the necessary tools for removing temporary files that Solidworks uses. Especially I wanted to pay attention to clearing temporary files in Solidworks data folders. During an improper completion of a solid, temporary files beginning with "~" remain in the folder, in some cases this is the cause of the failure of Solidworks. It is desirable to delete such files, you can manually, but you can assign this procedure to Solidworks Rx. Running disk checking and defragmentation can be done by Windows utility tools without resorting to Solidworks Rx. System maintenance is possible and even desirable to plan:


Problem Capture

On this tab, you can record an error for technical support, attach additional files and send. I have no relation to independent resolution, so I will not go into more depth.


Add-in


On this tab, you can run a performance test and compare them with the data of other users, and add another application to the tab. You can see the results of other users by the link.

It should be noted, even if you seemed to have found a problem with the driver or add-on, to maintain the service after all, there can be several errors.


There is one more reason that can not be detected using the Solidworks Rx utility. Those. after all sorts of manipulations, the solid still slows down. The error can be in the registry - there is a possibility that the necessary data in the registry has been deleted or changed. And this obviously happens, because the SOLIDWORKS installation directory contains the "graphicshardware.reg" registry file, which restores the default settings for the video card. The path to it is the following "C:\Program Files\SolidWorks Corp\SolidWorks\lang". 


Another reason for poor performance may be the power settings. If you have a laptop, then this must be checked. So Start - Control Panel - Power - Set up a power plan - Change additional power settings, set "High Performance".

High Perfomance


 This option refers to the settings of Solidworks, so it is better to check it before resetting. The speed of opening Solidworks documents can be affected by the Search for Linked Documents option. For diagnostics, you must remove all paths from the "File Location" menu from the "Referenced Documents" item.



I hope this article has helped you.

четверг, 21 сентября 2017 г.

How to Fix SOLIDWORKS Toolbox

Error Solidworks Toolbox:

  1. Failed to get writable document
  2. Unable to open read-only file
  3. Failed to  save Toolbox library: Access to the path is denied

Failed to get writable document



In this case, you need to check the access rights to the Toolbox directory (by default C: \ Solidworks Data can be viewed in the Toolbox settings)


To do this, right-click on the Toolbox-Properties - Security tab. Check that your account has write permissions.


Unable to open read-only file

With this error, you must tick the "Change the status of the read-only document to the record" in the Toolbox- "User Settings" configurator settings



Failed to  save Toolbox library: 
Access to the path is denied

In the third case, you need to check the write permission of the "ToolboxFiles.index" file, which is located in the Toolbox - \ Browser directory. This error may appear in SW2012 and higher versions. This is due to the fact that starting from Solidworks 2012 the toolbox does not depend on the SWBrowser.mdb database, but stores the structure in the "ToolboxFiles.index" file.

пятница, 21 июля 2017 г.

A Journal File Could not Be Created. Another SOLIDWORKS Session Running

Do you receive a warning message "A journal file could not be created. Auto recover will not work. Another SolidWorks session running" every time you open SOLIDWORKS?
Warning –  A Journal File Could not Be Created. Auto recover will not work. Another SOLIDWORKS Session Running
Warning – Auto recover will not work.


The path to the auto-recovery log "swxJRNL.swj" is not correct. The reasons for this message can be:


  • You do not have write permission for the folder, which can be the case on a secure network in a folder which is read-only for users.
  • A journal file is already in use by another SolidWorks session, either on your machine or on another machine, which can be caused by:
  • A second session of SolidWorks trying to create a journal file in the same location as the first.
  • A session of SolidWorks terminated abnormally and the journal file not having been terminated completely.
  • More than one user double-clicked files in the same folder to start SolidWorks, which can happen in shared network folders.


      When you start SolidWorks, it creates a journal file named swxJRNL.swj in the following location:

      C:\Users\current_user\AppData\Roaming\SolidWorks\SolidWorks version.


      When you create a new journal file, if one already exists in the target folder and is not in use, SolidWorks copies the existing file to swxJRNL.BAK and then creates the new file. Thus, swxJRNL.swj represents the current session and swxJRNL.BAK represents the previous session.

      The warning message is not harmful and can be ignored unless you need the journal file for programming purposes. However, multiple sessions of SolidWorks on the same computer, especially if one session is terminated abnormally, can decrease performance.

        How to solve the issue



        • Open up the Registry Editor window by clicking on WIndows Start button and typing “regedit”
        • Navigate to "HKEY_CURRENT_USER\Software\SolidWorks\SolidWorks 2012\ExtReferences" and rename values "SolidWorks Journal Folders" to "SolidWorks Journal Folders_old" . 
        Переименование параметра через F2
        Rename

        • Close Registry Editor and run SolidWorks.
        You will notice that the error message will no longer show. Note in the Registry Editor window there is a new values created for "SolidWorks Journal Folders". If the error message does not show and the problem is solved, you can delete the "SolidWorks Journal Folders_old" values that was renamed.



        суббота, 15 июля 2017 г.

        How to fix SOLIDWORKS errors caused by Microsoft update KB3072630



        After applying the update Windows KB3072630, many people have a problem with Solidworks, namely the error "Failed to create ToolboxLibrary object". It affects 2011-2015 and Solidworks 2016 beta. 
        Symptoms
        Instability may appear in many different functional areas of the software, so the list below may not be complete. Known symptoms are:
        • Crashes when recording, playing or editing a SOLIDWORKS Macro.
        • Missing add-ins from the SOLIDWORKS add-ins list in the Tools menu.
        • Error when launching SOLIDWORKS or opening a file: “Could not load SOLIDWORKS DLL: GdtAnalysisSupport.dll”.
        • Instability when using Equations;
        • Error when launching SOLIDWORKS or SOLIDWORKS Explorer: “DWG document manager library is invalid or missing
        • Error "Failed to create ToolboxLibrary object".
        • The error “The system administrator has set policies to prevent this installation” is displayed when attempting to apply a service pack to SOLIDWORKS with administrative rights.
        • After an installation or upgrade of SOLIDWORKS, many SOLIDWORKS add-ins are missing from the add-ins list
        • SOLIDWORKS crashes when launching, with a SWVBAServer error. This also happens when recording, playing, or editing a SOLIDWORKS Macro
        • The error “Could not load SOLIDWORKS DLL: sldshellutils” error is returned when selecting “Pack and Go…” from SOLIDWORKS or SOLIDWORKS Explorer
        • SOLIDWORKS Treehouse crashes when launching.


        How to fix these errors:
        First, check if you have KB3072630 installed:
        • From the Windows Control Panel, click Windows Update.
        • In the left pane, click View update history.
        • Browse the list of installed updates to check if KB3072630 was installed. If present, it will have been installed on or after July 14 2015.
        • If KB3072630 is installed on your system please review the recommendations in the applicable scenario below.
        On the Windows Control Panel, click Windows Update. In the left pane, click View update history. Review the list of installed updates, to ensure that it was liustanovleno update KB3072630. If KB3072630 update has been installed on your system, check the directions to correct errors.
        The solution recommended by Microsoft and Solidworks Corp is as follows:
        Click Start, click Run, in the Open box, type regedit, and then click OK.
         Locate and then click the following registry subkey:
        HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\Installer
        Note: If this section does not exist, create it.
        On the Edit menu, point to New, and then click the value of DWORD. DWORD name, type RemappedElevatedProxiesPolicy and then press ENTER.
        Right-click RemappedElevatedProxiesPolicyi then click Modify.
        In the Value data box, type 1, and then click OK.
        Install the required application (Solidworks).
        After successful installation of the application, RemappedElevatedProxiesPolicy reset the DWORD value to 0, to include Security Patch 3,072,630 KB.
        The whole operation can be simplified:

        Download and unzip the file FIX_KB3072630.zip.
        Run the "RunAfterRepair_enable_KB3072630.reg"

        After adding information to the registry, run the installation of Solidworks and select "Repair the individul installation" option.

        At the end of the recovery run Solidworks "RunBeforeRepair_disable_KB3072630.reg" file

        Enjoy.

        test