After Ajenti installation working site gives : 502 Bad Gateway nginx/1.6.0

Wiz Kiran hace 9 años actualizado por Yan Bourgeois hace 7 años 9
I use Debain 7.5 Wheezy and my site was up and running. I installed Ajenti and since then I get 502 Bad Gateway error. When I click on Nginx on Ajenti (already removed Apache), I get the following error

[Errno 2] No such file or directory: '/etc/nginx/sites-available' Traceback (most recent call last): File "/usr/lib/pymodules/python2.7/ajenti/plugins/main/main.py", line 158, in handle_message self.ui.dispatch_event(update['uid'], update['event'], update['params']) File "/usr/lib/pymodules/python2.7/ajenti/ui/__init__.py", line 72, in dispatch_event self.root.dispatch_event(uid, event, params) File "/usr/lib/pymodules/python2.7/ajenti/ui/element.py", line 382, in dispatch_event if child.dispatch_event(uid, event, params): File "/usr/lib/pymodules/python2.7/ajenti/ui/element.py", line 378, in dispatch_event self.event(event, params) File "/usr/lib/pymodules/python2.7/ajenti/ui/element.py", line 402, in event getattr(self, 'on_%s' % self_event)(**(params or {})) File "/usr/lib/pymodules/python2.7/ajenti/plugins/main/main.py", line 376, in on_switch child.broadcast('on_page_load') File "/usr/lib/pymodules/python2.7/ajenti/ui/element.py", line 356, in broadcast getattr(self, method)(*args, **kwargs) File "/usr/lib/pymodules/python2.7/ajenti/plugins/webserver_common/api.py", line 144, in on_page_load self.refresh() File "/usr/lib/pymodules/python2.7/ajenti/plugins/webserver_common/api.py", line 154, in refresh self.hosts = [WebserverHost(self, self.hosts_dir, x) for x in self.hosts_dir.list_available()] File "/usr/lib/pymodules/python2.7/ajenti/plugins/webserver_common/api.py", line 25, in list_available return [x for x in sorted(os.listdir(self.dir_a)) if not os.path.isdir(os.path.join(self.dir_a, x))] OSError: [Errno 2] No such file or directory: '/etc/nginx/sites-available'

Please help. Thanks
En revisión
Looks like you just stopped some backend service of your website on the way. NGINX section of Ajenti doesn't work for you because you don't have standard Debian "sites-available/sites-enabled" config layout in /etc/nginx. This however can't cause your website to stop.
The only thing I did was follow the install Ajenti for Debian commands on your website, and the working site gave 502. :(

Did you install Ajenti or Ajenti V as well too?
Ajenti V is a plugin to Ajenti. Ok so did you press the "Enable" button that says "If you press this, configs for NGINX, PHP-FPM, etc etc will be destroyed"?
Nope. Simply installed commands, that's all. 

i have this error too..

i just Simply installed commands, that's all.

I found the solution : apt-get install apache2

it will create folder needed for Ajenti