Quantcast
Channel: SCN: Message List - SAP Applications on SAP Adaptive Server Enterprise (SAP ASE)
Viewing all 3678 articles
Browse latest View live

log full, can't alter the database, ...

$
0
0

Hello,

 

I'm having troubles with a database. The transaction log is full.

 

When I look at syslogshold, the oldest transaction in the database belongs to spid6 :

 

Database        Start                spid   User     Name                   

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

workflow_db     24 Feb 2014 18:39:38      6 NULL     $dmpxact              

 

spid 6 is the checkpoint task :

 

spid status   loginame host   progname blk  dbname     cmd                          

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

1    recv sle wlprd02  CR2920 WL_7001  0    weblogic_d AWAITING COMMAND             

2    sleeping NULL     NULL   NULL     0    master     DEADLOCK TUNE                

3    sleeping NULL     NULL   NULL     0    master     KPP HANDLER                  

4    sleeping NULL     NULL   <astc>   0    master     ASTC HANDLER                 

5    sleeping NULL     NULL   <astc>   0    master     ASTC HANDLER                 

6    PLC slee NULL     NULL   NULL     0    workflow_d CHECKPOINT SLEEP             

7    sleeping NULL     NULL   NULL     0    workflow_d HK WASH                      

8    sleeping NULL     NULL   NULL     0    master     HK GC                        

9    sleeping NULL     NULL   NULL     0    master     HK CHORES                    

10   sleeping NULL     NULL   NULL     0    master     PORT MANAGER                 

11   sleeping NULL     NULL   NULL     0    master     NETWORK HANDLER             

 

When I try to alter the database to extend the log, it's hanging on process 6 :

 

 

 

 

   spid   status   loginame host   progname blk  dbname     cmd                          

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

      8 sleeping NULL     NULL   NULL     0    master     HK GC                        

      9 sleeping NULL     NULL   NULL     0    master     HK CHORES                    

    131 sleeping wlprd02  j2eete WL_7081  0    weblogic_d INSERT                       

    161 sleeping sa       xena-d sqsh-2.1 0    workflow_d DBCC                         

    189 lock sle sa       xena-d sqsh-2.1 6    master     ALTER DATABASE               

    402 sleeping jparent  CR2920 NULL     0    workflow_d DELETE                      

 

Proccesses 8 and 9 also have locks in the workflow_db :

 

spid   locktype           table_name           page          dbname        

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

      8 Sh_page            sysmessages                   1413 master        

      8 Sh_page            sysmessages                   1857 master        

      8 Ex_intent          JBPM_VARIABLEINSTANC             0 workflow_db   

      9 Sh_page            sysmessages                   1413 master        

      9 Sh_page            sysmessages                   1857 master        

      9 Sh_intent          JBPM_VARIABLEINSTANC             0 workflow_db   

      9 Ex_intent          systabstats                      0 workflow_db  

 

Process 161 is executing a dbcc checktable(syslogs) command which also hangs on a full transaction log :

 

[102] DST_ST_2.sa.workflow_db.1> dbcc checktable(syslogs);

Checking table 'syslogs' (object ID 8): Logical page size is 4096 bytes.

 

Checking partition 'syslogs_8' (partition ID 8) of table 'syslogs'. The logical page size

of this table is 4096 bytes.

The total number of data pages in partition 'syslogs_8' (partition ID 8) is 50996.

Partition 'syslogs_8' (partition ID 8) has 2041034 data rows.

 

The total number of data pages in this table is 50996.

*** NOTICE: Space used on the log segment is 51196 pages (199.98 MB), 99.99%.

*** NOTICE: Space reserved on the log segment is 18 pages (0.07 MB), 0.04%.

*** NOTICE: Space free on the log segment is -14 pages (-0.05 MB), -0.03%.

Table has 2041034 data rows.

Processed 10241 allocation unit(s) out of 20480 units (allocation page 2621440). 50% completed.

Processed 12288 allocation unit(s) out of 20480 units (allocation page 3145472). 60% completed.

Processed 14336 allocation unit(s) out of 20480 units (allocation page 3669760). 70% completed.

Processed 16384 allocation unit(s) out of 20480 units (allocation page 4194048). 80% completed.

Processed 18432 allocation unit(s) out of 20480 units (allocation page 4718336). 90% completed.

Processed 20480 allocation unit(s) out of 20480 units (allocation page 5242624). 100%  completed.

Processed 22528 allocation unit(s) out of 20480 units (allocation page 5766912). 110% completed.

Processed 24576 allocation unit(s) out of 20480 units (allocation page 6291200). 120% completed.

Processed 26624 allocation unit(s) out of 20480 units (allocation page 6815488). 130% completed.

Processed 28672 allocation unit(s) out of 20480 units (allocation page 7339776). 140% completed.

Processed 30720 allocation unit(s) out of 20480 units (allocation page 7864064). 150% completed.

Processed 34897 allocation unit(s) out of 30720 units (allocation page 8933376). 113% completed.

Processed 37786 allocation unit(s) out of 30720 units (allocation page 9672960). 123% completed.

Processed 40858 allocation unit(s) out of 30720 units (allocation page 10459392). 133% completed.

Processed 43930 allocation unit(s) out of 30720 units (allocation page 11245824). 143% completed.

Processed 47002 allocation unit(s) out of 30720 units (allocation page 12032256). 153% completed.

Msg 1105, Level 17, State 7

Server 'DST_ST_2_b', Line 1

Can't allocate space for object 'syslogs' in database 'workflow_db' because 'logsegment'

segment is full/has no free extents. If you ran out of space in syslogs, dump the

transaction log. Otherwise, use ALTER DATABASE to increase the size of the segment.

Msg 3475, Level 21, State 7

Server 'DST_ST_2_b', Line 1

There is no space available in SYSLOGS to log a record for which space has been reserved

in database 'workflow_db' (id 58). This process will retry at intervals of one minute.

 

Something seems wrong with the numbers and percentages.

 

Dataserver version is :

 

Adaptive Server Enterprise/15.7/EBF 21709 SMP SP110 /P/Solaris AMD64/OS 5.10/ase157sp11x/3546/64-bit/FBO/Fri Nov  8 06:01:08 2013     

 

De database was loaded from a dump made on a :

 

Adaptive Server Enterprise/15.7.0/EBF 20734 SMP ESD#03 /P/Solaris AMD64/OS 5.10/ase157 esd3/3183/64-bit/FBO/Sat Dec  8 19:24:28 2012

 

system.

 

Any idea how to proceed ?

 

Thanks,

Luc.


Re: log full, can't alter the database, ...

$
0
0

Hi Luc,

 

Can try to Increase log space as below:

 

sp_helpdevice

go

<get the device path for the current log device>

go

use master

go

disk init name = log<SID>_2, physname='<device path>\log<SID>_2.dat', size = '2048M'

go

alter database <SID> log on log<SID>_2 = 2048

go

checkpoint <SID>

go

 

Hope this helps.

 

Regards,

Deepak Kori

Re: ASE  service Syabase SQLServer_"SID" don't start

$
0
0

Hi,

 

I've reboot the server(host), and after the startup only 1.5go was  used.

 

In the task manager there is no process related with the ASE Server.

 

I have compared the configuration files, there is only one diferent value:

 

number of sort buffers = 1024 -> Old

number of sort buffers = 7168

 

After the replacement of the new from the older value the ASE can't start either.

 

Any other ideas?

 

Thank you.

Alcino

Re: ASE  service Syabase SQLServer_"SID" don't start

$
0
0

Hi Alcino,

 

Well, I'd like to go back and revisit the errorlog.

What were the last 20 or so lines in it now?  (i.e. after the most recent boot attempt).

If you go back to the most recent successful boot, what message immediately followed the "Checked out license ASE_ASM" message?

 

-bret

Tempdb and devices?

$
0
0

Hello, I have a tempdb with a few devices, each device was created for  data or  log  as it is recomended to keep them separate. My problem now is I need to take out a few of those devices that the tempdb is atached too, to then move them to a tempdb2 thats going to be created.  I know that the database ihas to be dropped to then move the devices but ASE dosnt let me. Please help me my job depends on this.

 

 

thank you in advance and sorry i for my english

 

ps.  tempdb needs to stay on the server. Just to make it simple if i didn't make my self clear is  that i need to move the tempdb devices and move them to a tempdb2

Re: Tempdb and devices?

$
0
0

Hello,

 

If you are on 15.7 SP100 or newer yoy may shrink a database, check this (alter database syntax) SyBooks Online and this is an example

 

Example 11

Removes 50MB of database sales_db from device mylogdev:

alter database sales_db log off mylogdev='50M'

in earlier versions follow this SyBooks Online (Archive)

 

It is an extract from ASE 12.5 documentation but applies also to ASE 15

 

Regards,

 

Kimon

Re: log full, can't alter the database, ...

$
0
0

(alter database wasn't an option, I already mentioned in my original post that the alter database was waiting on the checkpoint task).

 

I dropped the database and reloaded the backup.

 

dbcc checktable(syslogs) reported an error in the page counts and running checktable with the fix option corrected the error.

I did the same for the database the backup was taken from.

 

So I think this will have solved the issue.

 

Best Regards,

Luc.

Re: Tempdb and devices?


Re: help with database and devices

$
0
0

One option would be to use ASE's disk mirroring capability to move tempdb onto some other devices thus freeing up the current devices for use elsewhere.  See details in one of my previous posts @ Change path of files  [Ignore the option about dropping/recreating a database.]

 

--------

 

 

A second option would be to try using the newer capability of shrinking a database.  See the chapter titled "Shrinking Databases" in ASE 15.7 SP100 New Features Guide.

 

--------

 

[NOTE: The following is generally not supported by Sybase tech support, could invalidate your SAP contract, and if not performed properly could leave your dataserver in an unusable state.]

 

The third option would consist of manually deleting rows from master..sysusages and bouncing the dataserver.  This would have the effect of shrinking the tempdb database.  The question here is which rows to delete ... and while the simple answer is 'all but the first row', the better answer is 'it depends' as we don't know what changes you (or another DBA) may have already made to sysusages.

 

If the first 2 options don't work and you need to try the third option then we'll need more info from you, to include the complete output from the following

 

- sp_helpdb tempdb

- select * from master..sysusages where dbid = 2 order by lstart

 

Keep in mind that to perform this option you will need to be able to immediately bounce the dataserver. And of course I'd suggest you have a test dataserver (ie, one you can afford to lose) to practice on before trying this on any dataserver you cannot afford to lose.

Re: help with database and devices

$
0
0

Please go through note 1881347 & 1851172.

Re: Tempdb and devices?

$
0
0

Adaptive Server Enterprise/15.7/EBF 21339 SMP SP101 /P/X64/Windows Server/ase157sp101/3439/64-bit/OPT/Thu Jun 06 12:11:05 2013

 

name,db_size,owner,dbid,created,durability,lobcomplvl,inrowlen,status

'tempdb','     106.0 MB','sa','   2','Feb 27, 2014','no_recovery','         0','    NULL','select into/bulkcopy/pllsort, trunc log on chkpt, mixed log and data, allow wide dol rows'

Re: Tempdb and devices?

$
0
0

You'll need to provide the *entire* output from running 'sp_helpdb tempdb' which consists of at least 3 result sets (you've only provided the first result set).

Client configuration for Setting net password encryption reqd

$
0
0

I am trying to enforce all connections to the Database Server, however we have  a few different type of clients connecting using several applications. I am currently gathering all the applications and settings required to be able to connect to the server successfully

 

ISQL and BCP

add -X switch

 

ASE ADO.NET Data Provider

Data Source=myASEserver;Port=5000;Database=myDataBase;Uid=myUsername; Pwd=myPassword;EncryptPassword=1;

 

Open Client

cat ocs.cfg

 

[DEFAULT]section

CS_SEC_ENCRYPTION = CS_TRUE

CS_SEC_EXTENDED_ENCRYPTION = CS_TRUE

 

Will Perl, Python use the same ocs.cfg file or is there another way to set the connection to allow encryption?

 

Others Apps

DBArtisan

On the Security Tab check option 'Enable net password encryption'

 

I have not found ways to set Sybase Central and Toad For Sybase

 

Has anyone been able to get these applications connected with 'net password encryption reqd' set to1 ?

problem using sp_opt_querystats

$
0
0

The stored procedure can be very useful, but I can not make it work with all the option proposed in sp_opt_querystats help, here is an example

 

exec

 

sp_opt_querystats"select * from POS where br_number='XyZ' and acc_number='0000097' and cur_code='USD'","plancost",mydatabase.

the result is NULL output

 

[ BEGIN QUERY ANALYSIS ]

 

 

[ END QUERY ANALYSIS ]
the same no result is produced with

exec

 

sp_opt_querystats"select * from POS where br_number='XyZ' and acc_number='0000097' and cur_code='USD'","plancost",mydatabase.

 

[ BEGIN QUERY ANALYSIS ]

 

 

[ END QUERY ANALYSIS ]

 

Some other options such showplan statio etc are working fine.

 

Am I misusing the proc or there are shortcomings in it, The version of my ASE is:

 

Adaptive Server Enterprise/15.7/EBF 21342 SMP SP101 /P/Solaris AMD64/OS 5.10/ase157sp101/3439/64-bit/FBO/Thu Jun  6 16:33:15 2013  

Re: Client configuration for Setting net password encryption reqd

$
0
0


Hi,

 

Starting with our SDK 15.7 ESD#6 or higher you can use the ocs.cfg with both Perl and Python and inturn use the password encryption: SyBooks Online

 

It depends on your version of Sybase Central when you create a new ASE connection in the advanced tab put encrypt_password=true

 

Toad for Sybase should work also. I am not sure what version you are using the new version uses our ado.net driver so wondering if that software allows it.

 

Dawn


Re: Client configuration for Setting net password encryption reqd

$
0
0

Thank you for your response.

 

I tried that option before for Sybase Central and encountered the following error

 

Could not connect to the server.

 

 

JZ0LA: Failed to instantiate Cipher object. Transformation RSA/NONE/OAEPWithSHA1AndMGF1Padding is not implemented by any of the loaded JCE providers.

null

 

 

JZ0LA: Failed to instantiate Cipher object. Transformation RSA/NONE/OAEPWithSHA1AndMGF1Padding is not implemented by any of the loaded JCE providers.

  Error code=0

  SQL state=JZ0LA

null

  Error code=0

  SQL state=null

 

 

Connection parameters:

  User=sa

  Password=

  ENG=Test_Server

  encrypt_password=true

 

My Sybase Central Version is ==> Sybase Central Adaptive Server Enterprise Plug-in Utility/15.5/EBF 17785 ESD#1/S/1.6.0/asear155/Wed May 5 08:00:01 PDT 2010

 

I also found the option for Toad - similar to DBArtisan there is an option to encrypt connections. I am currently reviewing the requirements for Perl and Python. Based on your response it seems I might have to run SDK 15.7 ESD#6 or higher to take advantage of the connection option for encryption?

Re: Client configuration for Setting net password encryption reqd

$
0
0


Hi Courtney,

 

You should be able to use ocs.cfg with Perl.
The entry name would be:

[SybaseASE]

 

I've set this up using Kerberos and Perl before this was my entry:

cat ocs.cfg

[SybaseASE]
CS_SEC_SERVERPRINCIPAL = krbServer@KRBTEST
CS_SEC_NETWORKAUTH = CS_TRUE
[firstapp.pl]
CS_SEC_NETWORKAUTH = CS_TRUE
CS_SEC_SERVERPRINCIPAL = krbServer@KRBTEST
[isql]

 

 

Python would use:
[sybpydb]

 

 

Not much of a java guy, but somehow I have this doc that shows how to setup password encryption on old Sybase Centrals.

Steps to use password encryption you have to do all of this...
1) Add the new external jar which needs to be used by Sybase Central to support extended password encryption. It should be added to Sybase Central manually following these steps:
a) Start Sybase Central, click "Tools"->"Plug-ins"
b) Select the "Adaptive Server Enterprise" plug-in and click "Properties"
c) Select the "Advanced" tab and click "Browse" to add the new external jar:
%SYBASE%\jConnect-6_0\classes\EccpressoFIPS.jar
%SYBASE%\jConnect-6_0\classes\EccpressoFIPSJca.jar

2) At this point, close Sybase Central and reboot your PC (or kill the resident "scjview.exe" or "dbisql.exe" processes).

3) After rebooting, start Sybase Central or DBISQL. Start a new Connection dialog box. Click the "Advanced" tab and add the following strings:
ENCRYPT_PASSWORD=true
JCE_PROVIDER_CLASS=com.certicom.ecc.jcae.Certicom

 

I would honestly download the last Sybase Central version before you cannot download it any longer.
If you didn't know Sybase Central is End Of Life.
Believe the last one is in ASE 15.7 SP100 section,
but Dawn knows the exact version.

 

Regards,

Ryan

Re: Client configuration for Setting net password encryption reqd

Re: Client configuration for Setting net password encryption reqd

$
0
0

Would it be fair to say that Sybase Central does not support connection to Sybase with the configuration 'net password encryption reqd' set to 1?

Re: Client configuration for Setting net password encryption reqd

$
0
0

Courtney,

This should work:
Example:
isql -Usa -Psybase -Sredhead

sp_configure "net password", 1

go

 

Capture.PNG

 

00:0006:00000:00013:2014/02/28 07:19:58.13 server  Received LOGINREC

LOGINREC at 0x0x145b3d838

  host=`BJCN00530235A' user=`sa' hostproc=`3600'

  int2=2 int4=0 char=6 flt=4 date=8

  usedb=1 dmpld=0 interface=0 netconn_type=0

  appname=`SC_ASE_Plugin' servername=`'

  tds_vers=(5.0.0.0) progname=`jConnect' prog_vers=(7.0.0.12)

  noshort=0 flt4=12 date4=16

  language=`us_english' setlang=0

  SECURITY:  hier=0 e2e option: 0xa1 db bulk reserved: 0x00

  HA: ssn option: 0x08 ssn handle:(0x00, 0x00,  0x00, 0x00, 0x00, 0x00)

  UNUSED: slunused:(0x00)

role=0

  charset=`iso_1' setcharset=0 packetsize=`512'

 

Sybase Central version 6.0.0.4790

 

Do you have anythign else configured on the ASE like ssl?
This was giving me errors until I turned ssl off.

 

Regards,

Ryan

Viewing all 3678 articles
Browse latest View live