自拍偷在线精品自拍偷,亚洲欧美中文日韩v在线观看不卡

MySQL數(shù)據(jù)庫只監(jiān)聽某個特定地址的方法

數(shù)據(jù)庫 MySQL
網(wǎng)絡(luò)監(jiān)聽是確保數(shù)據(jù)庫中數(shù)據(jù)安全的措施之一,在MySQL數(shù)據(jù)庫中如何只監(jiān)聽某個特定地址?下文中將會給出答案。

問:怎樣才能指定MySQL只監(jiān)聽某個特定地址?

答:比較常見的辦法是,在my.cnf之mysqld節(jié),添加bind-address=127.0.0.1。但是也有人按照下面的辦法來做。

為了數(shù)據(jù)的安全,可以考慮讓MySQL只守候在127.0.0.1上,這樣從Internet上就無法直接訪問數(shù)據(jù)庫了。修改/etc/init.d/mysql文件,在start部分找到類似下面這行:

$bindir/mysqld_safe --datadir=$datadir

--pid-file=$pid_file &

修改成:

$bindir/mysqld_safe --datadir=$datadir

--pid-file=$pid_file --bind-address=127.0.0.1 &

重起MySQL:

/etc/init.d/mysql restart

最后netstat -l確認(rèn)一下:

tcp 0 0 localhost:mysql *:* LISTEN

通過上文中介紹的方法就能夠?qū)崿F(xiàn)MySQL數(shù)據(jù)庫操作過程中只監(jiān)聽某個特定地址,您學(xué)會了嗎?

【編輯推薦】

  1. 在SUSE10環(huán)境下安裝和配置MySQL數(shù)據(jù)庫
  2. 備份MySQL數(shù)據(jù)庫的簡單方法
  3. 對抗MySQL數(shù)據(jù)庫解密高手
  4. 認(rèn)識MySQL數(shù)據(jù)庫對服務(wù)器端光標(biāo)的限制
責(zé)任編輯:迎迎 來源: 賽迪網(wǎng)
相關(guān)推薦

2011-07-25 16:54:52

Oracle數(shù)據(jù)庫注冊監(jiān)聽

2018-05-14 10:56:36

MySQL數(shù)據(jù)庫存儲

2009-08-12 14:23:01

C#連接MySql數(shù)據(jù)

2011-07-04 15:56:32

ASP

2011-04-06 09:09:17

MySQL數(shù)據(jù)庫備份

2011-05-24 09:32:38

2010-05-12 10:29:51

MySQL數(shù)據(jù)庫

2010-05-17 10:24:44

MySQL數(shù)據(jù)庫

2010-10-15 13:45:20

安裝MySql數(shù)據(jù)庫

2011-08-25 17:49:14

MySQLmysqlcheck

2011-03-08 08:49:55

MySQL優(yōu)化單機(jī)

2010-02-03 16:46:07

Python特定數(shù)據(jù)庫

2011-05-13 09:42:21

2011-04-12 14:48:38

MySQL數(shù)據(jù)庫

2010-06-04 14:59:06

MySQL數(shù)據(jù)庫

2010-05-14 14:00:59

MySQL數(shù)據(jù)庫優(yōu)化

2022-09-20 19:37:08

MySQL

2011-02-22 14:26:04

ProFTPD

2011-02-22 14:26:04

ProFTPD

2011-03-24 10:59:08

Nagios監(jiān)控數(shù)據(jù)庫
點(diǎn)贊
收藏

51CTO技術(shù)棧公眾號