Category Archives: How to Fix

Solution to Vue cli · failed to download repo vuejs templates/webpack: connect etimeout followed by an IP digital error message

Vue scaffold construction error: Vue cli · failed to download repo vuejs templates/webpack: connect etimeout followed by an IP number,
in fact, it is a prompt for connection timeout. It should be that you need to climb over the wall when downloading a package, resulting in connection timeout. The screenshot of timeout error is as follows:

so we changed to offline GitHub, which is too difficult to open. Go here
1: https://codechina.csdn.net/mirrors/vuejs-templates/webpack?utm_ source=csdn_ github_ After downloading the accelerator, unzip it, and then change the name to webpack

2: Find. Vue templates in C: \ users \ administrator or ThinkPad in the user of drive C. if not, shift + right-click (or just right-click) MD. Vue templates to create a new one, and then put the webpack in it;

3: Go to your own project and right-click (or just right-click) Vue init webpack again. Project file name — offline; (parameter required – offline indicates offline initialization)

Initialization failed for ‘https://start.spring.io‘ Please check URL, network and proxy settings.

Error message:
initialization failed for‘ https://start.spring.io ’
Please check URL, network and proxy settings.

Error message:
Cannot download ‘ https://start.spring.io ’: connect timed out
the following error occurs when creating a new springboot project

1. Open file — settings

2. Search HTTP proxy – & gt; Check automatic proxy configuration URL:
– & gt; input https://start.spring.io –> Click auto detect proxy settings
– & gt; input https://start.spring.io –> Click OK

3. Finally, prompt: successful. It means success. Just recreate it

finally, it will be created successfully when it is newly created

PHP function file_ get_ Contents() reports an error when using HTTPS protocol: SSL operation failed

Scenario:

file_ get_ The contents () function is used to read the contents of a file into a string. It is one of the commonly used functions to read the contents of a file.

But sometimes file is used on the server_ get_ When the contents() function requests the URL file of HTTPS protocol, an error will be reported, and the file content cannot be read correctly,

reason:

The server is not properly configured with HTTPS certificate

Solution: (three solutions)

Method 1:

Download HTTPS certificate to server

The server downloads this certificate, http://curl.haxx.se/ca/cacert.pem
Php.ini configuration
openssl.cafile = “/ etc/SSL/certs/cacert. PEM”// the path where you actually download the certificate
Restart PHP

Method 2:

Use the curl function to process HTTPS parameters and obtain the file content

<?php
function getSSLPage($url) {
    $ch = curl_init();
    curl_setopt($ch, CURLOPT_HEADER, false);
    curl_setopt($ch, CURLOPT_URL, $url);
    curl_setopt($ch, CURLOPT_SSLVERSION,3); 
    $result = curl_exec($ch);
    curl_close($ch);
    return $result;
}

var_dump(getSSLPage("https://xxx.xxx.xxx"));
?>

Method 3:

Make file_ get_ The contents() function skips HTTPS authentication

$stream_opts = [
    "ssl" => [
        "verify_peer"=>false,
        "verify_peer_name"=>false,
    ]
]; 

$response = file_get_contents("https://xxx.xxx.xxx",false,stream_context_create($stream_opts));

  It is recommended to use curl function instead of file in development_ get_ Contents() function.

Failed to configure a DataSource: ‘url‘ attribute is not specified and no embedded datasource could

Error reason:
process analysis: you are integrating the springboot project. For me, in maven, bulid is added to prevent resources from being loaded. You can compare whether our contents are the same. I’m a fan of madness

<build>
    <resources>
        <resource>
            <directory>src/main/resources/</directory>
            <includes>
                <include>**/*.properties</include>
                <include>**/*.xml</include>
            </includes>
            <filtering>true</filtering>
        </resource>
        <resource>
            <directory>src/main/java</directory>
            <includes>
                <include>**/*.properties</include>
                <include>**/*.xml</include>
            </includes>
            <filtering>true</filtering>
        </resource>
    </resources>
</build>


I use the application.yaml format, but the bulid above is to prevent the xx.properties and xx.xml files from being loaded. The ox’s head is not the horse’s mouth.

resolvent:

Method 1: delete directly
method 2:
, changed to:

the first one is recommended. The second one I haven’t seen, but I ran and succeeded.

rabbit.listener.BlockingQueueConsumer$DeclarationException: Failed to declare queue(s)-2021-10-09

  Today’s Bug

I   Error: failed to start the order micro service. The message listening class cannot find the queue

org.springframework.amqp.rabbit.listener.BlockingQueueConsumer$DeclarationException:   Failed   to   declare   queue(s):[queue.ordertimeout]

  2、 Reason:   The configured dead letter queue is invalid and cannot be found

3、 Review the following configuration steps:

        1. Create switch: exchange.ordertimeout – & gt; Fanout type

        2. Create queue: queue.ordertimeout

        3. Bind switch exchange.ordertimeout and queue.ordertimeout

        4. Create queue.ordercreate

                (1) Arguments1: s-message-ttl=10000

                (2) Arguments2: x-dead-letter-exchange: exchange.ordertimeout  

          5. Principle: after creating an order – & gt; The lifetime of message queue.ordercreate is 10 seconds – & gt; After expiration, enter the dead letter exchange.ordertimeout – & gt;   Forward to message queue.ordertimeout  

The Tomcat connector configured to listen on port 8080 failed to start. The port may already be in u

***************************
APPLICATION FAILED TO START
***************************

Description:

The Tomcat connector configured to listen on port 8080 failed to start. The port may already be in use or the connector may be misconfigured.

Action:

Verify the connector's configuration, identify and stop any process that's listening on port 8080, or configure this application to listen on another port.

Port conflict
1. Open Task Manager
2. Open details
3. Find java.exe to end the task
if it still fails, you can clear the process by restarting the computer

Graphviz. Backend. Executablenotfound: failed to execute ‘dot’ Python uses graphviz to solve drawing errors

Solve the problem of drawing error with Python graphviz package

Finally, you need to restart pycharm to draw normally.

1. Error reporting

The error information is as follows:

graphviz.backend.ExecutableNotFound: failed to execute 'dot'make sure the Graphviz executables are on your systems' PATH

2. Determine variable type

The program prints variable data types plotted using graphviz

The print result shows that the type of drawing you want to draw is & lt; class ‘graphviz.dot.Digraph’>

3. Settle

3.1 Windows System Download and install graphviz

Graphviz download link to find the appropriate number of bits to download. Run the MSI file and install graphviz

3.2 configuring environment variables

Find the bin folder under the installation directory, copy the path, such as “D: \ software \ graphviz \ bin”, configure the system environment variable path, and create a new record for it. The content is the path copied in the previous step, as shown in Figure:

3.3 restart pycharm

After restart, use the. View () command to draw and display the image normally

. view() parameter explanation:
filename: picture name. The default is digraphv.gv. You can specify
Directory: picture saving path. The default is to save in the current path. You can specify

Run the code and view the image

es Failed to introspect Class [org.elasticsearch.client.RestHighLevelClient] from ClassLoader

This is usually a configuration error – it means that the code you use refers to a class, but the class itself is not in the classpath. In this case, this may also be a dependency management error in the relevant elasticsearch POMS itself, because it should contain the required classes

        <dependency>
            <groupId>org.elasticsearch.client</groupId>
            <artifactId>elasticsearch-rest-high-level-client</artifactId>
            <version>7.6.2</version>
        </dependency>
        <dependency>
            <groupId>org.elasticsearch.client</groupId>
            <artifactId>elasticsearch-rest-client</artifactId>
            <version>7.6.2</version>
        </dependency>
        <dependency>
            <groupId>org.elasticsearch</groupId>
            <artifactId>elasticsearch</artifactId>
            <version>7.6.2</version>
        </dependency>

Complete dependency, OK
(pay attention to switching to your version number)
maybe your mood is broken at the moment. Don’t worry. I believe it will bring you good luck _

NVIDIA-SMI has failed because it couldn’t communicate with the NVIDIA driver

Problem: Ubuntu 18.04 installs the graphics card driver normally. When the Ubuntu system is opened, the graphics card driver cannot be used. Use NVIDIA SMI to check the above errors.

resolvent:

Just execute two commands:

Sudo apt get install DKMS
sudo DKMS install – M NVIDIA – V 440.44 (440.44 indicates the driver version number)

Use the command ll/usr/SRC/to view the nvidia-440.44/ folder below. The version number varies from computer to computer

Then restart the computer, success.

QInotifyFileSystemWatcherEngine::addPaths: inotify_add_Watch failed: there is no space on the device

When Ubuntu runs many programs and monitors too many files, it may prompt: qinotifyfilesystemwatcherengine:: addpaths: inotify when running other programs_ add_ Watch failed: there is no space on the device

This involves the concept of Linux file system event monitoring framework

terms of settlement:

Add maximum number of monitoring files

Command settings: sudo sysctl fs.inotify.max_ user_ watches=524288

Effective: sudo sysctl – P

This method can only be solved temporarily. It will recover after restart. Enter the above two lines of commands every time you encounter this problem

Failed to bind properties under ‘‘ to com.zaxxer.hikari.HikariDataSource:

Problem Description:

An error was encountered while springboot was starting:

Error starting ApplicationContext. To display the conditions report re-run your application with 'debug' enabled.
2021-10-09 16:10:19.148 ERROR 3668 --- [           main] o.s.b.d.LoggingFailureAnalysisReporter   : 

***************************
APPLICATION FAILED TO START
***************************

Description:

Failed to bind properties under '' to com.zaxxer.hikari.HikariDataSource:

    Property: driver-class-name
    Value: com.mysql.cj.jdbc.Driver
    Origin: "driverClassName" from property source "source"
    Reason: java.lang.RuntimeException: Failed to load driver class com.mysql.cj.jdbc.Driver in either of HikariConfig class loader or Thread context classloader

Action:

Update your application's configuration

Cause analysis:

When testing springboot, the default is H2 database, and I use mysql, so I need to specify it in application.properties

Solution:

Specify the following in application.properties

spring.datasource.driver-class-name=com.mysql.jdbc.Driver