Operating System - HP-UX
1833074 Members
7949 Online
110049 Solutions
New Discussion

Re: setting the type of service (TOS) bit on HP-UX network apps

 
SOLVED
Go to solution
Mike Graves
New Member

setting the type of service (TOS) bit on HP-UX network apps

Can anyone tell me how I can set the TOS bit
on network packets leaving a HP-UX box via an API. Question comes from customer interested in diffserv. Thanks in advance.
1 REPLY 1
Steven Gillard_2
Honored Contributor
Solution

Re: setting the type of service (TOS) bit on HP-UX network apps

You need to use the setsockopt() system call with a level of IPPROTO_IP and the optname IP_TOS.

See "man 7 ip":

IP_TOS (unsigned char) Sets the IP Type of
Service. Allowable values for optval
are 4 for high reliability, 8 for high
throughput, and 16 for low delay. Other
values will not return an error, but may
have unpredictable results. Default:
zero.

Cheers,
Steve