Can't run "X -configure", "Server is already active" error

Solution 1:

I think you shall have to stop the xserver first. Try this:

  1. Open a Terminal with CTRL+ALT+F1 and login
  2. sudo stop lightdm (or kdm or gdm instead of lightdm if you installed kubuntu or GNOME shell)
  3. sudo Xorg -configure
  4. sudo start lightdm (or kdm or gdm instead of lightdm if you installed kubuntu or GNOME shell)

Solution 2:

run ps auxw |grep X

and kill the process

then run again.

refer:http://git.net/ml/apple.fink.beginners/2002-08/msg00246.html