Removing a default domain from one of your IP addresses in Plesk
Once you have set a domain to be the default domain for a specific IP address in Plesk, you will not be able to deselect that particular domain. At this point, you only have the option of switching the IP address to another domain on your (dv).
Before you start, this article has the following dependencies:
- You must have SSH access set up for the root user.
End of Life Warning
This service has a pending End of Life. Please move to a current service as soon as possible. For more information, please see: (dv) Dedicated-Virtual 4.0: Migration Information.
READ ME FIRST
The publishing of this information does not imply support of this article. This article is provided solely as a courtesy to our customers. Please take a moment to review the Statement of Support.
If you would like to do this, there is a solution using MySQL commands. You can manually set the
default_domain_id to zero for a specific IP address directly in the Plesk database. Make sure to replace IP.ADD.RE.SS with your address.
# mysql -uadmin -p`cat /etc/psa/.psa.shadow` -Dpsa -e "UPDATE IP_Addresses SET default_domain_id = 0 WHERE ip_address = 'IP.ADD.RE.SS';"
The following command will remove the default domain setting for all IP addresses:
# mysql -uadmin -p`cat /etc/psa/.psa.shadow` -Dpsa -e "UPDATE IP_Addresses SET default_domain_id = 0;"
Then you need to use the command 'websrvmng' to apply changes:
# /usr/local/psa/admin/sbin/websrvmng -a -v