Question about asterisk > Slow reload

Hi!
I’m running Asterisk 1.8.4.2.

I’m having the following issues:

In our Office, we have a firewall that disable the default gateway 192.168.10.1 because we only use internet in the night.

My PBX IP is: 192.168.10.5
I try to connect via ssh to my PBX IP, it ask for the username…OK, then it take something like 10 or more seconds to ask for the password… why? (NOTE* My Laptop and my PBX, we both are in the LAN) NO via remote connection

The rare is that, in the night (When internet is working) if i try to connect to my PBX, it ask me for the username…OK, then INMEDIATLY it ask for the password. INMEDIATLY.

Why is happening this?

I try other forums and they says is something about DNS… but… Why?
I’m NOT need anything about DNS if we are in the same Office LAN… What you think is happening bro?

The second issue is: When reload the asterisk CLI> reload… it takes more time thatn normal and if i try to make a call after reload the asterisk the calls don’t proceed… in my phone screen says: Calling…

But when the reload is completed is something like 10 seconds or more, If i try to call again, the call proceed correct…
I believe this issue is related with the FIRST one…

A reverse DNS operation will be being performed. If you do not have a proper in-addr.arpa domain for you LAN, when you are connected to the internet, you will get a definitive response that in-addr.arpa is broken for that address. If you are disconnected from the internet, you will have to wait for it to timeout (even then, some software may block until it does resolve or fail).

You can: give priority to /etc/hosts and define all the local addresses there.

Run a local nameserver which is authorative for your LAN’s addresses on in-addr.arpa (even if it doesn’t know any of them). This would be best practice if you can’t use the next option.

Allow DNS requests through, even during the day.

Reverse lookup is done by looking up the reversed IP address in the in-addr.arpa. domain, e.g. 192.168.0.1 would be looked up as 1.0.168.192.in-addr.arpa.

Anything as security conscious as ssh is going to be doing reverse lookups.

You can put

in your sshd_config to prevent useless dns lookups by sshd. You also should not be using passwords with ssh, learn how to work with ssh-agent, it will make your life easier.