In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-02-14 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >
Share
Shulou(Shulou.com)06/03 Report--
This article mainly introduces "how to solve the Could not resolve-api.weixin.qq.com problem in Linux". In the daily operation, I believe many people have doubts about how to solve the Could not resolve-api.weixin.qq.com problem in Linux. The editor consulted all kinds of materials and sorted out simple and easy-to-use operation methods. I hope it will be helpful to answer the doubt of "how to solve the Could not resolve-api.weixin.qq.com problem in Linux"! Next, please follow the editor to study!
However, when I was complacent, I was poured cold water on my first attempt to learn to install, and when the program was running properly, there was a problem shown in the following figure:
There is a problem with "Could not resolve: api.weixin.qq.com (Could not contact DNS servers)".
According to Mini Program development documents, normal follow-up of this module will not lead to any other situation, so when I first saw this error message, I was a little confused. My first reaction was that the wrong domain "api.weixin.qq.com" belonged to Wechat. If I reported an error, there should be a problem on Wechat. Then I immediately called the relevant Wechat customer service number to inquire. The result is not Wechat's problem.
So what's the problem? Is it the problem on the server? So I tried to use ping as a domain name to see if I could ping. After command testing, I found that I couldn't communicate with data, but I didn't know how to correct errors like this, which were blocked by ping.
So I began to conduct a corresponding search query on Baidu, and found that I could not solve this problem better. Finally, I consulted my friend. Under my friend's way of thinking, I finally solved this problem. "good memory is not as good as bad writing". Development needs to learn to learn, but also to learn to record, then I will make a simple record this time and share the experience of this project with you.
1. First of all, we troubleshoot the problems according to the problems. Since the backend uses curl to connect, we first need to ensure that our curl connection is normal. We need to test whether curl can parse dns properly, and use the following command to test:
Curl api.weixing.qq.com
The final test result is that ping does not work! Then we began to implement the corresponding new solution.
2.ping is generally a problem related to DNS configuration, so we started to edit and modify the DNS configuration file:
Vi / etc/resolv.conf
Based on the contents of the source file, add the following two lines of data code:
Nameserver 114.114.114.114 nameserver 8.8.8.8
Because the PHP environment I live in is Linux, and I operate pagodas, I use xshell to modify the data in the command line interface, modify and save, and then retest curl, and the problem is solved.
Each development problem will give us a new warning, let us find the problem and try our best to solve the problem, but don't forget, after solving the problem, we should learn to record the process of the problem, learn to share it with you, let's cheer together and roam in the ocean of knowledge developed by PHP!
At this point, the study on "how to solve the Could not resolve-api.weixin.qq.com problem in Linux" is over. I hope to be able to solve your doubts. The collocation of theory and practice can better help you learn, go and try it! If you want to continue to learn more related knowledge, please continue to follow the website, the editor will continue to work hard to bring you more practical articles!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.