I have a TeamCity 7.0.2 at CentOS 6.2 server without X Server. I've installed x11-fonts*, xvfb, firefox, xauth, extracted env. variable DISPLAY=localhost:1, and started xvfb.
After that I could start Selenium tests using maven. Tests are executed, but there's an issue with TeamCity. Usually TeamCity starts behaves absolutely inadequate (it confuses images at the page, sends xml or strange text with ampersands and numbers in responses and is a bit slower), also tests are executed 4 times slower (1h 15m) at server than at tester Windows 7-based machine (25m).
It worth to notice that tests launch two Jetty servers for tested application (one for REST-services application and another for client). In TeamCity I set JVM command line parameters: -Xms256m -Xmx1224m -XX:MaxPermSize=320m, and Additional Maven command line parameters ends with "-DMAVEN_OPTS=-Xmx1024m" (without quotes).
Also both web-services and TeamCity uses the same Oracle server (but different Oracle users).
Finally TeamCity and its build agent is at the same server.
Server has only 4GB of RAM, but during testing there're 400MB of RAM and 1.2GB of swap. TeamCity and Firefox uses about 65% of CPU during testing. There's no firefox process after end of testing.
My knowledge about Selenium is weak. I only know that we use 2.20.0 version of selenium-java maven dependency.
Please help me to determine why TeamCity sends wrong responses after Selenium tests. I've tried to give you all information I have, but feel free to ask me for more information.
UPD: Even without selenium tests this issue happens.