Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Can't receive UDP on linux system
Qt 6.11 is out! See what's new in the release blog

Can't receive UDP on linux system

Scheduled Pinned Locked Moved General and Desktop
6 Posts 4 Posters 2.6k Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • I Offline
    I Offline
    Ivan1120
    wrote on last edited by
    #1

    Hi guys:
    I am going to use udp in my own application, and i tested the example(broadcastsender, broadcastreceiver) in the Qt Creatror. One thing is weird, i test some situations and show them on the following:
    1.Sender in Windows, Receiver in Windows can receive data, but in Linux it can't.
    2.Sender in Linux, Receiver in Windows cant receive data, in Linux it can too.

    I have closed the firewall in the linux. In the situation 1, Receiver still didn't receive any data, does anyone know why?? Thanks in advance.

    1 Reply Last reply
    0
    • dheerendraD Offline
      dheerendraD Offline
      dheerendra
      Moderators Qt Champions 2024 Qt Champions 2022 Qt Champions 2017
      wrote on last edited by
      #2

      Hope windows and linux boxes are in same network. What is the IP of both windows and linux boxes ? Since you are telling that it can receive data in a same box, it means that port is not a issue.

      Another option is to check the packet flow using wireshark.

      Dheerendra
      @Community Service
      Certified Qt Specialist
      https://www.pthinks.com

      1 Reply Last reply
      1
      • I Offline
        I Offline
        Ivan1120
        wrote on last edited by
        #3

        Hi, the ip in the windows is 172.22.102.51 and in the linux is 172.22.102.90

        1 Reply Last reply
        0
        • tomasz3dkT Offline
          tomasz3dkT Offline
          tomasz3dk
          wrote on last edited by
          #4

          How many network interfaces have you on Linux machine?

          1 Reply Last reply
          0
          • N Offline
            N Offline
            nando76
            wrote on last edited by
            #5

            does ping work?

            1 Reply Last reply
            0
            • I Offline
              I Offline
              Ivan1120
              wrote on last edited by
              #6

              Hi guys:
                   I found where the problem is, because the linux connect to internet by wireless, and the windows have two interface, one by wireless and the other one by ethernet. If i remove the ethernet from windows, the linux system can receive the UDP from the windows through wireless. Can QUdpSocket have function that could ask which interface to broadcast??

              1 Reply Last reply
              0

              • Login

              • Login or register to search.
              • First post
                Last post
              0
              • Categories
              • Recent
              • Tags
              • Popular
              • Users
              • Groups
              • Search
              • Get Qt Extensions
              • Unsolved