使用者帳號登入紀錄顯示不正確

使用者帳號登入紀錄顯示不正確

我發現,System Settings > User Accounts如果您選擇帳戶,然後選擇名為的按鈕History(這表示顯示該帳戶的登入記錄),它將顯示您上次登入的時間Session Started,但它會顯示您Session Ended之前下次登入。

為了澄清我的意思,假設昨天我在這台機器上登入了我的帳戶14:29,然後在附近的某個時候23:00我註銷了,然後今天早上我在附近的某個地方登入了我的帳戶11:20,它將顯示以下內容:

    Today 11:20 Session Started
    Today 11:19 Session Ended
    Yesterday, 14:29 Session Started

因此,它假設當您登入新會話時,上一個會話結束,因此錯誤似乎是當會話正確結束時它不會記錄,而僅在新會話開始時記錄它。

所以它會顯示這樣的事情:

登入歷史圖形使用者介面

為什麼是這樣?我該如何解決這個問題?

資訊更新:

我在同一台機器上設定了另一個帳戶,並執行命令:

loginctl

但唯一活躍的帳戶(在我註銷其他帳戶後)是lightdm當前用戶帳戶。所以我知道會話正確關閉,那麼為什麼它不記錄它關閉?什麼,我是否必須在關閉和啟動時執行自己的自訂腳本才能獲得準確的登入記錄?

last以下是請求的命令輸出的一部分:

reboot   system boot  3.19.0-15-generi Sun May  3 18:34 - 22:38 (1+04:03)   
arthur-d pts/5        :0.0             Sat May  2 22:07 - 22:07  (00:00)    
arthur-d pts/18       :0.0             Sat May  2 22:07 - 22:07  (00:00)    
arthur-d pts/11       :0.0             Sat May  2 22:07 - 22:07  (00:00)    
arthur-d pts/5        :0.0             Sat May  2 22:07 - 22:07  (00:00)    
arthur-d pts/6        :0               Sat May  2 21:42 - 22:10  (00:28)    
arthur-d :0           :0               Sat May  2 21:42 - down   (00:53)    
reboot   system boot  3.19.0-15-generi Sat May  2 21:41 - 22:35  (00:54)    
arthur-d pts/5        :0               Sat May  2 16:15 - 16:16  (00:00)    
arthur-d pts/5        :0               Sat May  2 16:15 - 16:15  (00:00)    
arthur-d pts/5        :0               Sat May  2 15:43 - 15:43  (00:00)    
arthur-d pts/5        :0               Sat May  2 15:13 - 15:42  (00:29)    
arthur-d pts/5        :0               Sat May  2 15:06 - 15:07  (00:00)    
arthur-d pts/5        :0               Sat May  2 14:56 - 15:02  (00:05)    
arthur-d pts/5        :0               Sat May  2 14:55 - 14:56  (00:01)    
arthur-d pts/5        :0               Sat May  2 13:55 - 14:50  (00:54)    
arthur-d pts/5        :0               Sat May  2 13:24 - 13:55  (00:30)    
arthur-d pts/5        :0               Sat May  2 13:24 - 13:24  (00:00)    
arthur-d pts/7        :0               Sat May  2 13:09 - 13:17  (00:08)    
arthur-d pts/7        :0               Sat May  2 13:09 - 13:09  (00:00)    
arthur-d :0           :0               Sat May  2 13:08 - crash  (08:32)    
reboot   system boot  3.19.0-15-generi Sat May  2 13:07 - 22:35  (09:27)    
arthur-d pts/1        :0               Fri May  1 22:04 - 22:11  (00:06)    
arthur-d pts/1        :0               Fri May  1 22:04 - 22:04  (00:00)    
arthur-d pts/1        :0               Fri May  1 20:43 - 22:04  (01:20)    
arthur-d pts/4        :0               Fri May  1 20:35 - 20:42  (00:07)    
arthur-d pts/4        :0               Fri May  1 20:35 - 20:35  (00:00)    
arthur-d :0           :0               Fri May  1 20:34 - down   (02:05)    
reboot   system boot  3.19.0-15-generi Fri May  1 20:33 - 22:40  (02:06)    
arthur-d pts/1        :0               Fri May  1 16:08 - 16:08  (00:00)    
arthur-d pts/1        :0               Fri May  1 16:08 - 16:08  (00:00)    
arthur-d pts/1        :0               Fri May  1 16:08 - 16:08  (00:00)    
arthur-d pts/1        :0               Fri May  1 12:36 - 12:37  (00:00)    
arthur-d pts/1        :0               Fri May  1 12:33 - 12:36  (00:03)    
arthur-d pts/1        :0               Fri May  1 12:12 - 12:33  (00:21)    
arthur-d pts/1        :0               Fri May  1 12:08 - 12:11  (00:03)    
arthur-d pts/1        :0               Fri May  1 12:07 - 12:08  (00:00)    
arthur-d pts/1        :0               Fri May  1 12:07 - 12:07  (00:00)    
arthur-d pts/1        :0               Fri May  1 11:54 - 12:03  (00:09)    
arthur-d pts/1        :0               Fri May  1 11:54 - 11:54  (00:00)    

此問題在 Ubuntu GNOME 15.10 和 GNOME 3.18 以及 Unity 中也存在(因此unity-control-centergnome-control-center)。

答案1

如中所述錯誤#1443052,Trusty 和 Xenial 的 debdiff 已經提交(它們應該很快就會發布),這解決了該問題,並且 Yakkety 的修復程序已經發布。由於程式碼與上游補丁不相容,致力於解決該問題的人尚未在 Precise 中做到這一點。

由於此錯誤是accountsservice軟體包中的錯誤,而不是unity-control-center唯一需要升級的錯誤gnome-control-centeraccountsservice

這些是修復該問題的版本(有些版本在當時或撰寫時尚未發布):

  • 亞克蒂: 0.6.42-0ubuntu1

  • 謝尼爾: 0.6.40-2ubuntu11.3

  • 可靠: 0.6.35-0ubuntu7.3

相關內容