You are not logged in.
Pages: 1
Topic closed
I'm new to arch but I was wandering why starting services via "systemctl" doesn't display anything on the screen.
I've tried Debian before and starting for example apache2 display some output on the screen: eg. "OK" etc.
So user knows there was no errors.
Last edited by syscon (2020-10-27 21:51:11)
Offline
'echo $?'
Sakura:-
Mobo: MSI MAG X570S TORPEDO MAX // Processor: AMD Ryzen 9 5950X @4.9GHz // GFX: AMD Radeon RX 5700 XT // RAM: 32GB (4x 8GB) Corsair DDR4 (@ 3000MHz) // Storage: 1x 3TB HDD, 6x 1TB SSD, 2x 120GB SSD, 1x 275GB M2 SSD
Making lemonade from lemons since 2015.
Offline
Thank you for reply, but it is a bit cryptic to me; what do I do with 'echo $?'
Do I modify a file etc?
Offline
echo $? prints the return value of the previous command. If there was an error it would be printed. If systemctl was not asked for any output, it will not provide any unless something goes wrong.
"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman
Offline
That was not very helpful.
Running:
echo $? systemctl restart httpd
0 systemctl restart httpd
but
systemctl list-units --type=service --state=active
doesn't show apache running.
Offline
echo $? prints the return value of the previous command.
echo $? systemctl restart httpdPrint the exit status of the previous command followed by the string systemctl restart httpd
Last edited by loqs (2020-10-27 23:07:08)
Offline
It is hard to trouble shoot apache error as noting is showing in the log files.
Offline
It is hard to trouble shoot apache error as noting is showing in the log files.
Ah, what? This has nothing to do with anything else in this thread. So this is an XY Problem?
Please describe your actual problem if you want help.
Also - and I know this is hard to receive well - you may want to reconsider the distro you are using. It seems you are not familiar with the fundamentals of a shell or command line execution of *nix programs. If that is the case, arch will not be right for you at all. Get some experience with other distros first. If you do stick with arch, please take some time working through good linux tutorials like the ones here:
https://ryanstutorials.net/
Last edited by Trilby (2020-10-27 23:46:30)
"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman
Offline
When I try to "localhost" I get in error log: /var/log/httpd/dummy-host.example.com-error_log
[client 10.0.0.112:49420] AH01630: client denied by server configuration: /etc/httpd/docs
I don't have any "docs" file in /etc/httpd/
Offline
That doesn't mean much without knowing how you configured your host/vhost. More importantly, it is a completely different topic from this thread.
Please start a new thread to describe the actual problem. Describe how you configured apache, and post all modified configuration files (in the new thread).
Last edited by Trilby (2020-10-28 00:01:38)
"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman
Offline
Here is my httpd.conf
I disabled my configuration files that I loaded, so when I start it a browser and go to: localhost I should get some output, but instead I'm getting Acesss forbiden!
sed -e 's/#.*//' -e 's/[ ^I]*$//' -e '/^$/ d' httpd.conf
ServerRoot "/etc/httpd"
Listen 80
LoadModule mpm_event_module modules/mod_mpm_event.so
LoadModule authn_file_module modules/mod_authn_file.so
LoadModule authn_anon_module modules/mod_authn_anon.so
LoadModule authn_dbd_module modules/mod_authn_dbd.so
LoadModule authn_core_module modules/mod_authn_core.so
LoadModule authz_host_module modules/mod_authz_host.so
LoadModule authz_groupfile_module modules/mod_authz_groupfile.so
LoadModule authz_user_module modules/mod_authz_user.so
LoadModule authz_dbm_module modules/mod_authz_dbm.so
LoadModule authz_owner_module modules/mod_authz_owner.so
LoadModule authz_core_module modules/mod_authz_core.so
LoadModule authnz_ldap_module modules/mod_authnz_ldap.so
LoadModule access_compat_module modules/mod_access_compat.so
LoadModule auth_basic_module modules/mod_auth_basic.so
LoadModule file_cache_module modules/mod_file_cache.so
LoadModule cache_module modules/mod_cache.so
LoadModule reqtimeout_module modules/mod_reqtimeout.so
LoadModule ext_filter_module modules/mod_ext_filter.so
LoadModule include_module modules/mod_include.so
LoadModule filter_module modules/mod_filter.so
LoadModule deflate_module modules/mod_deflate.so
LoadModule mime_module modules/mod_mime.so
LoadModule ldap_module modules/mod_ldap.so
LoadModule log_config_module modules/mod_log_config.so
LoadModule logio_module modules/mod_logio.so
LoadModule env_module modules/mod_env.so
LoadModule mime_magic_module modules/mod_mime_magic.so
LoadModule expires_module modules/mod_expires.so
LoadModule headers_module modules/mod_headers.so
LoadModule usertrack_module modules/mod_usertrack.so
LoadModule unique_id_module modules/mod_unique_id.so
LoadModule setenvif_module modules/mod_setenvif.so
LoadModule version_module modules/mod_version.so
LoadModule slotmem_shm_module modules/mod_slotmem_shm.so
LoadModule ssl_module modules/mod_ssl.so
LoadModule unixd_module modules/mod_unixd.so
LoadModule dav_module modules/mod_dav.so
LoadModule status_module modules/mod_status.so
LoadModule autoindex_module modules/mod_autoindex.so
LoadModule info_module modules/mod_info.so
<IfModule !mpm_prefork_module>
LoadModule cgid_module modules/mod_cgid.so
</IfModule>
<IfModule mpm_prefork_module>
LoadModule cgi_module modules/mod_cgi.so
</IfModule>
LoadModule dav_fs_module modules/mod_dav_fs.so
LoadModule dav_lock_module modules/mod_dav_lock.so
LoadModule vhost_alias_module modules/mod_vhost_alias.so
LoadModule negotiation_module modules/mod_negotiation.so
LoadModule dir_module modules/mod_dir.so
LoadModule actions_module modules/mod_actions.so
LoadModule speling_module modules/mod_speling.so
LoadModule userdir_module modules/mod_userdir.so
LoadModule alias_module modules/mod_alias.so
LoadModule rewrite_module modules/mod_rewrite.so
<IfModule unixd_module>
User http
Group http
</IfModule>
ServerAdmin you@example.com
<Directory />
AllowOverride none
Require all denied
</Directory>
DocumentRoot "/srv/http"
<Directory "/srv/http">
Options FollowSymLinks
AllowOverride None
Require all granted
</Directory>
<IfModule dir_module>
DirectoryIndex index.html
</IfModule>
<Files ".ht*">
Require all denied
</Files>
ErrorLog "/var/log/httpd/error_log"
LogLevel warn
<IfModule log_config_module>
LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" combined
LogFormat "%h %l %u %t \"%r\" %>s %b" common
<IfModule logio_module>
LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\" %I %O" combinedio
</IfModule>
CustomLog "/var/log/httpd/access_log" common
</IfModule>
<IfModule alias_module>
ScriptAlias /cgi-bin/ "/srv/http/cgi-bin/"
</IfModule>
<IfModule cgid_module>
</IfModule>
<Directory "/srv/http/cgi-bin">
AllowOverride None
Options None
Require all granted
</Directory>
<IfModule headers_module>
RequestHeader unset Proxy early
</IfModule>
<IfModule mime_module>
TypesConfig conf/mime.types
AddType application/x-compress .Z
AddType application/x-gzip .gz .tgz
</IfModule>
Include conf/extra/httpd-mpm.conf
Include conf/extra/httpd-multilang-errordoc.conf
Include conf/extra/httpd-autoindex.conf
Include conf/extra/httpd-languages.conf
Include conf/extra/httpd-userdir.conf
Include conf/extra/httpd-vhosts.conf
Include conf/extra/httpd-default.conf
<IfModule proxy_html_module>
Include conf/extra/proxy-html.conf
</IfModule>
<IfModule ssl_module>
SSLRandomSeed startup builtin
SSLRandomSeed connect builtin
</IfModule>
Last edited by syscon (2020-10-28 00:28:53)
Offline
My dummy-host.example.com-error_log shows:
[Tue Oct 27 18:30:12.266155 2020] [authz_core:error] [pid 1972:tid 139724505196096] [client 127.0.0.1:59152] AH01630: client denied by server configuration: /etc/httpd/docs
dummy-host.example.com-access_log
127.0.0.1 - - [27/Oct/2020:18:30:12 -0600] "GET / HTTP/1.1" 403 1026
Offline
Please use code tags, for commands, their outputs and config listings e.t.c.
Code_of_conduct#Pasting_pictures_and_code
Please also read the rest of the CoC, which includes on topic per thread, marking threads as solved and editing your post rather than bumping your thread when no one else has posted.
Offline
You will not get help here if you refuse to acknowledge and follow any instructions you are given.
Last edited by Trilby (2020-10-28 01:02:32)
"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman
Offline
Please use code tags, for commands, their outputs and config listings e.t.c.
Code_of_conduct#Pasting_pictures_and_code
Please also read the rest of the CoC, which includes on topic per thread, marking threads as solved and editing your post rather than bumping your thread when no one else has posted.
This thread has been an XY Problem from the start. Combined with the minor CoC violations, I'm going to close this.
@syscon Please start a new thread, stating clearly the problem you're having (including an accurate title), and you will find you'll get much more productive responses. Please read this article to help you write a high-quality post: http://www.catb.org/esr/faqs/smart-questions.html
Are you familiar with our Forum Rules, and How To Ask Questions The Smart Way?
BlueHackers // fscanary // resticctl
Offline
Pages: 1
Topic closed