Category Archives: Error

[Solved] internal compiler error Killed (program cc1plus)

g++: internal compiler error: Killed (program cc1plus)

g++: internal compiler error: Killed (program cc1plus)
Please submit a full bug report,
with preprocessed source if appropriate.
See <http://bugzilla.redhat.com/bugzilla> for instructions.
gmake: *** [cmGeneratorTarget.o] Error 4
---------------------------------------------
Error when bootstrapping CMake:
Problem while running gmake
---------------------------------------------
Log of errors: /root/cmake-3.22.0/Bootstrap.cmk/cmake_bootstrap.log
---------------------------------------------

The reason is insufficient memory. The solution is to increase swap partition

[root@ALiYunOgenes cmake-3.22.0]# free -h
              total        used        free      shared  buff/cache   available
Mem:           991M        465M        257M        1.1M        268M        379M
Swap:            0B          0B          0B
[root@ALiYunOgenes cmake-3.22.0]# dd if=/dev/zero of=/var/swap bs=1024 count=2048000  
2048000+0 records in
2048000+0 records out
2097152000 bytes (2.1 GB) copied, 19.0987 s, 110 MB/s

[root@ALiYunOgenes cmake-3.22.0]# mkswap /var/swap 
Setting up swapspace version 1, size = 2047996 KiB
no label, UUID=d5ede89f-d76a-4b53-9ec9-256a9370fcfe

[root@ALiYunOgenes cmake-3.22.0]# swapon /var/swap 
swapon: /var/swap: insecure permissions 0644, 0600 suggested.
[root@ALiYunOgenes cmake-3.22.0]# vi /etc/fstab 
…………
/var/swap swap swap defaults 0 0
…………

[root@ALiYunOgenes cmake-3.22.0]# free -m          
              total        used        free      shared  buff/cache   available
Mem:            991         466          58           1         465         374
Swap:          1999           0        1999
[root@ALiYunOgenes cmake-3.22.0]# 

[Solved] harbor Error: because it doesn‘t contain any IP SANs

Bloggers encounter an interesting error when using Harbor:

Error response from daemon: Get https://192.168.2.250:443/v2/: x509:

cannot validate certificate for 192.168.2.250 because it doesn’t contain any IP SANs

Error reporting means: error response from the daemon: G ethttps://192.168.2.250:443/v2/: X509: unable to validate 192.168 2.250 because it does not contain any IP SAN

Blogger Harbor Address 192.168.2.250, using 443 as the secure port.

[reason]:

Docker was unable to validate the certificate for the private repository.

[solution]:

Don’t panic when you encounter a problem. Just hit the king and you’ll know how to solve it. I solved it this way:

1. Edit the docker configuration file (/etc/docker/daemon.JSON)

2. Add “secure registers”: [“192.168.2.250:443”], and specify the address and port of the harbor image warehouse.

3. Restart the docker service and the problem can be solved.

If it still cannot be solved, leave a message in the comment area.

[Solved] rabbitMQ: factory.newConnection() Error: com.rabbitmq.client.ShutdownSignalException

About rabbitmq: factory Newconnection() reported an error com rabbitmq. client.ShutdownSignalException
exception information

Exception in thread "main" java.io.IOException
	at com.rabbitmq.client.impl.AMQChannel.wrap(AMQChannel.java:129)
	at com.rabbitmq.client.impl.AMQChannel.wrap(AMQChannel.java:125)
	at com.rabbitmq.client.impl.AMQChannel.exnWrappingRpc(AMQChannel.java:147)
	at com.rabbitmq.client.impl.AMQConnection.start(AMQConnection.java:439)
	at com.rabbitmq.client.impl.recovery.RecoveryAwareAMQConnectionFactory.newConnection(RecoveryAwareAMQConnectionFactory.java:65)
	at com.rabbitmq.client.impl.recovery.AutorecoveringConnection.init(AutorecoveringConnection.java:160)
	at com.rabbitmq.client.ConnectionFactory.newConnection(ConnectionFactory.java:1216)
	at com.rabbitmq.client.ConnectionFactory.newConnection(ConnectionFactory.java:1173)
	at com.rabbitmq.client.ConnectionFactory.newConnection(ConnectionFactory.java:1131)
	at com.rabbitmq.client.ConnectionFactory.newConnection(ConnectionFactory.java:1294)
	at util.ConnectionUtil.getConnection(ConnectionUtil.java:40)
	at Foundation_auto ACK.Send.main(Send.java:27)
Caused by: com.rabbitmq.client.ShutdownSignalException: connection error; protocol method: #method<connection.close>(reply-code=530, reply-text=NOT_ALLOWED - vhost /kavito not found, class-id=10, method-id=40)
	at com.rabbitmq.utility.ValueOrException.getValue(ValueOrException.java:66)
	at com.rabbitmq.utility.BlockingValueOrException.uninterruptibleGetValue(BlockingValueOrException.java:36)
	at com.rabbitmq.client.impl.AMQChannel$BlockingRpcContinuation.getReply(AMQChannel.java:502)
	at com.rabbitmq.client.impl.AMQChannel.privateRpc(AMQChannel.java:293)
	at com.rabbitmq.client.impl.AMQChannel.exnWrappingRpc(AMQChannel.java:141)
	... 9 more

tools

public class ConnectionUtil {
    private static final String HOST = "127.0.0.1";
    /**
     * Here java access requires the use of 5672;
     * web access uses 15672;
     */
    private static final Integer PORT = 5672;
    private static final String VIRTUAL_HOST = "/kavito";
    private static final String USERNAME = "chen";
    private static final String PASSWORD = "a123";

    public static Connection getConnection() throws IOException, TimeoutException {
        // Define the connection factory
        ConnectionFactory factory = new ConnectionFactory();
        // Service address
        factory.setHost(HOST);
        // Port
        factory.setPort(PORT);

        // set account information, username, password, vhost
        // set virtual machine, one mq service can set multiple virtual machines, each virtual machine is equivalent to a separate mq
        factory.setVirtualHost(VIRTUAL_HOST);
        factory.setUsername(USERNAME);
        factory.setPassword(PASSWORD);

        // Get the connection through the factory
        Connection connection = factory.newConnection();
        return connection;
    }
}

problem-solving: my solution is not to use the online setting permission

Reference commands for setting permissions
rabbitmqctl set_permissions -p "/" username ".*" ".*" ".*"

My problem is caused by setting the virtual machine
the default virtual machine on rabbitmq is

and the virtual machine set in my code is

Solution:
the first Change the virtual machine in the code to

the second Create a new virtual machine named/kavito in rabbitmq (PS: the name here depends on your actual situation)

and set permissions for the corresponding user

[Solved] Pylink Windows Chinese path error: Specified file could not be opened

Solution:

Modify the jlink.py file under the pylink package path and find the flash_file method;

Find the self._dll.JLINK_DownloadFile line under this method, and modify the following parameter path.encode() to

path.encode(locale.getpreferredencoding()), Of course, you have to use the locale preamble package

[Solved] waterdrop Import hive to clickhouse Error: Too many partitions for single INSERT block (more than 100).

1. Problem description

Use waterdrop to import data into the Clickhouse, and then the log reports an error:

Caused by: ru.yandex.clickhouse.except.ClickHouseException: ClickHouse exception, code: 252, host: 10.252.32.26, port: 8123; Code: 252, e.displayText() = DB::Exception: Too many partitions for single INSERT block (more than 100). The limit is controlled by 'max_partitions_per_insert_block' setting. Large number of partitions is a common misconception. It will lead to severe negative performance impact, including slow server startup, slow INSERT queries and slow SELECT queries. Recommended total number of partitions for a table is under 1000..10000. Please note, that partitioning is not intended to speed up SELECT queries (ORDER BY key is sufficient to make range queries fast). Partitions are intended for data manipulation (DROP PARTITION, etc). (version 20.3.10.75 (official build))

	at ru.yandex.clickhouse.except.ClickHouseExceptionSpecifier.specify(ClickHouseExceptionSpecifier.java:58)
	at ru.yandex.clickhouse.except.ClickHouseExceptionSpecifier.specify(ClickHouseExceptionSpecifier.java:28)
	at ru.yandex.clickhouse.ClickHouseStatementImpl.checkForErrorAndThrow(ClickHouseStatementImpl.java:680)
	at ru.yandex.clickhouse.ClickHouseStatementImpl.sendStream(ClickHouseStatementImpl.java:656)
	at ru.yandex.clickhouse.ClickHouseStatementImpl.sendStream(ClickHouseStatementImpl.java:639)
	at ru.yandex.clickhouse.ClickHousePreparedStatementImpl.executeBatch(ClickHousePreparedStatementImpl.java:382)
	at io.github.interestinglab.waterdrop.output.Clickhouse$$anonfun$process$1.apply(Clickhouse.scala:133)
	at io.github.interestinglab.waterdrop.output.Clickhouse$$anonfun$process$1.apply(Clickhouse.scala:115)
	at org.apache.spark.rdd.RDD$$anonfun$foreachPartition$1$$anonfun$apply$29.apply(RDD.scala:926)
	at org.apache.spark.rdd.RDD$$anonfun$foreachPartition$1$$anonfun$apply$29.apply(RDD.scala:926)
	at org.apache.spark.SparkContext$$anonfun$runJob$5.apply(SparkContext.scala:2069)
	at org.apache.spark.SparkContext$$anonfun$runJob$5.apply(SparkContext.scala:2069)
	at org.apache.spark.scheduler.ResultTask.runTask(ResultTask.scala:87)
	at org.apache.spark.scheduler.Task.run(Task.scala:108)
	at org.apache.spark.executor.Executor$TaskRunner.run(Executor.scala:338)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
	at java.lang.Thread.run(Thread.java:748)
Caused by: java.lang.Throwable: Code: 252, e.displayText() = DB::Exception: Too many partitions for single INSERT block (more than 100). The limit is controlled by 'max_partitions_per_insert_block' setting. Large number of partitions is a common misconception. It will lead to severe negative performance impact, including slow server startup, slow INSERT queries and slow SELECT queries. Recommended total number of partitions for a table is under 1000..10000. Please note, that partitioning is not intended to speed up SELECT queries (ORDER BY key is sufficient to make range queries fast). Partitions are intended for data manipulation (DROP PARTITION, etc). (version 20.3.10.75 (official build))

2. Cause of problem

Clickhouse limit Max_partitions_per_insert_Block, that is, the partition of each inserted block. The solution is to modify this parameter and restart Clickhouse.

3. Solution

1. Modify users XML configuration

vi users.xml

add to

<max_partitions_per_insert_block>5000</max_partitions_per_insert_block>

2. Restart

sudo systemctl restart clickhouse-server

[Solved] flutter Project Error: ScrollController attached to multiple scroll views, Failed assertion: line 109 pos 12

1. Explain

Recently, I encountered an error when writing the shuttle project:

The following assertion was thrown while handling a gesture:
ScrollController attached to multiple scroll views.
'package:flutter/src/widgets/scroll_controller.dart':
Failed assertion: line 109 pos 12: '_positions.length == 1'

Reasons for error reporting:
1 The drawing function added to the project needs to navigate to different pages through the menu items of the drawing
2. A bottom navigation bar is added to the home page to navigate to different pages through the pagecontroller
3. The project manages routing and status through geTx.

Description of the problem: navigate to the settings or other pages through the drawer, and then re-navigate to the home page through the drawer. Click the item item item of the BottomNavigationBar, and will appear the error messages:

Failed assertion: line 109 pos 12: ‘_positions.length == 1’


2. Solution:

1. Drawer navigation uses Get.offAndToNamed(‘12313’); to jump.
2. You need to reinitialize the pageController every time you jump to the homepage. Through the build method of GetView, the controller is reinitialized every time the homepage interface is redrawn.

Specific operation:

code for the navigation part of the drawer:

class AppRouteProvide {
  Future onRouteTo(String routeName) {
    switch (routeName) {
      case Routes.Auth:
        Get.toNamed(Routes.Auth);
        break;
      case Routes.Home:
        Get.offAndToNamed(Routes.Home);
        break;
      case Routes.Help:
        Get.offAndToNamed(Routes.Help);
        break;
      case Routes.Splash:
        Get.toNamed(Routes.Splash);
        break;
      case Routes.Connect:
        Get.offAndToNamed(Routes.Connect);
        break;
      case Routes.Setting:
        Get.offAndToNamed(Routes.Setting);
        break;
    }
    return Future.value();
  }
}

Code of home page view:

class HomeScreen extends GetView<HomeController> {
  @override
  Widget build(BuildContext context) {
    // print('HomeScreen build');
    if (controller.pageController.hasClients) {
      controller.onClose();
      controller.onInit();
    }
    return AppbarWidgetScreen(
      body: _buildBody(context),
      bottomBar: _buildBottomNavigationBar(context),
    );
  }

Home page controller part code


class HomeController extends GetxController {
  final ApiRepository apiRepository;
  RxInt selectedIndex = 0.obs;

  late PageController pageController;
  RxList<Widget> widgetPage = <Widget>[
    HomeMainScreen(),
    HomeBuyScreen(),
    HomeCertScreen(),
    HomeSellScreen(),
    HomeMineScreen(),
  ].obs;

  HomeController({required this.apiRepository});

  @override
  void onReady() {
    super.onReady();
  }

  @override
  void onInit() {
    print('HomeController onInit()');
    pageController = PageController(
      initialPage: selectedIndex.value,
      keepPage: true,
    );
    super.onInit();
  }

  @override
  void onClose() {
    super.onClose();
  }

[Solved] Windows startup error: unable to find launcherrsxruntime.exe

Problem phenomenon:

The win10 system will report the following error after each restart,

Windows cannot find the file

C:\Program Files\WindowsApps\AdvancedMicroDeviceslnc-2.AMDRad… launcherrsxruntime.exe

Cause of problem:

It is estimated that the file in AMD’s driver is damaged due to what software is installed or abnormal startup

Solution:

Use AMD’s own driver management software to repair it (effective through personal test). The repair steps are as follows:

Press wins + I to enter Windows settings –> Application –> Applications and functions–> AMD Radeon Software –> Advanced options –> Repair

Restart verification after repair

Note: the above solutions are not necessarily applicable to all situations. If they cannot be solved, you can try to upgrade the driver or reinstall the driver.

[Solved] No corresponding flash error is found during MDK download

1. There is no stmf10x 128K flash model in keilmdk

2. Go to keil’s official website to download the DFP package of the corresponding model

you can download the latest installation package
3. Put the downloaded DFP into the Keil installation directory, (you can leave it alone. The installation path of the pack package is the default and cannot be changed)

4. After installation, you need to put the. FLM file in the downloaded package under this path

5. The. FLM file cannot be found in the downloaded DFP. You need to copy the. FLM file in
G:\keil\arm\pack\keil\stm32f1xx_df\2.4.0\flash

copy the copied file Put the parts into storage
in FLM package
G:\keil\arm\flash

then restart keil OK

VScode jsconfig.json files First Line error for no reasons

Error reporting:

analysis

Vscode will automatically check the semantics of JavaScript files. Because of the custom jsconfig The JSON file cannot overwrite the configuration of vscode, so an error will be reported.

Solution:

Open the configuration settings.json file and let the custom jsconfig.js file override the vscode default options.

[Solved] Browser Access Error: Request Header or Cookie too large

Browser access page error

Error details

Possible causes:

The request header is too large, which is usually caused by writing a large value in the cookie. Access too frequently, the browser cache is too large, resulting in errors.

Solution:

The client can clean up the cookie cache
the server adjusts the size of nginx buffer and adds two lines

http
{
client_header_buffer_size 32k;
large_client_header_buffers 4 32k;  
......
}

Restart service

[Solved] NPM install error: Maximum call stack size exceeded

1. Scene reproduction

Today, I wanted to pull someone else’s code to have a look, and then NPM install reported this error: “maximum call stack size exceeded”. I haven’t seen this error before, and finally found a solution.

2. Solution

1. Upgrade NPM, NPM install – G NPM
2 Re execute, NPM/cnpm install
3 If not, try clearing the NPM cache. NPM cache clean — force
4 Re execute, NPM/cnpm install