Forum Discussion

schmal_111133's avatar
schmal_111133
Icon for Nimbostratus rankNimbostratus
Aug 04, 2011

Change the IP TOS by HTTP header

Hi,

I have a scenario that I need to change the tos in the IP header based on an HTTP header if it exist then I should change the tos, can I do it by an iRule or by any other way?

 

 

 

something that should look like this I guess:

 

 

 

when HTTP_REQUEST {

 

if { [HTTP::header exists "TOS"] } {

 

IP::tos 16

 

}

 

log local0.alert "[IP::tos]"

 

forward

 

}

 

 

 

 

I trying to understand why this is not working.

 

 

 

Thanks in advance.

 

4 Replies

  • Hi Schmal,

     

     

    The wiki page shows it's a read only command. However, the set syntax passes validation. I found a very old case where we suggested a customer set the pool explicitly in the iRule for the command to work. But I couldn't find much more than that. I suggest opening a case with F5 Support and ask them to clarify whether you can set the value with IP::tos and if there are any issues or specific requirements for using the command.

     

     

    If you do this can you reply back with what you find out for future reference?

     

     

    Aaron
  • rK_77696's avatar
    rK_77696
    Historic F5 Account

    I have the same issue with another PoC, I am about to try a crack at using a Binary scan to solve the problem.

     

     

     

    rK

     

  • John_Alam_45640's avatar
    John_Alam_45640
    Historic F5 Account
    The IP::tos command can be used to set the value. I've only used it in the CLIENT_ACCEPTED event.