1. 程式人生 > >mysql 5.5 的預設配置檔案和資料檔案的存放路徑

mysql 5.5 的預設配置檔案和資料檔案的存放路徑

"C:\Program Files\MySQL\MySQL Server 5.5\" # Path to the database root datadir="C:\ProgramData\MySQL\MySQL Server 5.5\data\" # The default character set that will be used when a new schema or table is # created and no character set is defined character-set-server=utf8 # The default storage engine that will be used when create new tables when default-storage-engine=INNODB # Set the SQL mode to strict sql-mode="
STRICT_TRANS_TABLES,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION" # The maximum amount of concurrent sessions the MySQL server will # allow. One of these connections will be reserved for a user with # SUPER privileges to allow the administrator to login even if the # connection limit has been reached. max_connections=100 # Query cache is used to cache SELECT results and later return them # without actual executing the same query once again. Having the query # cache enabled may result in significant speed improvements, if your # have a lot of identical queries and rarely changing tables. See the # "
Qcache_lowmem_prunes" status variable to check if the current value # is high enough for your load. # Note: In case your tables change very often or if your queries are # textually different every time, the query cache may result in a # slowdown instead of a performance improvement. query_cache_size=0 # The number of open tables for all threads. Increasing this value # increases the number of file descriptors that mysqld requires. # Therefore you have to make sure to set the amount of open files # allowed to at least 4096 in the variable "
open-files-limit" in # section [mysqld_safe] table_cache=256 # Maximum size for internal (in-memory) temporary tables. If a table # grows larger than this value, it is automatically converted to disk # based table This limitation is for a single table. There can be many # of them. tmp_table_size=51M # How many threads we should keep in a cache for reuse. When a client # disconnects, the client's threads are put in the cache if there aren't # more than thread_cache_size threads from before. This greatly reduces # the amount of thread creations needed if you have a lot of new # connections. (Normally this doesn't give a notable performance # improvement if you have a good thread implementation.) thread_cache_size=8 #*** MyISAM Specific options # The maximum size of the temporary file MySQL is allowed to use while # recreating the index (during REPAIR, ALTER TABLE or LOAD DATA INFILE. # If the file-size would be bigger than this, the index will be created # through the key cache (which is slower). myisam_max_sort_file_size=100G # If the temporary file used for fast index creation would be bigger # than using the key cache by the amount specified here, then prefer the # key cache method. This is mainly used to force long character keys in # large tables to use the slower key cache method to create the index. myisam_sort_buffer_size=100M # Size of the Key Buffer, used to cache index blocks for MyISAM tables. # Do not set it larger than 30% of your available memory, as some memory # is also required by the OS to cache rows. Even if you're not using # MyISAM tables, you should still set it to 8-64M as it will also be # used for internal temporary disk tables. key_buffer_size=8M # Size of the buffer used for doing full table scans of MyISAM tables. # Allocated per thread, if a full scan is needed. read_buffer_size=64K read_rnd_buffer_size=256K # This buffer is allocated when MySQL needs to rebuild the index in # REPAIR, OPTIMZE, ALTER table statements as well as in LOAD DATA INFILE # into an empty table. It is allocated per thread so be careful with # large settings. sort_buffer_size=256K #*** INNODB Specific options *** # innodb_data_home_dir=0.0 # Use this option if you have a MySQL server with InnoDB support enabled # but you do not plan to use it. This will save memory and disk space # and speed up some things. # skip-innodb # Additional memory pool that is used by InnoDB to store metadata # information. If InnoDB requires more memory for this purpose it will # start to allocate it from the OS. As this is fast enough on most # recent operating systems, you normally do not need to change this # value. SHOW INNODB STATUS will display the current amount used. innodb_additional_mem_pool_size=8M # If set to 1, InnoDB will flush (fsync) the transaction logs to the # disk at each commit, which offers full ACID behavior. If you are # willing to compromise this safety, and you are running small # transactions, you may set this to 0 or 2 to reduce disk I/O to the # logs. Value 0 means that the log is only written to the log file and # the log file flushed to disk approximately once per second. Value 2 # means the log is written to the log file at each commit, but the log # file is only flushed to disk approximately once per second. innodb_flush_log_at_trx_commit=1 # The size of the buffer InnoDB uses for buffering log data. As soon as # it is full, InnoDB will have to flush it to disk. As it is flushed # once per second anyway, it does not make sense to have it very large # (even with long transactions). innodb_log_buffer_size=4M # InnoDB, unlike MyISAM, uses a buffer pool to cache both indexes and # row data. The bigger you set this the less disk I/O is needed to # access data in tables. On a dedicated database server you may set this # parameter up to 80% of the machine physical memory size. Do not set it # too large, though, because competition of the physical memory may # cause paging in the operating system. Note that on 32bit systems you # might be limited to 2-3.5G of user level memory per process, so do not # set it too high. innodb_buffer_pool_size=318M # Size of each log file in a log group. You should set the combined size # of log files to about 25%-100% of your buffer pool size to avoid # unneeded buffer pool flush activity on log file overwrite. However, # note that a larger logfile size will increase the time needed for the # recovery process. innodb_log_file_size=160M # Number of threads allowed inside the InnoDB kernel. The optimal value # depends highly on the application, hardware as well as the OS # scheduler properties. A too high value may lead to thread thrashing. innodb_thread_concurrency=17

相關推薦

mysql 5.5預設配置檔案資料檔案存放路徑

"C:\Program Files\MySQL\MySQL Server 5.5\" # Path to the database root datadir="C:\ProgramData\MySQL\MySQL Server 5.5\data\" # The default character set

MFC 獲取檔案資料夾的路徑

1.獲取檔案的路徑 CFileDialog fileDlg(TRUE); fileDlg.m_ofn.lpstrTitle=L"開啟檔案"; //fileDlg.m_ofn.lpstrFilter

RMAN實戰8:控制檔案資料檔案SCN、v$datafile_header檢視用途

前6篇都是講的RMAN的一些基礎理論和備份的東西,從今天開始進入恢復演練,恢復生產資料庫是每個DBA都不願意看到,但必須去面對。平時還要做好應急情況的預演練。 ORACLE啟動時資料文科和控制檔案的SCN對比 ORACLE進行正常關閉的時候

Linux 中檔案資料夾獲取 MySQL 許可權(SELinux)

  今天在 Linux 系統上移動 MySQL 的資料庫目錄 配置如下: /etc/my.cnf [mysqld]datadir=/home/mysqlsocket=/var/lib/mysql/mysql.sock 更改完配置檔案重啟MYSQL的時候出現

MySQL資料庫表內匯入txtcsv檔案資料

本文總結了在CentOS7上使用 LOAD DATA <LOCAL> INFILE 語句向MySQL8.0資料庫匯入txt檔案和csv檔案資料的方法和遇到的錯誤。由於兩者方法一樣,就先介紹匯入txt檔案的操作和錯誤,csv的直接在最後附上命令和簡要說明。 原始資

MySQL innodb引擎下根據.frm.ibd檔案恢復表結構資料

  一次恢復資料庫表結構和資料的實戰,僅以此貼作為記錄。   由於,前幾天我們使用的資料庫被入侵(順便鄙視一下安全管理人員),資料庫中的表都顯示不存在(僅剩一個黑客自建的----qq_xxxxx的表,但物理檔案都在,例如:.frm、.ibd檔案等)。因此,產生了這次恢復表結

初識RMAN 1:資料檔案控制檔案位置引數配置

演示了rman的資料檔案、控制檔案、歸檔日誌、備份並行度等相關引數的設定 rman啟動和配置引數檢視 準備條件 配置好環境變數 特權賬號或者sysdba許可權的使用者,一般用sa C:\app\oracle\product\12

Java實現zip檔案壓縮(單個檔案資料夾以及檔案資料夾的組合壓縮)

Java實現zip檔案壓縮(單個檔案、資料夾以及檔案和資料夾的組合壓縮) 2016年10月04日 23:22:24 ljheee 閱讀數:13215 標籤: 壓縮javazip 更多 個人分類: Java應用 版權宣告:本文為博

linux檢視檔案資料夾大小方法

檢視磁碟的佔用情況: $ sudo df -h udev 3.8G 0 3.8G 0% /dev tmpfs 771M 9.4M 762M 2% /run /dev/sda9 57G 5.1G 49

Python語言程式設計基礎(7)—— 檔案資料格式化

返回字串 file = input() #返回字串 fo = open(file,"r").read(6) print(fo)   返回列表形式 file = input() fo = open(file,"r") #print(fo) #返回列表形式 pr

Linux下檢視檔案資料夾佔用記憶體大小、刪除日誌 命令

轉:https://www.cnblogs.com/lixuwu/p/5944062.html 閱讀目錄 1 Linux下檢視檔案和資料夾大小 2 刪除系統日誌等 3 實踐 場景:在sts中執行自動部署時候maven提示No space left on d

python判斷檔案資料夾是否存在、沒有則建立資料

原文出處:https://www.cnblogs.com/hushaojun/p/4533241.html >>> import os >>> os.path.exists('d:/assist') True

Linux檔案資料夾許可權解讀

首先來檢視一下當前目錄下的檔案內容吧: ls -l 檢視當前目錄下的檔案列表 ls -ld 目錄名稱 檢視指定資料夾許可權 ls -l xxx.xxx (xxx.xxx是檔名) 檢視指定的檔案 我們可以看到檔案的許可權,-rw-rw-r-- 

踩坑經歷(七)MySQL匯出生產環境表結構資料

在命令列視窗下執行即可 編號 需求 SQL 1 匯出資料庫為dbname的表結構(其中使用者名稱為root,密碼為dbpasswd,生成的指令碼名為db.sql) my

Java建立、重新命名、刪除檔案資料

package my.file;   import java.io.File;   import java.io.FileOutputStream;   import java.io

intellij idea local changes 忽略 檔案資料夾的方法

在我們svn提交的時候想要看看自己改了哪些檔案,可以在 Version Control--> Local Changes 中看到,並在裡面提交程式碼即可,但是裡面會有很多我們不想看到的檔案,比如idea的配置檔案 *.iml、class檔案之類的, 想要忽略這些檔案可以用以下方法,在

第7章:檔案資料格式化

註明:本系列課程專為全國計算機等級考試二級 Python 語言程式設計考試服務 目錄 考綱考點 知識導圖 1、檔案的使用 檔案 檔案的型別 檔案的開啟和關閉 檔案的讀寫 2、資料組織的維度 一維資料 二維資料 高維資料 3、一維資料的處理

簡單使用tornado伺服器,建立hello world頁面及tornado簡單頁面,並配置templatestatic檔案路徑,url分發

首先安裝tornado:我用的最新版5.1.1 cmd 輸入命令 pip install tornado 建立hello world頁面及tornado簡單頁面,並配置template和static檔案路徑,url分發: 這裡要注意:py檔名不能用tornado,import時會報錯!

from表單同時存在檔案資料用fromdate非同步上傳

前端程式碼 from表單id自定義我這定義的uploadfrom前端的from表單我就不貼出來了 var formData = new FormData(document.getElementById("uplodfrom")); $.ajax({ url: '${pageCon

mooc-python語言程式設計練習7-檔案資料格式化

1.‪‬‪‬‪‬‪‬‪‬‮‬‭‬‫‬‪‬‪‬‪‬‪‬‪‬‮‬‪‬‫‬‪‬‪‬‪‬‪‬‪‬‮‬‭‬‫‬‪‬‪‬‪‬‪‬‪‬‮‬‪‬‫‬‪‬‪‬‪‬‪‬‪‬‮‬‭‬‪‬# 00390031003900310038435 以下選項對檔案描述錯誤的是:‪‬‪‬‪‬‪‬‪‬‮‬‭‬‫‬‪‬‪‬‪‬‪