Centos7—MySQL8 rpm安装依赖问题解决
在安装mysql-community-server-8.0.28-1.el7.x86_64.rpm出错,错误的依赖如下
Mysql rpm依赖问题大致解决方式如下:问题1: /usr/bin/perl is needed by mysql-community-server-8.0.28-1.el7.x86_64
解决方案:安装prel模块
1yum install -y perl-Module-Install.noarch
问题2: libaio.so.1(LIBAIO_0.1)(64bit) is needed by mysql-community-server-8.0.28-1.el7.x86_64
1yum install libaio
问题3: libnuma.so.1(libnuma_1.1)(64bit) is needed by mysql-community-server-8.0.28-1.el7.x86_64
1yum -y install numactl
问题4: mysql-community-icu-data-files = 8 ...
NIO——非阻塞式Demo
客户端
123456789101112131415161718192021222324252627public static void client() { try { //获取客户端通道 SocketChannel sc = SocketChannel.open(new InetSocketAddress("127.0.0.1", 8899)); //切换到非阻塞模式 sc.configureBlocking(false); //分配指定大学缓冲区 ByteBuffer buf = ByteBuffer.allocate(1024); //发送数据给服务端 Scanner scan = new Scanner(System.in); while (scan.hasNextLine()) { S ...
快速排序
快速排序
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051public static void main(String[] args) { int[] arr1 = {6, 1, 2, 23, 75, 6, 4, 7, 9, 3, 4, 5, 10, 8, 11, -1, 0}; int start = 0; int end = arr1.length - 1; System.out.print("首次排序-"); quickSort(arr1, start, end); System.out.print("【排序结果1:" + Arrays.toString(arr1)); System.out.println("\n快排次数:" + quickSortCount ...
冒泡排序与选择排序
冒泡排序
1.优点:比较简单,空间复杂度较低,是稳定的;
2.缺点:时间复杂度太高,效率慢;
12345678910int[] arr = new int[]{12, 3, 13, 15, 10, 2, 9, 3, 17}; for (int i = 0; i < arr.length; i++) { for (int n = 0; n < arr.length; n++) { if (arr[n] > arr[i]) { int temp = arr[i]; arr[i] = arr[n]; arr[n] = temp; } } }
选择排序
1.优点:一轮比较只需要换一次位置;
2.缺点:效率慢,不稳定;
1234567891011121314151617181 ...
免费SSR分享
-更新时间2022/3/4
复制下面文本导入Shadowsocks
1234567891011121314151617181920vmess://ew0KICAidiI6ICIyIiwNCiAgInBzIjogIkBTU1JTVUItVjAxLeS7mOi0ueaOqOiNkDpzdW8ueXQvc3Nyc3ViIiwNCiAgImFkZCI6ICJ0dW5uZWwtdHctYS0wMS54bmNsb3VkLnh5eiIsDQogICJwb3J0IjogIjUwNSIsDQogICJpZCI6ICI4MGJjNmRmNC0yOTA1LTM1ZjktYTY3MS0zNWJjODAzZDkzY2QiLA0KICAiYWlkIjogIjEiLA0KICAic2N5IjogImF1dG8iLA0KICAibmV0IjogIndzIiwNCiAgInR5cGUiOiAibm9uZSIsDQogICJob3N0IjogInR1bm5lbC10dy1hLTAxLnhuY2xvdWQueHl6IiwNCiAgInBhdGgiOiAiL25pYW95dW4iLA0KICAidGxzIjogIiIsDQo ...