<
From version < 50.1 >
edited by Vincent Massol
on 2020/01/28
To version < 52.1 >
edited by Thomas Mortagne
on 2020/02/11
>
Change comment: There is no comment for this version

Summary

Details

Page properties
Author
... ... @@ -1,1 +1,1 @@
1 -XWiki.VincentMassol
1 +XWiki.ThomasMortagne
Content
... ... @@ -32,7 +32,7 @@
32 32  You can create the database in several ways. For example use:
33 33  
34 34  {{code}}
35 -mysql -u root -e "create database xwiki default character set utf8 collate utf8_bin"
35 +mysql -u root -e "create database xwiki default character set utf8mb4 collate utf8mb4_bin"
36 36  {{/code}}
37 37  )))
38 38  * Give privileges to the ##xwiki## user for accessing and creating databases (for the multi wiki support). Specifically the ##xwiki## users needs permissions to be able to execute {{code}}CREATE DATABASE{{/code}}, {{code}}DROP SCHEMA{{/code}}, and then all CRUD operations on tables. Note that the command below should be tuned to be more restrictive as granting all permissions is not required:(((
... ... @@ -70,18 +70,18 @@
70 70  
71 71  = Tips =
72 72  
73 -== Convert a database from latin1 (or collation utf8_ci) to utf8/utf8_bin ==
73 +== Convert a database from latin1 (or collation utf8_ci) to utf8mb4/utf8mb4_bin ==
74 74  
75 75  {{code}}
76 76  #!/bin/bash
77 77  
78 78  db=xwiki
79 -to_character_set=utf8
80 -to_collation=utf8_bin
79 +to_character_set=utf8mb4
80 +to_collation=utf8mb4_bin
81 81  
82 82  mysql_cmd="mysql -u root"
83 83  
84 -$mysql_cmd -e "ALTER DATABASE $db CHARACTER SET utf8 COLLATE utf8_unicode_ci;"
84 +$mysql_cmd -e "ALTER DATABASE $db CHARACTER SET $to_character_set COLLATE $to_collation;"
85 85  
86 86  TBL_LIST=$($mysql_cmd -N -s -r -e "use $db;show tables;")
87 87  

Get Connected