我试图了解 Gconf、Dconf 和 Gsettings 的工作原理以及它们之间的关系。
我所知道的是:
我知道对于 Gconf 有一个 GUI - Gconf-editor,对于 Dconf - Dconf-editor。
所以:
如何在 Ubuntu 18.04 中关闭 Ubuntu 错误声音(尤其是在终端上)?
我想看输出的变化
gsettings list-recursively|grep text-scal
Run Code Online (Sandbox Code Playgroud)
这是
org.gnome.desktop.interface text-scaling-factor 1.0
com.canonical.Unity.Interface text-scale-factor 1.0
Run Code Online (Sandbox Code Playgroud)
但如果我试着用
watch gsettings list-recursively|grep text-scal
Run Code Online (Sandbox Code Playgroud)
我没有输出,因为管道似乎是问题所在。
我怎样才能看到变化?
是否有等效于 GSettings/dconf 的 gconf-editor?
我知道我可以gsettings set ...在命令行上使用,但这有点不方便(尤其是对于列表类型)。
这基本上是一个“学术”问题——试图更好地理解配置系统的内部结构。
我知道dconf系统是gnome3中的新配置系统,它取代了(已弃用的)gconf;这一点从Gconf、Dconf、Gsettings 以及它们之间的关系就很清楚了。
在我看来,程序gsettings和dconf-editorwhere 只是两种不同的方式来访问同一个dconf数据库,这在什么是 dconf,它的功能是什么,我如何使用它中得到了证实
?
编辑:我发现有人注意到它在某些架构名称中的大小写有所不同,请参见此处 --- dconf 架构名称是否区分大小写?; 但似乎差异不仅限于此。在一个答案中有一个不匹配的例子,但我没有找到原因的解释。
但是最近我发现从gsettings和访问的密钥dconf-editor不一样。例如,对于设置vino在dconf-editor下org.gnome.desktop.remote-access(见下面的截图),而在gsettings它们是下 org.gnome.Vino。有一些文档可以解释差异吗?
在gsettings 中:
(0)samsung-romano:~/tmp/try% gsettings list-recursively org.gnome.Vino
org.gnome.Vino alternative-port uint16 5900
org.gnome.Vino authentication-methods ['none']
org.gnome.Vino disable-background false
[...]
Run Code Online (Sandbox Code Playgroud)
和:
(0)samsung-romano:~/tmp/try% gsettings list-recursively org.gnome.desktop.remote-access
No such schema 'org.gnome.desktop.remote-access'
Run Code Online (Sandbox Code Playgroud)
但是在dconf-editor 中:

我需要通过 Puppet、虚拟终端或 ssh 自动化桌面配置。
不幸的是,gsettings通过 ssh 或虚拟终端调用会给出:
gsettings set org.compiz.core:/org/compiz/profiles/unity/plugins/core/ hsize "4"
(process:29520): dconf-WARNING **: failed to commit changes to dconf: Cannot autolaunch D-Bus without X11 $DISPLAY
Run Code Online (Sandbox Code Playgroud)
当我$DISPLAY用export DISPLAY=:0.0它设置时会出现另一个错误:
(process:29862): dconf-WARNING **: failed to commit changes to dconf: Could not connect: Connection refused
Run Code Online (Sandbox Code Playgroud)
我能做什么?
两天前,我从 Windows 迁移到了 Ubuntu 16.04。我喜欢我们可以自定义 Unity 桌面的方式。我只是在玩弄桌面环境的外观和感觉。就像在 Windows 中一样,我希望启动器位于屏幕底部。在谷歌上,我发现了一个命令,它是这样的:
gsettings set com.canonical.Unity.Launcher launcher-position Bottom
Run Code Online (Sandbox Code Playgroud)
此外,还有用于完成工作的 unity-tweak-tool 和 dconf 编辑器。但这些是完成工作的 GUI 方法。
我的问题是:
这里的答案告诉了如何获取进程的标准文件描述符。但是,我没有在输出中得到任何东西。
此外,该strace -p pid -o output.txt命令会向文件中抛出大量文本。
那么,简而言之,使用 GUI 应用程序做事与从命令行做事是一样的吗?
我正在使用 Ubuntu 18.04 并使用此命令
gsettings set org.gnome.shell.extensions.dash-to-dock click-action 'minimize'
Run Code Online (Sandbox Code Playgroud)
通过单击图标打开 Dock 上的最小化。如何恢复并关闭此功能?
因为如果打开多个窗口,它会刺激浏览器。如何从此设置中排除浏览器和/或如何恢复系统范围?
我在 VirtualBox 中运行 Ubuntu 12.04.1 LTS x64。在一次非常不幸的误点击(重置保存状态而不是加载保存状态)之后,我遇到了一个非常烦人的问题。
几乎所有应用程序(unity、synaptic、gedit 等)都会在启动时打印:
Using the 'memory' GSettings backend. Your settings will not be saved or shared with other applications.
Run Code Online (Sandbox Code Playgroud)
并且所有 GUI 设置都在重新启动后重置。
另一个症状:
$ GSETTINGS_BACKEND=dconf dconf-editor
(dconf-editor:2353): GLib-GIO-WARNING **: Can't find module 'dconf' specified in GSETTINGS_BACKEND
GLib-GIO-Message: Using the 'memory' GSettings backend. Your settings will not be saved or shared with other applications
Run Code Online (Sandbox Code Playgroud)
但/usr/lib/x86_64-linux-gnu/gio/modules/libdconfsettings.so存在。
我尝试过的(并没有帮助):
sudo apt-get install -f --reinstall dconf-tools libdconf0 libdconf-dbus-1-0 dconf-servicemake install它我必须保留当前的 Ubuntu 安装,因此完全重新安装对我来说不是一个选择。 …
gsettings ×10
dconf ×7
command-line ×2
unity ×2
18.04 ×1
dock ×1
gconf ×1
gnome ×1
gnome-shell ×1
grep ×1
launcher ×1
minimize ×1
puppet ×1
remote-login ×1
settings ×1
system ×1
ubuntu-dock ×1