Solved

I need help with Linux server

Posted on 2014-12-17
2
202 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
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

Microsoft Certification Exam 74-409

Veeam® is happy to provide the Microsoft community with a study guide prepared by MVP and MCT, Orin Thomas. This guide will take you through each of the exam objectives, helping you to prepare for and pass the examination.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
Linux server had an unexpected freeze. How to find out cause (sys logs)? 13 47
IP 10.0.1.2 / 255.0.0.0 61 56
Apache module 5 47
Migrating a Linux server to VMware 3 61
If you have a server on collocation with the super-fast CPU, that doesn't mean that you get it running at full power. Here is a preamble. When doing inventory of Linux servers, that I'm administering, I've found that some of them are running on l…
The Confluence of Individual Knowledge and the Collective Intelligence At this writing (summer 2013) the term API (http://dictionary.reference.com/browse/API?s=t) has made its way into the popular lexicon of the English language.  A few years ago, …
Learn how to find files with the shell using the find and locate commands. Use locate to find a needle in a haystack.: With locate, check if the file still exists.: Use find to get the actual location of the file.:
Learn how to navigate the file tree with the shell. Use pwd to print the current working directory: Use ls to list a directory's contents: Use cd to change to a new directory: Use wildcards instead of typing out long directory names: Use ../ to move…

830 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