Xvfb veya Firefox hatalar atma ve günlüğe kaydetme


9

cevabını başına bu soruya , ben firefox benim CentOS sunucu üzerinde çalışacak, böylece sanal bir ekran yapmak için Xvfb çalıştırıyorum. (Firefox'u görmem veya firefox ile herhangi bir gerçek anahtar veya ekran girişi / çıkışı yapmam gerekmiyor - sadece Selenyum'un kullanabilmesi için çalıştırılması gerekiyor.) Xvfb (veya firefox) 'un neden attığını anlamaya çalışıyorum bir sürü hata.

Ben bu komut ile Xvfb başlatmak:

Xvfb :1 -screen 0 1024x768x24 &

Ve hemen başlattıktan sonra, birkaç hata mesajı ekrana geri yansıtılır (garip bir şekilde, kabuk isteminden sonra görünürler):

[root@host /home/lm/cron]# Xvfb :1 -screen 0 1024x768x24 &               
[1] 9214
[root@host /home/lm/cron]# expected keysym, got XF86TouchpadOn: line 120 of inet
expected keysym, got XF86TouchpadOff: line 121 of inet

Ve Selenium test betiğimi çalıştırdığımda Selenium günlüğünde daha birçok hata görünüyor:

5 XSELINUXs still allocated at reset
SCREEN: 0 objects of 176 bytes = 0 total bytes 0 private allocs
DEVICE: 4 objects of 48 bytes = 192 total bytes 0 private allocs
CLIENT: 0 objects of 144 bytes = 0 total bytes 0 private allocs
WINDOW: 0 objects of 48 bytes = 0 total bytes 0 private allocs
PIXMAP: 1 objects of 16 bytes = 16 total bytes 0 private allocs
GC: 0 objects of 56 bytes = 0 total bytes 0 private allocs
CURSOR: 0 objects of 8 bytes = 0 total bytes 0 private allocs
CURSOR_BITS: 0 objects of 8 bytes = 0 total bytes 0 private allocs
DBE_WINDOW: 0 objects of 24 bytes = 0 total bytes 0 private allocs
TOTAL: 5 objects, 208 bytes, 0 allocs
4 DEVICEs still allocated at reset
DEVICE: 4 objects of 48 bytes = 192 total bytes 0 private allocs
CLIENT: 0 objects of 144 bytes = 0 total bytes 0 private allocs
WINDOW: 0 objects of 48 bytes = 0 total bytes 0 private allocs
PIXMAP: 1 objects of 16 bytes = 16 total bytes 0 private allocs
GC: 0 objects of 56 bytes = 0 total bytes 0 private allocs
CURSOR: 0 objects of 8 bytes = 0 total bytes 0 private allocs
CURSOR_BITS: 0 objects of 8 bytes = 0 total bytes 0 private allocs
DBE_WINDOW: 0 objects of 24 bytes = 0 total bytes 0 private allocs
TOTAL: 5 objects, 208 bytes, 0 allocs
1 PIXMAPs still allocated at reset
PIXMAP: 1 objects of 16 bytes = 16 total bytes 0 private allocs
GC: 0 objects of 56 bytes = 0 total bytes 0 private allocs
CURSOR: 0 objects of 8 bytes = 0 total bytes 0 private allocs
CURSOR_BITS: 0 objects of 8 bytes = 0 total bytes 0 private allocs
DBE_WINDOW: 0 objects of 24 bytes = 0 total bytes 0 private allocs
TOTAL: 1 objects, 16 bytes, 0 allocs
14:33:47.919 INFO - Done: /session/1330284794945
expected keysym, got XF86TouchpadOn: line 120 of inet
expected keysym, got XF86TouchpadOff: line 121 of inet

Şimdi, işin komik kısmı, TÜM bu karışıklığa rağmen, her şey çalışıyor: Selenium firefox mülküyle konuşuyor, firefox olması gerekeni yapıyor ve Selenyum'a geri geçiriyor, vb. Sadece (a) tüm bu mesajlar / hatalar konusunda endişelenmeli ve (b) bunu nasıl temizleyebilirim? (Aslında bana bunun çoğu 'kapatmak için' alloc'larla ilgili bir tür ayrıntılı günlük bilgisi olduğu anlaşılıyor ve sonra da bu 'beklenen keym' mesajları atılan istisnalar.)


2
Onların hata olduğunu sanmıyorum. Bence sadece X sunucusu konuşkan. Bu mesajları, komutunuzdaki "&" öğesinin önüne "2> / dev / null" ekleyerek / dev / null klasörüne de gönderebilirsiniz.
cjc

Yanıtlar:


6

Onların hata olduğunu sanmıyorum.

Sadece X sunucusu konuşkan.

Bu mesajları / dev / null'a, Xvfb'yi kullanarak Xvfb :1 -screen 0 1024x768x24 2>/dev/null &

Sitemizi kullandığınızda şunları okuyup anladığınızı kabul etmiş olursunuz: Çerez Politikası ve Gizlilik Politikası.
Licensed under cc by-sa 3.0 with attribution required.