http://goo.gl/EmKxy0

Archive

Posts Tagged ‘15.7’

Huge Page Support in Linux – To Increase Database Performance.

January 19th, 2014 No comments

Memory Management internally uses TLB cache to map the Virtual address to physical address.
If the TLB cache is small (TLB Miss) (since page size is small), it will need to refer the Page table. Page Table look ups are costly as compare to TLB cache.
That’s reason the applications ( Like Database) which have heavy memory demand can be configured to Huge TLB Pages so that Page Table access can be reduced  and overall application performance can be increased.
Linux has had support for huge pages since around 2003 where it was mainly used for large shared memory segments in database servers.
ASE Database performance can be increased bt 2-7% by using huge page on Linux Platform. You can check Huge Page Support on Linux :

cat /proc/meminfo | grep Huge
HugePages_Total: XXX
HugePages_Free:  XXX
HugePages_Rsvd:   XXX
Hugepagesize:     2048 kB

Source: http://linuxgazette.net/155/krishnakumar.html

From a memory management perspective, the entire physical memory is divided into “frames” and the virtual memory is divided into “pages”. The memory management unit performs a translation of virtual memory address to physical memory address. The information regarding which virtual memory page maps to which physical frame is kept in a data structure called the “Page Table”. Page table lookups are costly. In order to avoid performance hits due to this lookup, a fast lookup cache called Translation Lookaside Buffer(TLB) is maintained by most architectures. This lookup cache contains the virtual memory address to physical memory address mapping. So any virtual memory address which requires translation to the physical memory address is first compared with the translation lookaside buffer for a valid mapping. When a valid address translation is not present in the TLB, it is called a “TLB miss”. If a TLB miss occurs, the memory management unit will have to refer to the page tables to get the translation. This brings additional performance costs, hence it is important that we try to reduce the TLB misses.

On normal configurations of x86 based machines, the page size is 4K, but the hardware offers support for pages which are larger in size. For example, on x86 32-bit machines (Pentiums and later) there is support for 2Mb and 4Mb pages. Other architectures such as IA64 support multiple page sizes. In the past Linux did not support large pages, but with the advent of HugeTLB feature in the Linux kernel, applications can now benefit from large pages. By using large pages, the TLB misses are reduced. This is because when the page size is large, a single TLB entry can span a larger memory area. Applications which have heavy memory demands such as database applications, HPC applications, etc. can potentially benefit from this.

Source : https://lwn.net/Articles/374424/

Memory Mgmt uses Translation Look Buffer(TLB) Cache to map Virtual to physical address, The amount of memory that can be translated by this cache is referred to as the “TLB reach” and depends on the size of the page and the number of TLB entries.

If the TLB miss time is a large percentage of overall program execution, then the time should be invested to reduce the miss rate and achieve better performance.
Using more than one page size(Huge Page) was identified in the 1990s as one means of reducing the time spent servicing TLB misses by increasing TLB reach.
Broadly speaking, database workloads will gain about 2-7% performance using huge pages whereas scientific workloads can range between 1% and 45%.
Huge pages are not a universal gain, so transparent support for huge pages is limited in mainstream operating systems
it is possible that huge pages will be slower if the workload reference pattern is very sparse and making a small number of references per-huge-page.
Many modern operating systems, including Linux, support huge pages in a more explicit fashion, although this does not necessarily mandate application change. Linux has had support for huge pages since around 2003 where it was mainly used for large shared memory segments in database servers such as Oracle and DB2

Isolation Levels by example

December 28th, 2013 No comments

For Earlier post on Isolation Level please refer here.

Understanding Isolation Level “1″ : Avoids Dirty Reads (Default isolation level for ASE)

Transaction T1 (Session 1)modifies a data item. Another transaction T2 (Session 2)then reads that data item before T1 performs a COMMIT or ROLLBACK. If T1 then performs a ROLLBACK, T2 has read a data item that was never committed and so never really existed.

 Session1  Session 2   Remarks
1> select @@isolation “Isolation Level”
2>go
 Isolation Level
 —————
               1
(1 row affected)
1> insert into pmtmaster values(1,100)
2> go
1> begin tran
2> update pmtmaster set id2=200 where id1=1
3> go
1>
   

In Session1, updating the row with id2=1
 
 1> print “Session 2″
2> go               
Session 2           
1> select @@isolation “Isolation Level”
2> go
 Isolation Level
 —————
               1
(1 row affected)
1> select * from pmtmaster where id1=1
2> go
^C^C
[CanCan]
 In Isolation Level 1, that is default mode, we can not read dirty data as it is still not committed by other tran.
     So Isolation Level 1, avoids dirty reads.

Understanding Isolation Level “0″

Session1 Session 2 Remarks
1> select @@isolation “Isolation Level”
2>go
Isolation Level
—————
1
(1 row affected)
1> insert into pmtmaster values(1,100)
2> go
1> begin tran
2> update pmtmaster set id2=200 where id1=1
3> go
1>
   Same as Above , In Session1, updating the row with id2=1
 
1> print “Session 2″2> goSession 2
1> set transaction isolation level 0
2> go
1> select @@isolation “Isolation Level”
2> go
Isolation Level
—————
0
(1 row affected)
1> begin tran
2> select * from pmtmaster where id1=1
2> go
id1         id2
———– ———–
1         200
(1 row affected)
 
 Now with isolation level 0 , I am trying to read data and it is allowing dirty reads.
 rollback    If Session 1  rollbacks, session will have inconsistent.

Understanding Isolation Level “2″ : Avoid Repeatable Reads

What is Repeatable Reads?

Transaction T1 (session 1) reads a data item. Another transaction T2 (session 2) then modifies or
deletes that data item and commits. If T1 then attempts to reread the data item, it receives a modified                                      value or discovers  that the data item has been deleted.

Session1 Session 2 Remarks
 

1> select @@isolation “Isolation Level”
2> go
Isolation Level
—————
1
(1 row affected)
1> begin tran
2> select * from pmtmaster where id2=200
3> go
id1         id2
———– ———–
1         200
2         200
(2 rows affected)
 
 Transaction T1 (session 1) reads a data item.
 Session1 Continues..  

 1> begin tran
2> update pmtmaster set id2=300 where id1=2
3> go
1> commit
2> go
 Another transaction T2 (session 2) then modifies.
 1> select * from pmtmaster where id2=200
2> go
 id1         id2
 ———– ———–
           1         200
(1 row affected)
 
 If T1 then attempts to reread the data item, it receives a modified value/different result set in same transaction. This is issue in repeatable reads. Lets review how can we avoid it.

How to avoid Repeatable Reads?

 

1> set transaction isolation level 2
2> go
1> select @@isolation “Isolation Level”
2> go
 Isolation Level
 —————
               2
(1 row affected)
1> begin tran
2> select * from pmtmaster where id2=200
3> go
 id1         id2
 ———– ———–
           1         200
           2         200
(2 rows affected)
To avoid Repeatable read problem, enable the isolation level 2
 Session1 Continues…
 1> begin tran
2> update pmtmaster set id2=300 where id1=2
3> go
^C^C
[CanCan]
 Now Transaction T2 will not allow to modify the restult set which was read earlier tran 1(Session 1)
 1> select * from pmtmaster where id2=200
2> go
id1         id2
———– ———–
1         200
2         200
(2 rows affected)
 
 Still T1 will get same number of rows.

but still it has problem of Phantom Read?

Transaction T1 reads a set of data items satisfying some . Transaction T2 then creates data items that satisfy T1’s and commits. If T1 then repeats its read with the same ,  it gets a set of data items different from the first read.

1> begin tran
2> insert into pmtmaster values (3,200)
3> go
1> commit
2> go  
You can not modifies the result set but still you can insert new values and affect the result set.
1> select @@isolation “Isolation Level”
2> go
Isolation Level
—————
2(1 row affected)
1> select * from pmtmaster where id2=200
2> go
id1         id2
———– ———–
1         200
2         200
3         200
(3 rows affected) 
 Now you can see the same session 1 is still returning different number of result set. This is called as Phantom Reads.
   
 To Avoid Phantom Reads enable isolation level 3 as below.

Understanding Isolation Level “3″ : Avoid Phantom Reads

 1> set transaction isolation level 3
2> go
1> select @@isolation “Isolation Level”
2> go
Isolation Level
—————
3
(1 row affected)
1> begin tran
2> select * from pmtmaster where id2=200
3> go
id1         id2
———– ———–
1         200
2         200(2 rows affected)
To Avoid Phantom Reads , Lets enable isolation level 3
 
1> begin tran
2> update pmtmaster set id2=300 where id1=2
3> go
^C^C
[CanCan] 
 Now you can not modify the result set.
  1> begin tran
2> insert into pmtmaster values (3,200)
3> go
^C^C
[CanCan]
 You can not create data items to affect the result set
 1> select * from pmtmaster where id2=200
2> go
id1         id2
———– ———–
1         200
2         200
(2 rows affected)
 
 All the time you will get same result set.

SAP Recognized as a Market Leader by Gartner, Inc. in Operational Database Management Systems Magic Quadrant

November 17th, 2013 No comments

As per Gartner:

SAP

Located in Walldorf, Germany, SAP (www.sap.com) has several DBMS products that are used for transaction systems: SAP Sybase Adaptive Server Enterprise (ASE), SAP Sybase iAnywhere and SAP Hana. Both ASE and iAnywhere are available as software only, while SAP Hana is marketed as an appliance.

Strengths
  • Vision leadership — Moving into DBMS technology, SAP has introduced SAP Hana as an in-memory platform for hybrid transaction/analytical processing (HTAP) and acquired Sybase to add to the DBMS product line.

  • Strong DBMS offerings — In addition to SAP Hana, SAP Sybase ASE continues to support global-scale applications and was first to introduce an in-memory DBMS (IMDBMS) version.

  • Performance — References cited performance (scalability and reliability) as a major strength (one of the highest scores), mostly for SAP Sybase ASE.

Source : http://global.sap.com/corporate-en/news.epx?category=ALL&articleID=21912&searchmode=C&page=1&pageSize=10

& http://www.gartner.com/technology/reprints.do?id=1-1MNA5V2&ct=131105&st=sb

 

 

SAP® Sybase® Adaptive Server® Enterprise Gains Momentum With Rapid Customer Adoption

November 17th, 2013 No comments

 

In less than 18 months since the offering’s release in April 2012, more than 1,000 customers have chosen to run SAP Business Suite on SAP Sybase ASE and there are more than 2,000 customer installations. Both new and existing SAP customers can run a high-performance relational database management system (RDBMS) optimized for SAP Business Suite that helps improve operational efficiency and significantly reduce overall costs. The announcement was made at the SAP Database and Technology Partner Summit in Barcelona.

Source :: http://www.prnewswire.com/news-releases/sap-sybase-adaptive-server-enterprise-gains-momentum-with-rapid-customer-adoption-229819941.html

http://www.hispanicbusiness.com/2013/11/5/sap_sybase_adaptive_server_enterprise_gains.htm

Sybase vs. Oracle: 10 reasons to use Sybase on Linux

December 15th, 2012 No comments

By Mich Talebzedah, SearchOpenSource.com

Sybase products are generally perceived within the database administrator (DBA) community as very reliable and easy to maintain, particularly compared to Oracle. Any move from Sybase to other DBMS (database management system) have got to be justified in terms of the current level of dissatisfaction with Sybase and the level of desire to use other. I cannot recall anywhere where this is valid.

  1. The latest Sybase flagship product, ASE 15, has filled much of the perceived functionality gap between ASE and other databases.
  2. Linux is an ideal and cost-effective platform for development teams and many companies. With the availability of heterogeneous dump and load of Sybase databases across different operating systems, Sybase — by virtue of its modularity and ease of use — is an ideal DBMS for Linux. This needs to be contrasted with Oracle which is, pound for pound, a far heavier beast and resource-hungry.
  3. Sybase has a well-established and skilled workforce, offering infrastructure and development teams who are fully familiar with database architectures and Sybase products.
  4. Applications developed using Sybase have been running for a while and providing adequate service. There is absolutely no guarantee that migrating these applications to another DBMS will result in the same level of service. I know of no case where a migration from Sybase to Oracle or otherwise has resulted in a noticeable performance gain.
  5. The exit barriers from Sybase and the entry barriers to others are high. For a medium-to-large application, it will take an average of 10 years for investment for ROI. A simple cost/benefit analysis will verify this statement.
  6. Check our Sybase ASE 15′s total cost of ownership (TCO) compared to Oracle. Based on my clients’ experience, one requires 2.5 Oracle DBAs to provide the same level of service as a single Sybase DBA.
  7. Sybase is fairly modular and has a simple syntax. Contrast this with Oracle where, in most cases, you require a third-party product to allow the DBA to reduce his/her workload. Perhaps that may be a reason why TOAD, a non-Oracle product, is the most popular GUI interface for Oracle!
  8. Since Sybase is a very secure database. In fact, it is a favourite with the U.S. Department of Defense and Central Intelligence Agency. Sybase is quickly bringing the security features — such as extensive Kerberos support, programmable authentication and data encryption — to the market.
  9. SAP’s release of its lightway product for Sybase on Linux and IBM’s steps towards selling their line of P5 Linux servers with ASE, while they have DB2 and Informix themselves, are pretty strong statements about the future of Sybase.
  10. The future of Sybase is secure, largely because it is well entrenched in its core marketplace, the financial services market. More than half of Wall Street runs on Sybase. The majority of complex trading systems and banks use sophisticated replication technology to provide publisher-subscriber or peer-to-peer replication. At this juncture, none of the competitors can provide the same degree of functionality that Sybase Replication Server provides.

Source :http://searchenterpriselinux.techtarget.com/tip/Sybase-vs-Oracle-10-reasons-to-use-Sybase-on-Linux

Sybase DBA Interview Q&A – You Must Know !

October 9th, 2012 4 comments

Dear All,

Few month back, we posted  for Sybase DBA Interview Questions &  Answers Series and we received the lot of your valuable suggestions, regarding that.
Today, I would like to thanks for your thoughts , we tried to consider  same as per our feasibility

Wait is over Now !!  Please download the First Q&A Bank (Limited Edition) with below link :

Sybase-DBA-Interview-Q &A (517)

We are still improving and adding more questions and will be releasing full version by the Month End.
If you are still seeing any correction, improvement, you are most welcome.

Again Thanks, and Happy Learning Sybase !

-Team, sybaseblog.com.

PS : You need to login to download the Q&A Bank.

 

 

ASE15 New Features – II : DBA Perspective

September 15th, 2012 No comments

Source :   Sybase Resources on www & sybase.com 

In 2009 , I posted ASE 15 New Features -1 ,  Now recently ASE has released ASE15.7  ESD-2 and these are new features in recent versions;

Happy Reading and Enjoy !

 

ASE 15.7 ESD#2 New Features
==============================

• Automatic compressed Share Memory dump
• In-Row Large Object Compression
• create database Asynchronously
• Shared Query Plans
• User-Defined Optimization Goal
• Expanded Maximum Database Size
• alter table drop column without datacopy
• Enhancements to dump and load : Dump Configuration, History.
• Hash-Based Update Statistics
• Concurrent dump database and dump transaction Commands
• Fast-Logged Bulk Copy
• Enhancements to show_cached_plan_in_xml
• Merging, Splitting & Moving Partitions
• Non blocking Reorg
• Deferred Table Creation
• Granular Permissions & Predicate Priviliages
ASE 15.7 New Features
=============================

• Application Functionality Configuration Group
• ASE Thread-Based Kernel: The ASE kernel us now thread-based instead or process-based
• Data Compression : Use less storage space for the same amount of data, reduce cache memory consumption and improve performance because of lower I/O demands
• New Security Features: End-to-end CIS Kerberos authentication, dual control of encryption keys and unattended startup, secure logins, roles and password management and login profiles
• Abstract Plans in Cached Statements: Abstract plan information can be saved in statement cache
• Shrink Log Space: Allows you to shrink the log space and free storage without re-creating the database using the alter database command to remove unwanted portions of a database log
• Display Currently Set Switches: Allows visibility of all traceflags at the server and session level
• Changes for Large Objects: Includes storing in-row LOB columns for small text, image and unitext datatypes, storing declared SQL statements containing LOBs, indirectly referencing a LOB in T-SQL statements, and allows checking for null values of large objects
• Showing Cached Plans in XML: Allows showplan output in XML for a statement in cache
• Padding a Character Field Using str: Fields can be padded with a specified character or numeric
• Changes to select for update: Allows select for update command to exclusively lock rows for subsequent updates within the same transactio and for updatable cursors
• Creation of non-materialized, non-NULL columns
• Sharing Inline Defaults: Allows sharing inline defaults between different tables in the same db
• Monitoring data is retained to improve query performance
• Dynamic parameters can be analyzed before running a query to avoid inefficient query plans
• Monitor Lock Timeouts
• Enable and disable truncation of trailing zeros from varbinary and binary null data
• Full Recoverable DDL: Use dump transaction to fully recover the operations that earlier versions of Adaptive Server minimally logged
• Transfer Rows from Source to Target Table Using merge.
• View Statistics and Histograms with sp_showoptstats: Allow you to extract and display, in an XML document, statistics and histograms for various types of data objects from system tables
• Changes to Cursors: Changes to how cursors lock, manage trnasactions and are declared
• Nested select Statement Enhancements: Expands the abilities of the asterisk (*)
• Some system procedures can run in sessions that use chained transaction mode
• Expanded Variable-Length Rows: Redefines data-only locked (DOL) columns to use a row offset of upto 32767 bytes. Requires a logical page size of 16K to create wide, variable-length DOL rows.
• Like Pattern Matching: Treat square brackets individually in the like pattern-matching algorithm
• Quoted Identifiers: Use quoted identifiers for tables, views, column names, index names and system procedure parameters
• Allow Unicode Noncharacters: Enable permissive unicode configuration parameter, which is a member of enable functionality group, allows you to ignore Unicode noncharacters
• Reduce Query Processing Latency: Enables multiple client connections to reuse or share dynamic SQL lightweight procedures (LWPs)
• The sybdiag Utility: A new Java-based tool that collects comprehensive ASE configuraiton and environment data for use by Sybase Technical Support
• The optimizer Diagnostic Utility: Adds the sp_opt_querystats system procedure, which allows you to analyze the query plan generated by the optimizer and the factors that influenced its choice of a query plan

ASE 15.5 New Features
==============================

• In-memory databases provide improved performance by operating entirely in-memory and not reading/writing transactions to disk.
• Relaxed-durability for disk-resident databases delivers enhanced performance by eliminating committed transactions.
• “dump database” and “load database” functionality is provided for both in-memory and relaxed-durability databases.
• Faster compression for backups is provided by two new compression options (level 100 and 101).
• Backup Server support is now available for IBM’s Tivoli Storage Manager.
• Deferred name resolution allows the creation of stored procedures before the referenced objects are created in the database.
• FIPS 140-2 encryption is now provided for login passwords that are transmitted, stored in memory or stored on disk.
• Incremental Data Transfer allows exporting specific rows, based on either updates since the last transfer or by selected rows for an output file, and does so without blocking ongoing reads and updates.
• The new bigdatetime and bigtime datatypes provide microsecond level precision.
• You can now create and manage user-created tempdb groups, in addition to the default tempdb group.
• The new monTableTransfer table provides historical transfer information for tables.
• The new system table, spt_TableTransfer, stores results from table transfers.
• The sysdevices table has been modified to list the in-memory storage cache under the “name” and “phyname” columns.
• Auditing options have been added to support in-memory and relaxed-durability databases, incremental data transfer, and deferred name resolution.

ASE15 New Features – I : http://sybaseblog.com/2009/12/17/sybase-ase15-new_features/

ASE database for SAP ERP

December 20th, 2011 No comments

Hello all,

These are copilataion for Sybase ASE on SAP from the Rob’s Blog :

Read Full Story : http://blogs.sybase.com/database/2011/12/so-what-does-an-ase-database-look-like-in-sap-erp/

  • SAP has released Business Suite on ASE version 15.7.
  • All SAP application data resides in a single ASE database. There is another small database for use by SAP tools.
  • The ASE database uses a 16KB page size.
  • For ERP only (i.e. not counting CRM and the other Business Suite modules), the database contains about 80,000 tables and 170,000 indexes. This is because SAP ERP has many features and functions, all with their own set of tables. SAP customers typically run only a subset of all those functions so in practice a large part of those 80,000 tables will always remain empty.
  • All SAP tables use datarowslocking (there is an interesting historical dimension.
  • All tables names are in uppercase; some table names contain special characters, like the slash character in “/BCV/C_QATTR” (I don’t have a clue what that name means, BTW)
  • Apart from the tables, there are also about 10,000 views. No stored procedures or triggers are used.
  • SAP makes heavy use of dynamic SQL (also known as “prepared statements”).
  • Many tables have a text or image column.
  • All tables are owned by one database user (and that’s not the dbouser).
  • The ASE database is accessed through ODBC.
  • SAP makes frequent use of the built-in ASE Job Scheduler (originally added in ASE 12.5.1).
  • The ASE server uses Unicode with the utf8 character set.

K21– ASE’S KERNEL DESIGN FOR THE 21ST CENTURY – ASE 15.7’s THREADED KERNEL K21

November 29th, 2011 No comments

Basic Difference :

Process Kernel:

Pre-15.7 kernel (except Windows)
Each engine is a separate process

Retained in 15.7 for risk mitigation

Threaded Kernel:

Default kernel for 15.7

Each engine is a thread of a single process

Additional threads for handling I/O, etc.

ASE on Windows has always been thread based

http://www.sybase.com/files/Product_Overviews/ASE-15.7-New-Threaded-Kernel.pdf

http://blogs.sybase.com/tradingandrisk/2011/11/highly-consistent-response-times-with-new-threaded-kernel-in-ase-15-7/

Categories: ASE, News Tags: , , , , ,

ASE 15.7 for SAP® Business Suite Released in Techwave!!!

September 14th, 2011 No comments

Hi Folks,

Most Awaited Database ASE 15.7 has been released yday in Vegas Techwave:

Extremely good news for Sybase Users!!!!!!!!

http://www.sybase.com/detail?id=1094783

http://www.sybase.com/asebuiltforbusiness

http://www.ctoedge.com/content/making-database-smarter

http://blogs.sybase.com/tradingandrisk/2011/09/sybase-unveils-latest-ase-at-techwave-2011-in-las-vegas/

ASE 15.7 key features include:

Management of Large Datasets

  • Compression— allows large databases to be stored more compactly and reduces I/O times to ensure high performance on even the largest databases.
  • Reduced Query Latency— helps better handle large data sets, especially those which use dynamic SQL for interactive data retrieval.
  • Replication Performance—increases the performance of Sybase’s industry-leading transaction replication and syncing technology.
  • Enhancements for Parallel Hardware —improves optimization of multi-core/multi-threaded CPU architectures to get the maximum performance out of today’s latest processors

Simplified Administration

  • Online Operations—increases data availability while allowing data to be optimized for application performance.
  • Extended Diagnostics—allows DBAs to quickly pin-point performance bottlenecks and speed customer support requests.
  • Strong Password Encryption—protects the database from external intrusion and hacking
  • Single Sign-on & Login Profiles—makes it easier to manage large numbers of users and simplifies end-user access to the system

Ease of Application Development

  • Efficient Management of Large Objects—inline management of large objects as well as enhanced application development features such as large objects as parameters to stored procedures.
  • Enhanced Application Language Capabilities—many improved TransactSQL&™ language features to increase productivity of application developers as well as support for a variety of popular languages such as Python, PHP and Perl.
  • An Enterprise-Class DB for ISV applications —enhanced business-critical performance for ISV applications out of the box, enabling ISVs to easily write and port their applications to ASE 15.7.
Categories: ASE, News Tags: , , , , ,