我是新的ubuntu和安装了Ubuntu22.04.2LTS 64位和Gnome版本42.5。我在windows旁边安装了linux。ubuntu版本是我在大学的老师所要求的。
但是当我试图使用GUI或终端安装一些东西时,问题就开始出现了。例如,我现在不能打开'Ubuntu软件‘,我昨天经常打开它,但是它也没有正常显示,当我点击任何东西时,软件中心就崩溃了。
我在我的ubuntu上所做的事情:安装一个主题,跟随https://itsfoss.com/best-gtk-themes/。在https://github.com/zq1997/deepin-winehttps://github.com/zq1997/deepin-wine上安装一个深葡萄酒来安装微信。
顺便说一下,由于我在大陆中国,我必须设置一个代理,我用‘手动’->代理设置网络代理: 127.0.0.1;7890 // HTTPs代理: 127.0.0.1;7890 //HTTPs代理:127.0.0.1;7890。如果这是正确的方法,我就不会,因为我以前没有经验。但是我现在可以访问所有像youtube这样的外国网站,这些网站没有代理是无法访问的。来自清华的服务器,我在下面的测试中补充说,也是我的导师推荐的,但它不能正常工作。
我也不能在终端安装东西。例如,如果我键入
sudo apt install wine终点站告诉我
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:
The following packages have unmet dependencies:
wine : Depends: wine64 (>= 6.0.3~repack-1) but it is not going to be installed or
wine32 (>= 6.0.3~repack-1)
Depends: wine64 (< 6.0.3~repack-1.1~) but it is not going to be installed or
wine32 (< 6.0.3~repack-1.1~)
E: Unable to correct problems, you have held broken packages.在软件和更新中,我启用了前四个选项,并从在ubuntu提供的测试中性能最好的马来西亚服务器下载。在第二节,对不起,我没有一个像样的截图软件,因为我也不能安装任何软件
我可能做了一些不恰当的事情,意外地移除了一些服务器。
如果我输入
$ cat /etc/apt/sources.list
deb http://mirrors.tuna.tsinghua.edu.cn/ubuntu/ jammy main restricted universe multiverse
deb http://my.mirrors.thegigabit.com/ubuntu/ jammy main universe restricted multiverse我还成功地根据教师的要求安装了下列软件包(附sudo):
apt-get install build-essential # build-essential packages, include binary utilities, gcc, make, and so on
apt-get install man # on-line reference manual
apt-get install gcc-doc # on-line reference manual for gcc
apt-get install gdb # GNU debugger
apt-get install git # revision control system
apt-get install libreadline-dev # a library used later
apt-get install libsdl2-dev # a library used later
apt-get install llvm llvm-dev # llvm project, which contains libraries used later
apt-get install llvm-11 llvm-11-dev # only for ubuntu20.04我尝试过的其他帖子提供的解决方案:
~$ sudo apt-get --purge --reinstall install software-center
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
Package software-center is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source
E: Package 'software-center' has no installation candidate$ sudo apt clean
$ sudo apt update && sudo apt upgrade
Hit:1 http://my.mirrors.thegigabit.com/ubuntu jammy InRelease
Hit:2 http://mirrors.tuna.tsinghua.edu.cn/ubuntu jammy InRelease
Hit:3 https://dl.google.com/linux/chrome/deb stable InRelease
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
All packages are up to date.
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
Calculating upgrade... Done
Get more security updates through Ubuntu Pro with 'esm-apps' enabled:
libavcodec-extra libavdevice58 ffmpeg libpostproc55 libavcodec-extra58
libavutil56 libswscale5 libswresample3 libavformat58 libavfilter7
Learn more about Ubuntu Pro at https://ubuntu.com/pro
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
$ sudo apt autoremove gnome-software && sudo apt install gnome-software
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
The following packages will be REMOVED:
gnome-software gnome-software-common gnome-software-plugin-snap
0 upgraded, 0 newly installed, 3 to remove and 0 not upgraded.
After this operation, 3,251 kB disk space will be freed.
Do you want to continue? [Y/n] y
(Reading database ... 241694 files and directories currently installed.)
Removing gnome-software-plugin-snap (41.5-2) ...
Removing gnome-software (41.5-2) ...
Removing gnome-software-common (41.5-2) ...
Processing triggers for hicolor-icon-theme (0.17-2) ...
Processing triggers for gnome-menus (3.36.0-1ubuntu3) ...
Processing triggers for libglib2.0-0:amd64 (2.72.1-1) ...
Processing triggers for libglib2.0-0:i386 (2.72.1-1) ...
Processing triggers for libc-bin (2.35-0ubuntu3.1) ...
Processing triggers for man-db (2.10.2-1) ...
Processing triggers for mailcap (3.70+nmu1ubuntu1) ...
Processing triggers for desktop-file-utils (0.26-1ubuntu3) ...
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
The following additional packages will be installed:
gnome-software-common gnome-software-plugin-snap
Suggested packages:
gnome-software-plugin-flatpak
The following NEW packages will be installed:
gnome-software gnome-software-common gnome-software-plugin-snap
0 upgraded, 3 newly installed, 0 to remove and 0 not upgraded.
Need to get 655 kB of archives.
After this operation, 3,251 kB of additional disk space will be used.
Do you want to continue? [Y/n] y
Get:1 http://mirrors.tuna.tsinghua.edu.cn/ubuntu jammy/universe amd64 gnome-software-common all 41.5-2 [20.3 kB]
Get:2 http://mirrors.tuna.tsinghua.edu.cn/ubuntu jammy/universe amd64 gnome-software amd64 41.5-2 [606 kB]
Get:3 http://mirrors.tuna.tsinghua.edu.cn/ubuntu jammy/universe amd64 gnome-software-plugin-snap amd64 41.5-2 [28.8 kB]
Fetched 655 kB in 2s (305 kB/s)
Selecting previously unselected package gnome-software-common.
(Reading database ... 241633 files and directories currently installed.)
Preparing to unpack .../gnome-software-common_41.5-2_all.deb ...
Unpacking gnome-software-common (41.5-2) ...
Selecting previously unselected package gnome-software.
Preparing to unpack .../gnome-software_41.5-2_amd64.deb ...
Unpacking gnome-software (41.5-2) ...
Selecting previously unselected package gnome-software-plugin-snap.
Preparing to unpack .../gnome-software-plugin-snap_41.5-2_amd64.deb ...
Unpacking gnome-software-plugin-snap (41.5-2) ...
Setting up gnome-software-common (41.5-2) ...
Setting up gnome-software (41.5-2) ...
Processing triggers for desktop-file-utils (0.26-1ubuntu3) ...
Processing triggers for hicolor-icon-theme (0.17-2) ...
Processing triggers for gnome-menus (3.36.0-1ubuntu3) ...
Processing triggers for libglib2.0-0:i386 (2.72.1-1) ...
Processing triggers for libglib2.0-0:amd64 (2.72.1-1) ...
Processing triggers for libc-bin (2.35-0ubuntu3.1) ...
Processing triggers for man-db (2.10.2-1) ...
Processing triggers for mailcap (3.70+nmu1ubuntu1) ...
Setting up gnome-software-plugin-snap (41.5-2) ...$ sudo snap remove snap-store
snap-store removed
$ sudo snap install snap-store
error: cannot install "snap-store": Post
https://api.snapcraft.io/v2/snaps/refresh: parse 127.0.0.1:7890: first
path segment in URL cannot contain colon完成此操作后,我发现先前卸载的“软件”(而不是Ubuntu软件)再次出现。但它也不能正常运作。
索引页看起来很好,但是当我点击目录中的任何一个项目时,就会出现一个错误。之后,如果我点击任何一个软件,它就会崩溃。
$ gnome-software
04:13:02:0302 GLib-GIO g_dbus_proxy_new: assertion 'G_IS_DBUS_CONNECTION (connection)' failed
04:13:04:0191 Gs not handling error failed for action get-popular: status-code=500 kind=(null) message=Get https://api.snapcraft.io/v2/snaps/find?architecture=amd64&category=featured&confinement=strict%2Cclassic&fields=base%2Cconfinement%2Clinks%2Ccontact%2Cdescription%2Cdownload%2Clicense%2Cprices%2Cprivate%2Cpublisher%2Crevision%2Csummary%2Ctitle%2Ctype%2Cversion%2Cwebsite%2Cstore-url%2Cmedia%2Ccommon-ids%2Cchannel: parse 127.0.0.1:7890: first path segment in URL cannot contain colon
04:13:04:0191 Gs adding wildcard app */*/*/org.gnome.Builder.desktop/* to plugin cache
04:13:04:0191 Gs adding wildcard app */*/*/org.gnome.Calculator.desktop/* to plugin cache
04:13:04:0191 Gs adding wildcard app */*/*/org.gnome.clocks.desktop/* to plugin cache
04:13:04:0191 Gs adding wildcard app */*/*/org.gnome.Dictionary.desktop/* to plugin cache
04:13:04:0191 Gs adding wildcard app */*/*/org.gnome.Documents.desktop/* to plugin cache
04:13:04:0191 Gs adding wildcard app */*/*/org.gnome.Evince/* to plugin cache
04:13:04:0191 Gs adding wildcard app */*/*/org.gnome.gedit.desktop/* to plugin cache
04:13:04:0191 Gs adding wildcard app */*/*/org.gnome.Maps.desktop/* to plugin cache
04:13:04:0191 Gs adding wildcard app */*/*/org.gnome.Weather/* to plugin cache
04:13:04:0192 Gs Only 0 apps for recent list, hiding
04:13:04:0980 Gs Only 7 apps for popular list, hiding
04:13:05:0148 GsPluginSnap Failed to find refreshable snaps: status-code=500 kind=(null) message=cannot list updates: Post https://api.snapcraft.io/v2/snaps/refresh: parse 127.0.0.1:7890: first path segment in URL cannot contain colon
04:13:05:0193 Gtk Could not load a pixbuf from icon theme.
This may indicate that pixbuf loaders or the mime database could not be found.我还尝试了这两篇文章中包含的其他方法:https://www.maketecheasier.com/ubuntu-software-center-not-working-fixes/,https://itslinuxfoss.com/ubuntu-software-center-not-loading/,我相信它们都不适合我。这应该是我的代理或网络设置的问题。实际上,当我第一次安装ubuntu的时候,我无法访问这个“ubuntu”,在我完成安装之后,它告诉我,我可以访问软件中心的许多有用的软件,而且当时我不能打开它。
请帮帮我,这对我来说很重要!非常感谢。如果需要提供任何其他信息,请告诉我。
发布于 2023-04-27 13:59:10
如果遇到同样的问题,可以首先使代理正常工作,并确保您的存储库设置是正确的。
https://askubuntu.com/questions/1465316
复制相似问题