Important! This is an automatic machine translated page. If you can read english, you should Click Here to read the original English version of the article.

MySql: Give Root User Logon Permission From Any Host MySql: Dajte Root prihlásení užívateľa Povolenie od ľubovoľného hostiteľa

Note that this is Not very secure, and should only be used for a local development box where you don't feel like setting up individual permissions, but still need to connect from other machines. Všimnite si, že to nie je príliš bezpečné, a mali by byť použité len pre miestny rozvoj okno, kde nemáte pocit, že vytvorenie individuálnych povolení, ale ešte potrebné pripojiť z iných počítačov.

To configure this feature, you'll need to update the mysql user table to allow access from any remote host, using the % wildcard. Ak chcete nastaviť túto funkciu, budete musieť aktualizovať tabuľku mysql užívateľ povoliť prístup z akéhokoľvek vzdialeného počítača pomocou zástupných%.

Open the command-line mysql client on the server using the root account. Otvorte príkazový riadok-mysql klienta na server pomocou konta root.

mysql -uroot mysql-uroot

Then you will want to run the following two commands, to see what the root user host is set to already: Potom budete chcieť spustiť nasledujúce dva príkazy, aby zistili, čo užívateľa root hostiteľa je už nastavený na:

use mysql; využitia mysql;
select host, user from user; vyberte hosť, užívateľ od užívateľa;

Here's an example of the output on my database, which is pretty much the default settings. Tu je príklad výstupu na mojej databáze, ktorá je do veľkej miery predvolené nastavenia. Note that ubuntuserv is the hostname of my server. Všimnite si, že ubuntuserv je meno môjho servera.

mysql> use mysql; mysql> používať mysql;
Reading table information for completion of table and column names Čítanie tabuľke informácie pre vyplnenie tabuľky a názvy stĺpcov
You can turn off this feature to get a quicker startup with -A Môžete túto funkciu vypnúť, aby si rýchlejšie štarte sa --
Database changed Databáza zmenil

mysql> select host,user from user; mysql> select hosť, užívateľ od užívateľa;
+—————+——————+ +-----+------+
| host | user | | Host | užívateľa |
+—————+——————+ +-----+------+
| ubuntuserv | root | | Ubuntuserv | root |
| localhost | debian-sys-maint | | Localhostu | debian-sys-maint |
| localhost | root | | Localhostu | root |
+—————+——————+ +-----+------+
3 rows in set (0.00 sec) 3 rows in set (0.00 sec)

Now I'll update the ubuntuserv host to use the wildcard, and then issue the command to reload the privilege tables. Teraz budem aktualizovať ubuntuserv hostiteľa použiť zástupný, a potom sa vydať príkaz znovu načítať oprávnenie tabuľky. If you are running this command, substitute the hostname of your box for ubuntuserv. Ak ste sa spustením tohto príkazu nahraďte hostname vášho box pre ubuntuserv.

update user set host='%' where user='root' and host='ubuntuserv'; Aktualizácia užívateľské nastavenia host = '%', kde user = 'root' a host = 'ubuntuserv';
flush privileges; flush privileges;

That's all there is to it. To je všetko, čo sa to. Now I was able to connect to that server from any other machine on my network, using the root account. Teraz som bol schopný pripojiť k tomuto serveru z iného stroja v sieti pomocou konta root.

Again, note this isn't very secure, and you should at least make sure that you've Znovu si uvedomte, to nie je príliš bezpečné, a mali by ste aspoň uistiť, že ste set a root password nastaviť heslo užívateľa root . .

This article was originally written on 02/9/07 Tagged with: Tento článok bol pôvodne napísaný na 02/9/07 Tagged s: Database Databáza , , MySQL MySQL , , Programming Programovanie

Daily Email Updates Denný Svářeč

You can get our how-to articles in your inbox each day for free. Môžete si naše jak-na články vo vašej schránky každý deň zadarmo. Just enter your name and email below: Stačí zadať svoje meno a e-mail nižšie:


Name: Meno:
Email: E-mail:

Comments (3) Komentáre (3)

  1. daniel daniel

    I'm not exactly sure *why* you would want to do this. Nie som si úplne istý, prečo * * by ste chceli urobiť. IP based authentication is an extremely useful security feature, disabling it – especially for the root user – is probably a bad idea. Overovanie na základe IP je veľmi užitočná funkcia zabezpečenia, vypnúť je - najmä pre užívateľa root - je pravdepodobne zlý nápad.

    That said, there really isn't anything wrong with allowing a limited user account access from every IP. To hovorilo, tam naozaj nie je nič zlého umožňuje obmedzený prístup k užívateľskému účtu z každej IP. :-)

  2. The Geek Geek

    daniel, Daniel,

    That's why I noted that it isn't very secure a number of times =) To je dôvod, prečo som si všimol, že to nie je príliš bezpečné, koľkokrát =)

  3. Juan Juan

    I appreciated this. Vážila som si to. It has been a while since I have had to build a project from scratch. To bolo, čo som musel postaviť projekt na zelenej lúke. With this reference, I can now get on with development. S týmto odkazom, teraz môžem pustiť do vývoja. Later, I will absolutely want to lock down for my customer. Neskôr, budem úplne chcieť uzamknúť pre svojich zákazníkov. Then I hope to find another reference solution just as easily. Potom dúfam, že nájsť inú referenčný roztok rovnako ľahko.

    Actually implementing IP based authentication may not be the best answer for me due to the environment I will be in, but I will be investigating it. Vlastne sa vykonáva vyšetrovanie na základe overenia nemusí byť najlepšie riešenie pre mňa vzhľadom k životnému prostrediu budem mať, ale budem sa vyšetrujú. Simple is the essence of effectiveness for me. Jednoduchá je podstata efektívnosti pre mňa.

    And I do not plan on giving out the root password. A ja nemám plán na rozdávanie heslo užívateľa root. Isn't that a measure of security? Nie je to ako bezpečnostné opatrenia?


Leave a Comment Zanechať komentár




Leave your Zanechajte svoj friendly priateľský comment here. komentár tu.

If you have a computer help question, Ak máte počítač pomôže otázku, click here to leave it on the forums kliknite tu nechať to na fórach instead. miesto.

Note: Your comment may not show up immediately on the site. Poznámka: Váš komentár sa nezobrazia okamžite na mieste.

Our Friends Naši priatelia
Getting Started Začíname


About How-To Geek O tom, ako-To Geek
What Is That Process? Čo je to za proces?
svchost.exe svchost.exe
jusched.exe jusched.exe
dwm.exe Dwm.exe
ctfmon.exe ctfmon.exe
wmpnetwk.exe wmpnetwk.exe
wmpnscfg.exe WMPNSCFG.exe
rundll32.exe rundll32.exe
wfcrun32.exe wfcrun32.exe
Ipoint.exe Ipoint.exe
Itype.exe Itype.exe
Wfica32.exe Wfica32.exe
Mobsync.exe Mobsync.exe
conhost.exe conhost.exe
Dpupdchk.exe Dpupdchk.exe Adobe_Updater.exe Adobe_Updater.exe

Copyright © 2006-2009 HowToGeek.com. Copyright © 2006-2009 HowToGeek.com. All Rights Reserved. All Rights Reserved.