LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Server (https://www.linuxquestions.org/questions/linux-server-73/)
-   -   system-config-bind issues (https://www.linuxquestions.org/questions/linux-server-73/system-config-bind-issues-628912/)

jessicaK 03-18-2008 07:32 AM

system-config-bind issues
 
Hello!

I am using bind 9 on RHEL5. I migrated these zones over from a win2k3 server and attempted to edit them to match bind's format.

-rw-r--r-- 1 root named 579 Mar 17 14:52 test.com.db

*Tried chown'ing to named:named didn't help*

$TTL 1H
test.com. IN SOA ns1.dnsserver.com. hostmaster.ns1.dnsserver.com. (3
3H
1H
1W
1H )
@ 1H IN NS ns1.dnsserver.com.
@ 1H IN NS ns2.dnsserver.com.
@ 1H IN A 10.1.1.1
www 1H IN A 10.1.1.1

*the zone lost the space formating in the post sorry!*

The above is an example of a zone that is accepted by named on restart, however if i load the dns tool system-config-bind, and attempt to make changes to this record I receive:

"Save of Zone File /var/named/chroot/var/named/test.com.db failed:
dns_master_load: /var/named/chroot/var/named/test.com.db:2: unexpected end of line
dns_master_load: /var/named/chroot/var/named/test.com.db:1: unexpected end of input
/var/named/chroot/var/named/test.com.db:11: using RFC 1035 TTL semantics
zone test.com/IN: loading master file /var/named/chroot/var/named/test.com.db: unexpected end of input"

I have added the TTL on a record bases trying to replicate a fake zone created to see if I could find the difference that system-config-bind is looking for. The only files I have edited are the named.conf file located in /var/named/etc and creating the db files by hand so it is possible if there is another file that needs to be edited maybe I am missing.

Any help would greatly be appreciated!

jessicaK 03-18-2008 09:48 AM

Ok figured it out I think, there must be hidden characters since they came from windows. I figured vi would have seen this, but I guess not. Anyone have any good scripts to strip and create heh? :)

bathory 03-18-2008 09:52 AM

If you have edited the zone file in windows there are maybe some non-printable characters. Use the dos2unix command to transform the file in unix format.

Regards

jessicaK 03-18-2008 10:02 AM

yep dos2unix is awesome anyways hope whoever reads this has a great day!

~grumbles about missing something silly~

jessicaK 03-18-2008 10:03 AM

Quote:

Originally Posted by bathory (Post 3092668)
If you have edited the zone file in windows there are maybe some non-printable characters. Use the dos2unix command to transform the file in unix format.

Regards

Missed your response! That did the trick, thanks for reply :)


All times are GMT -5. The time now is 06:52 PM.