can mediaproxy relay set IP ToS

classic Classic list List threaded Threaded
8 messages Options
Reply | Threaded
Open this post in threaded view
|

can mediaproxy relay set IP ToS

Jeff Pyle
Hello,

Is it possible to configure mediaproxy, or iptables or that matter, to mark
the relay's outgoing packets with a specific ToS value?  Unfortunately some
up of my upstream providers strip the DSCP tags coming in and I'd like to
take the opportunity at the relay to remark them with EF (0x2E).



- Jeff
 


_______________________________________________
Users mailing list
[hidden email]
http://lists.opensips.org/cgi-bin/mailman/listinfo/users
Reply | Threaded
Open this post in threaded view
|

Re: can mediaproxy relay set IP ToS

Dan Pascu

On 30 Oct 2009, at 18:58, Jeff Pyle wrote:

> Hello,
>
> Is it possible to configure mediaproxy, or iptables or that matter,  
> to mark
> the relay's outgoing packets with a specific ToS value?  
> Unfortunately some
> up of my upstream providers strip the DSCP tags coming in and I'd  
> like to
> take the opportunity at the relay to remark them with EF (0x2E).

Not ATM. The support for marking the packets that pass through the  
conntrack rules is there, it's just not used yet.

--
Dan




_______________________________________________
Users mailing list
[hidden email]
http://lists.opensips.org/cgi-bin/mailman/listinfo/users
Reply | Threaded
Open this post in threaded view
|

Re: can mediaproxy relay set IP ToS

Jeff Pyle
Hi Dan,


On 11/3/09 4:00 AM, "Dan Pascu" <[hidden email]> wrote:

>
> On 30 Oct 2009, at 18:58, Jeff Pyle wrote:
>
>> Hello,
>>
>> Is it possible to configure mediaproxy, or iptables or that matter,
>> to mark
>> the relay's outgoing packets with a specific ToS value?
>> Unfortunately some
>> up of my upstream providers strip the DSCP tags coming in and I'd
>> like to
>> take the opportunity at the relay to remark them with EF (0x2E).
>
> Not ATM. The support for marking the packets that pass through the
> conntrack rules is there, it's just not used yet.


Is there any conceivable way with a mangle rule to mark any udp packets
within the relay's port range leaving the interface to have a certain DSCP
value?  For example, in my case, everything leaving eth1 within 16384-32768
I'd like to mark EF.  I looked at some iptables documentation and did some
tests but I wasn't able to come up with anything that did the job.


- Jeff


_______________________________________________
Users mailing list
[hidden email]
http://lists.opensips.org/cgi-bin/mailman/listinfo/users
Reply | Threaded
Open this post in threaded view
|

Re: can mediaproxy relay set IP ToS

Dan Pascu
On 3 Nov 2009, at 17:37, Jeff Pyle wrote:

>>> Is it possible to configure mediaproxy, or iptables or that matter,
>>> to mark
>>> the relay's outgoing packets with a specific ToS value?
>>> Unfortunately some
>>> up of my upstream providers strip the DSCP tags coming in and I'd
>>> like to
>>> take the opportunity at the relay to remark them with EF (0x2E).
>>
>> Not ATM. The support for marking the packets that pass through the
>> conntrack rules is there, it's just not used yet.
>
>
> Is there any conceivable way with a mangle rule to mark any udp  
> packets
> within the relay's port range leaving the interface to have a  
> certain DSCP
> value?  For example, in my case, everything leaving eth1 within  
> 16384-32768
> I'd like to mark EF.  I looked at some iptables documentation and  
> did some
> tests but I wasn't able to come up with anything that did the job.

I guess you can use iptables to mark all the packets that arrive on  
the mediaproxy ports with a flag and then use iptables to set the TOS  
value when they leave. Or it could be probably done in a single step:  
set the TOS value on all the packets arriving on the mediaproxy port  
range. I just don't remember how exactly this is done. You'll have to  
consult the iptables man page.

What I mentioned in mediaproxy would have done just this (when  
implemented), only it would be more precise: i.e. it would only mark  
the mediaproxy related packets, while the static iptables rule method  
may set the TOS value on non-mediaproxy packets if they happen to be  
in range.

--
Dan




_______________________________________________
Users mailing list
[hidden email]
http://lists.opensips.org/cgi-bin/mailman/listinfo/users
Reply | Threaded
Open this post in threaded view
|

Re: can mediaproxy relay set IP ToS

Jeff Pyle
At this point I'd accept quantity over quality.  All packets is better than
no packets.  I had tried on egress without success.  I'll have to rework it
to try on ingress instead.


- Jeff



On 11/5/09 4:44 AM, "Dan Pascu" <[hidden email]> wrote:

> On 3 Nov 2009, at 17:37, Jeff Pyle wrote:
>>>> Is it possible to configure mediaproxy, or iptables or that matter,
>>>> to mark
>>>> the relay's outgoing packets with a specific ToS value?
>>>> Unfortunately some
>>>> up of my upstream providers strip the DSCP tags coming in and I'd
>>>> like to
>>>> take the opportunity at the relay to remark them with EF (0x2E).
>>>
>>> Not ATM. The support for marking the packets that pass through the
>>> conntrack rules is there, it's just not used yet.
>>
>>
>> Is there any conceivable way with a mangle rule to mark any udp
>> packets
>> within the relay's port range leaving the interface to have a
>> certain DSCP
>> value?  For example, in my case, everything leaving eth1 within
>> 16384-32768
>> I'd like to mark EF.  I looked at some iptables documentation and
>> did some
>> tests but I wasn't able to come up with anything that did the job.
>
> I guess you can use iptables to mark all the packets that arrive on
> the mediaproxy ports with a flag and then use iptables to set the TOS
> value when they leave. Or it could be probably done in a single step:
> set the TOS value on all the packets arriving on the mediaproxy port
> range. I just don't remember how exactly this is done. You'll have to
> consult the iptables man page.
>
> What I mentioned in mediaproxy would have done just this (when
> implemented), only it would be more precise: i.e. it would only mark
> the mediaproxy related packets, while the static iptables rule method
> may set the TOS value on non-mediaproxy packets if they happen to be
> in range.
>
> --
> Dan
>
>
>
>
> _______________________________________________
> Users mailing list
> [hidden email]
> http://lists.opensips.org/cgi-bin/mailman/listinfo/users


_______________________________________________
Users mailing list
[hidden email]
http://lists.opensips.org/cgi-bin/mailman/listinfo/users
Reply | Threaded
Open this post in threaded view
|

OpenSIPS and OpenSIPS-CP

Robert Lindabury
Hello all!

I'm having some problems getting opensips-cp fifo working.

OpenSIPS 1.6.0-notls (x86_64/linux)  CentOS 5.4

osipsconsole and opensipsctl fifo commands all work fine.

mi_fifo.so module is loading fine and modparams seem to be as they
should be:

# ----- mi_fifo params -----
modparam("mi_fifo", "fifo_name", "/tmp/opensips_fifo")

the var/www/opensips-cp/config/boxes.global.inc.php config entry as
follows:

// mi host:port pair || fifo_file
$boxes[$box_id]['mi']['conn']="/tmp/opensips_fifo";

Whenever I try to execute a MI Command in opensips-cp I get:

"sorry -- cannot open write fifo"

I see the file in /tmp and owner/group is root/root with rw perms for
owner/group.

I tried changing the user/group to apache/apache with the same
permissions but same result.

Any suggestions?

Thanks!

-- Bob  

_______________________________________________
Users mailing list
[hidden email]
http://lists.opensips.org/cgi-bin/mailman/listinfo/users
Reply | Threaded
Open this post in threaded view
|

Re: OpenSIPS and OpenSIPS-CP

Iulia Bublea-2
Hi,

Try setting in opensips.cfg

modparam("mi_fifo", "fifo_mode", 0666)
Afterwards restart the opensips server.

Regards,
Iulia


Robert Lindabury wrote:

> Hello all!
>
> I'm having some problems getting opensips-cp fifo working.
>
> OpenSIPS 1.6.0-notls (x86_64/linux)  CentOS 5.4
>
> osipsconsole and opensipsctl fifo commands all work fine.
>
> mi_fifo.so module is loading fine and modparams seem to be as they
> should be:
>
> # ----- mi_fifo params -----
> modparam("mi_fifo", "fifo_name", "/tmp/opensips_fifo")
>
> the var/www/opensips-cp/config/boxes.global.inc.php config entry as
> follows:
>
> // mi host:port pair || fifo_file
> $boxes[$box_id]['mi']['conn']="/tmp/opensips_fifo";
>
> Whenever I try to execute a MI Command in opensips-cp I get:
>
> "sorry -- cannot open write fifo"
>
> I see the file in /tmp and owner/group is root/root with rw perms for
> owner/group.
>
> I tried changing the user/group to apache/apache with the same
> permissions but same result.
>
> Any suggestions?
>
> Thanks!
>
> -- Bob  
>
> _______________________________________________
> Users mailing list
> [hidden email]
> http://lists.opensips.org/cgi-bin/mailman/listinfo/users
>
>  


_______________________________________________
Users mailing list
[hidden email]
http://lists.opensips.org/cgi-bin/mailman/listinfo/users
Reply | Threaded
Open this post in threaded view
|

Re: OpenSIPS and OpenSIPS-CP

Jonathan Thurman
In reply to this post by Robert Lindabury
On Thu, Nov 5, 2009 at 12:40 PM, Robert Lindabury
<[hidden email]> wrote:

> Hello all!
>
> I'm having some problems getting opensips-cp fifo working.
>
> OpenSIPS 1.6.0-notls (x86_64/linux)  CentOS 5.4
>
> osipsconsole and opensipsctl fifo commands all work fine.
>
> mi_fifo.so module is loading fine and modparams seem to be as they
> should be:
>
> # ----- mi_fifo params -----
> modparam("mi_fifo", "fifo_name", "/tmp/opensips_fifo")
>
> the var/www/opensips-cp/config/boxes.global.inc.php config entry as
> follows:
>
> // mi host:port pair || fifo_file
> $boxes[$box_id]['mi']['conn']="/tmp/opensips_fifo";
>
> Whenever I try to execute a MI Command in opensips-cp I get:
>
> "sorry -- cannot open write fifo"
>
> I see the file in /tmp and owner/group is root/root with rw perms for
> owner/group.
>
> I tried changing the user/group to apache/apache with the same
> permissions but same result.

Add the apache user to the group that OpenSIPS runs as, then restart
httpd.  In my case this is the "opensips" group, and it works on that
platform.  Just know that apache will be able to write to any file
with group RW permissions and GID of opensips.

-Jonathan

_______________________________________________
Users mailing list
[hidden email]
http://lists.opensips.org/cgi-bin/mailman/listinfo/users