AskOverflow.Dev

AskOverflow.Dev Logo AskOverflow.Dev Logo

AskOverflow.Dev Navigation

  • 主页
  • 系统&网络
  • Ubuntu
  • Unix
  • DBA
  • Computer
  • Coding
  • LangChain

Mobile menu

Close
  • 主页
  • 系统&网络
    • 最新
    • 热门
    • 标签
  • Ubuntu
    • 最新
    • 热门
    • 标签
  • Unix
    • 最新
    • 标签
  • DBA
    • 最新
    • 标签
  • Computer
    • 最新
    • 标签
  • Coding
    • 最新
    • 标签
主页 / user-251621

eridani's questions

Martin Hope
eridani
Asked: 2024-06-12 23:56:05 +0800 CST

无法解析自己的本地(avahi)主机名

  • 7

更换故障路由器后,尝试从 PC“A”(Ubuntu 20.04.6) ssh 到 PC“A”,出现错误消息:ssh: Could not resolve hostname pca.local: Name or service not known。ping其他类似命令也找不到主机。

但是,从其他设备(如“pcb”到pca.local、“pca”到pcb.local、“pcb”到 )的主机名连接可以pcb.local正常工作。通过 IP 地址从“pca”到“pca”的连接也是如此。有趣的是,从“pca”到 的连接(pca没有.local)实际上可以正常工作!

但这对我来说毫无用处,因为它已经在脚本和其他东西中被熟知pca.local。LAN 中的所有设备在路由器更改后都保留了其 IP 地址。

我已尝试过:

  • cat /etc/hostname正如预期的那样显示自己的名字。
  • systemctl restart systemd-resolved。
  • /etc/init.d/networking restart。
  • dhclient -r eth0。
  • 几天内不能重新启动那台机器。

输出service avahi-daemon status

● avahi-daemon.service - Avahi mDNS/DNS-SD Stack
     Loaded: loaded (/lib/systemd/system/avahi-daemon.service; enabled; vendor preset: enabled)
     Active: active (running) since Wed 2024-06-12 12:44:47 CST; 1h 49min ago
TriggeredBy: ● avahi-daemon.socket
   Main PID: 163913 (avahi-daemon)
     Status: "avahi-daemon 0.7 starting up."
      Tasks: 2 (limit: 4383)
     Memory: 1.3M
     CGroup: /system.slice/avahi-daemon.service
             ├─163913 avahi-daemon: registering [pca.local]
             └─163914 avahi-daemon: chroot helper

jun 12 12:44:47 pca avahi-daemon[163913]: Server startup complete. Host name is pca.local. Local service cookie is 2927830272.
jun 12 12:44:47 pca avahi-daemon[163913]: Failed to parse address 'fe80::1%eth0', ignoring.
jun 12 13:08:25 pca avahi-daemon[163913]: Withdrawing address record for fe80::342a:68ff:fec8:fa4e on veth2964dfb.
jun 12 13:08:28 pca avahi-daemon[163913]: Registering new address record for fe80::a881:e7ff:fec7:ead3 on veth6ddcaf7.*.
jun 12 13:34:33 pca avahi-daemon[163913]: Withdrawing address record for fe80::a881:e7ff:fec7:ead3 on veth6ddcaf7.
jun 12 13:34:35 pca avahi-daemon[163913]: Registering new address record for fe80::5c62:9eff:fe29:543e on veth31f1578.*.
jun 12 13:53:37 pca avahi-daemon[163913]: Withdrawing address record for fe80::5c62:9eff:fe29:543e on veth31f1578.
jun 12 13:53:40 pca avahi-daemon[163913]: Registering new address record for fe80::c0eb:52ff:fe22:656d on veth6d79f34.*.
jun 12 14:26:11 pca avahi-daemon[163913]: Withdrawing address record for fe80::c0eb:52ff:fe22:656d on veth6d79f34.
jun 12 14:26:13 pca avahi-daemon[163913]: Registering new address record for fe80::2ce3:93ff:fe4e:8b6f on vethd1fb373.*.

输出ip addr show dev eth0

2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP group default qlen 1000
    link/ether 6a:55:c4:0f:59:ba brd ff:ff:ff:ff:ff:ff
    inet 192.168.1.94/24 brd 192.168.1.255 scope global noprefixroute eth0
       valid_lft forever preferred_lft forever
    inet6 2806:107e:15:413d:bdc8:3b3e:88ec:370e/64 scope global temporary dynamic 
       valid_lft 540279sec preferred_lft 21774sec
    inet6 2806:107e:15:413d:c92f:8f13:fca8:2576/64 scope global temporary deprecated dynamic 
       valid_lft 453986sec preferred_lft 0sec
    inet6 2806:107e:15:413d:7893:65ce:cb5a:a28c/64 scope global dynamic mngtmpaddr noprefixroute 
       valid_lft 2441181sec preferred_lft 2441181sec
    inet6 fe80::4455:f83b:22ee:5769/64 scope link noprefixroute 
       valid_lft forever preferred_lft forever

输出avahi-resolve-host-name pca.local

pca.local  192.168.1.94

输出cat /etc/avahi/avahi-daemon.conf | grep -v "#"

[server]
use-ipv4=yes
use-ipv6=no
ratelimit-interval-usec=1000000
ratelimit-burst=1000

[wide-area]
enable-wide-area=yes

[publish]
publish-hinfo=no
publish-workstation=no

[reflector]

[rlimits]

输出cat /etc/nsswitch.conf

# /etc/nsswitch.conf
#
# Example configuration of GNU Name Service Switch functionality.
# If you have the `glibc-doc-reference' and `info' packages installed, try:
# `info libc "Name Service Switch"' for information about this file.

passwd:         files
group:          files
shadow:         files
gshadow:        files

hosts:          files mymachines dns myhostname
networks:       files

protocols:      db files
services:       db files
ethers:         db files
rpc:            db files

netgroup:       nis
networking
  • 1 个回答
  • 149 Views
Martin Hope
eridani
Asked: 2020-06-07 06:53:55 +0800 CST

父文件系统快照是引用它的子数据集数据还是仅引用它们的 onw 数据?

  • 1

数据在您拍摄的尽可能多的快照中被引用,并且只有当您删除所有引用所述数据的快照以及正在运行的卷中的数据时,才会从磁盘中删除数据,这对于 btrfs 和 ZFS 都适用。

例如,在 btrfs 中,如果我创建~/mifyle.txt然后拍摄 的快照@home,除非我删除此快照,否则我的文件不会从磁盘中删除~/myfile.txt,并且 ZFS 也会发生同样的情况。

但是,如果我从@和拍摄快照@home怎么办?将~/myfile.txt在@和@home快照中引用还是仅在@home快照中引用?

ZFS 的行为是否有所不同?如果我创建一个文件rpool/home/myfile.txt,rpool父数据集和rpool/home子数据集在哪里,然后为rpool和拍摄快照rpool/home,myfile.txt会在两个数据集快照中引用还是仅在子数据集快照中引用?

btrfs zfs snapshot
  • 1 个回答
  • 821 Views
Martin Hope
eridani
Asked: 2019-10-24 09:39:58 +0800 CST

从命令行切换 Plasma 主题

  • 7

我想轻松地在深色和浅色主题之间切换(默认微风和深色微风主题),而无需导航到系统设置>全局主题>单击主题>单击应用。

所以我想知道是否有一种方法可以在不使用鼠标的情况下快速切换已安装的主题,也许可以运行以前制作的 Bash 脚本?

如果这种方式可行,那么我将能够使用此 On/Off plasmoid触发这些脚本。那么,有没有办法从命令行更改 Global Plasma 主题?

kde command-line themes kubuntu plasma-5
  • 1 个回答
  • 6915 Views
Martin Hope
eridani
Asked: 2018-10-24 12:43:06 +0800 CST

如何让 Flatpak 应用程序访问目录

  • 32

我从 Flathub 安装了 Elisa 音乐播放器,但它拒绝看到我的音乐分区,所以我无法将任何音乐添加到它的库中,除非我将其复制到/home/my_user/.

有没有办法让 Flatpak 应用程序访问非规范地址?

除了在编译时指定它......

permissions flatpak
  • 3 个回答
  • 46037 Views
Martin Hope
eridani
Asked: 2017-02-16 15:44:47 +0800 CST

突然不能再输入非英文字符了

  • 4

突然我的 Kubuntu 16.04 拒绝写一些字符。

通常我可以按´+ a=á但现在我只是´a在一些应用程序(如 Firefox)上进入其他应用程序(如 Konsole 或 Dolphin),甚至没有显示重音,只有a出现。

唯一的例外是 LibreOffice,其中输入按预期工作。

我已经清除了我的单键盘输入法配置System preferences > Input > Keyboard > Layout并重新配置,也咨询过这个问题,但无济于事。

这些是我的内容locale:

$ locale
LANG=es_MX.UTF-8
LANGUAGE=es_MX:es
LC_CTYPE="es_MX.UTF-8"
LC_NUMERIC="es_MX.UTF-8"
LC_TIME="es_MX.UTF-8"
LC_COLLATE="es_MX.UTF-8"
LC_MONETARY="es_MX.UTF-8"
LC_MESSAGES="es_MX.UTF-8"
LC_PAPER="es_MX.UTF-8"
LC_NAME="es_MX.UTF-8"
LC_ADDRESS="es_MX.UTF-8"
LC_TELEPHONE="es_MX.UTF-8"
LC_MEASUREMENT="es_MX.UTF-8"
LC_IDENTIFICATION="es_MX.UTF-8"
LC_ALL=

这是的输出$ im-config -m

default
ibus
none

none
kubuntu
  • 1 个回答
  • 549 Views
Martin Hope
eridani
Asked: 2017-02-04 08:41:26 +0800 CST

清除 Intel 01.org 驱动程序后更新 gnome-software

  • 1

由于我升级了我的 GPU,我按照这个问题的过程删除了英特尔的开源技术中心驱动程序。

通过这样做,一堆软件按预期降级,但其他一些不相关的软件被删除了。

The following packages were automatically installed and are no longer required:
  gnome-software-common libgtkspell3-3-0 libmowgli-2-0 libqt5keychain1 libqtkeychain1 libsnapd-glib1
  snapd-login-service
Use 'sudo apt autoremove' to remove them.
The following packages will be REMOVED:
  gnome-software libnvpair1 libuutil1 libzfs2 libzpool2 ubuntu-software ubuntu-zfs zfsutils
The following NEW packages will be installed:
  autoconf automake autopoint dh-autoreconf libcrypto++9v5 libltdl-dev libqt5keychain0 libtool libuv1 m4
The following packages will be upgraded:
  appstream debhelper libappstream4 libarchive13
The following packages will be DOWNGRADED:
  libguess1 libowncloudsync0 libshairplay0 mkvtoolnix mkvtoolnix-gui nethogs nodejs owncloud-client
  owncloud-client-l10n spl spl-dkms synergy xboxdrv zfs-dkms zfs-doc

其中包括gnome-software和ubuntu-software。如果我尝试重新安装它们,我会收到一个依赖错误:

sudo apt install gnome-software ubuntu-software
...
The following packages have unmet dependencies:
 gnome-software : Depends: appstream but it is not going to be installed
E: Unable to correct problems, you have held broken packages.

这是输出apt policy appstream:

  Installed: 0.10.6-1~ubuntu16.04.1
  Candidate: 0.10.6-1~ubuntu16.04.1
  Version table:
 *** 0.10.6-1~ubuntu16.04.1 100
        100 http://mx.archive.ubuntu.com/ubuntu xenial-backports/main amd64 Packages
        100 /var/lib/dpkg/status
     0.10.3-1~ubuntu16.04~ppa2 500
        500 http://ppa.launchpad.net/kubuntu-ppa/backports/ubuntu xenial/main amd64 Packages
     0.9.4-1ubuntu2 500
        500 http://mx.archive.ubuntu.com/ubuntu xenial-updates/main amd64 Packages
     0.9.4-1 500
        500 http://mx.archive.ubuntu.com/ubuntu xenial/main amd64 Packages

一切都指向 backports repos 把事情搞砸了,但我觉得奇怪的是,开发人员没有注意到如此明显的问题,而这种想法让我认为真正的问题在其他地方。我可以做些什么来修复软件中心?

我在 Ubuntu Unity x86_64 16.04

16.04
  • 1 个回答
  • 983 Views
Martin Hope
eridani
Asked: 2016-11-02 17:34:33 +0800 CST

如何在 16.04 Xenial 上使用 nVidia GPU?

  • 1

我有一个使用了几年的带有 Intel Graphics 的 Haswell 4670 CPU。

最近购买并实际安装了 nVidia GTX 1610 卡。但是当我将显示器插入显卡的 DVI 插槽并打开系统时,我什么也看不到。

如果我通过 VNC 应用程序登录,我可以在以下位置看到:系统设置 > 详细信息 > 概述”Ubuntu 仍在使用“Intel Haswell Desktop”图形而不是 nVidia。

到目前为止,我已经添加了ppa:graphics-drivers/ppaPPA,并且可以在“软件和更新 > 其他驱动程序”列表中看到 NVIDIA 367、NVIDIA 370 和 X.org Nouveau 以及英特尔驱动程序。

我可以从列表中选择任何选项,但是在单击“应用”按钮后,我的选择被取消选中,复选标记返回 X.org 条目并要求我重新启动。

重新启动后一切都一样,我可以将显示器插入 MoBo 的 DVI 端口并毫无问题地使用我的系统,但如果我将其插入 nVidia 端口,显示器只会显示“无信号消息”。

如果相关,MoBo 是技嘉 GA-Z87-HD3。

有什么提示吗?

drivers
  • 1 个回答
  • 252 Views
Martin Hope
eridani
Asked: 2015-12-02 07:46:47 +0800 CST

启动时跳过 Grub

  • 9

我将 Ubuntu 安装在 UEFI 机器的空磁盘中,并且一直直接启动,没有任何菜单或超时,直到上周的软件更新。我想保持启动简单,就像以前一样。

我所做的相关更改是将带有旧 Linux Deepin 安装的磁盘从我出售的 PC 移动到装有 Ubuntu 的同一台机器上。所以现在我在同一台 PC 上有 2 个磁盘。

当然,在启动时,我现在有一个 grub 菜单可以在 Ubuntu 和 Deepin 之间进行选择。我不需要这个菜单,因为我一直使用 Ubuntu,Deepin 磁盘有自己的 grub,我可以从 BIOS 选项中选择要启动的磁盘。

如何返回到旧的启动顺序?我真的不想断开我的深度盘。

阅读完这个问题后,我更改了/etc/default/grub文件中的一些内容,现在它看起来像这样:

# If you change this file, run 'update-grub' afterwards to update
# /boot/grub/grub.cfg.
# For full documentation of the options in this file, see:
#   info -f grub -n 'Simple configuration'

GRUB_DEFAULT=0
GRUB_HIDDEN_TIMEOUT=0
GRUB_HIDDEN_TIMEOUT_QUIET=true
GRUB_TIMEOUT=0
GRUB_DISTRIBUTOR=`lsb_release -i -s 2> /dev/null || echo Debian`
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash"
GRUB_CMDLINE_LINUX="noprompt"

# Uncomment to enable BadRAM filtering, modify to suit your needs
# This works with Linux (no patch required) and with any kernel that obtains
# the memory map information from GRUB (GNU Mach, kernel of FreeBSD ...)
#GRUB_BADRAM="0x01234567,0xfefefefe,0x89abcdef,0xefefefef"

# Uncomment to disable graphical terminal (grub-pc only)
#GRUB_TERMINAL=console

# The resolution used on graphical terminal
# note that you can use only modes which your graphic card supports via VBE
# you can see them in real GRUB with the command `vbeinfo'
#GRUB_GFXMODE=640x480

# Uncomment if you don't want GRUB to pass "root=UUID=xxx" parameter to Linux
#GRUB_DISABLE_LINUX_UUID=true

# Uncomment to disable generation of recovery mode menu entries
#GRUB_DISABLE_RECOVERY="true"

# Uncomment to get a beep at grub start
#GRUB_INIT_TUNE="480 440 1"

然后跑sudo update-grub起来没有问题。但是 grub 菜单和 10 秒超时在启动时仍然存在。

在 Ubuntu 磁盘上发布分区可能是相关的,因为这不是默认设置:

分区 - 挂载点 - 标志

/dev/sda1 - - bios_grub

/dev/sda2 - /boot/efi - boot,esp

/dev/sda3 - / -

/dev/sda4 - /home -

/dev/sda5 - swap -

boot
  • 2 个回答
  • 16133 Views

Sidebar

Stats

  • 问题 205573
  • 回答 270741
  • 最佳答案 135370
  • 用户 68524
  • 热门
  • 回答
  • Marko Smith

    如何运行 .sh 脚本?

    • 16 个回答
  • Marko Smith

    如何安装 .tar.gz(或 .tar.bz2)文件?

    • 14 个回答
  • Marko Smith

    如何列出所有已安装的软件包

    • 24 个回答
  • Marko Smith

    无法锁定管理目录 (/var/lib/dpkg/) 是另一个进程在使用它吗?

    • 25 个回答
  • Martin Hope
    Flimm 如何在没有 sudo 的情况下使用 docker? 2014-06-07 00:17:43 +0800 CST
  • Martin Hope
    Ivan 如何列出所有已安装的软件包 2010-12-17 18:08:49 +0800 CST
  • Martin Hope
    La Ode Adam Saputra 无法锁定管理目录 (/var/lib/dpkg/) 是另一个进程在使用它吗? 2010-11-30 18:12:48 +0800 CST
  • Martin Hope
    David Barry 如何从命令行确定目录(文件夹)的总大小? 2010-08-06 10:20:23 +0800 CST
  • Martin Hope
    jfoucher “以下软件包已被保留:”为什么以及如何解决? 2010-08-01 13:59:22 +0800 CST
  • Martin Hope
    David Ashford 如何删除 PPA? 2010-07-30 01:09:42 +0800 CST

热门标签

10.10 10.04 gnome networking server command-line package-management software-recommendation sound xorg

Explore

  • 主页
  • 问题
    • 最新
    • 热门
  • 标签
  • 帮助

Footer

AskOverflow.Dev

关于我们

  • 关于我们
  • 联系我们

Legal Stuff

  • Privacy Policy

Language

  • Pt
  • Server
  • Unix

© 2023 AskOverflow.DEV All Rights Reserve