Hi
I am using packetdrill wire_server and wire_client options on remote machines, the commands are
server side:
sudo ./packetdrill --wire_server --wire_server_dev=enp1s0f0
client side:
sudo ./packetdrill --local_ip=172.16.0.1 --gateway_ip=172.16.0.2 --netmask_ip=255.255.255.0 --remote_ip=
172.16.1.1/24 --wire_client --wire_client_dev="eno8" --wire_server_ip="13.0.0.21" ../tcp/ioctl/ioctl-siocinq-fin.pkt
It is working fine on kernel mode.
I am trying to run packetdrill on f-stack written over DPDK. In DPDK we unbind the interfaces from kernel and bind to DPDK. I have tried my TCP/IP stack shared library with the help of --so-filename on the client-side, but this is not working as my interface is not bind to kernel, and packetdrill will be unable to find the interface in the kernel. As packetdrill establish a connection with remote server first and then load the shared library.
sudo ./packetdrill --local_ip=172.16.0.1 --gateway_ip=172.16.0.2 --netmask_ip=255.255.255.0 --remote_ip=172.16.1.1/24 --wire_client --wire_client_dev="eno8" --wire_server_ip="13.0.0.21" --so_filename=<path to shared_lib> ../tcp/ioctl/ioctl-siocinq-fin.pkt
>> ioctl SIOCGIFINDEX: No such device
Main problem
===========
Due to this, I want to use LD_PRELOAD with packetdrill object file. I have tried to LD_PRELOAD it in various ways and searched out google to resolve it but failed.
I have created a sample object file opening a socket and close it. By LD_PRELOAD shared library on the object file, it responded as:
sudo LD_PRELOAD=<path to shared lib> ./a.out
>> In library socket
On running LD_PRELOAD with packetdrill.
sudo LD_PRELOAD=<path to shared lib> ./packetdrill --local_ip=172.16.0.1 --gateway_ip=172.16.0.2 --netmask_ip=255.255.255.0 --remote_ip=172.16.1.1/24 --wire_client --wire_client_dev="eno8" --wire_server_ip="13.0.0.21" ../tcp/ioctl/ioctl-siocinq-fin.pkt >> ioctl SIOCGIFINDEX: No such device
On packetdrill, LD_PRELOAD is not working, as none of my stack functions are preloaded.
Can you please let me know how can I run the packet drill with my shared library as LD_PRELOAD?
Kind regards,
Ibtisam