A packet transmission method in a multicast domain name system, mDNS, comprising: converting (43, 61), by a relay, a multicast Known-Answer service query packet that is sent by a user terminal and used to query service information in an mDNS, into a unicast Known-Answer service query packet and sending the unicast Known-Answer service query packet to a gateway, wherein an identity field of the unicast Known-Answer service query packet comprises a terminal identity determined by the relay for the user terminal that sends the multicast Known-Answer service query packet, wherein the converting comprises replacing, by the relay, the source address of the multicast Known-Answer service query packet sent by the user terminal with an address of the relay, replacing a destination address of the multicast Known-Answer service query packet sent by the user terminal with an address of the gateway, and writing the determined terminal identity into the identity field of the multicast Known-Answer service query packet; receiving (49, 62), by the relay, a unicast Known-Answer service answer packet that is sent by the gateway and comprises service information unknown to the user terminal, wherein the service information unknown to the user terminal is obtained by the gateway after removing, based on the terminal identity comprised in the received unicast Known-Answer service query packet, all service information known to the user terminal corresponding to the terminal identity from an established correspondence between a terminal identity and known service information; and converting (50, 63), by the relay, the unicast Known-Answer service answer packet into a multicast Known-Answer service answer packet and sending the multicast Known-Answer service answer packet to the user terminal. converting (43, 61), by a relay, a multicast Known-Answer service query packet that is sent by a user terminal and used to query service information in an mDNS, into a unicast Known-Answer service query packet and sending the unicast Known-Answer service query packet to a gateway, wherein an identity field of the unicast Known-Answer service query packet comprises a terminal identity determined by the relay for the user terminal that sends the multicast Known-Answer service query packet, wherein the converting comprises replacing, by the relay, the source address of the multicast Known-Answer service query packet sent by the user terminal with an address of the relay, replacing a destination address of the multicast Known-Answer service query packet sent by the user terminal with an address of the gateway, and writing the determined terminal identity into the identity field of the multicast Known-Answer service query packet; receiving (49, 62), by the relay, a unicast Known-Answer service answer packet that is sent by the gateway and comprises service information unknown to the user terminal, wherein the service information unknown to the user terminal is obtained by the gateway after removing, based on the terminal identity comprised in the received unicast Known-Answer service query packet, all service information known to the user terminal corresponding to the terminal identity from an established correspondence between a terminal identity and known service information; and converting (50, 63), by the relay, the unicast Known-Answer service answer packet into a multicast Known-Answer service answer packet and sending the multicast Known-Answer service answer packet to the user terminal.