<div dir="ltr"><br><div class="gmail_extra"><br><br><div class="gmail_quote">2013/4/8 Johan Wilfer <span dir="ltr"><<a href="mailto:lists@jttech.se" target="_blank">lists@jttech.se</a>></span><br><blockquote class="gmail_quote" style="margin:0pt 0pt 0pt 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
2013-04-08 16:36, Olivier skrev:<div><div class="h5"><br>
<blockquote class="gmail_quote" style="margin:0pt 0pt 0pt 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
Hello,<br>
<br>
Many times, I need to test in a lab Asterisk servers before sending them<br>
to customer locations.<br>
I'm currently having trouble to test SIP trunks without touching SIP<br>
configuration.<br>
<br>
So, how should I change my testing lab so that I could now test SIP<br>
trunks without modifying Asterisk server under test ?<br>
<br>
<br>
A typical set up is:<br>
<br>
Asterisk server1 under test <---SIP----> Router <----- SIP ----> Lab's<br>
Asterisk server2<br>
<br>
All machines (server1, router and server2) have Internet access.<br>
Router and server2 have a private address.<br>
<br>
Ideally, router should get customer's public adress (eg 1.2.3.4),<br>
server2 should also get my ITSP public address (eg 4.3.2.1) and both<br>
machines should route trafic to each other without leaving my LAN and<br>
using Internet access.<br>
<br>
What would you suggest ?<br>
</blockquote>
<br></div></div>
I often configure a router to do NAT in these cases. You can do NAT even with a public net on the inside. Configure the temporary router with the IP of the customers router for the inside, and make it a dhcp client (or whatever you use) in your LAN for the outside interface.<br>
<br>
You can make a route in your router to your ITSP-gw like this :<br>
route add -host 4.3.2.1 dev eth0<br>
<br>
This means all traffic to 4.3.2.1 will go to dev eth0 on your router.<br>
(The device in your network with the ip 4.3.2.1 also needs to have a route back to your router for replies.)<br></blockquote><div><br></div><div>Please, excuse me but I'm not sure I got your suggestion and I'm realizing I didn't correctly describe my lab set up.<br>
<br></div><div>At the moment, the router between both servers provides Internet access to server1.<br></div><div>That means it has one WAN interface eth0 which is "on server2 side" and one eth1 LAN interface which is on server1 side.<br>
</div><div>Currently, this router do NAT translation for server1.<br><br></div><div>Having clarified my setup, I guess your advice is to :<br>1. add address 1.2.3.4 to router's eth0<br></div><div>2. add address 4.3.2.1 to server2 interface<br>
</div><div>3. configure router to route trafic to 4.3.2.1 using server2 private address (such as "ip route add <a href="http://4.3.2.1/24">4.3.2.1/24</a> via 192.168.1.25")<br>4. configure server to route trafic to 1.2.3.4 using router private address<br>
<br></div><div>Is this correct ?<br></div><div><br></div><div><br></div><div> </div><blockquote class="gmail_quote" style="margin:0pt 0pt 0pt 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
<br>
Good luck!<span class=""><font color="#888888"><br>
<br>
-- <br>
Johan Wilfer<br>
<br>
--<br>
______________________________<u></u>______________________________<u></u>_________<br>
-- Bandwidth and Colocation Provided by <a href="http://www.api-digital.com" target="_blank">http://www.api-digital.com</a> --<br>
New to Asterisk? Join us for a live introductory webinar every Thurs:<br>
<a href="http://www.asterisk.org/hello" target="_blank">http://www.asterisk.org/hello</a><br>
<br>
asterisk-users mailing list<br>
To UNSUBSCRIBE or update options visit:<br>
<a href="http://lists.digium.com/mailman/listinfo/asterisk-users" target="_blank">http://lists.digium.com/<u></u>mailman/listinfo/asterisk-<u></u>users</a><br>
</font></span></blockquote></div><br></div></div>