Capture OTA Log with Intel AX2xx Wi-Fi Module
This KBA describes the procedure on using Ubuntu Wireshark to capture OTA log with Intel AX2xx Wi-Fi module.
How to install wireshark in ubuntu
Steps to Install Wireshark on Ubuntu Linux:
To install the latest version of Wireshark on Ubuntu we have to follow certain steps:
Step 1: Go to the terminal by simply pressing Ctrl + Alt + t or right-click + Open in Terminal
Step 2: Add a repository by running this command,
sudo add-apt-repository ppa:wireshark-dev/stable
Step 3: Update the repository
sudo apt update
Step 4: Install Wireshark sudo apt install wireshark
Step 5: Wireshark is installed, you can run in the terminal to do so run this command
or just simply go to show applications and run Wireshark.
You can check the version of your installed Wireshark by running the following command
apt show wireshark
If you face any error during installation or running Wireshark like Wireshark xdg_runtime_dir not set then open the terminal and run this command and click YES to the message box
sudo dpkg-reconfigure wireshark-common
After opening Wireshark if you can see wavy lines beside enp0s3 then congratulations, you are all set and good to go.
How to Use Wireshark
To capture the networking packages using Wireshark follow these steps
Step 1: Go to Wireshark and double click on the first option enp0s3 to start capturing
Step 2: You can see a window with various source and destination IP addresses, protocols, lengths, etc. This is where you are capturing the protocols. The Protocol is showing currently which network protocol is running on your system and their source and destination IP addresses. You can also apply filters by protocol names to see only the packets you want to see.
Step 3: After capturing all the required packets that you want you can stop by simply clicking the red square button at the top-left. To start capturing again just click the blue button beside the red stop button.
Commands for setting Intel AX2xx WIFI module as monitor mode
- sudo modprobe -r iwlwifi
- sudo modprobe iwlwifi amsdu_size=3
- sudo iw phy phy0 interface add mon0 type monitor (*1)
- sudo ifconfig mon0 up
- sudo iw dev wlp4s0 del (*2)
- sudo iw dev mon0 set channel 11(*3)
*1: Select mon0 as capture interface in wireshart as this set AX2xx WIFI module as monitor mode
*2: Need use ifconfig to get the original interface, it may be not wlp4s0
*3: Change other channel if you want to capture data at different channel
Change from channel 11 to channel 153