LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 04-08-2018, 05:00 PM   #1
ziggs
Member
 
Registered: Jan 2018
Posts: 37

Rep: Reputation: Disabled
Find the configuration for Apache and Modify it


Hi all,

I am having trouble trying to modify my apache server. I need to enable extended status and need to ensure that IO add the correct lines for the appropriate directory for my server status, while restricting access the host I currently have assigned.

I keep getting this error: E486: Pattern not found: server-status. I cannot figure out why, since my apache server is up and running. Any help would be greatly appreciated!! I attached two images!

Thanks,
Ziggs
Attached Thumbnails
Click image for larger version

Name:	Error E486.JPG
Views:	19
Size:	153.4 KB
ID:	27412   Click image for larger version

Name:	Apacher Server Status.JPG
Views:	19
Size:	85.6 KB
ID:	27413  
 
Old 04-08-2018, 07:04 PM   #2
keefaz
LQ Guru
 
Registered: Mar 2004
Distribution: Slackware
Posts: 6,552

Rep: Reputation: 872Reputation: 872Reputation: 872Reputation: 872Reputation: 872Reputation: 872Reputation: 872
search for mod_status in config

https://httpd.apache.org/docs/curren...od_status.html
 
Old 04-08-2018, 07:47 PM   #3
scasey
LQ Veteran
 
Registered: Feb 2013
Location: Tucson, AZ, USA
Distribution: CentOS 7.9.2009
Posts: 5,727

Rep: Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211
Also, use the -l switch to see the entire message in systemctl status

And...can you not copy/paste into [code] tags instead of using screen shots?

Have you read the apache documentation? It's comprehensive and quite well-done...but we are happy to help when you get stuck, too...
 
Old 04-08-2018, 08:07 PM   #4
ziggs
Member
 
Registered: Jan 2018
Posts: 37

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by scasey View Post
Also, use the -l switch to see the entire message in systemctl status

And...can you not copy/paste into [code] tags instead of using screen shots?

Have you read the apache documentation? It's comprehensive and quite well-done...but we are happy to help when you get stuck, too...
Sorry about that! Yes, I have, but I am missing this file as well: /etc/httpd/conf/httpd.conf no such file or directory exists. I know that I am supposed to enable it. I just do not have that file. Is it in the wrong location? or Do I need to create it?

Thanks
 
Old 04-08-2018, 08:18 PM   #5
scasey
LQ Veteran
 
Registered: Feb 2013
Location: Tucson, AZ, USA
Distribution: CentOS 7.9.2009
Posts: 5,727

Rep: Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211
Quote:
Originally Posted by ziggs View Post
Sorry about that! Yes, I have, but I am missing this file as well: /etc/httpd/conf/httpd.conf no such file or directory exists. I know that I am supposed to enable it. I just do not have that file. Is it in the wrong location? or Do I need to create it?

Thanks
Your first image is of that file, isn't it?
 
Old 04-08-2018, 08:25 PM   #6
ziggs
Member
 
Registered: Jan 2018
Posts: 37

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by scasey View Post
Your first image is of that file, isn't it?
Sorry...I had uninstalled and re-installed it httpd. I have to modify the files and directories. It must be in the wrong place because I keep getting the same error messages. I cannot pull up /server-status in Vi. It is because I need to enable the ExtendedStatus and go to the Mods? I am reading Apache doc as well, just confusing myself as you can see. I as well need to add the lines for the virtual directory. This is where I am getting confused. I made a copy of the httpd.conf file in case I mess this one up.

Thanks
 
Old 04-08-2018, 08:42 PM   #7
ziggs
Member
 
Registered: Jan 2018
Posts: 37

Original Poster
Rep: Reputation: Disabled
Have this issues now:

[root@localhost conf]# systemctl status httpd.service
● httpd.service - The Apache HTTP Server
Loaded: loaded (/usr/lib/systemd/system/httpd.service; enabled; vendor preset: disabled)
Active: failed (Result: exit-code) since Sun 2018-04-08 21:41:25 EDT; 24s ago
Docs: man:httpd(8)
man:apachectl(8)
Process: 1546 ExecStop=/bin/kill -WINCH ${MAINPID} (code=exited, status=1/FAILURE)
Process: 1544 ExecStart=/usr/sbin/httpd $OPTIONS -DFOREGROUND (code=exited, status=1/FAILURE)
Main PID: 1544 (code=exited, status=1/FAILURE)

Apr 08 21:41:25 localhost.localdomain systemd[1]: Starting The Apache HTTP Server...
Apr 08 21:41:25 localhost.localdomain httpd[1544]: [Sun Apr 08 21:41:25.082311 2018] [so:warn] [pid 1...ing
Apr 08 21:41:25 localhost.localdomain httpd[1544]: AH00526: Syntax error on line 96 of /etc/httpd/con...nf:
Apr 08 21:41:25 localhost.localdomain httpd[1544]: ServerName takes one argument, The hostname and po...ver
Apr 08 21:41:25 localhost.localdomain systemd[1]: httpd.service: main process exited, code=exited, st...URE
Apr 08 21:41:25 localhost.localdomain kill[1546]: kill: cannot find process ""
Apr 08 21:41:25 localhost.localdomain systemd[1]: httpd.service: control process exited, code=exited ...s=1
Apr 08 21:41:25 localhost.localdomain systemd[1]: Failed to start The Apache HTTP Server.
Apr 08 21:41:25 localhost.localdomain systemd[1]: Unit httpd.service entered failed state.
Apr 08 21:41:25 localhost.localdomain systemd[1]: httpd.service failed.
Hint: Some lines were ellipsized, use -l to show in full.
 
Old 04-09-2018, 12:53 PM   #8
scasey
LQ Veteran
 
Registered: Feb 2013
Location: Tucson, AZ, USA
Distribution: CentOS 7.9.2009
Posts: 5,727

Rep: Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211Reputation: 2211
Again,
Code:
 systemctl -l status httpd.service
to see the full text in the ellipsized lines.
Quote:
Syntax error on line 96 of /etc/httpd/con...nf
is pretty clear, tho.

Please use [code] tags to post code or output.

Last edited by scasey; 04-09-2018 at 12:54 PM.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
How to modify CGroup in the kernel configuration and then make a new image? hwang1298 Linux - Newbie 27 04-05-2018 04:40 PM
Allowing a normal user application to modify network configuration MALDATA Linux - Security 4 03-16-2017 01:34 AM
modify router configuration using snmp in linux dudastt Linux - Networking 4 07-20-2012 11:16 AM
cannot modify grub configuration ythevenot Linux - General 2 11-22-2004 06:07 PM
How can I modify the default configuration of gnome-terminalīs in RH 7.1 Coltrane Linux - Newbie 1 09-20-2001 02:04 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 02:26 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration