[ kefalo @ 29.03.2009. 19:10 ] @
kako ograniciti jednog user-a da ima pristup samo jednoj bazi podataka a da drugima ne moze pristupiti pa cak ni vidjeti ostale baze koje su na serveru? |
[ kefalo @ 29.03.2009. 19:10 ] @
[ bogdan.kecman @ 29.03.2009. 19:27 ] @
dodelis mu privilegije samo za tu bazu ...
na primer: Code: [arhimed@gedora10 6.3.21]$ bin/mysql -uroot Welcome to the MySQL monitor. Commands end with ; or \g. Your MySQL connection id is 4 Server version: 5.1.31-ndb-6.3.21-innodb-log Source distribution Type 'help;' or '\h' for help. Type '\c' to clear the buffer. mysql> show databases; +--------------------+ | Database | +--------------------+ | information_schema | | d1 | | d2 | | database2 | | mysql | | sbtest | +--------------------+ 6 rows in set (0.00 sec) mysql> grant all privileges on d2.* to 'luzer'@'localhost' identified by 'pera'; Query OK, 0 rows affected (0.00 sec) mysql> quit Bye [arhimed@gedora10 6.3.21]$ mysql -uluzer -ppera Welcome to the MySQL monitor. Commands end with ; or \g. Your MySQL connection id is 5 Server version: 5.1.31-ndb-6.3.21-innodb-log Source distribution Type 'help;' or '\h' for help. Type '\c' to clear the buffer. mysql> show databases; +--------------------+ | Database | +--------------------+ | information_schema | | d2 | +--------------------+ 2 rows in set (0.00 sec) mysql> [ kefalo @ 29.03.2009. 19:36 ] @
hvala puno na brzom odgovoru.
to je to sto trazim! :) Copyright (C) 2001-2025 by www.elitesecurity.org. All rights reserved.
|