Advertisement
Guest User

MySQL 5.7 --initialize with separate InnoDB Undo Tablespaces

a guest
Aug 28th, 2015
332
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.51 KB | None | 0 0
  1. [root@mylab mysql]# ./bin/mysqld -V
  2. ./bin/mysqld Ver 5.7.8-rc-enterprise-commercial-advanced for linux-glibc2.5 on x86_64 (MySQL Enterprise Server - Advanced Edition (Commercial))
  3.  
  4. [root@mylab mysql]# cat /tmp/my.cnf
  5. [mysqld]
  6. datadir=/tmp/mysqldata
  7. innodb_undo_log_truncate=ON
  8. innodb-undo-tablespaces=32
  9. innodb-undo-logs=64
  10.  
  11. [root@mylab mysql]# ./bin/mysqld --defaults-file=/tmp/my.cnf --initialize
  12. ... [snip]
  13.  
  14. [root@mylab mysql]# ls /tmp/mysqldata/
  15. auto.cnf client-cert.pem ibdata1 mysql public_key.pem sys undo003 undo006 undo009 undo012 undo015 undo018 undo021 undo024 undo027 undo030
  16. ca-key.pem client-key.pem ib_logfile0 performance_schema server-cert.pem undo001 undo004 undo007 undo010 undo013 undo016 undo019 undo022 undo025 undo028 undo031
  17. ca.pem ib_buffer_pool ib_logfile1 private_key.pem server-key.pem undo002 undo005 undo008 undo011 undo014 undo017 undo020 undo023 undo026 undo029 undo032
  18.  
  19. [root@mylab mysql]# ./bin/mysqld --defaults-file=/tmp/my.cnf --port=3377 --socket=/tmp/mysqltmp.sock --user=mysql &
  20. [2] 6088
  21. 2015-08-28T15:59:37.995416Z 0 [Note] ./bin/mysqld (mysqld 5.7.8-rc-enterprise-commercial-advanced) starting as process 6088 ...
  22. ...
  23. 2015-08-28T15:59:38.019596Z 0 [Note] InnoDB: Opened 32 undo tablespaces
  24. 2015-08-28T15:59:38.019605Z 0 [Note] InnoDB: 31 undo tablespaces made active
  25. 2015-08-28T15:59:38.133603Z 0 [Note] InnoDB: Creating shared tablespace for temporary tables
  26. 2015-08-28T15:59:38.133653Z 0 [Note] InnoDB: Setting file './ibtmp1' size to 12 MB. Physically writing the file full; Please wait ...
  27. 2015-08-28T15:59:38.305626Z 0 [Note] InnoDB: File './ibtmp1' size is now 12 MB.
  28. 2015-08-28T15:59:38.307018Z 0 [Note] InnoDB: 32 redo rollback segment(s) found. 32 redo rollback segment(s) are active.
  29. 2015-08-28T15:59:38.307030Z 0 [Note] InnoDB: 32 non-redo rollback segment(s) are active.
  30. ...
  31. 2015-08-28T15:59:38.421146Z 0 [Note] ./bin/mysqld: ready for connections.
  32. Version: '5.7.8-rc-enterprise-commercial-advanced' socket: '/tmp/mysqltmp.sock' port: 3377 MySQL Enterprise Server - Advanced Edition (Commercial)
  33.  
  34. [root@mylab mysql]# ls /tmp/mysqldata/
  35. auto.cnf client-key.pem ib_logfile1 performance_schema server-key.pem undo003 undo007 undo011 undo015 undo019 undo023 undo027 undo031
  36. ca-key.pem ib_buffer_pool ibtmp1 private_key.pem sys undo004 undo008 undo012 undo016 undo020 undo024 undo028 undo032
  37. ca.pem ibdata1 mylab.pid public_key.pem undo001 undo005 undo009 undo013 undo017 undo021 undo025 undo029
  38. client-cert.pem ib_logfile0 mysql server-cert.pem undo002 undo006 undo010 undo014 undo018 undo022 undo026 undo030
  39.  
  40. [root@mylab mysql]# mysql -p --socket=/tmp/mysqltmp.sock
  41. Enter password:
  42. ...
  43.  
  44. mysql> set password="test";
  45. Query OK, 0 rows affected (0.00 sec)
  46.  
  47. mysql> show global variables like "datadir";
  48. +---------------+-----------------+
  49. | Variable_name | Value |
  50. +---------------+-----------------+
  51. | datadir | /tmp/mysqldata/ |
  52. +---------------+-----------------+
  53. 1 row in set (0.00 sec)
  54.  
  55. mysql> show global variables like "innodb_undo%";
  56. +--------------------------+-------+
  57. | Variable_name | Value |
  58. +--------------------------+-------+
  59. | innodb_undo_directory | ./ |
  60. | innodb_undo_log_truncate | ON |
  61. | innodb_undo_logs | 64 |
  62. | innodb_undo_tablespaces | 32 |
  63. +--------------------------+-------+
  64. 4 rows in set (0.00 sec)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement