forum.vmspython.org Forum Index forum.vmspython.org
Forum system
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Data loss on system power outage

 
Post new topic   Reply to topic    forum.vmspython.org Forum Index -> MySQL for OpenVMS
View previous topic :: View next topic  
Author Message
icl



Joined: 26 Oct 2007
Posts: 29
Location: London, UK

PostPosted: Wed Jul 21, 2010 2:32 pm    Post subject: Data loss on system power outage Reply with quote

I have had a consistent problem with some MySQL databases - all running 5.1.22 on Itanium 8.3-1H1.


If I have a system power outage - without shutting down the MySQL server cleanly - I am losing data from tables.

The loss is not absolute as the information is still available in the mysql-bin.xxxxxx binary log files and I can manually restore from there.

However, I would have thought that the crash recovery of the database would have done this automatically. Is this not the case?

By way of example: simply adding a user to the MySQL database then doing a system reboot (without a clean MySQL shutdown) will result in that user not being available on reboot.

Ways around the issue I have found include:

Rebooting the MySQL server manually:

mysqladmin -uroot shutdown
@mysql051_root:[vms]mysql_startup

Likewise if I do a "PURGE TABLES" that also resolves the issue.

However I don't want to have to do this every day to prevent data loss.

Has anyone had the same problem - or got an answer?
Back to top
View user's profile Send private message
jfp



Joined: 12 Jul 2004
Posts: 618

PostPosted: Thu Jul 22, 2010 9:31 am    Post subject: Reply with quote

Hello,

what engine do you use: InnoDB or MyISAM?

If you use MyISAM I strongly suggest to convert your tables to InnoDB.

We are not aware of any data lost with InnoDB tables.

You can also upgrade to 5.1.36 (which is a HP kit), MyISAM is much more reliable in this version.

Jean-François
Back to top
View user's profile Send private message Send e-mail Visit poster's website
icl



Joined: 26 Oct 2007
Posts: 29
Location: London, UK

PostPosted: Fri Jul 23, 2010 10:27 am    Post subject: Reply with quote

Hi jfp

I am using InnoDB with this version.

Am I correct that the db should restore itself from the binary-log automatically after a crash?

I have tried resetting the database from scratch and I have the same problem each time.

Perhaps I should try 5.1.36. Is the installer the one in /tmp/ia64?
Back to top
View user's profile Send private message
icl



Joined: 26 Oct 2007
Posts: 29
Location: London, UK

PostPosted: Fri Jul 23, 2010 11:29 am    Post subject: Reply with quote

I tried to install 5.1.36 (new install)

But we are getting a conflict on the LIBZ images and the MySQLD is crashing:

This from mysqld.log


$ if f$trnlnm("LIBZ_SHR32") .eqs. "" then $ define LIBZ_SHR32 -
mysql051_root:[vms.lib]libz_shr32.exe
$ if f$trnlnm("LIBZ_SHR64") .eqs. "" then $ define LIBZ_SHR64 -
mysql051_root:[vms.lib]libz_shr64.exe
$!
$! All options except ansi defined using configuration file my.cnf
$!
$ mysqld --no-defaults --language=/mysql051_root/sql/share/english --bootstrap -
--log-warnings=0 --loose-skip-innodb --loose-skip-ndbcluster
%DCL-W-ACTIMAGE, error activating image LIBZ_SHR64
-CLI-E-IMGNAME, image file IA64$DKA100:[SYS0.SYSCOMMON.MYSQL051.][vms.lib]libz_s
hr64.exe;1
-IMGACT-F-SYMVECNFD, symbol vector entry not a valid procedure
MYSQL051_SRV job terminated at 23-JUL-2010 10:21:07.26

Any ideas?

icl
Back to top
View user's profile Send private message
icl



Joined: 26 Oct 2007
Posts: 29
Location: London, UK

PostPosted: Mon Jul 26, 2010 4:11 pm    Post subject: Reply with quote

I found an easyish workaround: adding the "flush" command to my.cnf to force changes to be written to disk on each command.

Not the best of solutions but at least I am not losing data and my overhead doesn't appear too affected.

JF - I will try and set up a build environment for the Itanium - what licenses do I need to compile/build. Anything in addition to C and MMS?
Back to top
View user's profile Send private message
jfp



Joined: 12 Jul 2004
Posts: 618

PostPosted: Tue Jul 27, 2010 11:52 am    Post subject: Reply with quote

Hi icl,

do you solve your installation problem ?

If i my memory is correct the is some note in itrc about "-IMGACT-F-SYMVECNFD, symbol vector entry not a valid procedure " error. I don't remember exactly.

You need C, C++, MMS to be able to build from source.

Optionally you may also need the various files to generate a pcsi kit, not in the mercurial repository, but can be added.

JF
Back to top
View user's profile Send private message Send e-mail Visit poster's website
icl



Joined: 26 Oct 2007
Posts: 29
Location: London, UK

PostPosted: Tue Jul 27, 2010 11:54 am    Post subject: Reply with quote

no - no luck on the 5.1.36 install.

I will take a look at ITRC
Back to top
View user's profile Send private message
bisonmalembouche



Joined: 01 Jun 2005
Posts: 74

PostPosted: Tue Jul 27, 2010 2:08 pm    Post subject: Reply with quote

I think it is this post

IMGACT-F-SYMVECNFD, symbol vector entry not a valid procedure

http://forums11.itrc.hp.com/service/forums/questionanswer.do?admit=109447626+1280232331642+28353475&threadId=1204873
Back to top
View user's profile Send private message Send e-mail
icl



Joined: 26 Oct 2007
Posts: 29
Location: London, UK

PostPosted: Tue Jul 27, 2010 2:15 pm    Post subject: Reply with quote

duh!!

I hadn't updated my OVMS8.3-1H1 with the latest patches.

I installed the latest patch VMS831H1I_UPDATE-V0800 and now 5.1.36 is working fine.

I still have this issue though that crash recovery is not recovering the entries from the binary log. Hence I will need to keep the global variable "flush" set to ON.
Back to top
View user's profile Send private message
icl



Joined: 26 Oct 2007
Posts: 29
Location: London, UK

PostPosted: Thu Jul 29, 2010 3:08 am    Post subject: Reply with quote

Some further feedback on the 5.1.36 install.

Whilst 5.1.36 MySQL Server process appears to work fine with the 8.3-1H1 Update 800. However users should avoid installing the latest HP SSL 1.4 release as this would require a rebuild of the executable with the new SSL shareable images.

Also - I have found the mysqlclient_mixed.olb/mysqlclient_upper.olb libraries that come with the install are missing some crucial function symbols. Executables built with these libraries failed.

I installed the 5.1.23 Client libraries and these appear to do the job fine - though I guess we must be missing some of the new functionality.
Back to top
View user's profile Send private message
icl



Joined: 26 Oct 2007
Posts: 29
Location: London, UK

PostPosted: Thu Jul 29, 2010 4:03 am    Post subject: Reply with quote

For info - the problems with the client libraries for 5.1.36 presumably stem from these link informationals/warnings:

%ILINK-W-NUDFSYMS, 3 undefined symbols:
%ILINK-I-UDFSYM, vms_shared_control
%ILINK-I-UDFSYM, vms_shared_open
%ILINK-I-UDFSYM, vms_shared_preclose
%ILINK-W-USEUNDEF, undefined symbol vms_shared_open referenced
....
Back to top
View user's profile Send private message
jfp



Joined: 12 Jul 2004
Posts: 618

PostPosted: Fri Jul 30, 2010 9:04 am    Post subject: Reply with quote

You can download an updated version of the client libraries from
http://www.vmsmysql.org/anonymous/kits/tmp/ia64/mysqlclient05136_upd1.zip for IA64.

JF
Back to top
View user's profile Send private message Send e-mail Visit poster's website
icl



Joined: 26 Oct 2007
Posts: 29
Location: London, UK

PostPosted: Tue Aug 03, 2010 11:20 am    Post subject: Reply with quote

JF

Thanks for that.

I get a fair number of "undefined symbols" with these libraries:

%ILINK-I-UDFSYM, BN_bin2bn
%ILINK-I-UDFSYM, DH_free
%ILINK-I-UDFSYM, DH_new
%ILINK-I-UDFSYM, ERR_get_error_line_data
%ILINK-I-UDFSYM, OPENSSL_add_all_algo_noconf
%ILINK-I-UDFSYM, SSL_CIPHER_get_name
%ILINK-I-UDFSYM, SSL_CTX_check_private_key
%ILINK-I-UDFSYM, SSL_CTX_ctrl
%ILINK-I-UDFSYM, SSL_CTX_free
%ILINK-I-UDFSYM, SSL_CTX_load_verify_locations
%ILINK-I-UDFSYM, SSL_CTX_new
%ILINK-I-UDFSYM, SSL_CTX_set_cipher_list
%ILINK-I-UDFSYM, SSL_CTX_set_def_verify_paths
%ILINK-I-UDFSYM, SSL_CTX_set_session_id_context
%ILINK-I-UDFSYM, SSL_CTX_set_verify
%ILINK-I-UDFSYM, SSL_CTX_use_PrivateKey_file
%ILINK-I-UDFSYM, SSL_CTX_use_certificate_file
%ILINK-I-UDFSYM, SSL_SESSION_set_timeout
%ILINK-I-UDFSYM, SSL_accept
%ILINK-I-UDFSYM, SSL_clear
%ILINK-I-UDFSYM, SSL_connect
%ILINK-I-UDFSYM, SSL_free
%ILINK-I-UDFSYM, SSL_get_current_cipher
%ILINK-I-UDFSYM, SSL_get_fd
%ILINK-I-UDFSYM, SSL_get_peer_certificate
%ILINK-I-UDFSYM, SSL_get_session
%ILINK-I-UDFSYM, SSL_library_init
%ILINK-I-UDFSYM, SSL_load_error_strings
%ILINK-I-UDFSYM, SSL_new
%ILINK-I-UDFSYM, SSL_read
%ILINK-I-UDFSYM, SSL_set_fd
%ILINK-I-UDFSYM, SSL_set_quiet_shutdown
%ILINK-I-UDFSYM, SSL_shutdown
%ILINK-I-UDFSYM, SSL_write
%ILINK-I-UDFSYM, TLSv1_client_method
%ILINK-I-UDFSYM, TLSv1_server_method
%ILINK-I-UDFSYM, X509_NAME_oneline
%ILINK-I-UDFSYM, X509_STORE_CTX_get_current_cert
%ILINK-I-UDFSYM, X509_STORE_CTX_get_error
%ILINK-I-UDFSYM, X509_STORE_CTX_get_error_depth
%ILINK-I-UDFSYM, X509_free
%ILINK-I-UDFSYM, X509_get_issuer_name
%ILINK-I-UDFSYM, X509_get_subject_name

I tried linking with SSLLIB:LIBSSL and SSLLIB:LIBCRYPTO (OPENSSL098A) which work with the earlier client library.

I have also tried linking with the VMS SSL:

SYS$SHARE:SSL$LIBSSL_SHR.EXE/SHARE
SYS$SHARE:SSL$LIBCRYPTO_SHR.EXE/SHARE

but this doesn't seem to work either.

which ones should I be using for this?

EDIT:

ah - ok - worked it out - needed to use SSLLIB:LIBSSL_MIXED and SSLLIB:LIBCRYPTO_MIXED. Looking in the BUILD_ALL.COM for 5.1.36 I saw these as the settings for JFP_SSL (OPENSSL098G) - does this mean I should update from OPENSSL098A - or are they compatible?
Back to top
View user's profile Send private message
jfp



Joined: 12 Jul 2004
Posts: 618

PostPosted: Tue Aug 03, 2010 9:18 pm    Post subject: Reply with quote

It is not mandatory to upgrade your SSL version, but probably a good idea.

JF
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic    forum.vmspython.org Forum Index -> MySQL for OpenVMS All times are GMT + 2 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group