mirror of
https://github.com/tuxis-ie/nsedit.git
synced 2026-04-27 00:25:50 +03:00
[GH-ISSUE #100] "An error occured while communicating to the server." when clicking existing zones on new nsedit install #57
Labels
No labels
bug
duplicate
enhancement
help wanted
invalid
pull-request
question
question
upstream
upstream
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/nsedit#57
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @damianharouff on GitHub (Aug 9, 2016).
Original GitHub issue: https://github.com/tuxis-ie/nsedit/issues/100
I've recently upgraded an old existing PowerDNS installation to PowerDNS 4, and am replacing Poweradmin with nsedit.
I've got everything working in terms of being able to log in and view a list of zones, however, when I click on some zones, it returns "An error occurred while communicating to the server":

Every time I click on one of these zones that return the "An error..." message, I see the following in the HTTP server error log:
[Tue Aug 09 14:33:06.792372 2016] [:error] [pid 13398] [client x.x.x.x:41590] PHP Fatal error: Call to undefined function Exception() in /var/www/html/nsedit/includes/class/Zone.php on line 243, referer: http://ns1.redacted.com/nsedit/index.php [Tue Aug 09 14:33:18.933587 2016] [:error] [pid 17214] [client x.x.x.x:41600] PHP Fatal error: Call to undefined function Exception() in /var/www/html/nsedit/includes/class/Zone.php on line 243, referer: http://ns1.redacted.com/nsedit/index.php [Tue Aug 09 14:33:26.489658 2016] [:error] [pid 17287] [client x.x.x.x:41602] PHP Fatal error: Call to undefined function Exception() in /var/www/html/nsedit/includes/class/Zone.php on line 243, referer: http://ns1.redacted.com/nsedit/index.php [Tue Aug 09 14:34:35.041491 2016] [:error] [pid 13420] [client x.x.x.x:41632] PHP Fatal error: Call to undefined function Exception() in /var/www/html/nsedit/includes/class/Zone.php on line 243, referer: http://ns1.redacted.com/nsedit/index.php [Tue Aug 09 14:35:03.377555 2016] [:error] [pid 13398] [client x.x.x.x:41642] PHP Fatal error: Call to undefined function Exception() in /var/www/html/nsedit/includes/class/Zone.php on line 243, referer: http://ns1.redacted.com/nsedit/index.php [Tue Aug 09 14:35:24.824011 2016] [:error] [pid 13444] [client x.x.x.x:41644] PHP Fatal error: Call to undefined function Exception() in /var/www/html/nsedit/includes/class/Zone.php on line 243, referer: http://ns1.redacted.com/nsedit/index.phpOK so if we take a look at line 243 I see that it's part of this block of code:
public function addRecord($content, $disabled = FALSE, $setptr = FALSE) {
foreach ($this->records as $record) {
if ($record->content == $content) {
throw Exception("Record already exists");
}
}
$record = new Record($content, $disabled, $setptr);
array_push($this->records, $record);
}
Line 243 is "throw Exception"... alright, I can see that this needs to be "throw new Exception....". I fix this, and now I get the following notice:

I'd like to reiterate that this is an existing zone with data already in it, and it seems to affect only some of the zones. Other zones seem to work without issue.
Let me know what more data I can provide to help troubleshoot.
@tuxis-ie commented on GitHub (Aug 9, 2016):
Grmbl. Can it be that there are actually duplicate records within the same rrset in those zones?
@damianharouff commented on GitHub (Aug 9, 2016):
Yes, that does seem to be the issue... I deleted duplicates and it seems to load now. I appreciate the pointer on that.