Printing & Running Report Issues

Moderators: Phil Winkler, Graham Smith, Pete Tabord

Printing & Running Report Issues

Postby RossDawe » Thu Mar 24, 2016 9:43 am

Hi there,

Wondered if anyone can help us out. We are experiencing very, very, very slow actions when printing (1 hour to print out 10 pages) and running reports takes 20 minutes of which we cannot touch the computer otherwise it crashes. We are currently running Ffenics 1.6 and I think a colleague of mine (Giles) spoke to Pete not too long ago.

We’ve been migrated from XP / 2003 server to Win 7 and a 2012 server. Since then some of the print jobs and various other bits and bobs are slow. Pete suggested something about Temporary File locations. Giles was trying to find where the option was to review the temporary location Ffenics was using but couldn't seem to find it?

Regards

Ross Dawe
RossDawe
 
Posts: 4
Joined: Tue Mar 22, 2016 12:26 pm
Has thanked: 0 time
Been thanked: 0 time
 

Re: Printing & Running Report Issues

Postby Gil Fleming » Thu Mar 24, 2016 11:11 am

Hi Ross

You need to have ffenics loaded, but not your application. Either load your application then click File/Close Application, or just run a plain ffenics.exe.

From the ffenics opening screen (should have the ffenics splash screen in the centre), click File/Workstation Preferences. Bottom field is for your temporary files, which should be defined locally for each workstation. Not sure why this would slow your procedure to a crawl, unless it's an immensely complex procedure. How many records are you processing? Can you post the procedure up here?
Gil Fleming
Director
Fleming Technical Limited

You can't think about what you don't know - Mike Fidler
If you can't fight, wear a big hat - John S Fleming
The best way to have a good idea is to have lots of ideas - Linus Pauling
Gil Fleming
 
Posts: 546
Joined: Tue May 15, 2012 10:26 am
Location: Liverpool, UK
Has thanked: 1 time
Been thanked: 2 times
 

Re: Printing & Running Report Issues

Postby Graham Smith » Thu Mar 24, 2016 12:24 pm

By default, Ffenics should use the TEMP directory as defined in your Windows path which is normally C:\Windows\Temp. If you are not normally doing any maintenance on your computer, like running Windows DiskCleanup, then the temp directory can get very full which will slow down everything. But what you are describing sounds way beyond this.

There are any number of things that may have happened when you migrated and I have seen cases where a "new" server was horribly slow. One frequent cause of slow downs is an over aggressive anti-virus setup. Generally speaking, there's nothing in a Ffenics database directory that's subject to viral attack, so it's generally safe to exclude that directory from the active monitoring (or whatever it's called with whatever you are using). That's the next thing I would look at.

After that, it starts to get complicated. If they are running SQL server or any kind of mail server on your new server, that can eat up a lot of resources that could slow the server down. An underpowered processor or insufficient memory could also effect performance. But let's stick with what may be easiest to fix for now.
Graham Smith
DataSmith, Delaware
"For every expert there is an equal and opposite expert.", Arthur C. Clarke (1917 - 2008)
"X-Clacks-Overhead: GNU Terry Pratchett"
User avatar
Graham Smith
 
Posts: 2501
Joined: Fri Sep 07, 2007 11:31 am
Location: Delaware, USA
Has thanked: 0 time
Been thanked: 1 time
 

Re: Printing & Running Report Issues

Postby RossDawe » Thu Mar 24, 2016 2:55 pm

Ah – we only use the Runtime version of ffenics on the client machines so that probably rules the temp problem out. The only difference in the program is that we moved it from a 2003 server and XP clients to 2012 server and windows 7 clients.

It’s shared the same way with the same permissions.

It’s as if that new environment is preventing the program from operating as it did before on the 2003/Xp platform.
RossDawe
 
Posts: 4
Joined: Tue Mar 22, 2016 12:26 pm
Has thanked: 0 time
Been thanked: 0 time
 

Re: Printing & Running Report Issues

Postby Graham Smith » Fri Mar 25, 2016 12:43 pm

RossDawe wrote:Ah – we only use the Runtime version of ffenics on the client machines...

Look in the Ffenics runtime directory for PRISM.INI At the end of the file is the location of the Temp director. You can change this and then copy the file to all other RT machines.

BTW, I was quite certain that the default directory was the TEMP directory in the PATH, but the PRISM.INI says the default is the app directory. That comment may be something left over from older versions. Pete would have to chime in on this.

RossDawe wrote:It’s as if that new environment is preventing the program from operating as it did before on the 2003/Xp platform.

It IS a completely new environment and I have seen this happen before. This may be a locking issue - that would be my first guess.

Were ALL workstations changed to Win7 ?
Are there ANY WinXP workstations on the network?

In the same PRISM.INI file, look to see if Network type is Full locking. If it's not, then we may have some additional changes to make.

I really hate to go down this path, but if you are seeing this much of a slowdown, then it may be necessary to dig into the application itself. I don't want to jump the gun here but it's possible that there are design issues that are slowing things down but it's only with the change in setup that you are seeing the effects of it.

We may also want to look at the other settings in PRISIM.INI to see if any changes were made there. There are some settings that can make an application run faster or slower depending on the network setup. I've never had any reason to mess with them, myself.
Graham Smith
DataSmith, Delaware
"For every expert there is an equal and opposite expert.", Arthur C. Clarke (1917 - 2008)
"X-Clacks-Overhead: GNU Terry Pratchett"
User avatar
Graham Smith
 
Posts: 2501
Joined: Fri Sep 07, 2007 11:31 am
Location: Delaware, USA
Has thanked: 0 time
Been thanked: 1 time
 

Re: Printing & Running Report Issues

Postby RossDawe » Fri Apr 01, 2016 9:57 am

Hi guys,

We've taken a look at our Prism.ini and here are the contents :

[LOCKING]
#Type : String
#Default: NetBIOS computer name
;Can be used to override local user name, but generally obsolete
DEName=

#Type : Integer
#Default: 0
;Obsolete
SharedLocalDatabase=0

#Type : Integer
#Default: 5
ITimeout=5

#Type : Integer
#Default: 0
STimeout=0

#Type : Integer
#Default: 1
ConflMsg=1

#Type : Integer
#Default: 5 = Full locking
NetworkType=5

#Type : Integer
#Default: 2000
MajorTimeout=2000

#Type : Integer
#Default: 100
MinorTimeout=100

[SORTING]
#Type : Integer
#Default: 100
MemSortBuffers=100

[CBUFFERING]
#Type : Integer
#Default: 200
InitialSize=200

#Type : Integer
#Default: 200
GrowBy=200

#Type : Integer
#Default: 200
PageSize=200

#Type : Integer
#Default: 20
MaxPages=20

[SQL]
#Type : Integer
#Default: 1
Reporting=1

[DQL]
#Type : Integer
#Default: 1
FreeTuples=1

#Type : Integer
#Default: 25
ScanQuitRatio=25

#Type : Integer
#Default: 0
HideBlanks=0

#Type : Integer
#Default: 0
TreeDumpMode=0

[STATS]
#Type : Integer
#Default: 0
RunningTotals=0

#Type : Integer
#Default: 0
KeepLastTuple=0

[DEBUG32]
#Type : Integer
#Default: 0
UserIO=0

#Type : Integer
#Default: 0
MessageFile=0

#Type : Integer
#Default: 0
SoftWindows=0

#Type : Integer
#Default: 0
Debug=0

#Type : Integer
#Default: 0
Alpha=0

#Type : Integer
#Default: 0
Beta=0

[ERRORMESSAGES]
#Type : Integer
#Default: 0
Beep=1

[TRACEMESSAGES]
#Type : Integer
#Default: 0
GlobalCount=0

#Type : Integer
#Default: 0
StackSize=0

#Type : Integer
#Default: 0
OpenRels=0

#Type : Integer
#Default: 0
OpenFiles=0

[TEMPFILES]
#Type : String
#Default: is BLAMK which means use the app dir
TempDir=



The slow downs seem to revolve around report generation.

When we run the application locally from the Windows 7 computer it seems to generate those reports fine which makes us assume it's the relationship between Server & client.
RossDawe
 
Posts: 4
Joined: Tue Mar 22, 2016 12:26 pm
Has thanked: 0 time
Been thanked: 0 time
 

Re: Printing & Running Report Issues

Postby Graham Smith » Fri Apr 01, 2016 1:01 pm

I'll compare your PRISIM.INI to the defaults. It is set for Full Locking, so we can eliminate that.

As I said, I've seen something in a DFW database along the lines you are seeing. It got really bad when they switched to MS Small Business Server, which was running SQL Server and Exchange (email) - those two things ate up so much of the resources that there was little left for the database.

Also, they were running a server based Anti-Virus that monitored everything. This is the next thing I would look at. Ffenics databases have lots and lots of files that are constantly being opened and written to. An AV that is looking for malicious activity can put a real slowdown in that. If they are running an AV, see if they will exclude the database directory.

Server 2012 is actually somewhat more robust than 2003 was and if all the workstations are Win7, it should be using a more favorable locking than it was before. So there may be something else that's different - in fact there probably is. Finding that can be difficult if you aren't the one that set it up.

Reports/Procedures can involve a lot of files and locks being opened. Doing that on a local database isn't a real problem but doing it on a server, where other people are using those same files can prove problematic. Doing the reports with the database locked will help since it gets rid of the competition, but that's not practical. There are some things that might be able to improve performance but that means digging into the application - something I'm not in a position to do.
Graham Smith
DataSmith, Delaware
"For every expert there is an equal and opposite expert.", Arthur C. Clarke (1917 - 2008)
"X-Clacks-Overhead: GNU Terry Pratchett"
User avatar
Graham Smith
 
Posts: 2501
Joined: Fri Sep 07, 2007 11:31 am
Location: Delaware, USA
Has thanked: 0 time
Been thanked: 1 time
 

Re: Printing & Running Report Issues

Postby Pete Tabord » Mon Apr 04, 2016 9:13 am

The selection of a temporary directory is as follows:

1) Path set in .ini file
2) Path from TEMP environment variable
3) Path from TMP environment variable
4) Application directory.

It's possible that neither TEMP nor TMP are set in Windows 7, in which case it will switch to the application directory on the server. Which in turn will mean sorts etc. shunting data back and forth across the network instead of doing whatever they were doing locally.

There is a lot of comment on the web about this with other products failing because the temp variable in Win 7 is not set or is pointing to an invalid directory. We actually test if the directory is valid, so we don't stop working, but of course performance can be affected.

Typical registry keys to check:
Code: Select all
HKEY_LOCAL_MACHINE\System\CurrentControlSet\Control\Session Manager\Environment\TEMP

HKLM\System\CurrentControlSet\Control\Session Manager\Environment\TMP

Note from Microsoft:

The TEMP and TMP environment variables are used to designate which folders in the file system (which path) should be used by applications that require a temporary workspace. TEMP is typically used by applications, such as Microsoft Exchange. TMP is typically used by development tools, such as Microsoft Visual C++®. The path for each variable is usually relative to the security context of the application or tool.



The last sentence in the quote above is the sort of thing that worries me. Permissions on Win 7 and later and the equivalent servers have become nightmarishly complicated, at least to me.

Personally I think it would be easier to have an FFTEMP dir on each local machine and set it as the temporary file directory in the .ini file.

PS. on the Rights issue, make sure your users have write and delete rights to the temporary file directory, wherever it is.
Peter J. Tabord
Head of Development
Database Software Ltd.
ptabord@ffenics.com
Pete Tabord
 
Posts: 1881
Joined: Fri Sep 07, 2007 12:48 pm
Location: Caernarfon, Gwynedd, UK
Has thanked: 0 time
Been thanked: 3 times
 

Re: Printing & Running Report Issues

Postby Graham Smith » Mon Apr 04, 2016 12:21 pm

You can check to see if TEMP and TMP exist by opening a command prompt and typing SET. By default, I believe both show as being in Users\AppData\Local\Temp.

You can view and set these two things by way of the Control Panel / System / Advanced System Settings / Environment Variables.

The C:\WINDOWS\TEMP is cleared when you run Disk Cleanup or a utility like CCleaner (which you should do from time to time). If you create a separate TEMP directory for Ffenics, then you should setup a Task to clear it out periodically.
Graham Smith
DataSmith, Delaware
"For every expert there is an equal and opposite expert.", Arthur C. Clarke (1917 - 2008)
"X-Clacks-Overhead: GNU Terry Pratchett"
User avatar
Graham Smith
 
Posts: 2501
Joined: Fri Sep 07, 2007 11:31 am
Location: Delaware, USA
Has thanked: 0 time
Been thanked: 1 time
 

Re: Printing & Running Report Issues

Postby Pete Tabord » Tue Apr 05, 2016 9:43 am

As a matter of interest I tried that on the two machines at hand, one is Windows 10 and one is Windows 7.

On w7, both TMP and TEMP are set.
On W10 neither is set.

Is it possible that one only has access to these if logged on as administrator?
Peter J. Tabord
Head of Development
Database Software Ltd.
ptabord@ffenics.com
Pete Tabord
 
Posts: 1881
Joined: Fri Sep 07, 2007 12:48 pm
Location: Caernarfon, Gwynedd, UK
Has thanked: 0 time
Been thanked: 3 times
 

Re: Printing & Running Report Issues

Postby RossDawe » Tue Apr 05, 2016 10:08 am

Thanks for the replies, really appreciate the help.

We have changed the TEMP path to be C:\FFTEMP and added full permissions.

When the procedure that hangs is run nothing seems to appear in that FFTEMP folder.

the hang seems to happen when it's Reading Data from the table according to the
status in the bottom left of the window. when the hang eventually stops after a few minutes
it then starts printing out the records, all be it very slowly.

If we close Ffentics during the hang, the jobs it must have processed are then sent to
the printer and they start printing.

By default the TEMP/TMP locations are :

TEMP=C:\Users\%user%\AppData\Local\Temp
TMP=C:\Users\%user%\AppData\Local\Temp

We tested those as TEMP locations in the PRISM ini also but no difference unfrortunately.

We can see those being populated by things such as Photoshop etc.
RossDawe
 
Posts: 4
Joined: Tue Mar 22, 2016 12:26 pm
Has thanked: 0 time
Been thanked: 0 time
 

Re: Printing & Running Report Issues

Postby Graham Smith » Tue Apr 05, 2016 12:30 pm

Pete Tabord wrote:On W10 neither is set.

I fixed my prior post to reflect that it should default to your user directory - not sure why my two Win7 machines are set to Windows\Temp.. It's possible that this information may not display if you aren't and admin, but that doesn't sound right. Regardless, if you run the CmdPrompt as an admin then that would show it.

You can also get the information in a command prompt by typing "echo %temp%" and "echo %tmp%"
Graham Smith
DataSmith, Delaware
"For every expert there is an equal and opposite expert.", Arthur C. Clarke (1917 - 2008)
"X-Clacks-Overhead: GNU Terry Pratchett"
User avatar
Graham Smith
 
Posts: 2501
Joined: Fri Sep 07, 2007 11:31 am
Location: Delaware, USA
Has thanked: 0 time
Been thanked: 1 time
 

Re: Printing & Running Report Issues

Postby Pete Tabord » Thu Apr 07, 2016 1:38 pm

Is it just down to one slow procedure now?
Peter J. Tabord
Head of Development
Database Software Ltd.
ptabord@ffenics.com
Pete Tabord
 
Posts: 1881
Joined: Fri Sep 07, 2007 12:48 pm
Location: Caernarfon, Gwynedd, UK
Has thanked: 0 time
Been thanked: 3 times
 
 

Return to Ffenics 1.x

Who is online

Users browsing this forum: No registered users and 11 guests

cron