Sybase NNTP forums - End Of Life (EOL)

The NNTP forums from Sybase - forums.sybase.com - are now closed.

All new questions should be directed to the appropriate forum at the SAP Community Network (SCN).

Individual products have links to the respective forums on SCN, or you can go to SCN and search for your product in the search box (upper right corner) to find your specific developer center.

How to control memory usage

10 posts in General Discussion Last posting was on 2004-01-19 15:39:01.0Z
MickeyBob Posted on 2004-01-15 22:00:54.0Z
Sender: 5e85.40070d79.1804289383@sybase.com
From: MickeyBob
Newsgroups: ianywhere.public.general
Subject: How to control memory usage
X-Mailer: WebNews to Mail Gateway v1.1s
Message-ID: <40070d96.5e88.846930886@sybase.com>
NNTP-Posting-Host: 10.22.241.41
X-Original-NNTP-Posting-Host: 10.22.241.41
Date: 15 Jan 2004 14:00:54 -0800
X-Trace: forums-1-dub 1074204054 10.22.241.41 (15 Jan 2004 14:00:54 -0800)
X-Original-Trace: 15 Jan 2004 14:00:54 -0800, 10.22.241.41
Lines: 21
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub ianywhere.public.general:2313
Article PK: 4517

I have a ASA 9.0 application running on a Windows XP
Embedded PC and have a "challenge" with memory management.
The PC only has 128Mb with approximately 112Mb available.
Virtural memory is disabled and cannot be enabled. I have a
user interface application to the ASA application. After the
application and database are loaded, Task Manager shows
approximately 84Mb in use so there is approximately 28Mb of
freeboard. I have a procedure in the application that
invokes a stored procedure in the database that executes a
series of TABLE LOAD statements. During this procedure, ASA
will consume any remaining RAM and eventually crashes the
application.

Here's my question. Is there anyway to limit the amount of
memory that this stored procedure uses? I have investigated
command line options such as the -c and -ca 0 options but
these appear to have no affect.

I will appreciate any insight into this issue.

Thanks,


Piter Posted on 2004-01-16 06:08:37.0Z
From: "Piter" <piter@piter.pi>
Newsgroups: ianywhere.public.general
References: <40070d96.5e88.846930886@sybase.com>
Subject: Re: How to control memory usage
Lines: 44
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1158
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165
X-Original-NNTP-Posting-Host: vpn-uk-017.sybase.com
Message-ID: <40078215@forums-2-dub>
X-Original-Trace: 15 Jan 2004 22:17:57 -0800, vpn-uk-017.sybase.com
X-Original-NNTP-Posting-Host: forums-2-dub.sybase.com
X-Original-Trace: 15 Jan 2004 21:53:15 -0800, forums-2-dub.sybase.com
NNTP-Posting-Host: forums-master.sybase.com
X-Original-NNTP-Posting-Host: forums-master.sybase.com
Date: 15 Jan 2004 22:08:37 -0800
X-Trace: forums-1-dub 1074233317 10.22.108.75 (15 Jan 2004 22:08:37 -0800)
X-Original-Trace: 15 Jan 2004 22:08:37 -0800, forums-master.sybase.com
X-Authenticated-User: ngsysop
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub ianywhere.public.general:2315
Article PK: 4520

What about this:

-ch server option

----------------------------------------------------------------------------
----

Function
Sets a maximum cache size, as a limit to automatic cache growth.

Syntax
{ dbsrv9 | dbeng9 } -ch {
integer |
integerG |
integerK |
integerM |
integerP } ...

<MickeyBob> wrote in message news:40070d96.5e88.846930886@sybase.com...
> I have a ASA 9.0 application running on a Windows XP
> Embedded PC and have a "challenge" with memory management.
> The PC only has 128Mb with approximately 112Mb available.
> Virtural memory is disabled and cannot be enabled. I have a
> user interface application to the ASA application. After the
> application and database are loaded, Task Manager shows
> approximately 84Mb in use so there is approximately 28Mb of
> freeboard. I have a procedure in the application that
> invokes a stored procedure in the database that executes a
> series of TABLE LOAD statements. During this procedure, ASA
> will consume any remaining RAM and eventually crashes the
> application.
>
> Here's my question. Is there anyway to limit the amount of
> memory that this stored procedure uses? I have investigated
> command line options such as the -c and -ca 0 options but
> these appear to have no affect.
>
> I will appreciate any insight into this issue.
>
> Thanks,


MickeyBob Posted on 2004-01-16 13:03:46.0Z
Sender: 71b1.4007e25d.1804289383@sybase.com
From: MickeyBob
Newsgroups: ianywhere.public.general
Subject: Re: How to control memory usage
X-Mailer: WebNews to Mail Gateway v1.1s
Message-ID: <4007e363.71b5.846930886@sybase.com>
References: <40070d96.5e88.846930886@sybase.com><40078215@forums-2-dub>
X-Original-NNTP-Posting-Host: 10.22.241.42
X-Original-Trace: 16 Jan 2004 05:13:07 -0800, 10.22.241.42
Lines: 53
X-Original-NNTP-Posting-Host: forums-2-dub.sybase.com
X-Original-Trace: 16 Jan 2004 04:48:23 -0800, forums-2-dub.sybase.com
NNTP-Posting-Host: forums-master.sybase.com
X-Original-NNTP-Posting-Host: forums-master.sybase.com
Date: 16 Jan 2004 05:03:46 -0800
X-Trace: forums-1-dub 1074258226 10.22.108.75 (16 Jan 2004 05:03:46 -0800)
X-Original-Trace: 16 Jan 2004 05:03:46 -0800, forums-master.sybase.com
X-Authenticated-User: ngsysop
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub ianywhere.public.general:2319
Article PK: 4523

Unfortunately, I have tried the -ch option. Here's the
command I currently use to start the database:

"C:\Program Files\Sybase\SQL Anywhere 9\win32\dbeng9.exe"
-qs -ch 500k -ca 0 -cs -n Xstretch -xs HTTP
"C:\DATA\xstretch.db"

> What about this:
>
> -ch server option
>
> ----------------------------------------------------------
> ------------------ ----
>
> Function
> Sets a maximum cache size, as a limit to automatic cache
> growth.
>
> Syntax
> { dbsrv9 | dbeng9 } -ch {
> integer |
> integerG |
> integerK |
> integerM |
> integerP } ...
>
>
>
> <MickeyBob> wrote in message
> > news:40070d96.5e88.846930886@sybase.com... I have a ASA
> > 9.0 application running on a Windows XP Embedded PC and
> > have a "challenge" with memory management. The PC only
> > has 128Mb with approximately 112Mb available. Virtural
> > memory is disabled and cannot be enabled. I have a user
> > interface application to the ASA application. After the
> > application and database are loaded, Task Manager shows
> approximately 84Mb in use so there is approximately 28Mb
> > of freeboard. I have a procedure in the application that
> > invokes a stored procedure in the database that executes
> > a series of TABLE LOAD statements. During this procedure
> > , ASA will consume any remaining RAM and eventually
> > crashes the application.
> >
> > Here's my question. Is there anyway to limit the amount
> > of memory that this stored procedure uses? I have
> > investigated command line options such as the -c and -ca
> > 0 options but these appear to have no affect.
> >
> > I will appreciate any insight into this issue.
> >
> > Thanks,
>
>


Stephen Rice Posted on 2004-01-16 14:06:53.0Z
Newsgroups: ianywhere.public.general
Subject: Re: How to control memory usage
From: Stephen Rice <srice_nospam@ianywhere.com>
References: <4007e363.71b5.846930886@sybase.com>
Organization: iAnywhere Solutions
Message-ID: <Xns94725A1F1CD65sricenospamianywhere@10.22.241.106>
User-Agent: Xnews/5.04.25
NNTP-Posting-Host: srice-pc.sybase.com
X-Original-NNTP-Posting-Host: srice-pc.sybase.com
Date: 16 Jan 2004 06:06:53 -0800
X-Trace: forums-1-dub 1074262013 172.31.141.106 (16 Jan 2004 06:06:53 -0800)
X-Original-Trace: 16 Jan 2004 06:06:53 -0800, srice-pc.sybase.com
Lines: 32
X-Authenticated-User: techsupp
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub ianywhere.public.general:2321
Article PK: 4525


MickeyBob wrote in news:4007e363.71b5.846930886@sybase.com:

> Unfortunately, I have tried the -ch option. Here's the
> command I currently use to start the database:
>
> "C:\Program Files\Sybase\SQL Anywhere 9\win32\dbeng9.exe"
> -qs -ch 500k -ca 0 -cs -n Xstretch -xs HTTP
> "C:\DATA\xstretch.db"
>

Weird...some thoughts

can you add a -o <filename> and post the contents of the output file.
I'm interested in any logging of changes to cache (since if -ch -ca are
working then there shouldn't be any). Also what, if any message gets
written when things start crashing

Also, is it possible that your disk is filling? with such a tiny cache
I would expect your pagefile and database temp file to get busy and
possible large

/steve

--
Stephen Rice
Technical Services Manager
iAnywhere Solutions

- Please Post-
Whitepapers, TechDocs, and bug fixes are all available through the
iAnywhere
Developer Community at www.ianywhere.com/developer


MickeyBob Posted on 2004-01-16 17:10:07.0Z
Sender: 75ab.40081c5f.1804289383@sybase.com
From: MickeyBob
Newsgroups: ianywhere.public.general
Subject: Re: How to control memory usage
X-Mailer: WebNews to Mail Gateway v1.1s
Message-ID: <40081d21.75c3.846930886@sybase.com>
References: <4007e363.71b5.846930886@sybase.com><Xns94725A1F1CD65sricenospamianywhere@10.22.241.106>
MIME-Version: 1.0
Content-Type: text/plain; charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable
X-Original-NNTP-Posting-Host: 10.22.241.42
X-Original-Trace: 16 Jan 2004 09:19:29 -0800, 10.22.241.42
Lines: 96
X-Original-NNTP-Posting-Host: forums-2-dub.sybase.com
X-Original-Trace: 16 Jan 2004 08:54:43 -0800, forums-2-dub.sybase.com
NNTP-Posting-Host: forums-master.sybase.com
X-Original-NNTP-Posting-Host: forums-master.sybase.com
Date: 16 Jan 2004 09:10:07 -0800
X-Trace: forums-1-dub 1074273007 10.22.108.75 (16 Jan 2004 09:10:07 -0800)
X-Original-Trace: 16 Jan 2004 09:10:07 -0800, forums-master.sybase.com
X-Authenticated-User: ngsysop
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub ianywhere.public.general:2323
Article PK: 4527

Here's the output log...

I. 01/16 11:33:55. Adaptive Server Anywhere Database Engine
Version 9.0.0.1108
I. 01/16 11:33:55.
I. 01/16 11:33:55. Copyright © 1989-2003 Sybase, Inc.
I. 01/16 11:33:55. Portions Copyright © 2002-2003,
iAnywhere Solutions, Inc.
I. 01/16 11:33:55. All rights reserved. All unpublished
rights reserved.
I. 01/16 11:33:55.
I. 01/16 11:33:56. This software contains confidential and
trade secret information of
I. 01/16 11:33:56. iAnywhere Solutions, Inc.
I. 01/16 11:33:56. Use, duplication or disclosure of the
software and documentation
I. 01/16 11:33:56. by the U.S. Government is subject to
restrictions set forth in a license
I. 01/16 11:33:56. agreement between the Government and
iAnywhere Solutions, Inc. or
I. 01/16 11:33:56. other written agreement specifying the
Government's rights to use the
I. 01/16 11:33:56. software and any applicable FAR
provisions, for example, FAR 52.227-19.
I. 01/16 11:33:56.
I. 01/16 11:33:56. iAnywhere Solutions, Inc., One Sybase
Drive, Dublin, CA 94568, USA
I. 01/16 11:33:56. Developer edition, not licensed for
deployment
I. 01/16 11:33:56.
I. 01/16 11:33:56. 500K of memory used for caching
I. 01/16 11:33:56. Minimum cache size: 500K, maximum cache
size: 500K
I. 01/16 11:33:56. Using a maximum page size of 2048 bytes
I. 01/16 11:33:56. Starting database "XStretch" (C:\Program
Files\XStretchXPe\Database\XStretch.db) at Fri Jan 16 2004
11:33
I. 01/16 11:33:56. Note: Database file "C:\Program
Files\XStretchXPe\Database\XStretch.db" consists of 2105
disk fragments
I. 01/16 11:33:58. Transaction log: XStretch.log
I. 01/16 11:33:58. Starting checkpoint of "XStretch"
(XStretch.db) at Fri Jan 16 2004 11:33
I. 01/16 11:33:58. Finished checkpoint of "XStretch"
(XStretch.db) at Fri Jan 16 2004 11:33
I. 01/16 11:33:58. Database "XStretch" (XStretch.db) started
at Fri Jan 16 2004 11:33
I. 01/16 11:33:58. Note: Server cache size is too small for
database "XStretch"
I. 01/16 11:33:58. Database server started at Fri Jan 16
2004 11:33
I. 01/16 11:33:58. Trying to start SharedMemory link ...
I. 01/16 11:33:58. SharedMemory link started
successfully
I. 01/16 11:33:58. Trying to start NamedPipes link ...
I. 01/16 11:33:58. NamedPipes link started successfully
I. 01/16 11:33:59. Trying to start TDS (TCPIP) link ...
I. 01/16 11:33:59. Starting on port 2638
I. 01/16 11:33:59. TDS (TCPIP) link started successfully
I. 01/16 11:33:59. HTTP listener starting on port 80
I. 01/16 11:33:59. Now accepting requests
I. 01/16 11:35:13. Note: Duplicate index
"ndxPlt_sys_employee-PK" for table "Plt_sys_employee" in
database "XStretch"
I. 01/16 11:35:13. Note: Duplicate index
"ndxCSM_user_profile-PK" for table "CSM_user_profile" in
database "XStretch"
I. 01/16 11:35:13. Note: Duplicate index
"ndxSap_Employee-PK" for table "Sap_employee" in database
"XStretch"
I. 01/16 11:35:29. Note: Duplicate index
"ndxCSM_Standards-PK" for table "CSM_Standards" in database
"XStretch"
I. 01/16 11:35:46. Starting checkpoint of "XStretch"
(XStretch.db) at Fri Jan 16 2004 11:35
I. 01/16 11:35:46. Finished checkpoint of "XStretch"
(XStretch.db) at Fri Jan 16 2004 11:35
I. 01/16 11:45:12. Disconnecting shared memory client,
process id not found
I. 01/16 11:45:12. Starting checkpoint of "XStretch"
(XStretch.db) at Fri Jan 16 2004 11:45
I. 01/16 11:45:14. Finished checkpoint of "XStretch"
(XStretch.db) at Fri Jan 16 2004 11:45
I. 01/16 11:45:30. Starting checkpoint of "XStretch"
(XStretch.db) at Fri Jan 16 2004 11:45
I. 01/16 11:45:31. Finished checkpoint of "XStretch"
(XStretch.db) at Fri Jan 16 2004 11:45
I. 01/16 11:45:31. Database server stopped at Fri Jan 16
2004 11:45


Re: virtual memory. This particular PC is running XP
Embedded and has the page file disable and there is no way
to enable it without a completely new OS image.

Thanks for the assistance.


Reg Domaratzki Posted on 2004-01-16 18:15:59.0Z
From: "Reg Domaratzki" <Spam_bad_rdomarat@ianywhere.com>
Newsgroups: ianywhere.public.general
References: <4007e363.71b5.846930886@sybase.com><Xns94725A1F1CD65sricenospamianywhere@10.22.241.106> <40081d21.75c3.846930886@sybase.com>
Subject: Re: How to control memory usage
Lines: 113
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1158
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165
NNTP-Posting-Host: rdomarat-pc.sybase.com
X-Original-NNTP-Posting-Host: rdomarat-pc.sybase.com
Message-ID: <40082a5f@forums-1-dub>
Date: 16 Jan 2004 10:15:59 -0800
X-Trace: forums-1-dub 1074276959 172.31.143.163 (16 Jan 2004 10:15:59 -0800)
X-Original-Trace: 16 Jan 2004 10:15:59 -0800, rdomarat-pc.sybase.com
X-Authenticated-User: techsupp
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub ianywhere.public.general:2324
Article PK: 4529

500Kb of memory is not enough memory to load the code for the database
engine, what happens if you use a more reasonable value like 8M (8 Mb) or
16M after the -ch switch?

--
Reg Domaratzki, Sybase iAnywhere Solutions
Sybase Certified Professional - Sybase ASA Developer Version 8
Please reply only to the newsgroup

iAnywhere Developer Community : http://www.ianywhere.com/developer
ASA Patches and EBFs : http://downloads.sybase.com/swx/sdmain.stm
-> Choose SQL Anywhere Studio
-> Set "Platform Preview" and "Time Frame" to ALL

<MickeyBob> wrote in message news:40081d21.75c3.846930886@sybase.com...
Here's the output log...

I. 01/16 11:33:55. Adaptive Server Anywhere Database Engine
Version 9.0.0.1108
I. 01/16 11:33:55.
I. 01/16 11:33:55. Copyright © 1989-2003 Sybase, Inc.
I. 01/16 11:33:55. Portions Copyright © 2002-2003,
iAnywhere Solutions, Inc.
I. 01/16 11:33:55. All rights reserved. All unpublished
rights reserved.
I. 01/16 11:33:55.
I. 01/16 11:33:56. This software contains confidential and
trade secret information of
I. 01/16 11:33:56. iAnywhere Solutions, Inc.
I. 01/16 11:33:56. Use, duplication or disclosure of the
software and documentation
I. 01/16 11:33:56. by the U.S. Government is subject to
restrictions set forth in a license
I. 01/16 11:33:56. agreement between the Government and
iAnywhere Solutions, Inc. or
I. 01/16 11:33:56. other written agreement specifying the
Government's rights to use the
I. 01/16 11:33:56. software and any applicable FAR
provisions, for example, FAR 52.227-19.
I. 01/16 11:33:56.
I. 01/16 11:33:56. iAnywhere Solutions, Inc., One Sybase
Drive, Dublin, CA 94568, USA
I. 01/16 11:33:56. Developer edition, not licensed for
deployment
I. 01/16 11:33:56.
I. 01/16 11:33:56. 500K of memory used for caching
I. 01/16 11:33:56. Minimum cache size: 500K, maximum cache
size: 500K
I. 01/16 11:33:56. Using a maximum page size of 2048 bytes
I. 01/16 11:33:56. Starting database "XStretch" (C:\Program
Files\XStretchXPe\Database\XStretch.db) at Fri Jan 16 2004
11:33
I. 01/16 11:33:56. Note: Database file "C:\Program
Files\XStretchXPe\Database\XStretch.db" consists of 2105
disk fragments
I. 01/16 11:33:58. Transaction log: XStretch.log
I. 01/16 11:33:58. Starting checkpoint of "XStretch"
(XStretch.db) at Fri Jan 16 2004 11:33
I. 01/16 11:33:58. Finished checkpoint of "XStretch"
(XStretch.db) at Fri Jan 16 2004 11:33
I. 01/16 11:33:58. Database "XStretch" (XStretch.db) started
at Fri Jan 16 2004 11:33
I. 01/16 11:33:58. Note: Server cache size is too small for
database "XStretch"
I. 01/16 11:33:58. Database server started at Fri Jan 16
2004 11:33
I. 01/16 11:33:58. Trying to start SharedMemory link ...
I. 01/16 11:33:58. SharedMemory link started
successfully
I. 01/16 11:33:58. Trying to start NamedPipes link ...
I. 01/16 11:33:58. NamedPipes link started successfully
I. 01/16 11:33:59. Trying to start TDS (TCPIP) link ...
I. 01/16 11:33:59. Starting on port 2638
I. 01/16 11:33:59. TDS (TCPIP) link started successfully
I. 01/16 11:33:59. HTTP listener starting on port 80
I. 01/16 11:33:59. Now accepting requests
I. 01/16 11:35:13. Note: Duplicate index
"ndxPlt_sys_employee-PK" for table "Plt_sys_employee" in
database "XStretch"
I. 01/16 11:35:13. Note: Duplicate index
"ndxCSM_user_profile-PK" for table "CSM_user_profile" in
database "XStretch"
I. 01/16 11:35:13. Note: Duplicate index
"ndxSap_Employee-PK" for table "Sap_employee" in database
"XStretch"
I. 01/16 11:35:29. Note: Duplicate index
"ndxCSM_Standards-PK" for table "CSM_Standards" in database
"XStretch"
I. 01/16 11:35:46. Starting checkpoint of "XStretch"
(XStretch.db) at Fri Jan 16 2004 11:35
I. 01/16 11:35:46. Finished checkpoint of "XStretch"
(XStretch.db) at Fri Jan 16 2004 11:35
I. 01/16 11:45:12. Disconnecting shared memory client,
process id not found
I. 01/16 11:45:12. Starting checkpoint of "XStretch"
(XStretch.db) at Fri Jan 16 2004 11:45
I. 01/16 11:45:14. Finished checkpoint of "XStretch"
(XStretch.db) at Fri Jan 16 2004 11:45
I. 01/16 11:45:30. Starting checkpoint of "XStretch"
(XStretch.db) at Fri Jan 16 2004 11:45
I. 01/16 11:45:31. Finished checkpoint of "XStretch"
(XStretch.db) at Fri Jan 16 2004 11:45
I. 01/16 11:45:31. Database server stopped at Fri Jan 16
2004 11:45


Re: virtual memory. This particular PC is running XP
Embedded and has the page file disable and there is no way
to enable it without a completely new OS image.

Thanks for the assistance.


Robert Waywell Posted on 2004-01-16 20:49:00.0Z
From: "Robert Waywell" <nospam_rwaywell@ianywhere.com>
Newsgroups: ianywhere.public.general
References: <4007e363.71b5.846930886@sybase.com><Xns94725A1F1CD65sricenospamianywhere@10.22.241.106> <40081d21.75c3.846930886@sybase.com>
Subject: Re: How to control memory usage
Lines: 127
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2600.0000
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2600.0000
NNTP-Posting-Host: rwaywell-pc.sybase.com
X-Original-NNTP-Posting-Host: rwaywell-pc.sybase.com
Message-ID: <40084e3c$1@forums-1-dub>
Date: 16 Jan 2004 12:49:00 -0800
X-Trace: forums-1-dub 1074286140 172.31.142.236 (16 Jan 2004 12:49:00 -0800)
X-Original-Trace: 16 Jan 2004 12:49:00 -0800, rwaywell-pc.sybase.com
X-Authenticated-User: techsupp
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub ianywhere.public.general:2326
Article PK: 4531

In addition to Reg's point ...

This output shows the server being started up and shut down cleanly. It does
not show any problem with the server 'crashing'. In order to be useful you
would need to generate the -o output while actually running the procedure
that 'crashes' the server.

--
-----------------------------------------------
Robert Waywell
Sybase Adaptive Server Anywhere Developer - Version 8
Sybase Certified Professional

Sybase's iAnywhere Solutions

Please respond ONLY to newsgroup

EBF's and Patches: http://downloads.sybase.com
choose SQL Anywhere Studio >> change 'time frame' to all

To Submit Bug Reports: http://case-express.sybase.com/cx/cx.stm

SQL Anywhere Studio Supported Platforms and Support Status
http://my.sybase.com/detail?id=1002288

Whitepapers, TechDocs, and bug fixes are all available through the iAnywhere
Developer Community at www.ianywhere.com/developer

<MickeyBob> wrote in message news:40081d21.75c3.846930886@sybase.com...
Here's the output log...

I. 01/16 11:33:55. Adaptive Server Anywhere Database Engine
Version 9.0.0.1108
I. 01/16 11:33:55.
I. 01/16 11:33:55. Copyright © 1989-2003 Sybase, Inc.
I. 01/16 11:33:55. Portions Copyright © 2002-2003,
iAnywhere Solutions, Inc.
I. 01/16 11:33:55. All rights reserved. All unpublished
rights reserved.
I. 01/16 11:33:55.
I. 01/16 11:33:56. This software contains confidential and
trade secret information of
I. 01/16 11:33:56. iAnywhere Solutions, Inc.
I. 01/16 11:33:56. Use, duplication or disclosure of the
software and documentation
I. 01/16 11:33:56. by the U.S. Government is subject to
restrictions set forth in a license
I. 01/16 11:33:56. agreement between the Government and
iAnywhere Solutions, Inc. or
I. 01/16 11:33:56. other written agreement specifying the
Government's rights to use the
I. 01/16 11:33:56. software and any applicable FAR
provisions, for example, FAR 52.227-19.
I. 01/16 11:33:56.
I. 01/16 11:33:56. iAnywhere Solutions, Inc., One Sybase
Drive, Dublin, CA 94568, USA
I. 01/16 11:33:56. Developer edition, not licensed for
deployment
I. 01/16 11:33:56.
I. 01/16 11:33:56. 500K of memory used for caching
I. 01/16 11:33:56. Minimum cache size: 500K, maximum cache
size: 500K
I. 01/16 11:33:56. Using a maximum page size of 2048 bytes
I. 01/16 11:33:56. Starting database "XStretch" (C:\Program
Files\XStretchXPe\Database\XStretch.db) at Fri Jan 16 2004
11:33
I. 01/16 11:33:56. Note: Database file "C:\Program
Files\XStretchXPe\Database\XStretch.db" consists of 2105
disk fragments
I. 01/16 11:33:58. Transaction log: XStretch.log
I. 01/16 11:33:58. Starting checkpoint of "XStretch"
(XStretch.db) at Fri Jan 16 2004 11:33
I. 01/16 11:33:58. Finished checkpoint of "XStretch"
(XStretch.db) at Fri Jan 16 2004 11:33
I. 01/16 11:33:58. Database "XStretch" (XStretch.db) started
at Fri Jan 16 2004 11:33
I. 01/16 11:33:58. Note: Server cache size is too small for
database "XStretch"
I. 01/16 11:33:58. Database server started at Fri Jan 16
2004 11:33
I. 01/16 11:33:58. Trying to start SharedMemory link ...
I. 01/16 11:33:58. SharedMemory link started
successfully
I. 01/16 11:33:58. Trying to start NamedPipes link ...
I. 01/16 11:33:58. NamedPipes link started successfully
I. 01/16 11:33:59. Trying to start TDS (TCPIP) link ...
I. 01/16 11:33:59. Starting on port 2638
I. 01/16 11:33:59. TDS (TCPIP) link started successfully
I. 01/16 11:33:59. HTTP listener starting on port 80
I. 01/16 11:33:59. Now accepting requests
I. 01/16 11:35:13. Note: Duplicate index
"ndxPlt_sys_employee-PK" for table "Plt_sys_employee" in
database "XStretch"
I. 01/16 11:35:13. Note: Duplicate index
"ndxCSM_user_profile-PK" for table "CSM_user_profile" in
database "XStretch"
I. 01/16 11:35:13. Note: Duplicate index
"ndxSap_Employee-PK" for table "Sap_employee" in database
"XStretch"
I. 01/16 11:35:29. Note: Duplicate index
"ndxCSM_Standards-PK" for table "CSM_Standards" in database
"XStretch"
I. 01/16 11:35:46. Starting checkpoint of "XStretch"
(XStretch.db) at Fri Jan 16 2004 11:35
I. 01/16 11:35:46. Finished checkpoint of "XStretch"
(XStretch.db) at Fri Jan 16 2004 11:35
I. 01/16 11:45:12. Disconnecting shared memory client,
process id not found
I. 01/16 11:45:12. Starting checkpoint of "XStretch"
(XStretch.db) at Fri Jan 16 2004 11:45
I. 01/16 11:45:14. Finished checkpoint of "XStretch"
(XStretch.db) at Fri Jan 16 2004 11:45
I. 01/16 11:45:30. Starting checkpoint of "XStretch"
(XStretch.db) at Fri Jan 16 2004 11:45
I. 01/16 11:45:31. Finished checkpoint of "XStretch"
(XStretch.db) at Fri Jan 16 2004 11:45
I. 01/16 11:45:31. Database server stopped at Fri Jan 16
2004 11:45


Re: virtual memory. This particular PC is running XP
Embedded and has the page file disable and there is no way
to enable it without a completely new OS image.

Thanks for the assistance.


MickeyBob Posted on 2004-01-18 14:49:15.0Z
Sender: 1f14.400a9812.1804289383@sybase.com
From: MickeyBob
Newsgroups: ianywhere.public.general
Subject: Re: How to control memory usage
X-Mailer: WebNews to Mail Gateway v1.1s
Message-ID: <400a9ceb.1f2d.846930886@sybase.com>
References: <4007e363.71b5.846930886@sybase.com><Xns94725A1F1CD65sricenospamianywhere@10.22.241.106> <40081d21.75c3.846930886@sybase.com><40084e3c$1@forums-1-dub>
NNTP-Posting-Host: 10.22.241.41
X-Original-NNTP-Posting-Host: 10.22.241.41
Date: 18 Jan 2004 06:49:15 -0800
X-Trace: forums-1-dub 1074437355 10.22.241.41 (18 Jan 2004 06:49:15 -0800)
X-Original-Trace: 18 Jan 2004 06:49:15 -0800, 10.22.241.41
Lines: 50
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub ianywhere.public.general:2336
Article PK: 4541

First, a bit of clarification. The server doesn't crash but
my .NET application does.

I spoke with Terry Hugill in Tech support and he suggested I
invoke the stored procedure from Sybase Central outside of
my .NET application but with the application loaded. I
connected to the server from Sybase Central and Interactive
SQL and then invoked the stored procedure. Sure enough, the
memory wasn't consumed.

I then dug in a little deeper into my .NET code. I'm
essentially declaring a ASA command object to execute my
stored procedure. I placed MessageBox commands on either
call to the command object's Execute method as follows:

MessageBox.Show("Start Stored Procedure execution");
int retval = cmd.ExecuteNonQuery();
MessageBox.Show("End Stored Procedure execution");

By placing the MessageBoxes on either side of the
cmd.ExecuteNonQuery(), I know when this particular call is
made. I run my application with task manager visible so I
can watch the memory usage. It is ONLY while the
ExecuteNonQuery method is executing that the memory is
consumed. It also appears that the longer the stored
procedure takes, the more memory consumed. My first
inclination is to say there is a memory leak in the ASA
command object's ExecuteNonQuery method. However, I've run
this same application (no code changes) on my personal
computer with performance monitor active and tracking memory
usage. I've repeatedly executed the stored procedure from a
single instance of my application and after some initial
allocation of memory the first time it's invoked, the memory
usage is stable and does not seem to increase. This would
tend to indicate that there is something unique with running
my application on the particular PC where I'm experiencing
the problem. (It's running Windows XPe).

I've since come up with a work around that works on my PC
but I have yet to implement and test it on the other. It
spawns a new process and runs dbisql in a hidden window. I
construct the call to the stored procedure and pass it as
arguments to dbisql. I think that will avoid the problem
with the "ExecuteNonQuery memory leak". This doesn't
identify and/or correct the problem but it let's me get on
with my life.

Any thoughts?

Thanks


Robert Waywell Posted on 2004-01-19 15:39:01.0Z
From: "Robert Waywell" <nospam_rwaywell@ianywhere.com>
Newsgroups: ianywhere.public.general
References: <4007e363.71b5.846930886@sybase.com><Xns94725A1F1CD65sricenospamianywhere@10.22.241.106> <40081d21.75c3.846930886@sybase.com><40084e3c$1@forums-1-dub> <400a9ceb.1f2d.846930886@sybase.com>
Subject: Re: How to control memory usage
Lines: 77
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2600.0000
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2600.0000
NNTP-Posting-Host: rwaywell-pc.sybase.com
X-Original-NNTP-Posting-Host: rwaywell-pc.sybase.com
Message-ID: <400bfa15$1@forums-1-dub>
Date: 19 Jan 2004 07:39:01 -0800
X-Trace: forums-1-dub 1074526741 172.31.142.236 (19 Jan 2004 07:39:01 -0800)
X-Original-Trace: 19 Jan 2004 07:39:01 -0800, rwaywell-pc.sybase.com
X-Authenticated-User: techsupp
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub ianywhere.public.general:2345
Article PK: 4550

Sounds like you have reproduced a behaviour that you should submit to Tech
Support.

--
-----------------------------------------------
Robert Waywell
Sybase Adaptive Server Anywhere Developer - Version 8
Sybase Certified Professional

Sybase's iAnywhere Solutions

Please respond ONLY to newsgroup

EBF's and Patches: http://downloads.sybase.com
choose SQL Anywhere Studio >> change 'time frame' to all

To Submit Bug Reports: http://case-express.sybase.com/cx/cx.stm

SQL Anywhere Studio Supported Platforms and Support Status
http://my.sybase.com/detail?id=1002288

Whitepapers, TechDocs, and bug fixes are all available through the iAnywhere
Developer Community at www.ianywhere.com/developer

<MickeyBob> wrote in message news:400a9ceb.1f2d.846930886@sybase.com...
> First, a bit of clarification. The server doesn't crash but
> my .NET application does.
>
> I spoke with Terry Hugill in Tech support and he suggested I
> invoke the stored procedure from Sybase Central outside of
> my .NET application but with the application loaded. I
> connected to the server from Sybase Central and Interactive
> SQL and then invoked the stored procedure. Sure enough, the
> memory wasn't consumed.
>
> I then dug in a little deeper into my .NET code. I'm
> essentially declaring a ASA command object to execute my
> stored procedure. I placed MessageBox commands on either
> call to the command object's Execute method as follows:
>
> MessageBox.Show("Start Stored Procedure execution");
> int retval = cmd.ExecuteNonQuery();
> MessageBox.Show("End Stored Procedure execution");
>
> By placing the MessageBoxes on either side of the
> cmd.ExecuteNonQuery(), I know when this particular call is
> made. I run my application with task manager visible so I
> can watch the memory usage. It is ONLY while the
> ExecuteNonQuery method is executing that the memory is
> consumed. It also appears that the longer the stored
> procedure takes, the more memory consumed. My first
> inclination is to say there is a memory leak in the ASA
> command object's ExecuteNonQuery method. However, I've run
> this same application (no code changes) on my personal
> computer with performance monitor active and tracking memory
> usage. I've repeatedly executed the stored procedure from a
> single instance of my application and after some initial
> allocation of memory the first time it's invoked, the memory
> usage is stable and does not seem to increase. This would
> tend to indicate that there is something unique with running
> my application on the particular PC where I'm experiencing
> the problem. (It's running Windows XPe).
>
> I've since come up with a work around that works on my PC
> but I have yet to implement and test it on the other. It
> spawns a new process and runs dbisql in a hidden window. I
> construct the call to the stored procedure and pass it as
> arguments to dbisql. I think that will avoid the problem
> with the "ExecuteNonQuery memory leak". This doesn't
> identify and/or correct the problem but it let's me get on
> with my life.
>
> Any thoughts?
>
> Thanks


Piter Posted on 2004-01-19 11:39:52.0Z
From: "Piter" <piter@piter.pi>
Newsgroups: ianywhere.public.general
References: <4007e363.71b5.846930886@sybase.com><Xns94725A1F1CD65sricenospamianywhere@10.22.241.106> <40081d21.75c3.846930886@sybase.com>
Subject: Re: How to control memory usage
Lines: 110
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1158
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165
X-Original-NNTP-Posting-Host: vpn-uk-014.sybase.com
Message-ID: <400bc443@forums-2-dub>
X-Original-Trace: 19 Jan 2004 03:49:23 -0800, vpn-uk-014.sybase.com
X-Original-NNTP-Posting-Host: forums-2-dub.sybase.com
X-Original-Trace: 19 Jan 2004 03:24:12 -0800, forums-2-dub.sybase.com
NNTP-Posting-Host: forums-master.sybase.com
X-Original-NNTP-Posting-Host: forums-master.sybase.com
Date: 19 Jan 2004 03:39:52 -0800
X-Trace: forums-1-dub 1074512392 10.22.108.75 (19 Jan 2004 03:39:52 -0800)
X-Original-Trace: 19 Jan 2004 03:39:52 -0800, forums-master.sybase.com
X-Authenticated-User: ngsysop
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub ianywhere.public.general:2342
Article PK: 4547

Will it be the same with 9.0.0.1252? (latest build)?

Also, what looks strange for me - your original topic was about server
crash - there is no crash in your log.

IMHO, start your server with limits at least 2Mb (better 8M)

And use only needed communication parameters i.e. - x tcpip if you are using
tcp/ip or only shared mem link - if all application+server on one machine.

Pit
<MickeyBob> wrote in message news:40081d21.75c3.846930886@sybase.com...
Here's the output log...

I. 01/16 11:33:55. Adaptive Server Anywhere Database Engine
Version 9.0.0.1108
I. 01/16 11:33:55.
I. 01/16 11:33:55. Copyright © 1989-2003 Sybase, Inc.
I. 01/16 11:33:55. Portions Copyright © 2002-2003,
iAnywhere Solutions, Inc.
I. 01/16 11:33:55. All rights reserved. All unpublished
rights reserved.
I. 01/16 11:33:55.
I. 01/16 11:33:56. This software contains confidential and
trade secret information of
I. 01/16 11:33:56. iAnywhere Solutions, Inc.
I. 01/16 11:33:56. Use, duplication or disclosure of the
software and documentation
I. 01/16 11:33:56. by the U.S. Government is subject to
restrictions set forth in a license
I. 01/16 11:33:56. agreement between the Government and
iAnywhere Solutions, Inc. or
I. 01/16 11:33:56. other written agreement specifying the
Government's rights to use the
I. 01/16 11:33:56. software and any applicable FAR
provisions, for example, FAR 52.227-19.
I. 01/16 11:33:56.
I. 01/16 11:33:56. iAnywhere Solutions, Inc., One Sybase
Drive, Dublin, CA 94568, USA
I. 01/16 11:33:56. Developer edition, not licensed for
deployment
I. 01/16 11:33:56.
I. 01/16 11:33:56. 500K of memory used for caching
I. 01/16 11:33:56. Minimum cache size: 500K, maximum cache
size: 500K
I. 01/16 11:33:56. Using a maximum page size of 2048 bytes
I. 01/16 11:33:56. Starting database "XStretch" (C:\Program
Files\XStretchXPe\Database\XStretch.db) at Fri Jan 16 2004
11:33
I. 01/16 11:33:56. Note: Database file "C:\Program
Files\XStretchXPe\Database\XStretch.db" consists of 2105
disk fragments
I. 01/16 11:33:58. Transaction log: XStretch.log
I. 01/16 11:33:58. Starting checkpoint of "XStretch"
(XStretch.db) at Fri Jan 16 2004 11:33
I. 01/16 11:33:58. Finished checkpoint of "XStretch"
(XStretch.db) at Fri Jan 16 2004 11:33
I. 01/16 11:33:58. Database "XStretch" (XStretch.db) started
at Fri Jan 16 2004 11:33
I. 01/16 11:33:58. Note: Server cache size is too small for
database "XStretch"
I. 01/16 11:33:58. Database server started at Fri Jan 16
2004 11:33
I. 01/16 11:33:58. Trying to start SharedMemory link ...
I. 01/16 11:33:58. SharedMemory link started
successfully
I. 01/16 11:33:58. Trying to start NamedPipes link ...
I. 01/16 11:33:58. NamedPipes link started successfully
I. 01/16 11:33:59. Trying to start TDS (TCPIP) link ...
I. 01/16 11:33:59. Starting on port 2638
I. 01/16 11:33:59. TDS (TCPIP) link started successfully
I. 01/16 11:33:59. HTTP listener starting on port 80
I. 01/16 11:33:59. Now accepting requests
I. 01/16 11:35:13. Note: Duplicate index
"ndxPlt_sys_employee-PK" for table "Plt_sys_employee" in
database "XStretch"
I. 01/16 11:35:13. Note: Duplicate index
"ndxCSM_user_profile-PK" for table "CSM_user_profile" in
database "XStretch"
I. 01/16 11:35:13. Note: Duplicate index
"ndxSap_Employee-PK" for table "Sap_employee" in database
"XStretch"
I. 01/16 11:35:29. Note: Duplicate index
"ndxCSM_Standards-PK" for table "CSM_Standards" in database
"XStretch"
I. 01/16 11:35:46. Starting checkpoint of "XStretch"
(XStretch.db) at Fri Jan 16 2004 11:35
I. 01/16 11:35:46. Finished checkpoint of "XStretch"
(XStretch.db) at Fri Jan 16 2004 11:35
I. 01/16 11:45:12. Disconnecting shared memory client,
process id not found
I. 01/16 11:45:12. Starting checkpoint of "XStretch"
(XStretch.db) at Fri Jan 16 2004 11:45
I. 01/16 11:45:14. Finished checkpoint of "XStretch"
(XStretch.db) at Fri Jan 16 2004 11:45
I. 01/16 11:45:30. Starting checkpoint of "XStretch"
(XStretch.db) at Fri Jan 16 2004 11:45
I. 01/16 11:45:31. Finished checkpoint of "XStretch"
(XStretch.db) at Fri Jan 16 2004 11:45
I. 01/16 11:45:31. Database server stopped at Fri Jan 16
2004 11:45


Re: virtual memory. This particular PC is running XP
Embedded and has the page file disable and there is no way
to enable it without a completely new OS image.

Thanks for the assistance.