Solved

I need help with Linux server

Posted on 2014-12-17
2
204 Views
Last Modified: 2014-12-17
Hello,

Our web server hosts a few sites. for example, it host test1.contoso.com, test2.contoso.com, test3.contoso.com, etc. How do I delete test3.contoso.com? It's all hosted on one server which run red hat linux and has apache, mysql, and php running.

Also, is there a way to disable email notification services on the server? I don't want any email coming or redirecting from the server if there is alert/notification setup.

thank you!
0
Comment
Question by:auraria
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 58

Expert Comment

by:Gary
ID: 40505639
In httpd.conf remove the virtual host block
If you can't find it then it is probably being loaded from the sites-enabled folder - check the httpd.conf for any .conf include lines.
Should also remove the DNS entry - how will depend on where your DNS is hosted

disable email notification services
Email from what?
0
 
LVL 12

Accepted Solution

by:
Kent W earned 500 total points
ID: 40505649
To remove from apache, find the <virtualhost></virtualhost> container that defines your "test3.contoso.com" entry, and either REM it out or remove the entry and restart apache.
In RH, this is usually found at
/etc/httpd/conf/httpd.conf
Look toward the end of the config file.

To actually remove the files, (and be careful with recursive removes...)
If the sites files actually live in, say, /var/www/html/test.contoso.com/
then you would issue a remove recursive command -
rm -Rf /var/www/html/test3.contoso.com/

To remove the database, if it's named something like test3_contoso_db, then
run the mysql client (mysql -u user - p password), then when at the mysql cli, do a -
mysql> drop database test3_contosos_db;
(note the semi-colon on the end)

Php is just an interpreter running through apache, so there is nothing you need to do with it.
0

Featured Post

Learn by Doing. Anytime. Anywhere.

Do you like to learn by doing?
Our labs and exercises give you the chance to do just that: Learn by performing actions on real environments.

Hands-on, scenario-based labs give you experience on real environments provided by us so you don't have to worry about breaking anything.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Little introduction about CP: CP is a command on linux that use to copy files and folder from one location to another location. Example usage of CP as follow: cp /myfoder /pathto/destination/folder/ cp abc.tar.gz /pathto/destination/folder/ab…
In part one, we reviewed the prerequisites required for installing SQL Server vNext. In this part we will explore how to install Microsoft's SQL Server on Ubuntu 16.04.
The purpose of this video is to demonstrate how to set up the WordPress backend so that each page automatically generates a Mailchimp signup form in the sidebar. This will be demonstrated using a Windows 8 PC. Tools Used are Photoshop, Awesome…
How to Install VMware Tools in Red Hat Enterprise Linux 6.4 (RHEL 6.4) Step-by-Step Tutorial
Suggested Courses

628 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question