You are not logged in or registered. Please login or register to use the full functionality of this SYBASETEAM.COM Website...
Current time: 03-12-2010, 07:53 PM Hello There, Guest! (LoginRegister)
Post Reply 
 
Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Using Solaris temp filesystem tmpfs for a Sybase tempdb device
07-01-2009, 02:11 AM
Post: #1
Using Solaris temp filesystem tmpfs for a Sybase tempdb device
Background

Adaptive Server devices usually are raw devices or file system devices. Solaris users have a third option, tmpfs, for tempdb.

tmpfs -- the temporary file system -- caches writes only for a session. Files are not preserved across operating system reboots.

Should you use tmpfs?

To determine whether tmpfs would benefit your system, perform benchmarks comparing the memory assigned to tmpfs versus the memory assigned to the data cache.

Usually, it is more effective to give extra memory to the server for use as general data cache rather than creating a tmpfs device for tempdb. If tempdb is used heavily, then it will use a fair share of the data cache. If tempdb is not used often, then the server can use the memory assigned to data cache for non-tempdb data processing, but if the memory is assigned for tempfs it is wasted.

Servers that are most likely to benefit from using tmpfs are those that are already near the addressable memory limit:

* For Sybase SQL Server 11.0.x, see TechNote 20239: Addressable Memory Limits for Sybase SQL Server 11.0.x .
* For Adaptive Server Enterprise 11.5.x, see TechNote 20101: Addressable Memory Limits in Adaptive Server Enterprise 11.5.x .
* For Adaptive Server 11.9.2, the limits generally are the same as in TechNote 20101.

Addressable memory in Adaptive Server 11.9.3 generally is 4TB, and therefore tmpfs may not be as beneficial.

Creating a tmpfs device

Follow these steps:

1. Create and test an operating system startup script that creates tmpfs after every operating system reboot. See the Solaris man page on tmpfs for details on creating a tmpfs filesystem.
2. Create the tmpfs device with disk init just like creating any other filesystem device, except that you are specifying the tmpfs filesystem you just created. For example, if you named and mounted it as "/mytmpfs":

1> use master
2> go

1> disk init name = "tempdb1_dev1",
2> physname = "/mytmpfs/tempdb",
3> vdevno = 3, size = 102400
4> go

This creates a 200MB device for tempdb on the /mytmpfs device.
3. Use alter database to extend tempdb to the tmpfs device:

1> alter database tempdb
2> on tempdb1 = 200
3> go

4. Modify your RUN_Server file to issue a UNIX touch command against tempdb on the tmpfs device before the call to the dataserver. This creates the file if it does not exist, as might happen if the operating system had been rebooted. Upon startup, the server can activate the device and rewrite tempdb. If the file entry was missing, the server would not be able to activate it and tempdb would not be available.

Ref: http://www.sybase.com/detail?id=20448

Source & Copyright : Sybase,Inc.

Kishor,
TechSupport-SeniorMember(SybaseTeam.Com)
Find all posts by this user
Quote this message in a reply

Post Reply 


Possibly Related Threads...
Thread: Author Replies: Views: Last Post
  Sybase Database dump failed for a database with no space left on device error padalav 0 174 01-28-2010 10:37 AM
Last Post: padalav
  How to get the max tempdb usage and max log file usage for user database till date GANESHBSUTAR 3 232 01-07-2010 10:49 PM
Last Post: Joshi
  Common Adaptive Server Enterprise Issues on Sun Solaris Joshi 0 218 12-31-2009 04:19 PM
Last Post: Joshi
  Using Solaris tmpfs for a tempdb Device in Sybase ASE albert 0 106 12-20-2009 03:54 PM
Last Post: albert
  find out the size of tables and indexes in any tempdb john 0 185 12-03-2009 05:45 PM
Last Post: john
  Sybase ASE server hung on Solaris and not responding Joshi 0 116 09-09-2009 01:44 AM
Last Post: Joshi
  Determine the owning session or owner of a #temp table in Sybase ASE 15.0 Nagendra 0 170 07-22-2009 11:33 AM
Last Post: Nagendra
  Query to find device name for each database fragment Nagendra 0 164 07-22-2009 11:06 AM
Last Post: Nagendra
  How do I move sybase tempdb off of the Master Device? sybasegeek 0 137 04-27-2009 11:19 AM
Last Post: sybasegeek
  monitor sybase tempdb log space albert 0 789 04-22-2009 01:58 AM
Last Post: albert

Forum Jump: