redshift是否需要有效的互联网连接?

似乎没有活跃的互联网连接,红移不会运行。 如果是这样,当没有连接到互联网时,是否有某种方式可以运行?

更新:请注意,修复程序现在正在进行中。 您可以等到它到达官方存储库,或者按照第53条中的建议并在错误报告中自行应用它。


正如Anwar指出的那样,Redshift默认在线获取其地理位置数据。 但是有一种解决方法:

手动配置地理位置数据


a。)使用配置文件

从项目的主页 :

Redshift将在“〜/ .config / redshift.conf”中查找配置文件。 这是一个例子:

; Global settings [redshift] temp-day=5700 temp-night=3500 transition=1 gamma=0.8:0.7:0.8 location-provider=manual adjustment-method=vidmode ; The location provider and adjustment method settings ; are in their own sections. [manual] lat=55.0 lon=12.0 ; In this example screen 1 is adjusted by vidmode. Note ; that the numbering starts from 0, so this is actually ; the second screen. [vidmode] screen=1` 

查找上面提供的目录。 如果配置文件不存在,请创建一个并附加您喜欢的任何自定义选项。

您需要包含location-provider=manual并修改lat=long=与您的位置。 此对话框将帮助您确定坐标。


b。)使用命令行参数

启动启动应用程序

在此处输入图像描述

在启动应用列表中找到Redshift条目,然后单击编辑 。 在命令下输入以下字符串:

 gtk-redshift -l LAT:LONG 

LAT和LONG对应于您的坐标。 点击保存,然后重新启动以激活Redshift

答案是肯定的。 Redshift需要有效的Internet连接。 它取决于从Internet获取地理位置的libgeoclue0包。

 $ apt-cache depends redshift redshift Depends: libc6 Depends: libgconf2-4 Depends: libgeoclue0 Depends: libglib2.0-0 Depends: libx11-6 Depends: libxcb-randr0 Depends: libxcb1 Depends: libxxf86vm1 

您还可以通过从终端运行redshift来validation这一点。 终端将显示如下消息

 Started Geoclue provider `Geoclue Master'. Using provider `geoclue'. According to the geoclue provider we're at: 22.36, 91.80 Using method `randr'. 

这表明,它正在使用互联网。

但是,如果您在没有互联网连接的情况下从终端开始红移,终端将显示以下类型的消息:

 Started Geoclue provider `Geoclue Master'. Using provider `geoclue'. Could not get location (3 retries left): Geoclue master client has no usable Position providers. Unable to get location from provider.