<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:georss='http://www.georss.org/georss' xmlns:gd='http://schemas.google.com/g/2005' xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-2552934363134993103</id><updated>2011-11-27T19:54:46.469-05:00</updated><category term='Unix'/><category term='LifeStyle'/><category term='HighAvailability'/><category term='ASE'/><category term='General'/><category term='Oracle'/><category term='Scripts'/><category term='Replication'/><title type='text'>James Xing's Sybase DBA blog</title><subtitle type='html'>Database related notes with focus on Sybase</subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default?max-results=100'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>69</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>100</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-3261778853628828110</id><published>2010-08-07T22:20:00.003-04:00</published><updated>2010-08-07T22:27:45.017-04:00</updated><title type='text'>closed comment section</title><content type='html'>I closed the comment section today, as I am getting daily spam from this site. I have tried to delete the spam comments, but it's still took too much of my time. so I leave it for now. When I have time, will clean it up.&lt;br /&gt;&lt;br /&gt;Nothing really exciting for me in the last little while, so I have no new post. The best news was probably the sybase buy out from SAP. Sybase will be safe for another 10-20 year, I guess.  wish I had bought sybase stock before the buyout :)&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-3261778853628828110?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/3261778853628828110/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=3261778853628828110' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/3261778853628828110'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/3261778853628828110'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2010/08/closed-comment-section.html' title='closed comment section'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-3955580573462475368</id><published>2009-06-28T21:26:00.002-04:00</published><updated>2009-06-28T21:41:23.620-04:00</updated><title type='text'></title><content type='html'>What a historical year it is? I haven't posted for over a year now, simply because it's so many changes happened in the past 1 year, the fall of bear stern, lehman brothers, stock market crash, layoff, company strategy change ..... though I was not impacted, but it's amazing to watch all these happening around me and I am not too interested on the techinical stuff at this moment.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-3955580573462475368?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/3955580573462475368/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=3955580573462475368' title='15 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/3955580573462475368'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/3955580573462475368'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2009/06/what-historical-year-it-is-i-havent.html' title=''/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>15</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-9008235291597322506</id><published>2008-06-09T23:18:00.002-04:00</published><updated>2008-06-09T23:26:14.329-04:00</updated><title type='text'></title><content type='html'>&lt;strong&gt;Sybase stock was up more than 20% in May&lt;/strong&gt;&lt;br /&gt;&lt;br /&gt;I noticed Sybase stock (symbol SY) was up more than 20% in May. That's pretty good run. Right now it's $31.47.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-9008235291597322506?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/9008235291597322506/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=9008235291597322506' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/9008235291597322506'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/9008235291597322506'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2008/06/sybase-stock-was-up-more-than-20-in-may.html' title=''/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-6408813590792213502</id><published>2008-06-01T11:37:00.004-04:00</published><updated>2008-06-27T15:56:18.664-04:00</updated><title type='text'></title><content type='html'>&lt;strong&gt;DDL for master..syslogins&lt;/strong&gt;&lt;br /&gt;&lt;br /&gt;The DDL for syslogins comes in handy when you work on syslogins related tasks, i.e. Migrate syslogins from Sybase 12.0 to Sybase 12.5. Most DBA tools reverse DDL for user tables only.&lt;br /&gt;&lt;br /&gt;USE&lt;br /&gt;tempdb&lt;br /&gt;go&lt;br /&gt;CREATE TABLE dbo.jx_syslogins&lt;br /&gt;(&lt;br /&gt;suid int NOT NULL,&lt;br /&gt;status smallint NOT NULL,&lt;br /&gt;accdate datetime NOT NULL,&lt;br /&gt;totcpu int NOT NULL,&lt;br /&gt;totio int NOT NULL,&lt;br /&gt;spacelimit int NOT NULL,&lt;br /&gt;timelimit int NOT NULL,&lt;br /&gt;resultlimit int NOT NULL,&lt;br /&gt;dbname sysname(30) NULL,&lt;br /&gt;name sysname(30) NOT NULL,&lt;br /&gt;password varbinary(30) NULL,&lt;br /&gt;language varchar(30) NULL,&lt;br /&gt;pwdate datetime NULL,&lt;br /&gt;audflags int NULL,&lt;br /&gt;fullname varchar(30) NULL,&lt;br /&gt;srvname varchar(30) NULL,&lt;br /&gt;logincount smallint NULL,&lt;br /&gt;procid int NULL)&lt;br /&gt;go&lt;br /&gt;&lt;br /&gt;1&gt; insert master..syslogins (suid, status, accdate , totcpu , totio , spacelimit , timelimit , resultlimit , dbname , name , password , language , pwdate , audflags , fullname , srvname , logincount )&lt;br /&gt;2&gt; select * from jx_syslogins&lt;br /&gt;3&gt; go&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-6408813590792213502?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/6408813590792213502/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=6408813590792213502' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/6408813590792213502'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/6408813590792213502'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2008/06/ddl-for-master.html' title=''/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-8421520213764389875</id><published>2008-05-15T16:12:00.000-04:00</published><updated>2008-05-15T16:13:57.839-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Oracle'/><title type='text'></title><content type='html'>&lt;strong&gt;How to stop Oracle Archive log mode&lt;/strong&gt;&lt;br /&gt;&lt;br /&gt;startup mount;&lt;br /&gt;alter database noachivelog;&lt;br /&gt;alter database open;&lt;br /&gt;archive log list;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-8421520213764389875?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/8421520213764389875/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=8421520213764389875' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/8421520213764389875'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/8421520213764389875'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2008/05/how-to-stop-oracle-archive-log-mode.html' title=''/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-7644533294546355608</id><published>2008-05-09T11:28:00.001-04:00</published><updated>2008-05-09T11:29:56.336-04:00</updated><title type='text'></title><content type='html'>&lt;strong&gt;How to move a datafile using disk mirroring in Sybase12.5&lt;/strong&gt;&lt;br /&gt;&lt;br /&gt;Example: move audit01 device from /dir1/datafile1 to /dir2/datafile2&lt;br /&gt;&lt;br /&gt;sp_configure ‘disable disk mirroring’, 0&lt;br /&gt;go&lt;br /&gt;shutdown with nowait&lt;br /&gt;go&lt;br /&gt;&lt;br /&gt;- restart dataserver&lt;br /&gt;&lt;br /&gt;disk mirror&lt;br /&gt;name = audit01,&lt;br /&gt;mirror = "/dir2/datafile2"&lt;br /&gt;go&lt;br /&gt;&lt;br /&gt;disk unmirror&lt;br /&gt;name = audit01,&lt;br /&gt;side = "primary",&lt;br /&gt;mode = remove&lt;br /&gt;go&lt;br /&gt;&lt;br /&gt;sp_helpdevice audit01&lt;br /&gt;go&lt;br /&gt;sp_configure 'disable disk mirroring", 1&lt;br /&gt;go&lt;br /&gt;- restart dataserver&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-7644533294546355608?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/7644533294546355608/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=7644533294546355608' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/7644533294546355608'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/7644533294546355608'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2008/05/how-to-move-datafile-using-disk.html' title=''/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-1594715914942775507</id><published>2008-05-02T22:23:00.004-04:00</published><updated>2008-05-02T22:32:38.649-04:00</updated><title type='text'></title><content type='html'>&lt;strong&gt;Sybase reports record First Quarter Results&lt;/strong&gt;&lt;br /&gt;&lt;br /&gt;Highlights:&lt;br /&gt;Total revenue of $260.1 million, up 13% year over year&lt;br /&gt;License revenue increased 13% year over year&lt;br /&gt;Services revenue increased 8% year over year&lt;br /&gt;Database license revenue increased 19% year over year&lt;br /&gt;Messaging revenue increased 37% year over year&lt;br /&gt;GAAP operating margin of 14%, versus 9% a year ago; non-GAAP operating margin of 19%, versus 15% a year ago&lt;br /&gt;GAAP net income of $24.2 million, up 60% year over year; GAAP EPS up 65% year over year&lt;br /&gt;Non-GAAP net income of $35.3 million, up 42% year over year; non-GAAP EPS up 46% year over year&lt;br /&gt;Cash flow from operations of $94.6 million, up 36% year over year&lt;br /&gt;&lt;br /&gt;I think the license increase are primarily due to the fact that license key is mandatory in version 15. The older version of sybase does not need to have a key to run. Many Sybase users have setup additional sybase servers without license. As they migrate to Sybase15, they have to buy extra licenses.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-1594715914942775507?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/1594715914942775507/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=1594715914942775507' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/1594715914942775507'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/1594715914942775507'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2008/05/sybase-reports-record-first-quarter.html' title=''/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-7429518941165033544</id><published>2008-04-19T14:44:00.003-04:00</published><updated>2008-04-19T15:13:23.118-04:00</updated><title type='text'></title><content type='html'>&lt;strong&gt;Asus unveils Eee PC 9000 XP laptop&lt;/strong&gt;&lt;br /&gt;&lt;br /&gt;checked ebay, I was surprised that this laptop is in market already. below are the desc from 1 ebay seller. I am interested to get one with GPS build in.&lt;br /&gt;&lt;br /&gt;Mobility &amp;amp; Reliability&lt;br /&gt;• At half the size of regular notebooks and weighing less than 1kg, you can take the Eee PC anywhere.&lt;br /&gt;• Bumps and shocks are no longer issues. With a dependable solid-state disk, you get unparalleled shock-protection and reliability.&lt;br /&gt;• Power-efficient design provides longer operating time when on the go.&lt;br /&gt;&lt;br /&gt;Ease &amp;amp; Technology&lt;br /&gt;• With a rapid start-up time, the Eee PC 900 is always ready to get into action.&lt;br /&gt;• No technical manual required with the specially designed, user-friendly and intuitive graphic interface .&lt;br /&gt;&lt;br /&gt;Work &amp;amp; Connectivity&lt;br /&gt;• You’re always connected with built-in WiFi 802.11 b/g that automatically detects and connects to the Internet at any hotspot.&lt;br /&gt;• The Eee PC 900 includes the documents and the e-mails software, and a suite of other productivity software to help keep you on track.&lt;br /&gt;• Upload photos and videos and share them instantly on Flickr or YouTube without waiting till you get home.&lt;br /&gt;&lt;br /&gt;Media &amp;amp; Entertainment&lt;br /&gt;• Enjoy music and videos with extensive support for a wide range of digital multimedia.&lt;br /&gt;• Log on to Skype or other network, and you can connect with friends anywhere, anytime.&lt;br /&gt;• Clear up wire clutter with the built-in card reader, webcam, speakers, and microphone.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-7429518941165033544?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/7429518941165033544/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=7429518941165033544' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/7429518941165033544'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/7429518941165033544'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2008/04/asus-unveils-eee-pc-9000-xp-laptop.html' title=''/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-297114949983620150</id><published>2008-03-24T13:58:00.001-04:00</published><updated>2008-03-24T13:58:56.810-04:00</updated><title type='text'></title><content type='html'>Sybase DBA certificate resource&lt;br /&gt;&lt;br /&gt;1) &lt;a href="http://www.sybase.com/professional-services/education/certification"&gt;Sybase Certificate home page&lt;/a&gt;&lt;br /&gt;2) &lt;a href="http://www.sybase.com/professional-services/education/professionalcertification/adaptiveserverenterprise/adminassociate125#guide"&gt;Sybase DBA certificate study guide&lt;/a&gt;&lt;br /&gt;3) &lt;a href="http://www.blogger.com/sybooks.sybase.com"&gt;Sybase manual&lt;/a&gt;&lt;br /&gt;4) &lt;a href="http://www.sybase.com/professional-services/education/professionalcertification/adaptiveserverenterprise/adminassociate125#general"&gt;Sybase exam&lt;/a&gt;&lt;br /&gt;5) &lt;a href="http://www.sybase.com/professional-services/education/professionalcertification/adaptiveserverenterprise/adminassociate125#guide"&gt;Review from other experienced DBA&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-297114949983620150?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/297114949983620150/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=297114949983620150' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/297114949983620150'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/297114949983620150'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2008/03/sybase-dba-certificate-resource-1.html' title=''/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-1858791072769706513</id><published>2008-03-11T11:50:00.000-04:00</published><updated>2008-03-11T11:58:47.306-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ASE'/><title type='text'>How to change ASE sort order</title><content type='html'>I recently tried to merge a system requiring case insensitive with a system using case sensitive sort order which is the default setting for Sybase ASE. Here are the steps&lt;br /&gt;&lt;br /&gt;- check what sort order is being used&lt;br /&gt;            sp_helpsort&lt;br /&gt;- try to change it to the new order&lt;br /&gt;-           sp_configure ‘default sortorder id', new_sort_order_value &lt;br /&gt;- If you get error like this&lt;br /&gt;&lt;br /&gt;    1&gt; sp_configure 'default sortorder id', 52&lt;br /&gt;    2&gt; go&lt;br /&gt;    Msg 5824, Level 16, State 4:Server 'SNAP_PROD', Procedure 'sp_configure', Line 777:Cannot reconfigure server to use sort order ID 52, because the row for itsunderlying character set (ID 1) does not exist in syscharsets.&lt;br /&gt;    (return status = 1)&lt;br /&gt;&lt;br /&gt;Then exit from isql and run like this&lt;br /&gt;      $SYBASE/bin/charset -Psa_pw -Sservername nocase.srt iso_1&lt;br /&gt;&lt;br /&gt;then recycle the instance, the instance will be down automatically once conversion is done.&lt;br /&gt;Start the instance again&lt;br /&gt;Run sp_helpsort to verify&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-1858791072769706513?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/1858791072769706513/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=1858791072769706513' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/1858791072769706513'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/1858791072769706513'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2008/03/how-to-change-ase-sort-order.html' title='How to change ASE sort order'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-2809968784678470430</id><published>2008-03-05T13:42:00.000-05:00</published><updated>2008-03-05T13:49:18.292-05:00</updated><title type='text'>Compare Sybase vs MS SQL Server</title><content type='html'>a nice comparison between Sybase 12.5 and MS SQL Server 2000.&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.mssqlcity.com/Articles/Compare/sql_server_vs_sybase.htm"&gt;http://www.mssqlcity.com/Articles/Compare/sql_server_vs_sybase.htm&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-2809968784678470430?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/2809968784678470430/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=2809968784678470430' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/2809968784678470430'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/2809968784678470430'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2008/03/compare-sybase-vs-ms-sql-server.html' title='Compare Sybase vs MS SQL Server'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-2863298521982228627</id><published>2008-02-26T16:12:00.000-05:00</published><updated>2008-02-26T16:18:10.099-05:00</updated><title type='text'>Veritas Quick I/O</title><content type='html'>VERITAS Quick I/O bypasses the file system page cache, eliminating extra buffering, and providing direct writes to disk. It thereby enhances performance, enables more efficient use of memory and significantly reduces CPU usage.&lt;br /&gt;&lt;br /&gt;Here is a link to a Sybase performance test on Veritas storage. It's done by Veritas Software Corp.&lt;br /&gt;&lt;br /&gt;&lt;a href="http://eval.symantec.com/mktginfo/products/White_Papers/Storage_Server_Management/sf_sybase_40_perf_solaris.pdf"&gt;http://eval.symantec.com/mktginfo/products/White_Papers/Storage_Server_Management/sf_sybase_40_perf_solaris.pdf&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-2863298521982228627?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/2863298521982228627/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=2863298521982228627' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/2863298521982228627'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/2863298521982228627'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2008/02/veritas-quick-io.html' title='Veritas Quick I/O'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-8775702976647950352</id><published>2008-02-15T16:19:00.000-05:00</published><updated>2008-02-15T16:21:10.184-05:00</updated><title type='text'>DBArtisan</title><content type='html'>DBArtisan is a popular DBA tool. You may find some DBA job posting even has requirement on familiarity on this tool.&lt;br /&gt;&lt;br /&gt;The tool itself is very simple and not much different from the native tool from database vendors, the main strength is it provide same interface across all platform (Oracle, Sybase, DB2 and SQL Server).&lt;br /&gt;&lt;br /&gt;The tool is quite expensive. I found a trick here that is totally legal. It can save significant money for the business and greatly increase ROI. But the sales people from the vendor definitely don’t want you know. I will keep my mouth shut.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-8775702976647950352?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/8775702976647950352/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=8775702976647950352' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/8775702976647950352'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/8775702976647950352'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2008/02/dbartisan.html' title='DBArtisan'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-2571293462019039910</id><published>2008-02-13T10:29:00.000-05:00</published><updated>2008-02-13T10:35:35.966-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ASE'/><title type='text'>backup/recovery strategy consideration</title><content type='html'>&lt;a name="1008604"&gt;&lt;/a&gt;Below are some of the consideration when design database backup/recovery strategy&lt;br /&gt;&lt;br /&gt;* How and where will you store your recovery-related files? Will you store backups on tape or other offline storage, or only on disk?&lt;br /&gt;* At what intervals will you take scheduled backups? And what form of physical backups will you take in each situation?&lt;br /&gt;&lt;a name="1011166"&gt;&lt;/a&gt;* What situations require you to take a database backup outside of the regular schedule? Sometimes you must take an unscheduled backup to ensure that you can recover your data. You may also have business requirements that require backups for auditing purposes or other reasons not related to database recovery.&lt;br /&gt;&lt;a name="1011167"&gt;&lt;/a&gt;* How can you validate your backups, to ensure that you can recover your database when necessary?&lt;br /&gt;&lt;a name="1007096"&gt;&lt;/a&gt;* How do you manage records of your backups?&lt;br /&gt;&lt;a name="1009753"&gt;&lt;/a&gt;* Do you have detailed recovery plans that cover each type of failure? How do your DBAs can execute these plans in a crisis? Can scripts be written to automate execution of these plans in a crisis?&lt;br /&gt;&lt;a name="1010423"&gt;&lt;/a&gt;* Can you apply Sybase database availability technologies, such as Warm Standby, Sybase HA, vcs, to improve availability during a database failure? How does using these availability technologies affect your backup and recovery strategy?&lt;br /&gt;&lt;a name="1009754"&gt;&lt;/a&gt;&lt;br /&gt;These are of course only a few of the considerations you should take into account. Available resources (hardware, media, staff, budget, and so on) will also be factors in your decision.&lt;br /&gt;&lt;br /&gt;&lt;a name="1008604"&gt;&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-2571293462019039910?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/2571293462019039910/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=2571293462019039910' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/2571293462019039910'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/2571293462019039910'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2008/02/backuprecovery-strategy-consideration.html' title='backup/recovery strategy consideration'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-5848254706505410233</id><published>2008-02-10T15:58:00.000-05:00</published><updated>2008-02-10T16:13:36.735-05:00</updated><title type='text'>Trace flag 298</title><content type='html'>Recently when we upgraded an Sybase server from v11.5 to v12.5.4, the application got some outer join error (11055, "Query contains an illegal outer-join request". ).&lt;br /&gt;&lt;br /&gt;Somehow, it's very difficult to get the developer fix his program. To keep the project moving, I turned on the trace flag 298, this flag is to reverse sybase outer join behaviour back to the way used in prior to v12.0. From ASE 12.0 onwards the behaviour of correlated subqueries containing T-SQL outer joins has changed. The problem (error) disppeared after sybase is recycled with trace flag 298. The project team was so amazed as this solution was not expected.&lt;br /&gt;&lt;br /&gt;The drawback is that this db can not be put into other sybase servers because of the trace flag used.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-5848254706505410233?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/5848254706505410233/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=5848254706505410233' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/5848254706505410233'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/5848254706505410233'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2008/02/trace-flag-298.html' title='Trace flag 298'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-1903872602343484043</id><published>2008-02-08T14:32:00.000-05:00</published><updated>2008-02-08T14:38:11.164-05:00</updated><title type='text'>Chinese New Year's day</title><content type='html'>Yesterday was Chinese New Year's day. To celebrate this holiday, I joined a few friends for lunch at &lt;a href="http://www.toronto.com/winterlicious/listing/212886"&gt;Acqua&lt;/a&gt;, an exceptionally stylish restaurant at downtown Toronto.&lt;br /&gt;&lt;br /&gt;The &lt;a href="http://www.toronto.com/winterlicious/article/598633"&gt;meal&lt;/a&gt; was great. Price was good too, as it’s also the last day of this year’s famous &lt;a href="http://www.toronto.com/winterlicious?google"&gt;Toronto Winterlicious&lt;/a&gt;.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-1903872602343484043?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/1903872602343484043/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=1903872602343484043' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/1903872602343484043'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/1903872602343484043'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2008/02/chinese-new-years-day.html' title='Chinese New Year&apos;s day'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-5288853871385645318</id><published>2008-02-05T15:21:00.000-05:00</published><updated>2008-02-05T15:24:42.379-05:00</updated><title type='text'>tempdb full</title><content type='html'>When tempdb is full, you really can't do anything, even for DBA. The only solution at the moment is either expand tempdb or do a server recycle. Once the server is recycled, all the traces are gone. There is no way to find out who/what caused the trouble.&lt;br /&gt;&lt;br /&gt;The key here is to capture the related information before tempdb is full. Use threshold action procedure to capture process info in sysprocesses, syslogshold, syslocks and other related info, save it in permanent tables. Even after the server is recycled, the info is still there to be analyzed. But remember thresholdaction definition will be gone after server recycle. So a tip I am using is to add the create threshold statement into server RUN file.&lt;br /&gt;&lt;br /&gt;There are other options to use, ie. Resource limit, multiple tempdb etc.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-5288853871385645318?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/5288853871385645318/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=5288853871385645318' title='4 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/5288853871385645318'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/5288853871385645318'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2008/02/tempdb-full.html' title='tempdb full'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>4</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-4162647857635055914</id><published>2008-02-02T22:32:00.000-05:00</published><updated>2008-02-02T22:53:17.771-05:00</updated><title type='text'>Bought a new laptop</title><content type='html'>I made some profit from the recent stock market turmoil. To reward myself, I decided to buy a new laptop from DELL. Order was placed. I will get it in couple weeks. can't wait to see it.&lt;br /&gt;&lt;br /&gt;Here is the link. It's a good deal valid till Feb 8, 2008&lt;br /&gt;&lt;a href="http://www.redflagdeals.com/deals/main.php/alldeals/comments/dellca_vostro_1400_laptop_w_c2d_t5270_1gb_ram_120gb_hd_windows_xp_home_599"&gt;http://www.redflagdeals.com/deals/main.php/alldeals/comments/dellca_vostro_1400_laptop_w_c2d_t5270_1gb_ram_120gb_hd_windows_xp_home_599&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;With the laptop, I can be relax if I am in gym or public library. No need to worry about getting support calls and having to go home to access computer. I also expect more fun playing on Window XP. My desktop computer purchased last year is on Window vista which is too new for many software.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-4162647857635055914?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/4162647857635055914/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=4162647857635055914' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/4162647857635055914'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/4162647857635055914'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2008/02/bought-new-laptop.html' title='Bought a new laptop'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-4348275784211637978</id><published>2008-01-22T15:41:00.000-05:00</published><updated>2008-01-22T15:50:24.541-05:00</updated><title type='text'>DST patch</title><content type='html'>If your systems are used in US, then you probably have heard about DST patch. and I was surprised that even the latest EBF from Sybase contains the out-of-date java, which is not DST compliant. From enterprise point of view, it's better to upgrade all java binary up-to-date.&lt;br /&gt;&lt;br /&gt;ASE has no logic for Daylight Savings Time. It relies entirely on the Operating System to return the date.&lt;br /&gt;Basically ASE will change when the Operating System does. If the Operating System time changes, ASE gradually speeds up or gradually slows down its clock until in sync with the operating system.&lt;br /&gt;From the official Sybase DST response document ("Daylight Savings Time and Sybase Products") :&lt;br /&gt;"Most Sybase Server Products do not have any direct support for handling daylight saving time. ... Sybase Servers support the use of date and time data through the datetime and smalldatetime datatypes (and, with newer server, the date and time datatypes), as well as the getdate(), dateadd(), datediff(), and datepart() functions. ... The datetime and smalldatetime datatypes, however, do not store time zone information and the products are entirely ignorant of the concepts of time zones and daylight saving time."&lt;br /&gt;For more information, see:&lt;br /&gt;&lt;a href="http://www.sybase.com/detail?id=1048699"&gt;http://www.sybase.com/detail?id=1048699&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;There are 2 ways to update java to be DST compliant.&lt;br /&gt;1) upgrade JDK to higher version than 1.4.2 - download from Sun web site, then cp it to the right directory&lt;br /&gt;2) run tzupdater like this if the java is already 1.4.2&lt;br /&gt;java -jar /$PATHTOtzupdater/tzupdater.jar -u&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-4348275784211637978?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/4348275784211637978/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=4348275784211637978' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/4348275784211637978'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/4348275784211637978'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2008/01/dst-patch.html' title='DST patch'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-863832301596227758</id><published>2008-01-09T11:35:00.000-05:00</published><updated>2008-01-09T11:45:41.268-05:00</updated><title type='text'>How to control Sybase process on OS level</title><content type='html'>In Sun Solaris 9 and newer versin, there is new feature that can be used for controlling resource usage for Unix process. It's defined in /etc/project. A project is a grouping of processes that are subject to a set of constraints.For example, we could limit a project to how many processes it could have, or how large of a file it could create.&lt;br /&gt;&lt;br /&gt;The project file contains a series of one-line entries, one for each configured project. Each line takes the following form:&lt;br /&gt;  project-name:project-id:comment:user-list:group-list:attributes&lt;br /&gt;&lt;br /&gt;Whith this feature, we can limit cpu/space/file size etc of Sybase processes. This is especially useful for the powerful server with multiple Sybase instances running. It can prevent one screwed process from taking over the whole box.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-863832301596227758?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/863832301596227758/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=863832301596227758' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/863832301596227758'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/863832301596227758'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2008/01/how-to-control-sybase-process-on-os.html' title='How to control Sybase process on OS level'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-4186745782750444666</id><published>2007-12-28T15:47:00.000-05:00</published><updated>2007-12-28T15:55:49.328-05:00</updated><title type='text'>Naming convention for Sybase instance</title><content type='html'>There are many ways of naming &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_0"&gt;Sybase&lt;/span&gt; instance, especially S&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_1"&gt;ybase&lt;/span&gt; instance name can be as long as 30 &lt;span class="blsp-spelling-corrected" id="SPELLING_ERROR_2"&gt;characters&lt;/span&gt;. Much better than Oracle instance name limitation.&lt;br /&gt;&lt;br /&gt;The key is to 1) keep it short 2) keep it meaningful 3)easy to distinguish server type.&lt;br /&gt;&lt;br /&gt;The best naming convention I think is in following format&lt;br /&gt;    &lt;span class="blsp-spelling-error" id="SPELLING_ERROR_3"&gt;ApplicationName&lt;/span&gt;_&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_4"&gt;ServerType&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;i.e. PAYROLL_PROD, PAYROLL_&lt;span class="blsp-spelling-error" id="SPELLING_ERROR_5"&gt;UAT&lt;/span&gt;, PAYROLL_DEV&lt;br /&gt;&lt;br /&gt;Other information can be added to names are line_of_&lt;span class="blsp-spelling-corrected" id="SPELLING_ERROR_6"&gt;business&lt;/span&gt;, server location etc. but those are changing fast in today's business &lt;span class="blsp-spelling-corrected" id="SPELLING_ERROR_7"&gt;environment&lt;/span&gt;.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-4186745782750444666?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/4186745782750444666/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=4186745782750444666' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/4186745782750444666'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/4186745782750444666'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2007/12/naming-convention-for-sybase-instance.html' title='Naming convention for Sybase instance'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-4615835734685803559</id><published>2007-10-21T10:39:00.000-04:00</published><updated>2007-10-21T10:52:59.414-04:00</updated><title type='text'>new job next Monday</title><content type='html'>Due to office move and long commute time, I have decided to choose my own office.&lt;br /&gt;&lt;br /&gt;Luckily I not only found a place with better office location, but also better position with leadership role required. yesterday was my last day. It's mixed feeling leaving this position as the people there are just terrific. It was great pleasure working with these peoples, especially the management team. They arranged farewell lunch on Thursday and just before I left office yesterday, the DBA team got together. Representing the team, our director gave me a watch and a greeting card donated by the team. &lt;br /&gt;&lt;br /&gt;This is the best place I have ever worked in and best group of people. I will treasure every moment I had with them. I hope my new job will have similar experience for me. I am prepared to do my best in my new job and advance my career quickly as the new place is a bigger environment, which means more opportunities. In the future, I will post things I learned on technical side as well as soft skill side.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-4615835734685803559?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/4615835734685803559/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=4615835734685803559' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/4615835734685803559'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/4615835734685803559'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2007/10/new-job-next-monday.html' title='new job next Monday'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-612911425765315510</id><published>2007-09-06T15:52:00.000-04:00</published><updated>2007-09-06T15:57:57.989-04:00</updated><title type='text'>How to find out the orphaned users</title><content type='html'>As we refresh UAT server with production backup, it's possible that some orphaned users are left on UAT server. Security auditor treated each orphaned user as 1 count of Medium level vulnerability finding. So it's important to delete orphaned users from servers.&lt;br /&gt;&lt;br /&gt;Here is the sql I used to find out orphaned users&lt;br /&gt;&lt;br /&gt;select * from userDbName1..sysusers where suid not in (select suid from master..syslogins) and suid &gt; 0&lt;br /&gt;go&lt;br /&gt;select * from userDbName2..sysusers where suid not in (select suid from master..syslogins) and suid &gt; 0&lt;br /&gt;go&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-612911425765315510?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/612911425765315510/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=612911425765315510' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/612911425765315510'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/612911425765315510'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2007/09/how-to-find-out-orphaned-users.html' title='How to find out the orphaned users'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-6082707747144595552</id><published>2007-08-16T13:45:00.000-04:00</published><updated>2007-08-16T13:51:57.943-04:00</updated><title type='text'>Replication server location</title><content type='html'>Currently we have Sybase Replication residing on Unix server which has primary ASE server, the BRT server is on another unix box.&lt;br /&gt;&lt;br /&gt;The problem with this setup is once the production server is down, the replication server will go down as well. The transaction in stable queue will be lost too.&lt;br /&gt;&lt;br /&gt;The better option if there is no standalone machine for Replication server is to have Sybase replication server sitting on BRT box. This is what I am going to do in the next few weeks. Move the replication server from prod box to BRT box. I have to&lt;br /&gt;&lt;br /&gt;1) move the RSSD db from primary server to secondary server.&lt;br /&gt;2) setup Rep server and stable queues on BRT server.&lt;br /&gt;&lt;br /&gt;I will post the steps required for this migration in another post.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-6082707747144595552?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/6082707747144595552/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=6082707747144595552' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/6082707747144595552'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/6082707747144595552'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2007/08/replication-server-location.html' title='Replication server location'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-6558174257018433517</id><published>2007-08-07T16:31:00.000-04:00</published><updated>2007-08-07T16:36:32.854-04:00</updated><title type='text'>finally found the root cause of a performance problem</title><content type='html'>After I created a few new db on production server, the server become very slow. I have been looking around to find the root cause.&lt;br /&gt;&lt;br /&gt;Finally found the problem last Friday. The problem was not caused by the new dbs. It's caused by the application. The app generated tons of log files in /tmp on the Unix server. Which slowed down the db server. After the files in /tmp were purged, the server is back to normal. As I observed, the server was slow before I implemented the new dbs, but sometime there is some office politics to play....&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-6558174257018433517?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/6558174257018433517/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=6558174257018433517' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/6558174257018433517'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/6558174257018433517'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2007/08/finally-found-root-cause-of-performance.html' title='finally found the root cause of a performance problem'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-1767906268169336677</id><published>2007-08-02T10:32:00.000-04:00</published><updated>2007-08-02T10:52:56.619-04:00</updated><title type='text'>How to change tempdb ownership</title><content type='html'>When I created second tempdb using my own DBA id due to SOX compliance, the db was under my ID. Now I need to change the ownership to sa. Sybase doc says you can change ownership with sp_changedbowner, but that's not right. and Sybase needs to update the doc to avoid too many support calls.&lt;br /&gt;&lt;br /&gt;Here is how to change, I tested it, it works perfectly.&lt;br /&gt;&lt;br /&gt;1&gt;use master&lt;br /&gt;2&gt;go&lt;br /&gt;1&gt;sp_configure 'allow updates', 1&lt;br /&gt;2&gt;go&lt;br /&gt;1&gt;begin tran&lt;br /&gt;2&gt;go&lt;br /&gt;1&gt;update sysdatabases set suid = suser_id("&lt;new&gt;") where name = "&lt;name&gt;"&lt;br /&gt;2&gt;go&lt;br /&gt;1&gt;update &lt;name&gt;..sysusers set suid = suser_id("&lt;new&lt;br /&gt;1&gt;owner's name") where suid=&lt;the&gt;&lt;br /&gt;2&gt;go&lt;br /&gt;1&gt;dbcc dbrepair(&lt;name&gt;, "updowner")&lt;br /&gt;2&gt;go&lt;br /&gt;1&gt;select suid from master..sysdatabases where name = &lt;name of your&lt;br /&gt;1&gt;tempdb&gt;&lt;br /&gt;2&gt;go&lt;br /&gt;1&gt;select * from &lt;name&gt;..sysusers where name = '&lt;new&gt;'&lt;br /&gt;2&gt;go&lt;br /&gt;1&gt;commit tran&lt;br /&gt;2&gt;go&lt;br /&gt;*****If the data from the selects do not look right, then issue a rollback tran instead of a commit tran&lt;br /&gt;1&gt;sp_configure 'allow updates', 0&lt;br /&gt;2&gt;go&lt;br /&gt;By running the dbcc dbrepair command you should not have to recycle the ASE.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-1767906268169336677?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/1767906268169336677/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=1767906268169336677' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/1767906268169336677'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/1767906268169336677'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2007/08/how-to-change-tempdb-ownership.html' title='How to change tempdb ownership'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-1639268643294794551</id><published>2007-05-16T11:22:00.000-04:00</published><updated>2007-05-16T11:27:14.492-04:00</updated><title type='text'>create second tempdb</title><content type='html'>steps to follow for creating second tempdb on sybase server&lt;br /&gt;&lt;br /&gt;- create data and log devices using disk init&lt;br /&gt;- turn off dsync on both devices&lt;br /&gt;   sp_deviceattr tempdb_report_data, dsync, false&lt;br /&gt;   go&lt;br /&gt;   sp_deviceattr tempdb_report_log, dsync, false&lt;br /&gt;  go&lt;br /&gt;- create second tempdb&lt;br /&gt;  create temporary database tempdb_report&lt;br /&gt;  on tempdb_report_data = 2000&lt;br /&gt;  log on tempdb_report_log = 500&lt;br /&gt;  go&lt;br /&gt;- make the second tempdb the first user db to be recovered.&lt;br /&gt;  sp_dbrecovery_order tempdb_report, 1&lt;br /&gt;   go&lt;br /&gt;  sp_tempdb 'bind', 'lg', loginname, 'db', 'tempdb_report'&lt;br /&gt;  go&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-1639268643294794551?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/1639268643294794551/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=1639268643294794551' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/1639268643294794551'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/1639268643294794551'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2007/05/create-second-tempdb.html' title='create second tempdb'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-1110539837525115669</id><published>2007-05-07T15:52:00.000-04:00</published><updated>2007-05-07T16:28:47.180-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ASE'/><title type='text'>extend dbccdb</title><content type='html'>After a user database was expanded, the space requirement for dbccdb will be different. More space is required. To expand dbccdb, I will follow the steps as below.&lt;br /&gt;&lt;br /&gt;use master&lt;br /&gt;go&lt;br /&gt;disk init (or resize an existing device)&lt;br /&gt;go&lt;br /&gt;alter database dbccdb on newdevice = xxx&lt;br /&gt;go&lt;br /&gt;use dbccdb&lt;br /&gt;go&lt;br /&gt;sp_extendsegment scanseg, dbccdb, newdevice&lt;br /&gt;go&lt;br /&gt;sp_extendsegment textseg, dbccdb, newdevice&lt;br /&gt;go&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-1110539837525115669?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/1110539837525115669/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=1110539837525115669' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/1110539837525115669'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/1110539837525115669'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2007/05/extend-dbccdb.html' title='extend dbccdb'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-833879319878189264</id><published>2007-04-05T09:52:00.000-04:00</published><updated>2007-04-05T09:56:25.007-04:00</updated><title type='text'>ssh to remote host without password</title><content type='html'>I found I lost my posts when I migrated my blog from xingstech.com to this free blog. Here is one I was looking this morning. steps used to setup ssh to remote host without password&lt;br /&gt;&lt;br /&gt;How to ssh from Host1 to Host2 without password&lt;br /&gt;&lt;br /&gt;on host1&lt;br /&gt; - ssh host2&lt;br /&gt;   answer yes, then provide password&lt;br /&gt;&lt;br /&gt;- Once get on host2,&lt;br /&gt;  cd $HOME&lt;br /&gt;  mkdir .ssh&lt;br /&gt;  cd .ssh&lt;br /&gt;  scp host1:$HOME/.ssh/id_dsa.pub authorized_keys&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-833879319878189264?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/833879319878189264/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=833879319878189264' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/833879319878189264'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/833879319878189264'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2007/04/ssh-to-remote-host-without-password.html' title='ssh to remote host without password'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-4934318962112193991</id><published>2007-03-27T14:53:00.000-04:00</published><updated>2007-03-27T14:54:28.513-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ASE'/><title type='text'>turn off dsync for tempdb device</title><content type='html'>sp_deviceattr &lt;devname&gt;,dsync,false&lt;br /&gt;go&lt;br /&gt;&lt;br /&gt;reboot server&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-4934318962112193991?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/4934318962112193991/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=4934318962112193991' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/4934318962112193991'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/4934318962112193991'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2007/03/turn-off-dsync-for-tempdb-device.html' title='turn off dsync for tempdb device'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-6420053124238835207</id><published>2007-03-27T14:45:00.000-04:00</published><updated>2007-03-27T14:46:59.520-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ASE'/><title type='text'>How to move tempdb off from master device</title><content type='html'>To drop the master device from the segments:&lt;br /&gt;&lt;br /&gt;Alter tempdb onto another device, if you have not already done so. For example:alter database tempdb on tune3 = 20&lt;br /&gt;Issue a use tempdb command, and then drop the master device from the segments:&lt;br /&gt;&lt;br /&gt;sp_dropsegment "default", tempdb, master&lt;br /&gt;sp_dropdegment system, tempdb, master&lt;br /&gt;sp_dropdegment logsegment, tempdb, master&lt;br /&gt;&lt;br /&gt;To verify that the default segment no longer includes the master device, issue this command:&lt;br /&gt;&lt;br /&gt;select dbid, name, segmap&lt;br /&gt;from sysusages, sysdevices&lt;br /&gt;where sysdevices.low &lt;= sysusages.size + vstart&lt;br /&gt;and sysdevices.high &gt;= sysusages.size + vstart -1&lt;br /&gt;and dbid = 2&lt;br /&gt;and (status = 2 or status = 3)&lt;br /&gt;&lt;br /&gt;The segmap column should report "1" for any allocations on the master device, indicating that only the system segment still uses the device: dbid name segmap&lt;br /&gt;------ --------------- -----------&lt;br /&gt;2 master 1&lt;br /&gt;2 tune3 7&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-6420053124238835207?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/6420053124238835207/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=6420053124238835207' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/6420053124238835207'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/6420053124238835207'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2007/03/how-to-move-tempdb-off-from-master.html' title='How to move tempdb off from master device'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-4168986900458582856</id><published>2007-03-27T14:38:00.000-04:00</published><updated>2007-03-27T14:41:14.023-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ASE'/><title type='text'>How to separate data and log segment</title><content type='html'>1. use disk init to create the new log device for your database&lt;br /&gt;&lt;br /&gt;2. dump tran &lt;databasename&gt; with truncate_only- to make sure we clear the log&lt;br /&gt;&lt;br /&gt;3. use sp_logdevice to move the log to the new device&lt;br /&gt;- sp_logdevice &lt;dbname&gt;, &lt;new&gt;&lt;br /&gt;- this will change the sgmaps of 7 to 3 and move the log to the new device which has a segmap of 4&lt;br /&gt;&lt;br /&gt;4. dump tran &lt;databasename&gt; with truncate_only- to make sure we clear any log that might remain on the data device&lt;br /&gt;&lt;br /&gt;5. use sp_helplog to make sure that the log starts on the log device&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-4168986900458582856?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/4168986900458582856/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=4168986900458582856' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/4168986900458582856'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/4168986900458582856'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2007/03/how-to-separate-data-and-log-segment.html' title='How to separate data and log segment'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-2943511395313605299</id><published>2007-03-22T13:15:00.000-04:00</published><updated>2007-03-22T13:17:11.513-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Replication'/><title type='text'>Sybase replication server performance tuning docs</title><content type='html'>Found a tunning guide on sybase web site. Though it's out of date, but still useful for the most part.&lt;br /&gt;&lt;a href="http://www.sybase.com/content/1015811/ReplicationServerPNTv1_4.pdf"&gt;http://www.sybase.com/content/1015811/ReplicationServerPNTv1_4.pdf&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-2943511395313605299?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/2943511395313605299/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=2943511395313605299' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/2943511395313605299'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/2943511395313605299'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2007/03/sybase-replication-server-performance.html' title='Sybase replication server performance tuning docs'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-3305007458028446617</id><published>2007-03-07T10:56:00.000-05:00</published><updated>2007-03-07T11:01:55.835-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ASE'/><title type='text'>What's the best way to setup dbccdb?</title><content type='html'>dbccdb is used to run dbcc checkstorage. Setting up dbccdb is time consuming. Once it's setup on one server, it can be copied to another server with similar configuration. In my case, I setup dbccdb on UAT server, it can be copied to UATBRT server via dump and load method. This is much easier and faster way to get dbccdb setup. Please note this is for servers with similar configuration and setup.&lt;br /&gt;For servers with different configuration, you have to follow the procedures outlined in sybase system admin docs.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-3305007458028446617?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/3305007458028446617/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=3305007458028446617' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/3305007458028446617'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/3305007458028446617'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2007/03/whats-best-way-to-setup-dbccdb.html' title='What&apos;s the best way to setup dbccdb?'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-3802810216487204919</id><published>2007-03-01T14:25:00.000-05:00</published><updated>2007-03-01T14:33:23.860-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Replication'/><title type='text'>How to find out tables missing primary key</title><content type='html'>Before setup replication server, I need to find out which table is missing primary key. I used following query to find out&lt;br /&gt;&lt;br /&gt;use dbname&lt;br /&gt;go&lt;br /&gt;select name&lt;br /&gt;from sysobjects&lt;br /&gt;where id not in (select id from syskeys where type = 1)&lt;br /&gt;and type = 'U'&lt;br /&gt;go&lt;br /&gt;&lt;br /&gt;So many tables are missing primary key, then I try to reduce the list by checking if they have unique index using following query&lt;br /&gt;&lt;br /&gt;select o.name&lt;br /&gt;from sysobjects o&lt;br /&gt;where o.id not in (select id from syskeys where type = 1)&lt;br /&gt;and o.type = 'U'&lt;br /&gt;and o.id not in (select id from sysindexes where status &amp; 2 = 2 )&lt;br /&gt;order by o.name&lt;br /&gt;&lt;br /&gt;the list of tables is reduced to half about 76. Then I further reduce the list by checking the size of each table.&lt;br /&gt;&lt;br /&gt;select distinct o.name, rowcnt(i.ioampg)  &lt;br /&gt;from sysobjects o, sysindexes i  &lt;br /&gt;where o.id not in (select id from syskeys where type = 1)  &lt;br /&gt;and o.type = 'U'  &lt;br /&gt;and o.id not in (select id from sysindexes where status &amp; 2 = 2 )&lt;br /&gt;and o.id = i.id&lt;br /&gt;order by rowcnt(i.ioampg)&lt;br /&gt;go&lt;br /&gt;&lt;br /&gt;Take out all the empty tables. Now the list is short and I can work on the few tables (adding PK etc).&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-3802810216487204919?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/3802810216487204919/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=3802810216487204919' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/3802810216487204919'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/3802810216487204919'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2007/03/how-to-find-out-tables-missing-primary.html' title='How to find out tables missing primary key'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-1157964628373291522</id><published>2007-02-22T13:58:00.001-05:00</published><updated>2007-02-22T13:58:41.239-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Replication'/><title type='text'>what if logsegment is full because of replication</title><content type='html'>It’s very frustrating when this happens. you can not dump transaction because the sendary truncation point from replication. the dump tran command works but logsegment is still full. Then you can not disable the replication, because the log is almost full. Below is the steps to handle this situation&lt;br /&gt;&lt;br /&gt;1) sp_stop_rep_agent dbname&lt;br /&gt;2) dbcc settrunc(ltm,ignore)&lt;br /&gt;3) dump tran dbname -or-&lt;br /&gt;dump tran dbname with truncate_only&lt;br /&gt;4) (in the rssd): rs_zeroltm dsname, dbanme&lt;br /&gt;afterward, we have to resync the databases.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-1157964628373291522?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/1157964628373291522/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=1157964628373291522' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/1157964628373291522'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/1157964628373291522'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2007/02/what-if-logsegment-is-full-because-of.html' title='what if logsegment is full because of replication'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-7785913563683529922</id><published>2007-02-22T13:56:00.000-05:00</published><updated>2007-02-22T13:57:36.414-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ASE'/><title type='text'>How to see the sql running on ASE</title><content type='html'>In Oracle, there is nice feature that we can see the top sql statement running. In Sybase, it’s not easy. But there is work around. searching sybase support site, there seems a few way to do this. The most practical ways are&lt;br /&gt;&lt;br /&gt;1) run dbcc traceon(3605), dbcc pss(0, spid, 0), dbcc traceoff(3605)&lt;br /&gt;&lt;br /&gt;2) run dbcc traceon(3604), dbcc sqltext(spid), dbcc traceoff(3604), the limitation of this is there is 400 byte limitation.&lt;br /&gt;&lt;br /&gt;Other options are 1) monitoring server, which requires extra setup 2) third party tool, which requires extra dollar. They are not possible at my site.&lt;br /&gt;&lt;br /&gt;I will look into writing a perl script for this when I have time.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-7785913563683529922?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/7785913563683529922/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=7785913563683529922' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/7785913563683529922'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/7785913563683529922'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2007/02/how-to-see-sql-running-on-ase.html' title='How to see the sql running on ASE'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-2385190210130087078</id><published>2007-02-22T13:55:00.002-05:00</published><updated>2007-02-22T13:56:37.684-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Replication'/><title type='text'>What to do when Sybase stable queue filled up?</title><content type='html'>Last night, the stable queue of one of  Sybase replication server was filled up very quickly. I was able to disabled the replication for a few db before the sq was completly full. To summarize, here are the things I will do next time.&lt;br /&gt;&lt;br /&gt;1. take a snapshot of both Primary server and BRT server (sysprocesses, syslock, sp_who, syslogshold)&lt;br /&gt;&lt;br /&gt;2. Rep Server: admin disk_space to check space usage in sq&lt;br /&gt;&lt;br /&gt;3. Disable replication on ASE: sp_stop_rep_agent dbname, then sp_config_rep_agent dbname, ‘disable’&lt;br /&gt;&lt;br /&gt;To prevend this from happenning again, we need to add repdef, patch Rep Server with newer EBF, enhance our monitoring to find out the problem earlier.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-2385190210130087078?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/2385190210130087078/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=2385190210130087078' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/2385190210130087078'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/2385190210130087078'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2007/02/what-to-do-when-sybase-stable-queue.html' title='What to do when Sybase stable queue filled up?'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-6453172532009871059</id><published>2007-02-22T13:55:00.001-05:00</published><updated>2007-02-22T13:55:50.345-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='LifeStyle'/><title type='text'>SAIC - California</title><content type='html'>I noticed there is a reader from SAIC california. That reminded me my time in California a few years ago.&lt;br /&gt;&lt;br /&gt;I went to California during the dot com boom. Instead of going to SF, I went to LA instead. I worked as DBA consultant for Arco in downtown LA, a well known oil company in California. The company was sold to BP (at the wrong time I guess). And BP decided to outsource the whole IT to SAIC. So I was helping them make the transition and worked for SAIC for short term of period. Once mission was completed, then it’s 911, the US market was stalled. I left California and came back to Canada for a full time job as DBA team lead in a health care organization. I still miss the good time I had in California. one of the best place in the world.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-6453172532009871059?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/6453172532009871059/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=6453172532009871059' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/6453172532009871059'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/6453172532009871059'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2007/02/saic-california.html' title='SAIC - California'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-1486287179253127385</id><published>2007-02-22T13:54:00.001-05:00</published><updated>2007-02-22T13:54:46.156-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ASE'/><title type='text'>Sybase backup performance</title><content type='html'>To improve Sybase backup performance, there are a few ways&lt;br /&gt;&lt;br /&gt;1. test different -m value in backup server RUN file.&lt;br /&gt;2. use stripe, the best is to stripe to different disks.&lt;br /&gt;3. dump to disk, instead of tape,&lt;br /&gt;4. use local backup server, instead of remote backup server.&lt;br /&gt;5. don’t use compression&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-1486287179253127385?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/1486287179253127385/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=1486287179253127385' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/1486287179253127385'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/1486287179253127385'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2007/02/sybase-backup-performance.html' title='Sybase backup performance'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-690774011357309284</id><published>2007-02-22T13:53:00.000-05:00</published><updated>2007-02-22T13:54:13.673-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ASE'/><title type='text'>Sybase 15 upgrade over last weekend</title><content type='html'>Over the weekend, I upgraded one of our production server from Sybase 12.5.0.3 to Sybase 15.0 ESD #2.&lt;br /&gt;&lt;br /&gt;The upgrade was successful, though there were a scary situation happened. What I learned from this upgrade&lt;br /&gt;&lt;br /&gt;1), never trust a script to do the db backup. DBA needs to manually create the script and run the script, create a separate directory to store the backup.&lt;br /&gt;&lt;br /&gt;2), sybsecurity upgrade was not successful. I had to reinstall them from scratch. System tables are changed in Sybase 15.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-690774011357309284?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/690774011357309284/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=690774011357309284' title='9 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/690774011357309284'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/690774011357309284'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2007/02/sybase-15-upgrade-over-last-weekend.html' title='Sybase 15 upgrade over last weekend'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>9</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-8653057887928652290</id><published>2007-02-22T13:51:00.000-05:00</published><updated>2007-02-22T13:53:24.383-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='General'/><title type='text'>What is SOX compliance</title><content type='html'>I have been diligently working on SOX related issues for all the sybase servers in my company. What is really SOX compliance? why it’s named SOX.&lt;br /&gt;&lt;br /&gt;Here is what I got from wiki (&lt;a href="http://en.wikipedia.org/wiki/Sarbanes-Oxley_Act"&gt;http://en.wikipedia.org/wiki/Sarbanes-Oxley_Act&lt;/a&gt;)&lt;br /&gt;&lt;br /&gt;The Sarbanes–Oxley Act of 2002 (Pub. L. No. 107-204, 116 Stat. 745, also known as the Public Company Accounting Reform and Investor Protection Act of 2002 and commonly called SOX or Sarbox; July 30, 2002) is a &lt;a title="United States federal law" href="http://xingstech.com/wiki/United_States_federal_law"&gt;United States federal law&lt;/a&gt; passed in response to a number of major &lt;a title="Accounting scandals" href="http://xingstech.com/wiki/Accounting_scandals"&gt;corporate and accounting scandals&lt;/a&gt; including those affecting &lt;a title="Enron" href="http://xingstech.com/wiki/Enron"&gt;Enron&lt;/a&gt;, &lt;a title="Tyco International" href="http://xingstech.com/wiki/Tyco_International"&gt;Tyco International&lt;/a&gt;, &lt;a title="Peregrine Systems" href="http://xingstech.com/wiki/Peregrine_Systems"&gt;Peregrine Systems&lt;/a&gt; and WorldCom (recently &lt;a title="MCI WorldCom" href="http://xingstech.com/wiki/MCI_WorldCom"&gt;MCI and currently now part of Verizon Businesses&lt;/a&gt;). These scandals resulted in a decline of public trust in &lt;a title="Accounting" href="http://xingstech.com/wiki/Accounting"&gt;accounting&lt;/a&gt; and reporting practices. Named after sponsors Senator &lt;a title="Paul Sarbanes" href="http://xingstech.com/wiki/Paul_Sarbanes"&gt;Paul Sarbanes&lt;/a&gt; (&lt;a title="Democratic Party (United States)" href="http://xingstech.com/wiki/Democratic_Party_(United_States)"&gt;D&lt;/a&gt;–&lt;a title="Maryland" href="http://xingstech.com/wiki/Maryland"&gt;Md.&lt;/a&gt;) and Representative &lt;a title="Michael G. Oxley" href="http://xingstech.com/wiki/Michael_G._Oxley"&gt;Michael G. Oxley&lt;/a&gt; (&lt;a title="Republican Party (United States)" href="http://xingstech.com/wiki/Republican_Party_(United_States)"&gt;R&lt;/a&gt;–&lt;a title="Ohio" href="http://xingstech.com/wiki/Ohio"&gt;Oh.&lt;/a&gt;), the Act was approved by the &lt;a title="United States House of Representatives" href="http://xingstech.com/wiki/United_States_House_of_Representatives"&gt;House&lt;/a&gt; by a vote of &lt;a class="external text" title="http://clerk.house.gov/cgi-bin/vote.asp?year=" rollnumber="348" href="http://clerk.house.gov/cgi-bin/vote.asp?year=2002&amp;amp;rollnumber=348"&gt;423-3&lt;/a&gt; and by the &lt;a title="United States Senate" href="http://xingstech.com/wiki/United_States_Senate"&gt;Senate&lt;/a&gt; &lt;a class="external text" title="http://www.senate.gov/legislative/LIS/roll_call_lists/roll_call_vote_cfm.cfm?congress=" session="2&amp;amp;vote=" href="http://www.senate.gov/legislative/LIS/roll_call_lists/roll_call_vote_cfm.cfm?congress=107&amp;session=2&amp;amp;vote=00192"&gt;99-0&lt;/a&gt;. The legislation is wide ranging and establishes new or enhanced standards for all U.S. &lt;a title="Public company" href="http://xingstech.com/wiki/Public_company"&gt;public company&lt;/a&gt; boards, management, and public accounting firms. The Act contains 11 titles, or sections, ranging from additional Corporate Board responsibilities to criminal penalties, and requires the &lt;a title="Securities and Exchange Commission" href="http://xingstech.com/wiki/Securities_and_Exchange_Commission"&gt;Securities and Exchange Commission&lt;/a&gt; (SEC) to implement rulings on requirements to comply with the new law. Some believe the legislation was necessary and useful, others believe it does more economic damage than it prevents, and yet others observe how essentially modest the Act is compared to the heavy rhetoric accompanying it.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-8653057887928652290?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/8653057887928652290/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=8653057887928652290' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/8653057887928652290'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/8653057887928652290'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2007/02/what-is-sox-compliance.html' title='What is SOX compliance'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-8432636468638082442</id><published>2007-02-22T13:49:00.000-05:00</published><updated>2007-02-22T13:50:57.731-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='LifeStyle'/><title type='text'>Holiday</title><content type='html'>It has been busy for the last few weeks. especially for the weekend. we have too many tasks. Finally it slow down this week as Christmas is coming. This is another week of system freeze.&lt;br /&gt;&lt;br /&gt;I also bought a new laptop for myself. Time to enjoy a bit. By the way, Yearly Bonus is coming this week. That’s extra sweet!&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-8432636468638082442?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/8432636468638082442/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=8432636468638082442' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/8432636468638082442'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/8432636468638082442'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2007/02/holiday.html' title='Holiday'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-6431748129838739239</id><published>2007-02-21T16:35:00.000-05:00</published><updated>2007-02-21T16:36:14.831-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ASE'/><title type='text'>Sybase row level locking</title><content type='html'>Last Friday night, I implemented row level locking on one of our critical stock trading system. As result, the deadlocking issue is greatly reduced. so far we have not seen any after the implementation. The command used is as follow&lt;br /&gt;&lt;br /&gt;alter table TableName lock datarows&lt;br /&gt;&lt;br /&gt;Of course, I used a shell script to run against every table in the database, after that drop and recreate triggers with ”if update(column)” clause.&lt;br /&gt;&lt;br /&gt;I also bumped up default data cache, large I/O and number of locks. Everything looks good so far. Need to monitor it for one more week to get a weekly report.&lt;br /&gt;&lt;br /&gt;An interesting finding from this promotion is that the Replication Server seems has a bug, even after the I changed maintainence user’s password, it couldn’t pick up the new password and kept complaining about the login failure. A Rep server recycle solved the problem.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-6431748129838739239?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/6431748129838739239/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=6431748129838739239' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/6431748129838739239'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/6431748129838739239'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2007/02/sybase-row-level-locking.html' title='Sybase row level locking'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-6071749562330977835</id><published>2007-02-21T16:34:00.000-05:00</published><updated>2007-02-21T16:35:35.457-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Unix'/><title type='text'>setfile - File access control command</title><content type='html'>Today we had a case that smurf account needs to read our sybase audit log files. The smurf account is not a member of Sybase group, so to make our sybase files readable by smurf account, In the old days, we can either create a new group, then put smurf and sybase account in to same group, then grant read acess to group member, or add sybase account to the smurf group. Both option requires some level of extra work or security concern.&lt;br /&gt;A nice new feature from Solaris new version is the file access control. I used “setfacl” to grant the read access to smurf account without doing anything else. the command is&lt;br /&gt;&lt;br /&gt;setfacl -m user:smurf:r– FileName&lt;br /&gt;&lt;br /&gt;use getfacl FileName to display the status.&lt;br /&gt;&lt;br /&gt;a nice new feature from Solaris is the file access control.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-6071749562330977835?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/6071749562330977835/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=6071749562330977835' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/6071749562330977835'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/6071749562330977835'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2007/02/setfile-file-access-control-command.html' title='setfile - File access control command'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-2860623553860066136</id><published>2007-02-21T16:31:00.000-05:00</published><updated>2007-02-21T16:34:21.196-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ASE'/><title type='text'>How to drop Sybase xp_cmdshell</title><content type='html'>It’s long weekend here, well, another day, another trick learned. Sybase has xp_cmdshell extended stored procedure. This procedure is a security concern, as power user can use this procedure to call OS commands under the security context of the service sybase runs under. What can I do to remove the procedure, I did a lot of research on this, couldn’t find anythng on the web. Some of the information on the web are already out of date, as they assume the xp_cmdsell is still in master db. In Sybase 12.5, the xp_cmdshell is in sybsystemprocs. but the sp_dropextendedproc requires the user to be in master db.&lt;br /&gt;&lt;br /&gt;1&gt; use sybsystemprocs&lt;br /&gt;2&gt; go&lt;br /&gt;1&gt; exec sp_dropextendedproc xp_cmdshell&lt;br /&gt;2&gt; go&lt;br /&gt;Msg 18388, Level 16, State 1:Server ‘TESTServer’, Procedure ’sp_dropextendedproc’, Line 23:You must be in the master database in order to run ’sp_dropextendedproc’.&lt;br /&gt;(return status = 1)&lt;br /&gt;1&gt; use master&lt;br /&gt;2&gt; go&lt;br /&gt;1&gt; sp_dropextendedproc xp_cmdshell&lt;br /&gt;2&gt; go&lt;br /&gt;Msg 3701, Level 11, State 1:Server ‘TESTServer’, Line 1:Cannot drop the procedure ‘xp_cmdshell’, because it doesn’t exist in the systemcatalogs.&lt;br /&gt;Msg 18389, Level 16, State 1:Server ‘TOR_GSF_UAT’, Procedure ’sp_dropextendedproc’, Line 66:sp_dropextendedproc failed. Check the SQL Server error log file.&lt;br /&gt;(return status = 1)&lt;br /&gt;&lt;br /&gt;finally I figured out I can do it this way&lt;br /&gt;1&gt; use sybsystemprocs&lt;br /&gt;2&gt; go&lt;br /&gt;1&gt; select name from sysobjects where type = ‘XP’&lt;br /&gt;2&gt; go&lt;br /&gt;name&lt;br /&gt;——————————&lt;br /&gt;xp_cmdshell&lt;br /&gt;xp_freedll&lt;br /&gt;(2 rows affected)&lt;br /&gt;&lt;br /&gt;1&gt; dbcc dropextendedproc(xp_cmdshell)&lt;br /&gt;2&gt; go&lt;br /&gt;1&gt; select name from sysobjects where type = ‘XP’&lt;br /&gt;2&gt; go&lt;br /&gt;name&lt;br /&gt;——————————&lt;br /&gt;xp_freedll&lt;br /&gt;(1 row affected)&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-2860623553860066136?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/2860623553860066136/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=2860623553860066136' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/2860623553860066136'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/2860623553860066136'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2007/02/how-to-drop-sybase-xpcmdshell.html' title='How to drop Sybase xp_cmdshell'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-629110798157069069</id><published>2007-02-21T16:29:00.000-05:00</published><updated>2007-02-21T16:30:50.554-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Unix'/><title type='text'>Unix ENV variable - save some typing work</title><content type='html'>Today I found a new trick, that when I setup ENV=~/.kshrc;export ENV in $HOME/.profile on Solaris, when I type ksh, the .kshrc gets automatically sourced.&lt;br /&gt;&lt;br /&gt;If I don’t have ENV setup in .profile, I have to run “ksh” first, then ”. .kshrc” to source the file.&lt;br /&gt;&lt;br /&gt;It saved a few typing each time I get on the server.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-629110798157069069?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/629110798157069069/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=629110798157069069' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/629110798157069069'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/629110798157069069'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2007/02/unix-env-variable-save-some-typing-work.html' title='Unix ENV variable - save some typing work'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-2048559669152746709</id><published>2007-02-21T16:28:00.000-05:00</published><updated>2007-02-21T16:29:09.283-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Unix'/><title type='text'>Copy directory to another machine using scp</title><content type='html'>On solaris 10, scp is recommended, to copy a directory, I used following command&lt;br /&gt;&lt;br /&gt;scp -r localfile RemotedBox:/xxxx/yyyy/&lt;br /&gt;&lt;br /&gt;I was surprised that our Unix admin didn’t know the option and he had to search google.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-2048559669152746709?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/2048559669152746709/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=2048559669152746709' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/2048559669152746709'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/2048559669152746709'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2007/02/copy-directory-to-another-machine-using.html' title='Copy directory to another machine using scp'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-4531828434639304275</id><published>2007-02-21T16:27:00.000-05:00</published><updated>2007-02-21T16:28:16.022-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Unix'/><title type='text'>How to delete file named "-l" on Unix box</title><content type='html'>By accident, I created a huge file named “-I” on a critical production file system and made space usage 100% full. In very short time, I tried all the options I knew to delete it before I found the right way.&lt;br /&gt;&lt;br /&gt;rm -I&lt;br /&gt;rm “-I”&lt;br /&gt;rm ‘-I’&lt;br /&gt;rm ‘\-I’&lt;br /&gt;rm \-I&lt;br /&gt;&lt;br /&gt;the last one works, the right way to delete it is “rm ./-I”.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-4531828434639304275?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/4531828434639304275/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=4531828434639304275' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/4531828434639304275'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/4531828434639304275'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2007/02/how-to-delete-file-named-l-on-unix-box.html' title='How to delete file named &quot;-l&quot; on Unix box'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-514246861412774600</id><published>2007-02-21T16:26:00.000-05:00</published><updated>2007-02-21T16:27:14.392-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ASE'/><title type='text'>What's next available device number?</title><content type='html'>In the old version (before 12.5), whenever we need to create a new device, we have to calculate the next availabe device number. The way to do it is run&lt;br /&gt;&lt;br /&gt;select max(low/16777216) from sysdevices&lt;br /&gt;&lt;br /&gt;then use the number + 1 as next available device number. and make sure sp_configure ‘nubmer of device’ is higer enough. In Sybase 12.5, device no is no longer required, sybase will automatically pick the next available number for any new device. Nice feature for DBA.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-514246861412774600?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/514246861412774600/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=514246861412774600' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/514246861412774600'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/514246861412774600'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2007/02/whats-next-available-device-number.html' title='What&apos;s next available device number?'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-2213707650648628918</id><published>2007-02-21T16:25:00.000-05:00</published><updated>2007-02-21T16:26:02.185-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ASE'/><title type='text'>refresh UAT server from production server</title><content type='html'>One of the tasks I do very often is to refresh our UAT server with production db dump. In addition to dump and load the user db, there are some additional things I have to copy it over.&lt;br /&gt;&lt;br /&gt;master..syslogins&lt;br /&gt;master..sysloginroles&lt;br /&gt;master..syssrvroles - the srid maps to id in userdb..sysroles&lt;br /&gt;&lt;br /&gt;There are some other system tables, ie. sysremotelogins etc.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-2213707650648628918?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/2213707650648628918/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=2213707650648628918' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/2213707650648628918'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/2213707650648628918'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2007/02/refresh-uat-server-from-production.html' title='refresh UAT server from production server'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-44053230078688512</id><published>2007-02-21T16:24:00.001-05:00</published><updated>2007-02-21T16:24:57.516-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ASE'/><title type='text'>How to see if a process is still running</title><content type='html'>Once a process is started, we have no way to know if it’s doing anything. Sometimes, people are concerned that it’s hanging. A work around is to check the I/O counter value for the running process in sysprocesses table.&lt;br /&gt;&lt;br /&gt;select physical_io from master..sysprocesses where spid = MYID&lt;br /&gt;&lt;br /&gt;wait a second, then run again. If the second result is higher, that means it’s doing something.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-44053230078688512?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/44053230078688512/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=44053230078688512' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/44053230078688512'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/44053230078688512'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2007/02/how-to-see-if-process-is-still-running.html' title='How to see if a process is still running'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-6286106618227858242</id><published>2007-02-21T16:23:00.000-05:00</published><updated>2007-02-21T16:24:00.937-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Unix'/><title type='text'>change all files' group to sybase</title><content type='html'>I found some of the files in sybase directory are under group name not sybase. To change every file to sybase. I issued command&lt;br /&gt;&lt;br /&gt;cd $SYBASE&lt;br /&gt;find . -exec chgrp sybase {} \;&lt;br /&gt;&lt;br /&gt;This changed all files under $SYBASE and sub-directory to group sybase&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-6286106618227858242?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/6286106618227858242/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=6286106618227858242' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/6286106618227858242'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/6286106618227858242'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2007/02/change-all-files-group-to-sybase.html' title='change all files&apos; group to sybase'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-7248557808222698306</id><published>2007-02-21T16:21:00.000-05:00</published><updated>2007-02-21T16:22:50.959-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ASE'/><title type='text'>How to delete all those sybase cfg files</title><content type='html'>Sybase configuration file is not used properly when Sybase auditing is enabled. every time sybase switches audit trail, it creates a new cfg file. In case there are lots of activities on the server, this could be very messy in the cfg directory.&lt;br /&gt;&lt;br /&gt;What I did is to setup a cronjob to archive the cfg files to backup directory, this will keep the Sybase binary directory clean.&lt;br /&gt;&lt;br /&gt;00 01 * * * find &lt;$SYBASE/$SYBASE_ASE -name ‘$DSQUERY.[0-9][0-9][0-9]’ -exec mv {} backupDirectory \;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-7248557808222698306?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/7248557808222698306/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=7248557808222698306' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/7248557808222698306'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/7248557808222698306'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2007/02/how-to-delete-all-those-sybase-cfg.html' title='How to delete all those sybase cfg files'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-2309247026157790662</id><published>2007-02-21T16:20:00.000-05:00</published><updated>2007-02-21T16:21:34.265-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ASE'/><title type='text'>How to increase the size of existing device</title><content type='html'>Sybase 12.5 has a nice new feature to expand the size of existing device. In the past, the only way to add space to a database is to create a new device, then expand db on the new device. Now we have anther option. Below is the usage&lt;br /&gt;&lt;br /&gt;disk init&lt;br /&gt;name = ‘existingDevice’,&lt;br /&gt;size = ‘additionalM’&lt;br /&gt;Please note, this is to add space to exisiting device. i.e the device is 100M, the following command will make the device 500M&lt;br /&gt;&lt;br /&gt;disk resize name = testDev, size = “400M”&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-2309247026157790662?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/2309247026157790662/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=2309247026157790662' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/2309247026157790662'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/2309247026157790662'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2007/02/how-to-increase-size-of-existing-device.html' title='How to increase the size of existing device'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-6433529086640081162</id><published>2007-02-21T16:19:00.002-05:00</published><updated>2007-02-21T16:20:29.746-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='HighAvailability'/><title type='text'>How to recycle Sybase ASE without failover</title><content type='html'>Our Sybase ASE server is built on VCS, the method to recycle Sybase Server with failover is as follow&lt;br /&gt;Method 1:&lt;br /&gt;disable the automatic failover for the resource as root,&lt;br /&gt;shutdown the sybase server, shutdown or shutdown with nowait&lt;br /&gt;startup sybase server&lt;br /&gt;enable the automatic failover for the resource&lt;br /&gt;Method 2&lt;br /&gt;hares -offline xxxx -sys yyybox&lt;br /&gt;wait until the sybase server is down completely&lt;br /&gt;do ps -ef  grep sybase to make sure all dataserver are down&lt;br /&gt;hares -online  -sys  ( to startup sybase server and mark resource as online)&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-6433529086640081162?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/6433529086640081162/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=6433529086640081162' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/6433529086640081162'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/6433529086640081162'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2007/02/how-to-recycle-sybase-ase-without.html' title='How to recycle Sybase ASE without failover'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-2436868439471158594</id><published>2007-02-21T16:19:00.001-05:00</published><updated>2007-02-21T16:19:36.391-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ASE'/><title type='text'>How to setup Sybase auditing</title><content type='html'>have been setting up Sybase auditing across all UAT/production servers. The best way to speed up the auditing is as follow&lt;br /&gt;1. prepare first sql script to backup databases, create devices, create sybsecurity and sybsecurity_archive database, then setup dboptions i.e trun log, select into.&lt;br /&gt;2. telnet to the unix db server, run $SYBASE/$SYBASE_ASE/scripts/installsecurity&lt;br /&gt;3. alter database sybsecurity onto new audit trail device, sp_addaudittable to all new audit trail devices, setup audit options with sp_audit. i.e. sp_audit “all”,”sa_role”,”all”,”on”, then shutdown the server&lt;br /&gt;4. startup the server,&lt;br /&gt;turn on auditing -  sp_configure ‘auditing’, 1&lt;br /&gt;configure auditing - sp_configure ’suspend audit when device full’, 0&lt;br /&gt;create auditing archive table in sybsecurity_archive - select * into sybsecurity_archive..sysaudits from sysaudits_01 where 1=2&lt;br /&gt;create procedure audit_threshold.&lt;br /&gt;sp_addthreshold to sybsecurity&lt;br /&gt;create ArchiveSysaudits procedure in sybsecurity_archive database.&lt;br /&gt;create database dump devices for sybsecurity and sybsecurity_archive db.&lt;br /&gt;5. schedule cronjobs to backup sybsecurity and sybsecurity_archive db daily, purge and archive auditing records. create dump directories for all the dump devices added.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-2436868439471158594?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/2436868439471158594/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=2436868439471158594' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/2436868439471158594'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/2436868439471158594'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2007/02/how-to-setup-sybase-auditing.html' title='How to setup Sybase auditing'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-8612895629513618140</id><published>2007-02-21T16:10:00.001-05:00</published><updated>2007-02-21T16:10:52.957-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Unix'/><title type='text'>How to log everything you did on unix server</title><content type='html'>yesterday I was asked to check file permission of different directories and their  subdirectories by auditors. Apparently, I can not do copy and paste from telnet window to MS word. Unix has a nice command called “script” used for just this purpose. below is the usage.&lt;br /&gt;$script audit.log&lt;br /&gt;ls -lR $SYBASE&lt;br /&gt;ls -lR /sybase_devices/&lt;br /&gt;……&lt;br /&gt;exit&lt;br /&gt;the audit.log will show the commands I typted and their output. All I need is to send the output file to the auditors. It may take weeks for them just to read the files, but that’s their business.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-8612895629513618140?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/8612895629513618140/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=8612895629513618140' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/8612895629513618140'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/8612895629513618140'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2007/02/how-to-log-everything-you-did-on-unix.html' title='How to log everything you did on unix server'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-4944004146364206012</id><published>2007-02-21T16:09:00.001-05:00</published><updated>2007-02-21T16:10:01.428-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Replication'/><title type='text'>How to reset maint user password in Replication Server</title><content type='html'>We have warm standby here, Due to security restriction, DBA is not allowed to know the maint user password, as maint user is an dbo, who have access to everything in the database. below is the steps I used to reset maint user password&lt;br /&gt;1. login to Replication server,&lt;br /&gt;resume connection to BRTserver.dbname&lt;br /&gt;resume connection to PRODserver.dbname&lt;br /&gt;&lt;br /&gt;2. login to BRT ASE server, run “sp_password” to reset maint user password to a new one.&lt;br /&gt;3. Login to PROD ASE server, run “sp_password” to reset maint user password to a new one.&lt;br /&gt;4, login to Replication server,&lt;br /&gt;run “alter connection to BRTserver.dbname set password ”&lt;br /&gt;run “alter connection to PRODserver.dbname set password ”&lt;br /&gt;resume connection to BRTserver.dbname&lt;br /&gt;resume connection to PRODserver.dbname&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-4944004146364206012?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/4944004146364206012/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=4944004146364206012' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/4944004146364206012'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/4944004146364206012'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2007/02/how-to-reset-maint-user-password-in.html' title='How to reset maint user password in Replication Server'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-1746441801517787726</id><published>2007-02-21T16:07:00.000-05:00</published><updated>2007-02-21T16:08:51.161-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='HighAvailability'/><title type='text'>Sybase HA failback procedure</title><content type='html'>below are the steps used to failback Sybase HA server from secondary node to primary node.&lt;br /&gt;-check if failed node has rebooted cleanly(no hardware/OS errors)&lt;br /&gt;-check companion status of Secondary server via sp_companion command. sp_companion should give the companion state as “Secondary Failover”&lt;br /&gt;-To have current primary host release data devices and prepare for failback, exec sp_companion “”, “prepare_failback”&lt;br /&gt;-During the failback /opt/VRTSvcs/bin/hagrp -state should give the value change as&lt;br /&gt;ONLINE-&gt;ONLINE/STOPPING-&gt;OFFLINE or OFFLINE-&gt;PARTIAL/STARTING-&gt;ONLINE&lt;br /&gt;- Once the switch is completed, check the companion state on both Sybase servers, node0 should be “Primary failback”, node1 should be “Secondary failback”&lt;br /&gt;- go to the primary server, issue sp_companion , resume&lt;br /&gt;This will initiate recovery on database failback&lt;br /&gt;- sp_companion , do_advisory, “all”&lt;br /&gt;-Verify companion state on both servers&lt;br /&gt; sp_companion should show “Primary Normal” on node0 and “Secondary Normal” on node1&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-1746441801517787726?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/1746441801517787726/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=1746441801517787726' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/1746441801517787726'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/1746441801517787726'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2007/02/sybase-ha-failback-procedure.html' title='Sybase HA failback procedure'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-8669749542820983343</id><published>2007-02-21T16:04:00.001-05:00</published><updated>2007-02-21T16:06:59.897-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ASE'/><title type='text'>It's tough last night</title><content type='html'>There were three production problem calls last night, I had to wake up to fix the problems as I am primary oncall this week. 1 before mid night, 2 after mid night.&lt;br /&gt;&lt;br /&gt;The first one is a space issue, the second one is the replication server issue, the third one is user connection issue that we run out of user connections, I had to use unix command to kill the database server to reconfigure the server. All were well, but I didn’t get into sleep well after 2am this morning. still managed to get into office on time this morning. Tough job as DBA.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-8669749542820983343?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/8669749542820983343/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=8669749542820983343' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/8669749542820983343'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/8669749542820983343'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2007/02/its-tough-last-night_21.html' title='It&apos;s tough last night'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-1922839999382996415</id><published>2007-02-21T16:04:00.000-05:00</published><updated>2007-02-21T16:06:39.394-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ASE'/><title type='text'>It's tough last night</title><content type='html'>There were three production problem calls last night, I had to wake up to fix the problems as I am primary oncall this week. 1 before mid night, 2 after mid night.&lt;br /&gt;&lt;br /&gt;The first one is a space issue, the second one is the replication server issue, the third one is user connection issue that we run out of user connections, I had to use unix command to kill the database server to reconfigure the server. All were well, but I didn’t get into sleep well after 2am this morning. still managed to get into office on time this morning. Tough job as DBA.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-1922839999382996415?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/1922839999382996415/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=1922839999382996415' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/1922839999382996415'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/1922839999382996415'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2007/02/its-tough-last-night.html' title='It&apos;s tough last night'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-6650543708046652077</id><published>2007-02-21T16:03:00.000-05:00</published><updated>2007-02-21T16:04:25.905-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ASE'/><title type='text'>Why the timestamp is not the date of upgrade?</title><content type='html'>One interesting thing that’s confusing to people is that the timestamp of files changed during patch or upgrade is not the datetime of the day we were making the changes.&lt;br /&gt;&lt;br /&gt;For example, I applied EBF13324 in July for one of our servers. dataserver was replaced, you can find the list of files in the release in EBF13324_Filelist.txt of the tar file. But when you go to the directory and do “ls -l”, you will find the timestamp is “Mar 24″. This has confused our auditors. They asked “did you really applied EBF in July?”&lt;br /&gt;&lt;br /&gt;The reason is that we used Sybase installer to unload the files and the original timestamp was copied over. All the servers with same EBF will have the same timestamp, no matter when it’s applied.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-6650543708046652077?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/6650543708046652077/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=6650543708046652077' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/6650543708046652077'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/6650543708046652077'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2007/02/why-timestamp-is-not-date-of-upgrade.html' title='Why the timestamp is not the date of upgrade?'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-7989997169342694359</id><published>2007-02-21T16:01:00.000-05:00</published><updated>2007-02-21T16:02:50.816-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Scripts'/><title type='text'>ASE server setup: post-server-setup script</title><content type='html'>Tasks to be done after sybase database server is setup.&lt;br /&gt;# Create diskdump directory for all dbs using mkdir&lt;br /&gt;echo “drop data dump device”&lt;br /&gt;echo “setup data dump device for all dbs”&lt;br /&gt;echo “setup log dump device for all dbs”&lt;br /&gt;echo “make backup for all databases”&lt;br /&gt;echo “bcp out important system tables&lt;br /&gt;echo “change ASE configuration”&lt;br /&gt;echo “create threshold action stored proc”&lt;br /&gt;echo “create DBA personal ID”&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-7989997169342694359?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/7989997169342694359/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=7989997169342694359' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/7989997169342694359'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/7989997169342694359'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2007/02/ase-server-setup-post-server-setup.html' title='ASE server setup: post-server-setup script'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-4572097475052645679</id><published>2007-02-21T15:48:00.000-05:00</published><updated>2007-02-21T15:51:32.725-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ASE'/><title type='text'>Sybase ASE15 new features</title><content type='html'>Today I browsed through Sybase ASE 15.0.1 new features. This version was released just a few days ago. Below are some useful new features I found.&lt;br /&gt;&lt;br /&gt;configuration parameter - "startup delay", it controls when repagent is started during the server start. In old version, repagent starts at the same time and printed some error messages in sybase errorlog, saying couldn't call to rep server. This is a nice feature, but the name is little confusing. Why not name it "repagent startup delay"?&lt;br /&gt;&lt;br /&gt;function - isdate(), isnumberic(). which return true/false regarding the input string.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-4572097475052645679?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/4572097475052645679/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=4572097475052645679' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/4572097475052645679'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/4572097475052645679'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2007/02/sybase-ase15-new-features.html' title='Sybase ASE15 new features'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-1023811690017163175</id><published>2007-02-21T15:44:00.000-05:00</published><updated>2007-02-21T15:46:07.520-05:00</updated><title type='text'>check stable queue</title><content type='html'>Over the weekend, I have added all the missing function repdef on one of our Replication server, the stable queue usage was down sharply after the change. To monitor the space usage of stable queue, I wrote a small shell script and schedule it to run once per hour for 1 week.&lt;br /&gt;&lt;br /&gt;isql -Usa -S &lt;&lt;&gt;&gt; stableq.log&lt;br /&gt;`cat pwd`&lt;br /&gt;use RSSD&lt;br /&gt;go&lt;br /&gt;select getdate()&lt;br /&gt;go&lt;br /&gt;rs_helppartition&lt;br /&gt;go&lt;br /&gt;EOF&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-1023811690017163175?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/1023811690017163175/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=1023811690017163175' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/1023811690017163175'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/1023811690017163175'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2007/02/check-stable-queue.html' title='check stable queue'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-6496013704602751882</id><published>2007-02-20T16:28:00.000-05:00</published><updated>2007-02-20T16:32:26.743-05:00</updated><title type='text'>ASE server setup script : pre-setup</title><content type='html'>Due to the large number of servers at the bank, DBA has to setup server quite often. Just like other large database shop, we have server setup standard. Below is the script I just created recently for server setup, Nothing fancy, it's very handy during setup.&lt;br /&gt;&lt;br /&gt;export DSQUERY=&lt;br /&gt;export DISKDUMP='&lt;br /&gt;export DEVICE_DIR=''&lt;br /&gt;export ERRORLOGDIR=''&lt;br /&gt;&lt;br /&gt;###################################################&lt;br /&gt;echo "create Sybase server home directory"&lt;br /&gt;&lt;br /&gt;###################################################&lt;br /&gt;mkdir ${DSQUERY}&lt;br /&gt;&lt;br /&gt;###################################################&lt;br /&gt;echo "creating sybase errorlog directory"&lt;br /&gt;&lt;br /&gt;###################################################&lt;br /&gt;ls -l $ERRORLOGDIRmkdir $ERRORLOGDIR/${DSQUERY}mkdir $ERRORLOGDIR/${DSQUERY}/history&lt;br /&gt;&lt;br /&gt;###################################################&lt;br /&gt;echo "creating sybase dump directory&lt;br /&gt;&lt;br /&gt;###################################################&lt;br /&gt;mkdir $DISKDUMP/${DSQUERY}ls -l $DISKDUMP/${DSQUERY}&lt;br /&gt;&lt;br /&gt;###################################################&lt;br /&gt;echo "check if we have write permission in ${DEVICE_DIR}"###################################################&lt;br /&gt;touch ${DEVICE_DIR}/testfilels -l $${DEVICE_DIR}/testfilerm ${DEVICE_DIR}/testfile&lt;br /&gt;&lt;br /&gt;###################################################&lt;br /&gt;echo "check size of file systems for Sybase Server"&lt;br /&gt;&lt;br /&gt;###################################################&lt;br /&gt;df -k $ERRORLOGDIRdf -k $DISKDUMPdf -k $DEVICE_DIR&lt;br /&gt;&lt;br /&gt;###################################################&lt;br /&gt;echo "check if shared memory is setup"&lt;br /&gt;&lt;br /&gt;###################################################&lt;br /&gt;grep "shmsys:shminfo_shmmax" /etc/system&lt;br /&gt;&lt;br /&gt;###################################################&lt;br /&gt;echo "Next step: setup .kshrc in home directory"&lt;br /&gt;echo "           ftp sybase tar file to local box" #######################################&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-6496013704602751882?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/6496013704602751882/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=6496013704602751882' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/6496013704602751882'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/6496013704602751882'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2007/02/ase-server-setup-script-pre-setup.html' title='ASE server setup script : pre-setup'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-6327237258473774464</id><published>2007-02-20T16:24:00.000-05:00</published><updated>2007-02-20T16:26:33.562-05:00</updated><title type='text'>a script to generate bcp out for all tables</title><content type='html'>As DBA, I was asked to export tables quite often, to speed up the process, also for my own benefit, I wrote a small korn shell script to do the job.&lt;br /&gt;&lt;br /&gt;isql -Usa -P -w 1000 &lt;&gt; bcp.ksh&lt;br /&gt;use&lt;br /&gt;go&lt;br /&gt;set nocount on&lt;br /&gt;select "echo bcping table "+ name+char(10)+ "bcp ..'" + name + "' out '"+name+".bcp' -c -Usa -P -t''"from sysobjectswhere type = 'U'&lt;br /&gt;go&lt;br /&gt;EOF&lt;br /&gt;&lt;br /&gt;#future enhancements are to interactively ask for values of loginId, Password, ServerName, dbName and export location&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-6327237258473774464?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/6327237258473774464/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=6327237258473774464' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/6327237258473774464'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/6327237258473774464'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2007/02/script-to-generate-bcp-out-for-all.html' title='a script to generate bcp out for all tables'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2552934363134993103.post-2030984437467807905</id><published>2007-02-20T16:16:00.000-05:00</published><updated>2007-02-20T16:21:57.972-05:00</updated><title type='text'>Welcome to James' sybase collection</title><content type='html'>Welcome to James Xing’s Sybase DBA blog.&lt;br /&gt;&lt;br /&gt;I am Sr Sybase DBA for one of the largest investment banks in Canada. Among the 100+ sybase servers, some of the systems are very critical, i.e. online banking system, derivative trading system, stock trading system. This site is a collection of my notes and thoughts during my DBA career. Sybase DBA web site is very rare on the internet due to different reasons. I hope this blog can be useful for the Sybase community.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2552934363134993103-2030984437467807905?l=mysybase.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mysybase.blogspot.com/feeds/2030984437467807905/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2552934363134993103&amp;postID=2030984437467807905' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/2030984437467807905'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2552934363134993103/posts/default/2030984437467807905'/><link rel='alternate' type='text/html' href='http://mysybase.blogspot.com/2007/02/welcome-to-james-sybase-collection.html' title='Welcome to James&apos; sybase collection'/><author><name>James</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry></feed>
