Small knowledge, big challenge! This article is participating in the creation activity of “Essential Tips for Programmers”.
This article has participated in the “Digitalstar Project” and won a creative gift package to challenge the creative incentive money.
If the Linux VM password is forgotten, change the password in but user mode
Step 1: Restart the VIRTUAL machine. When the progress bar appears again, press E (to start the editor) to enter the following interface. Press E again
Step 2: After entering the following interface, select the second item by pressing up and down keys and press eStep 3: After entering the following screen, type space and s after quiet, then press Enter to confirmStep 4: After entering the following interface, press B (boot)Step 5: Enter the single-user mode, enter passwd root (root indicates the user name whose password needs to be reset) and the new password, and press Enter to confirmStep 6: Enter reboot to restart the systemStep 7: After the restart, log in with the new password
The domain name cannot be resolved.
If the following error message is displayed during the ping of www.baidu.com on the Linux host, domain name resolution is abnormal
#ping www.baidu.com
ping:unknown host www.baidu.com
First of all, under the premise of no problem in the network (can Ping Baidu IP 119.75.217.109, but can not Ping through www.baidu.com)
Solution: Check whether the DNS server is configured. If the DNS server is not configured, you are advised to set it to Google DNS (8.8.8.8, There is no problem after the general setting is completed.) If there is, you can try several common DNS in China (DNS 114.114.114.114 of the three major carriers, DNS 223.5.5.5.5 of Ali Cloud,223.6.6.6)
#vim/etc/resolv.conf nameserver 8.8.8.8 # add this line to /etc/resolv.
2. Restart nic (need to restart service after modifying configuration file) # Service Network Restort
Then you can ping www.baidu.com and resolve the domain name normally