问题列表 - 第6758页

有没有可以上传文本文件的网站?

我想将文本文件上传到网站,以便与其他人共享。

我使用的网站只允许图片。

software-recommendation pastebin ubuntu-mate

-2
推荐指数
1
解决办法
108
查看次数

未满足的依赖关系,但“apt --fix-broken install”不起作用

我的nvidia-smi不起作用:

NVIDIA-SMI has failed because it couldn't communicate with the NVIDIA driver. Make sure that the latest NVIDIA driver is installed and running.
Run Code Online (Sandbox Code Playgroud)

我尝试了这篇文章中的命令

sudo apt update && sudo apt upgrade -y
sudo apt --fix-broken install
sudo apt-get --with-new-pkgs upgrade nvidia-kernel-common-535
sudo apt autoremove
Run Code Online (Sandbox Code Playgroud)

但我的电脑仍然弹出错误

Reading package lists... Done 
Building dependency tree... Done 
Reading state information... Done 
You might want to run 'apt --fix-broken install' to correct these. 
The following packages have unmet dependencies:
nvidia-dkms-535:
Depends: nvidia-kernel-common-535 …
Run Code Online (Sandbox Code Playgroud)

nvidia dependencies drivers

10
推荐指数
1
解决办法
1638
查看次数

使用 bash,根据模式匹配创建文件

我们有一个内容如下的文件。

/* ----------------- pattern_1 ----------------- */ 

jb: pattern_1   Data: asdflj  adfas Log: dir/log1

/* ----------------- pattern_2 ----------------- */ 

jb: pattern_2   typ: CM comm: ${dir}/DISPV mach: au_buh description: "run flag"


/* ----------------- pattern_3 ----------------- */ 

jb: pattern_3   typ: fw  own: buh out_file: "${log}/jl.log" err: "log.err"
Run Code Online (Sandbox Code Playgroud)

该文件必须分为 3 个并创建为 3 个单独的文件,如下所示:

模式_1.txt

/* ----------------- pattern_1 ----------------- */ 

jb: pattern_1   Data: asdflj  adfas Log: dir/log1
Run Code Online (Sandbox Code Playgroud)

模式_2.txt

* ----------------- pattern_2 ----------------- */ 

jb: pattern_2   typ: CM comm: ${dir}/DISPV mach: au_buh description: "run flag"
Run Code Online (Sandbox Code Playgroud)

模式_3.txt …

command-line text-processing

2
推荐指数
1
解决办法
578
查看次数

如何解锁用 Muon 锁定的包

我使用 Muon 包管理器将包锁定到特定版本,但是当我尝试释放锁定时,收到消息“无法锁定包代码。无法写入锁定文件。”

错误信息

sudo apt-mark showhold是空空如也。我尝试清除软件包并重新安装它,但它仍然安装锁定版本。

如果我强制它安装特定版本,这是可行的,但随后apt dist-upgrade想要降级软件包:

Hit:1 http://archive.ubuntu.com/ubuntu jammy InRelease
Get:2 https://deb.nodesource.com/node_19.x jammy InRelease [4,563 B]                                                                                                                                                                       
Hit:3 http://archive.ubuntu.com/ubuntu jammy-updates InRelease                                                                                                                                                                             
Hit:4 http://archive.ubuntu.com/ubuntu jammy-backports InRelease                                                                                                                                                                           
Hit:5 http://archive.ubuntu.com/ubuntu jammy-security InRelease                                                                                                                                                                            
Ign:6 https://repo.mongodb.org/apt/ubuntu focal/mongodb-org/6.0 InRelease                                                                                                                                                                 
Hit:7 https://download.sublimetext.com apt/stable/ InRelease                                                                                      
Hit:8 http://packages.microsoft.com/repos/code stable InRelease                                                             
Hit:9 https://deb.opera.com/opera-stable stable InRelease                                 
Hit:10 https://linux-clients.seafile.com/seafile-deb/jammy stable InRelease
Hit:11 https://repo.mongodb.org/apt/ubuntu focal/mongodb-org/6.0 Release
Fetched 4,563 B in 1s (3,842 B/s)
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
2 packages can …
Run Code Online (Sandbox Code Playgroud)

package-management apt dpkg muon-package-manager held-packages

2
推荐指数
1
解决办法
238
查看次数

Ubuntu 22.04,启动速度非常慢,端口转发后没有以太网

昨天我(linux新手)端口转发了42420端口,和一些朋友一起玩复古故事。在路由器上启用它并告诉firewall-cmd允许哪个端口后,我们玩起来没有任何问题。

但今天 - 在关机过夜后,我发现机器启动速度比以前慢了很多(以前需要大约 10 秒,现在需要 2 分钟,一直如此),而且最重要的是,以太网连接不起作用,电缆也不起作用昨天还可以用,但我的手机上的 USB 网络共享也不起作用。

在裸机上使用 Ubuntu 22.04,Linux 版本 6.5.0-15-generic。

的输出systemd-analyze blame告诉我

  • plymouth-quit-wait.service需要 21 秒
  • NetworkManager-wait-online.service需要 3 秒
  • 任何其他都是 1 秒或更短。

firwall-cmd 命令是firewall-cmd --permanent --zone=public --add-port=42420/tcp,(我认为)它绝对允许每个人进行连接,但我认为它是安全的,因为除了 Vintage Story 之外,没有应用程序使用该端口进行任何操作。

我知道我仍然可以访问互联网,因为 wifi 仍然有效(在我的手机上,机器没有 wifi 适配器)。

也许 ISP 阻止了我设备上的每个连接以阻止“潜在的攻击者”,我对此表示怀疑,因为甚至 USB 网络共享都不起作用。

有人知道可能是什么问题吗?任何帮助是极大的赞赏。

照片systemd-analyze plot > test.svg

这两个问题的解决方案,感谢@Daniel T: 显然我安装了ufw和firewalld,它们是冲突的,卸载firewalld似乎已经解决了这两个问题——互联网和启动时间恢复正常。

boot plymouth port-forwarding ethernet

6
推荐指数
1
解决办法
417
查看次数

为什么 apt 找不到已经安装的包?

在 Ubuntu 22.04.3 上:

paul@box4x4:~$ apt search libstdc++ | grep installed

WARNING: apt does not have a stable CLI interface. Use with caution in scripts.

libstdc++-11-dev/jammy-updates,jammy-security,now 11.4.0-1ubuntu1~22.04 amd64 [installed,automatic]
libstdc++-12-dev/jammy-updates,jammy-security,now 12.3.0-1ubuntu1~22.04 amd64 [installed]
libstdc++6/jammy-updates,jammy-security,now 12.3.0-1ubuntu1~22.04 amd64 [installed,automatic]
Run Code Online (Sandbox Code Playgroud)

这表明libstdc++-12-dev已经安装了。搜索它:

paul@box4x4:~$ apt search libstdc++-12-dev
Sorting... Done
Full Text Search... Done
Run Code Online (Sandbox Code Playgroud)

失败了。这是为什么?

package-management apt search

2
推荐指数
1
解决办法
68
查看次数

应用中心打不开.deb包

正如您所看到的,错误就在标题中。当我打开.deb包时,应用程序中心会显示一个加载图标:

加载错误

我已经让它这样加载了两个多小时,但它继续无限旋转。

这是 Ubuntu 中的错误,还是我计算机上的应用程序中心的错误?关于我可以做什么来解决这个问题有什么建议吗?

也许还有其他可以管理应用程序的应用程序?

先感谢您。

software-center package-management deb 23.10

6
推荐指数
1
解决办法
686
查看次数

dnsmasq 不记录 dns 查询

以下是我从命令行调试此问题的方法:

$ dnsmasq --no-daemon --log-queries
Run Code Online (Sandbox Code Playgroud)

log-queries选项放入配置文件中并将其作为守护进程运行,日志文件中仍然没有显示任何内容。我期待当我这样做时dig example.com,它应该出现。

这是上面命令的输出:

dnsmasq: started, version 2.89 cachesize 150
dnsmasq: compile time options: IPv6 GNU-getopt DBus no-UBus i18n IDN2 DHCP DHCPv6 no-Lua TFTP conntrack ipset nftset auth cryptohash DNSSEC loop-detect inotify dumpfile
dnsmasq: reading /etc/resolv.conf
dnsmasq: using nameserver 8.8.8.8#53
dnsmasq: using nameserver 1.1.1.1#53
dnsmasq: using nameserver 2001:4860:4860::8888#53
dnsmasq: using nameserver 2001:4860:4860::8844#53
dnsmasq: read /etc/hosts - 7 names
Run Code Online (Sandbox Code Playgroud)

Ubuntu版本:23.10
内核6.5.0
dnsmasq版本:2.89

networking dns dnsmasq 23.10

4
推荐指数
1
解决办法
302
查看次数

X11 会话无法在 Raspberry Pi 5 上的 arm64 Ubuntu 23.10 上启动

Ubuntu 23.10 arm64 在带有 Wayland 的 Raspberry Pi 5 上运行良好。我想禁用 Wayland 并使用 X11 会话,因为 Citrix 的某些功能在 Wayland 中不起作用,因此我尝试通过WaylandEnable=false/etc/gdm3/custom.conf. 这种方法在 Raspberry Pi 4 上的 Ubuntu 22.04 上运行良好,但是在 Raspberry 5 上的 23.10 上,X11 会话无法启动:我最终在屏幕上看到一个闪烁的光标。要让 X11 在 raspi5 上的 Ubuntu 23.10 上运行,还需要执行其他步骤吗?

更新1

从控制台(通过 ssh)运行 startx 会给出以下输出:

jacob@jacob-raspi5:~$ startx
xauth:  file /home/jacob/.Xauthority does not exist

/usr/lib/xorg/Xorg.wrap: Only console users are allowed to run the X server
xinit: giving up
xinit: unable to connect to X server: Connection refused
xinit: …
Run Code Online (Sandbox Code Playgroud)

xorg raspberrypi 23.10

6
推荐指数
1
解决办法
495
查看次数

三月最后一个星期日的 touch -t 错误

如果日期代码表示任何一年 3 月最后一个星期日的 2:00:00AM 到 2:59:59AM,touch -t 会给我“无效的日期格式”错误(我已经检查过 2023,2014,2016,2018 )。核心实用程序中这种奇怪的现象让我大吃一惊。这是一些已知的错误吗?有解决方法吗?

\n

例子:

\n
$ touch -t 201603270159.59 myfile.txt #1:59AM works\n$ touch -t 202303260200.00 myfile.txt #2:00AM fails\ntouch: invalid date format \xe2\x80\x98202303260200.00\xe2\x80\x99\n$ touch -t 201603270259.59 myfile.txt #2:59AM fails\ntouch: invalid date format \xe2\x80\x98201603270259.59\xe2\x80\x99\n$ touch -t 201603270300.00 myfile.txt #3:00AM works\n$ touch -t 202303270200.00 myfile.txt #2:00AM the next day works\n
Run Code Online (Sandbox Code Playgroud)\n

(这些内容为 YYYYMMDDHHMM.SS)。

\n

我接触了 5000 个文件的集合,这些文件的时间戳可追溯到 12 年前。这是触摸失败的日期时间戳列表。问题日期始终是三月的最后一个星期日

\n
touch -t 201403300248.57 fileA.txt\ntouch -t 201403300251.21 fileB.txt\ntouch -t 201403300253.03 fileC.txt\ntouch -t 201603270252.42 fileD.txt\ntouch -t 201603270234.43 …
Run Code Online (Sandbox Code Playgroud)

command-line bug-reporting date coreutils

8
推荐指数
1
解决办法
784
查看次数