MastereQ | 2021-07-20 15:57:41 UTC | #1
root@vps16365:/etc/nginx/sites-enabled# sudo service apache2 restart Job for apache2.service failed because the control process exited with error code. See "systemctl status apache2.service" and "journalctl -xe" for details.
Jak chce przeładować apache wyskakuje taki błąd. Chcę to naprawić by pterodactyl działał z phpmyadmin
KrEdEnS | 2021-07-20 15:58:45 UTC | #2
Chcesz używać apache2, używając jednocześnie nginxa? Tak się nie da, albo ogórki albo ogrodnika córki ;)
KMatuszak | 2021-07-20 17:48:22 UTC | #3
[quote=”KrEdEnS, post:2, topic:19461”]
Tak się nie da
[/quote]
Dlaczego nie? Nie widzę przeszkód, wystarczy w jednym z nich zmienić domyślne porty na inne.
W ogóle skąd pewność że problemem są dwie usługi działające na tym samym porcie? Równie dobrze ten problem może wynikać z błędnej konfiguracji serwera.
KrEdEnS | 2021-07-20 17:55:24 UTC | #4
[quote=”KMatuszak, post:3, topic:19461”]
Dlaczego nie? Nie widzę przeszkód, wystarczy w jednym z nich zmienić domyślne porty na inne.
[/quote]
Oczywiście, że się da ale po zadanym pytaniu, wątpię że używa obu, raczej przez przypadek zainstalował oba i boryka się z problemem używając preinstalowanych konfiguracji tych serwerów WWW.
@MastereQ wpisz i pokaż co pokazuje systemctl status apache2.service
MastereQ | 2021-07-20 18:12:04 UTC | #5
[quote=”KrEdEnS, post:4, topic:19461”]
systemctl status apache2.service
[/quote]
root@vps14645:~# systemctl status apache2.service ● apache2.service - The Apache HTTP Server Loaded: loaded (/lib/systemd/system/apache2.service; enabled; vendor preset: Drop-In: /lib/systemd/system/apache2.service.d └─apache2-systemd.conf Active: failed (Result: exit-code) since Tue 2021-07-20 15:54:45 UTC; 2h 13mi Process: 30201 ExecStop=/usr/sbin/apachectl stop (code=exited, status=0/SUCCES Process: 30822 ExecStart=/usr/sbin/apachectl start (code=exited, status=1/FAIL Main PID: 10062 (code=exited, status=0/SUCCESS) Jul 20 15:54:45 vps14645 apachectl[30822]: AH00558: apache2: Could not reliably Jul 20 15:54:45 vps14645 apachectl[30822]: (98)Address already in use: AH00072: Jul 20 15:54:45 vps14645 apachectl[30822]: (98)Address already in use: AH00072: Jul 20 15:54:45 vps14645 apachectl[30822]: no listening sockets available, shutt Jul 20 15:54:45 vps14645 apachectl[30822]: AH00015: Unable to open logs Jul 20 15:54:45 vps14645 apachectl[30822]: Action 'start' failed. Jul 20 15:54:45 vps14645 apachectl[30822]: The Apache error log may have more in Jul 20 15:54:45 vps14645 systemd[1]: apache2.service: Control process exited, co Jul 20 15:54:45 vps14645 systemd[1]: apache2.service: Failed with result 'exit-c Jul 20 15:54:45 vps14645 systemd[1]: Failed to start The Apache HTTP Server. lines 1-19/19 (END)...skipping... ● apache2.service - The Apache HTTP Server Loaded: loaded (/lib/systemd/system/apache2.service; enabled; vendor preset: enabled) Drop-In: /lib/systemd/system/apache2.service.d └─apache2-systemd.conf Active: failed (Result: exit-code) since Tue 2021-07-20 15:54:45 UTC; 2h 13min ago Process: 30201 ExecStop=/usr/sbin/apachectl stop (code=exited, status=0/SUCCESS) Process: 30822 ExecStart=/usr/sbin/apachectl start (code=exited, status=1/FAILURE) Main PID: 10062 (code=exited, status=0/SUCCESS) Jul 20 15:54:45 vps14645 apachectl[30822]: AH00558: apache2: Could not reliably determine the server's fully qualified domain name, using 127.0.1.1. Set the 'ServerName' directive globally to suppress this message Jul 20 15:54:45 vps14645 apachectl[30822]: (98)Address already in use: AH00072: make_sock: could not bind to address [::]:80 Jul 20 15:54:45 vps14645 apachectl[30822]: (98)Address already in use: AH00072: make_sock: could not bind to address 0.0.0.0:80 Jul 20 15:54:45 vps14645 apachectl[30822]: no listening sockets available, shutting down Jul 20 15:54:45 vps14645 apachectl[30822]: AH00015: Unable to open logs Jul 20 15:54:45 vps14645 apachectl[30822]: Action 'start' failed. Jul 20 15:54:45 vps14645 apachectl[30822]: The Apache error log may have more information. Jul 20 15:54:45 vps14645 systemd[1]: apache2.service: Control process exited, code=exited status=1 Jul 20 15:54:45 vps14645 systemd[1]: apache2.service: Failed with result 'exit-code'. Jul 20 15:54:45 vps14645 systemd[1]: Failed to start The Apache HTTP Server.
KrEdEnS | 2021-07-20 18:12:38 UTC | #6
[quote=”MastereQ, post:5, topic:19461”]
Jul 20 15:54:45 vps14645 apachectl[30822]: (98)Address already in use: AH00072: make_sock: could not bind to address [::]:80
Jul 20 15:54:45 vps14645 apachectl[30822]: (98)Address already in use: AH00072: make_sock: could not bind to address 0.0.0.0:80
[/quote]
Prawdopodobnie używasz już nginxa i port 80 zajmuje właśnie on.
MastereQ | 2021-07-20 18:19:42 UTC | #7
ta mam nginxa
KrEdEnS | 2021-07-20 18:34:29 UTC | #8
Ok, i tu pojawia się pytanie po co Ci apache, skoro możesz używać nginxa. Jeżeli faktycznie chcesz dodatkowo używać apache (ze względu np na htaccess) to zmień port na vhoście w apache i zrób revers proxy na nginx, żeby serwować WWW na 80 i 443.
Jeżeli chcesz zostać na nginx i używać htaccessa zainteresuj się https://github.com/e404/htaccess-for-nginx
W sumie to wait, pterodactyla masz na nginx czy apache2
MastereQ | 2021-07-20 19:07:04 UTC | #9
nginxa jednak nie potrzebuje bo panel moge miec na apache2
ale gdy wpisuje “systemctl restart apache2” to wywala erora:
Job for apache2.service failed because the control process exited with error code.
See “systemctl status apache2.service” and “journalctl -xe” for details.
nginxa odinstalowalem za pomoca “sudo apt purge nginx”
KrEdEnS | 2021-07-20 19:23:06 UTC | #10
Spróbuj zrestartować vpsa i luknij na logi apache2 systemctl status apache2.service
MastereQ | 2021-07-20 19:24:27 UTC | #11
jak to zrobic XD
KrEdEnS | 2021-07-20 19:25:48 UTC | #12
reboot -n
- zrestartuje serwer (wyłączy i włączy)
potem sprawdź czy apache2 się włączy, jak nie no to pokaż logi
dodatkowo po restarcie profilaktycznie wpisz service nginx status
MastereQ | 2021-07-20 19:29:30 UTC | #13
[quote=”KrEdEnS, post:12, topic:19461”]
service nginx status
[/quote]
root@vps14645:~# service nginx status ● nginx.service - A high performance web server and a reverse proxy server Loaded: loaded (/lib/systemd/system/nginx.service; enabled; vendor preset: en Active: failed (Result: exit-code) since Tue 2021-07-20 19:25:59 UTC; 1min 19 Docs: man:nginx(8) Process: 803 ExecStartPre=/usr/sbin/nginx -t -q -g daemon on; master_process o Jul 20 19:25:59 vps14645 systemd[1]: Starting A high performance web server and Jul 20 19:25:59 vps14645 nginx[803]: nginx: [emerg] open() "/etc/nginx/sites-ena Jul 20 19:25:59 vps14645 nginx[803]: nginx: configuration file /etc/nginx/nginx. Jul 20 19:25:59 vps14645 systemd[1]: nginx.service: Control process exited, code Jul 20 19:25:59 vps14645 systemd[1]: nginx.service: Failed with result 'exit-cod Jul 20 19:25:59 vps14645 systemd[1]: Failed to start A high performance web serv lines 1-12/12 (END)...skipping... ● nginx.service - A high performance web server and a reverse proxy server Loaded: loaded (/lib/systemd/system/nginx.service; enabled; vendor preset: enabled) Active: failed (Result: exit-code) since Tue 2021-07-20 19:25:59 UTC; 1min 19s ago Docs: man:nginx(8) Process: 803 ExecStartPre=/usr/sbin/nginx -t -q -g daemon on; master_process on; (code=exited, status=1/FAILURE) Jul 20 19:25:59 vps14645 systemd[1]: Starting A high performance web server and a reverse proxy server... Jul 20 19:25:59 vps14645 nginx[803]: nginx: [emerg] open() "/etc/nginx/sites-enabled/pterodactyl.conf" failed (2: No such file or directory) in /etc/nginx/nginx.conf:62 Jul 20 19:25:59 vps14645 nginx[803]: nginx: configuration file /etc/nginx/nginx.conf test failed Jul 20 19:25:59 vps14645 systemd[1]: nginx.service: Control process exited, code=exited status=1 Jul 20 19:25:59 vps14645 systemd[1]: nginx.service: Failed with result 'exit-code'. Jul 20 19:25:59 vps14645 systemd[1]: Failed to start A high performance web server and a reverse proxy server.
KrEdEnS | 2021-07-20 19:35:48 UTC | #14
Usuń nginx będą na roocie
apt purge nginx
MastereQ | 2021-07-20 19:43:17 UTC | #15
mam usuniete bo wyskakuje
0 upgraded, 0 newly installed, 0 to remove and 7 not upgraded.
KrEdEnS | 2021-07-20 19:42:00 UTC | #16
Ok, spróbuj
service nginx stop
service apache2 restart
MastereQ | 2021-07-21 00:22:38 UTC | #19
[quote=”KrEdEnS, post:16, topic:19461”]
service apache2 restart
[/quote]
root@vps14645:~# service nginx stop
Failed to get properties: Unit name [email protected] is neither a valid invocation ID nor unit name.
Failed to get properties: Unit name [email protected] is neither a valid invocation ID nor unit name.
root@vps14645:~# service apache2 restart
teraz jak chce wejsc do pterodaktyla to wywala blad:
Composer detected issues in your platform: Your Composer dependencies require a PHP version “>= 7.4.0”.
psycha siada
dobra ogarnalem to z apache2
system | 2021-08-21 22:44:12 UTC | #20
Ten temat został automatycznie zamknięty 32 dni po ostatnim wpisie. Tworzenie nowych odpowiedzi nie jest już możliwe.