A linux machine is connected to internet over two interfaces ppp0 and ppp1 using two modems. Also this machine acts as wireless access point through an interface say, eth0 with ip address 192.168.1.1 and acts as gateway for the connected devices through this network with subnet mask 255.255.255.0
Now is it possible to achieve the following:
When any of the connected devices through wireless AP needs internet connection linux machine has to use ppp1 interface for internet.
If any of the applications on the linux machine needs internet connection linux machine should use ppp0 interface for the internet.
Can this be achieved by adding rules to chains in filter/nat tables?
If the kernel routing table has a default rule to route the default traffic through interface ppp0, wil kernel completely ignore ppp1 for internet?
PS: new to networking and routing concepts, If the question is not clear leave a comment, will try to give more information.