Re: [Freeciv-Dev] Possible bug in scripts/setup_auth_server.sh

2013-11-10 Thread Marko Lindqvist
On 11 November 2013 02:49, Jacob Nevins
<0jacobnk.fc...@chiark.greenend.org.uk> wrote:
>
> I wonder if we can get rid of this implementation-specific "MyISAM"
> thing anyway, since it's troublesome? Is it necessary to specify
> something like that? It's not as if Freeciv needs a particularly
> optimised database. (I've done zero research into why it's there, it was
> like that when I found it.)

 It has been there from the very first commit that added
authentication support, first as part of instructions for manual
database creation (comment in auth.c)

http://svn.gna.org/viewcvs/freeciv/branches/S2_0/server/auth.c?revision=11357


 - ML

___
Freeciv-dev mailing list
Freeciv-dev@gna.org
https://mail.gna.org/listinfo/freeciv-dev


Re: [Freeciv-Dev] Possible bug in scripts/setup_auth_server.sh

2013-11-10 Thread Jacob Nevins
Manuel Umlauf writes:
> I tried to run a freeciv server with authentication and a MySQL
> database under Arch Linux which uses MariaDB instead. The script
> setup_auth_server.sh didn't work for that.
  [...]
> This doesn't work with MariaDB 5.5.33 because of 'TYPE=MyISAM' which
> is deprecated/removed. It also seems to be deprecated in MySQL.
  [...]
> I hope it's okay to send this to the mailing list since I am not
> sure if this is considered a bug.

Thanks for the report. This is indeed the sort of thing we'd like to
hear about; a bug report would be appropriate.

I wonder if we can get rid of this implementation-specific "MyISAM"
thing anyway, since it's troublesome? Is it necessary to specify
something like that? It's not as if Freeciv needs a particularly
optimised database. (I've done zero research into why it's there, it was
like that when I found it.)

(What version of Freeciv are you using? If it's 2.4.x, then you might
want to consider using SQLite, which is perfectly adequate and less
hassle all round.)

___
Freeciv-dev mailing list
Freeciv-dev@gna.org
https://mail.gna.org/listinfo/freeciv-dev


[Freeciv-Dev] Possible bug in scripts/setup_auth_server.sh

2013-11-10 Thread Manuel Umlauf

Hello,

I tried to run a freeciv server with authentication and a MySQL database 
under Arch Linux which uses MariaDB instead. The script 
setup_auth_server.sh didn't work for that. It uses two commands to 
create the appropriate tables (line 424 and 438):


CREATE TABLE $TABLE_USER (id int(11) NOT NULL auto_increment, name 
varchar(48) default NULL, password varchar(32) default NULL, email 
varchar(128) default NULL, createtime int(11) default NULL, accesstime 
int(11) default NULL, address varchar(255) default NULL, createaddress 
varchar(255) default NULL, logincount int(11) default '0', PRIMARY KEY  
(id), UNIQUE KEY name (name) ) TYPE=MyISAM;


CREATE TABLE $TABLE_LOG ( id int(11) NOT NULL auto_increment, name 
varchar(48) default NULL, logintime int(11) default NULL, address 
varchar(255) default NULL, succeed enum('S','F') default 'S', PRIMARY 
KEY  (id) ) TYPE=MyISAM;


This doesn't work with MariaDB 5.5.33 because of 'TYPE=MyISAM' which is 
deprecated/removed. It also seems to be deprecated in MySQL. So even if 
there is no problem yet, there will probably be one in the future I 
guess. The correct syntax to specify the storage engine would be: 
'ENGINE=MyISAM' ( http://bugs.mysql.com/bug.php?id=47974 )
I changed both lines in my setup_auth_server.sh and it works fine on my 
system.


I hope it's okay to send this to the mailing list since I am not sure if 
this is considered a bug.


Cheers, Manuel



___
Freeciv-dev mailing list
Freeciv-dev@gna.org
https://mail.gna.org/listinfo/freeciv-dev