Ubuntu下忘记MySQL root密码解决方法
Linux下忘记MySQL root密码解决方法,基于Ubuntu 12.04 LTS。
Linux下忘记MySQL root密码解决方法,,基于Ubuntu 12.04 LTS。
忘了mysql密码,从网上找到的解决方案记录在这里。
编辑mysql的配置文件/etc/mysql/my.cnf,在[mysqld]段下加入一行“skip-grant-tables”。
重启mysql服务
@ubuntu:~$ sudo service mysql restart
mysql stop/waiting
mysql start/running, process 18669
用空密码进入mysql管理命令行,切换到mysql库。
@ubuntu:~$ mysql
Welcome to the MySQL monitor. Commands end with ; or \g.
mysql> use mysql
Database changed
执行update user set password=PASSWORD("new_pass") where user='root'; 把密码重置为new_pass。退出数据库管理。
mysql> update user set password=PASSWORD("new_pass") where user='root';
Query OK, 0 rows affected (0.00 sec)
Rows matched: 4 Changed: 0 Warnings: 0
mysql>quit
回到vim /etc/mysql/my.cnf,把刚才加入的那一行“skip-grant-tables”注释或删除掉。
再次重启mysql服务sudo service mysql restart,使用新的密码登陆,修改成功。
@ubuntu:~$ mysql -uroot -pnew_pass
Welcome to the MySQL monitor. Commands end with ; or \g.
mysql>

Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

AI Hentai Generator
Generate AI Hentai for free.

Hot Article

Hot Tools

Notepad++7.3.1
Easy-to-use and free code editor

SublimeText3 Chinese version
Chinese version, very easy to use

Zend Studio 13.0.1
Powerful PHP integrated development environment

Dreamweaver CS6
Visual web development tools

SublimeText3 Mac version
God-level code editing software (SublimeText3)

Hot Topics



Driven by the era of automotive electrification, China's domestic automakers are actively involved in the production of electric supercars. Recently, Haopin, a high-end electric brand owned by GAC Aian, launched an electric supercar called SSR. Previously, BYD's Yangwang U9 also received widespread attention. Recently, a video was circulated on the Internet, purportedly showing Yangwang. U9 test video. In the video, a U9 is speeding on the track. Surprisingly, the vehicle's brake discs flash bright orange, making it look like it is competing in the 24 Hours of Le Mans. Particularly striking is the fact that the brake discs on the front wheels are at least twice as bright as those on the rear wheels. However, it is impossible to determine from the video whether the flash of light is caused by the flames produced by the brake discs during braking or whether it is the lighting effect of the vehicle. exhaust

When some Win7 laptop customers use the numeric keyboard, they encounter the reason why they type u but it becomes 4. what happen? In fact, this is because your laptop has the keyboard integrated into the letter keys. You can fix this problem by simply closing the keyboard. The specific steps are as follows: FN+nunlock key conversion can input English letters normally. This method can also be used if the customer encounters pressing I to change to 5. How to solve the problem that the win7 numeric keyboard u becomes 4:1. For better convenience, the laptop does not have a small keyboard area. Therefore, there are keys that define the function of the numeric keypad. You can use the FN+nunlock key to convert. Some must use shift+numlock to enter English or data. 2.Numpad-

The OKX trading platform offers a variety of rates, including transaction fees, withdrawal fees and financing fees. For spot transactions, transaction fees vary according to transaction volume and VIP level, and adopt the "market maker model", that is, the market charges a lower handling fee for each transaction. In addition, OKX also offers a variety of futures contracts, including currency standard contracts, USDT contracts and delivery contracts, and the fee structure of each contract is also different.

The article introduces that virtual currency is a digital or virtual currency form that relies on cryptography and trades through peer-to-peer networks, and lists common currencies such as Bitcoin. It is usually available on cryptocurrency exchanges such as Coinbase, and all the advantages and disadvantages of each transaction. It emphasizes that the purchase of virtual currency is high, the price fluctuates greatly, and is prone to fraud and hacking. It reminds you to conduct sufficient research before investing and only invest in funds that can bear losses. The information is for reference only and is not investment advice.

When we use the win10 operating system, some friends need to use UF u8 on the computer because of work but don’t know how to operate it. Regarding this problem, the editor thinks that we can download UF u8 online first, and then go through the properties of the computer. Just make the corresponding settings, such as changing the computer name, modifying the registry, etc. Let’s take a look at how the editor did it for the detailed steps~ UFIDA u8win10 installation tutorial step 1: 1. On the “This PC” icon, select “Properties”; 2. Click Change under computer name, domain and workgroup settings Setting button: 3. Click on the "Computer Name" tab and enter the name that needs to be modified in the computer name field (English letters within 8 digits, excluding punctuation and special symbols); 4.

TRON, a decentralized content entertainment platform based on blockchain technology, provides a comprehensive ecosystem that supports a variety of digital assets. The most well-known currency on the TRON chain is TRONIX (TRX), a practical token used to pay transaction fees and provide network incentives.

Ripple (XRP) Outlook: Can the altcoin season exceed $4? This article will explore whether Ripple (XRP) can break through the all-time high of $4 in the upcoming altcoin season. Despite the overall cryptocurrency market sluggish, XRP still has upside potential. Can XRP break through $4? Analysts predict XRP will rebound in the coming months, even reaching an all-time high of $4.12 on April 15, up nearly 80%. However, the average forecast price is around $3.12, and April 15 may be just a brief peak. XRP's cooperation with South Korea and the approval process of XRPETF will be key factors affecting its price. South Korea cooperation will increase XRP's market share in South Korea; and the approval of XRPETF will

U coins (UNI), a native token of the decentralized exchange Uniswap, is widely used in the field of decentralized finance. This article introduces ten top U currency trading apps, including Uniswap, Coinbase, Binance, Gemini, Kraken, FTX, Huobi Global, Bybit, KuCoin and Gate.io. These apps cover a wide range of user needs, from beginner-friendly to advanced trading features.
