sudo apt upgrade git 报错

报错:sudo apt upgrade git

mariadb-common

E: Sub-process /usr/bin/dpkg returned an error code (1)

skywalk@ubjail1:~/github/moltbot$ sudo apt upgrade apt

Reading package lists... Done

Building dependency tree... Done

Reading state information... Done

apt is already the newest version (2.4.14).

Calculating upgrade... Done

The following packages will be upgraded:

dirmngr gnupg gnupg-l10n gnupg-utils gpg gpg-agent gpg-wks-client gpg-wks-server gpgconf gpgsm gpgv

libapache2-mod-php8.1 libavahi-client3 libavahi-common-data libavahi-common3 libcaca0 libglib2.0-0 libglib2.0-bin

libglib2.0-data libglib2.0-dev libglib2.0-dev-bin libpng-dev libpng-tools libpng16-16 libsodium-dev libsodium23

libtasn1-6 libtasn1-6-dev libtasn1-doc libxslt1-dev libxslt1.1 locales mariadb-server mariadb-server-10.6 openssl

php8.1 php8.1-cli php8.1-common php8.1-fpm php8.1-mysql php8.1-opcache php8.1-readline screen

43 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.

24 not fully installed or removed.

Need to get 0 B/24.9 MB of archives.

After this operation, 13.3 kB of additional disk space will be used.

Do you want to continue? Y/n y

Extracting templates from packages: 100%

Preconfiguring packages ...

Setting up mariadb-common (1:10.6.23-0ubuntu0.22.04.1) ...

update-alternatives: error: alternative path /etc/mysql/mariadb.cnf doesn't exist

dpkg: error processing package mariadb-common (--configure):

installed mariadb-common package post-installation script subprocess returned error exit status 2

Errors were encountered while processing:

mariadb-common

E: Sub-process /usr/bin/dpkg returned an error code (1)

重新配置包

复制代码
sudo dpkg --configure -a

不行,还是报错

dpkg: error processing package mariadb-server-10.6 (--configure):

dependency problems - leaving triggers unprocessed

Processing triggers for mailcap (3.70+nmu1ubuntu1) ...

Processing triggers for libc-bin (2.35-0ubuntu3.12) ...

Errors were encountered while processing:

mariadb-common

mariadb-client-core-10.6

libmariadb3:amd64

mariadb-client-10.6

mariadb-server-core-10.6

mariadb-server-10.6

skywalk@ubjail1:~/github/moltbot$ sudo apt upgrade git

Reading package lists... Done

Building dependency tree... Done

Reading state information... Done

git is already the newest version (1:2.34.1-1ubuntu1.15).

Calculating upgrade... Done

The following packages will be upgraded:

dirmngr gnupg gnupg-l10n gnupg-utils gpg gpg-agent gpg-wks-client gpg-wks-server gpgconf gpgsm gpgv

libapache2-mod-php8.1 libavahi-client3 libavahi-common-data libavahi-common3 libcaca0 libglib2.0-0 libglib2.0-bin

libglib2.0-data libglib2.0-dev libglib2.0-dev-bin libpng-dev libpng-tools libpng16-16 libsodium-dev libsodium23

libtasn1-6 libtasn1-6-dev libtasn1-doc libxslt1-dev libxslt1.1 locales mariadb-server mariadb-server-10.6 openssl

php8.1 php8.1-cli php8.1-common php8.1-fpm php8.1-mysql php8.1-opcache php8.1-readline screen

43 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.

5 not fully installed or removed.

Need to get 0 B/24.9 MB of archives.

After this operation, 13.3 kB of additional disk space will be used.

Do you want to continue? Y/n y

Extracting templates from packages: 100%

Preconfiguring packages ...

Setting up mariadb-common (1:10.6.23-0ubuntu0.22.04.1) ...

update-alternatives: error: alternative path /etc/mysql/mariadb.cnf doesn't exist

dpkg: error processing package mariadb-common (--configure):

installed mariadb-common package post-installation script subprocess returned error exit status 2

Errors were encountered while processing:

mariadb-common

E: Sub-process /usr/bin/dpkg returned an error code (1)

解决方法 尝试‌完全清除并重新安装‌:

复制代码
sudo apt purge mariadb-common mariadb-client-core-10.6 mariadb-client-10.6
sudo apt install mariadb-common mariadb-client-core-10.6 mariadb-client-10.6

安装完毕之后,再安装git等就ok了

git

正常

复制代码
git pull
remote: Enumerating objects: 5, done.
remote: Counting objects: 100% (4/4), done.
remote: Total 5 (delta 4), reused 4 (delta 4), pack-reused 1 (from 1)
Unpacking objects: 100% (5/5), 1.67 KiB | 243.00 KiB/s, done.
From https://github.com/moltbot/moltbot
   718bc3f9c..6372242da  main       -> origin/main
Updating 718bc3f9c..6372242da
Fast-forward
 ui/src/ui/app-chat.ts             | 17 ++++++++++++++++-
 ui/src/ui/app-gateway.ts          |  8 ++++++++
 ui/src/ui/app-lifecycle.ts        |  6 +++---
 ui/src/ui/app-render.helpers.ts   | 52 +++++++++++++++++++++++++++++++++++++++++++++-------
 ui/src/ui/app.ts                  |  1 +
 ui/src/ui/controllers/sessions.ts | 21 ++++++++++++++++-----
 6 files changed, 89 insertions(+), 16 deletions(-)
相关推荐
云泽80813 分钟前
Git 版本控制系统(下):从 .git 目录结构到冲突解决机制详解
大数据·git·elasticsearch
麻辣布丁7 小时前
Git冲突原因与解决方法全解
大数据·git·elasticsearch
一支黑色の铅笔11 小时前
VSCode 克隆Git项目
ide·git·vscode
拽着尾巴的鱼儿14 小时前
Idea:Cannot Run Git 无法运行git
java·git·intellij-idea
y小川17 小时前
【git】移除远端已删除的git分支
git
OsDepK1 天前
项目快速Git至仓库(完整版)
大数据·git·elasticsearch·搜索引擎
妙码生花1 天前
使用git更新ai-go-admin框架
前端·人工智能·git·golang·typescript·php
朝阳5811 天前
如何用 AI 自动生成规范的 Git 提交信息:从暂存区 diff 到 Conventional Commit
人工智能·git
hudawei9961 天前
有未保存的修改,不能切换分支
git·git stash·stash
康一夏1 天前
Git Commit 规范实践:Angular Commit 规范 + Commitlint 自动化验证
git·自动化·commit msg·commit规范