• We value your experience with Plesk during 2024
    Plesk strives to perform even better in 2025. To help us improve further, please answer a few questions about your experience with Plesk Obsidian 2024.
    Please take this short survey:

    https://pt-research.typeform.com/to/AmZvSXkx
  • The Horde webmail has been deprecated. Its complete removal is scheduled for April 2025. For details and recommended actions, see the Feature and Deprecation Plan.
  • We’re working on enhancing the Monitoring feature in Plesk, and we could really use your expertise! If you’re open to sharing your experiences with server and website monitoring or providing feedback, we’d love to have a one-hour online meeting with you.

Resolved Can not delete IP

Erwan

Regular Pleskian
Server operating system version
Debian 10
Plesk version and microupdate number
18.0.50
Hi all,

We want to remove IP addresses that we no longer use (15 ip).
No domain affected.
It's ok with 14 but not for 1, we have a message:
Unable to remove the IP address x.x.x.x because it is used by the DNS zone of one or more domains
There is no domain that use this IP:
plesk db "SELECT d.id AS 'Domain ID', d.name AS 'Domain', ipc.ipAddressId AS 'IP ID', ip.ip_address AS 'IPv4/IPv6' FROM domains d, DomainServices ds, IpAddressesCollections ipc, IP_Addresses ip WHERE d.id = ds.dom_id AND ds.type = 'web' AND ds.ipCollectionId = ipc.ipCollectionId AND ip.id = ipc.ipAddressId ORDER BY d.id ASC"

if the fact that the IP is used in a DNS zone of a domain blocks the deletion (without being the IP of the domain), how can we detect which domain is concerned?
There are 150 domains on the affected server.
I don't want to go to each DNS zone... :(

Is there a commande line?

Thank you.
Erwan
 
So i try:
# DNSLIST='alldnszones.txt'; plesk bin domain --list | while read i; do echo -e “n—– DOMAIN: $i —–n” >> $DNSLIST; plesk bin dns --info $i >> $DNSLIST; done

But the Ip is not in the list.

The is error message with the command:
exit status 1
The DNS zone for this domain is switched off


If the IP is in a disabled zone, can it block? how to do ?
 
How about something like...

# plesk db "select * from IP_Addresses where ip_address='X.X.X.X'"
 
No, it list IP from the network that i want to delete and i can not.
I want to know where ip used on a DNS zone...
 
How about this:
Code:
for domain in $(plesk db -Ne 'SELECT name FROM domains WHERE parentDomainId=0 ORDER BY name;'); do plesk bin dns --info $domain | grep X.X.X.X; done
 
# for domain in $(plesk db -Ne 'SELECT name FROM domains WHERE parentDomainId=0 ORDER BY name;'); do plesk bin dns --info $domain | grep <myip>; done
The DNS zone for this domain is switched off.
exit status 1
The DNS zone for this domain is switched off.
exit status 1
The DNS zone for this domain is switched off.
exit status 1
The DNS zone for this domain is switched off.
exit status 1
The DNS zone for this domain is switched off.
exit status 1
The DNS zone for this domain is switched off.
exit status 1
The DNS zone for this domain is switched off.
exit status 1
The DNS zone for this domain is switched off.
exit status 1
The DNS zone for this domain is switched off.


The same result i had with:
# DNSLIST='alldnszones.txt'; plesk bin domain --list | while read i; do echo -e “n—– DOMAIN: $i —–n” >> $DNSLIST; plesk bin dns --info $i >> $DNSLIST; done
 
Hi Peter,

#grep -R <ip address> /etc/nginx/*/*/*.conf
=> nothing

The problem is not with the domain ips. IP i want to delete is not used.
But Plesk doesn't want to delete it because it says the ip is apparently used in a DNS zone on the server.
If I search in the DNS zones (see previous mesages) there is nothing except maybe in the DNS zones of DNS disabled that previous queries cannot read.

Is there a way to find out where the ip is used in DNS disabled DNS zones?
or at least know the domains with the DNS deactivated so that I can do the control manualy, domain by domain by reactivating the DNS to see?
 
No solution ??
Is there a way to override Plesk blocking?

In summary, I want to delete an IP with the manager. Plesk refuses with the message:
Unable to remove the IP address x.x.x.x because it is used by the DNS zone of one or more domains

Ip is not used with a domain.
Ip is not used in DNS zone from domains which use internal DNS.
 
Ip is not used in DNS zone from domains which use internal DNS.
Could you please run this on the the Linux console:
plesk db -Ne "SELECT host FROM psa.dns_recs WHERE val LIKE 'your_ip_address_here';"
It returns all records from the DNS table that use the IP address.
 
Last edited:
Thank you Peter!

It was domain alias without DNS management that had been created before the change of the ip on the main domain.
By reactivating the DNS, deleting the zones with the ip concerned and deactivating on each domain alias concerned, the ip could then be deleted.
 
Back
Top