Bonjour Sleep Proxy
   HOME

TheInfoList



OR:

Apple An apple is a round, edible fruit produced by an apple tree (''Malus'' spp.). Fruit trees of the orchard or domestic apple (''Malus domestica''), the most widely grown in the genus, are agriculture, cultivated worldwide. The tree originated ...
's Bonjour Sleep Proxy service is an
open source Open source is source code that is made freely available for possible modification and redistribution. Products include permission to use and view the source code, design documents, or content of the product. The open source model is a decentrali ...
component of
zero-configuration networking Zero-configuration networking (zeroconf) is a set of technologies that automatically creates a usable computer network based on the Internet Protocol Suite (TCP/IP) when computers or network peripherals are interconnected. It does not require manu ...
, designed to assist in reducing power consumption of networked electronic devices. It allows a device providing services, such as file sharing, printer sharing, or remote log-in, to ''sleep'', i.e. enter a low-power mode, while its services remain available, even world-wide, by registering with a ''sleep proxy server'' on the local network. The sleep proxy server continues to both advertise the services on the local network on behalf of the sleep host, and listen for incoming connections whether the services are available only locally or across the Internet. When any device attempts to use any proxied service, the proxy server wakes the sleeping device and the service works as if the sleeping device had remained fully powered. Any device that can act as a sleep proxy server advertises this on all LANs of which it is a part. A device providing network services, such as file sharing, when its services are not actively being used can register its services with an available sleep proxy server and sleep until one of its services is needed. The sleep proxy server continues to advertise the services in
Multicast DNS Multicast DNS (mDNS) is a computer networking protocol that resolves hostnames to IP addresses within small networks that do not include a local name server. It is a Zero-configuration_networking#Name_service_discovery, zero-configuration service, ...
(mDNS) on behalf of the sleeping host. When the sleep proxy server sees an attempt to use any such service it wakes the sleeping host and the service proceeds normally, and in the case of
SSH The Secure Shell Protocol (SSH Protocol) is a cryptographic network protocol for operating network services securely over an unsecured network. Its most notable applications are remote login and command-line execution. SSH was designed for Un ...
, a server with an active session can register with a proxy, sleep, and be awakened with the next received packet, continuing the same session. Apple refers to the service as Bonjour Sleep Proxy in its support documents. The service uses the ''Wake on Demand'' feature, first offered in
Mac OS X Snow Leopard Mac OS X Snow Leopard (version 10.6) (also referred to as OS X Snow Leopard) is the seventh major release of macOS, Apple's desktop and server operating system for Macintosh computers. Snow Leopard was publicly unveiled on June 8, 2009, at A ...
.


Details


Address Resolution Protocol and Neighbor Discovery Protocol

When a sleep proxy service accepts a request to proxy, it in effect takes over the IP addresses of proxied servers by announcing this through
Address Resolution Protocol The Address Resolution Protocol (ARP) is a communication protocol for discovering the link layer address, such as a MAC address, associated with a internet layer address, typically an IPv4 address. The protocol, part of the Internet protocol s ...
(ARP) and
Neighbor Discovery Protocol The Neighbor Discovery Protocol (NDP), or simply Neighbor Discovery (ND), is a protocol of the Internet protocol suite used with Internet Protocol Version 6 (IPv6). It operates at the internet layer of the Internet model, and is responsible for ...
(NDP). To claim traffic for the proxied host’s IPv4 addresses, it sends gratuitous ARP announcements so that packets addressed to the proxied server go to the proxy instead, and for IPv6 it does the same using the analogous NDP. To maintain the association, it responds on behalf of the sleeping host to ARP and NDP requests. This process effectively maps the IP addresses of proxied servers to a physical port of the proxy server. When a packet arrives, from anywhere on the Internet, for a proxied service, the sleep proxy server wakes the sleeping host and reverses the above process, using ARP and NDP again to re-associate the same IP addresses with the proper machine, and any service proceeds as if the server had not slept. This may appear confusing to network administrators who are not expecting the behaviour of changing MAC addresses.


Wake-on-LAN and magic packets

The method by which a sleep proxy server wakes a sleeping host is ''
wake-on-LAN Wake-on-LAN (WoL) is an Ethernet or Token Ring computer networking standard that allows a computer to be turned on or awakened from sleep mode by a network message. The message is usually sent to the target computer by a program executed on a d ...
''. The network interface of a sleeping host with this capability will wake the machine when it receives a specific series of bits, and a packet containing this pattern is a '' magic packet''. Early implementations of
Wake on LAN Wake-on-LAN (WoL) is an Ethernet or Token Ring computer networking standard that allows a computer to be turned on or awakened from sleep mode by a network message. The message is usually sent to the target computer by a program executed on a d ...
(WoL) required wired network interfaces. In the wireless case ( Wi‑Fi), the wake-up packet is sent via
Wireless Multimedia Extensions Wireless Multimedia Extensions (WME), also known as Wi-Fi Multimedia (WMM), is a Wi-Fi Alliance interoperability certification, based on the IEEE 802.11e standard. It provides basic Quality of service (QoS) features to IEEE 802.11 networks. WMM p ...
(WMM). In either case the function must be supported by the network interface. Apple provides instructions for checking compatibility with this feature for Macintosh computers.


Supported services and examples

The sleep proxy service is able to advertise any Bonjour-supported services, while the host computer sleeps. Some examples of supported services are: *
File sharing File sharing is the practice of distributing or providing access to digital media, such as computer programs, multimedia (audio, images and video), documents or electronic books. Common methods of storage, transmission and dispersion include ...
: a host supporting the sleep proxy service, which offers file services, may go to sleep as needed. When someone needs to access shared files, the host will wake up automatically. * iTunes library sharing: the computer hosting the
iTunes iTunes is a media player, media library, and mobile device management (MDM) utility developed by Apple. It is used to purchase, play, download and organize digital multimedia on personal computers running the macOS and Windows operating s ...
library may go to sleep, and will automatically wake when someone wishes to browse the iTunes library from a different PC. * Printer sharing: a printer may be connected and shared from a computer supporting sleep proxy service. The computer can go to sleep when not in use, but will wake when needed to service a print job being sent from a different computer. *
SSH The Secure Shell Protocol (SSH Protocol) is a cryptographic network protocol for operating network services securely over an unsecured network. Its most notable applications are remote login and command-line execution. SSH was designed for Un ...
: a computer offering SSH access may go to sleep, and awaken via the sleep proxy service when an SSH login is initiated. *
Desktop sharing Desktop sharing is a common name for technologies and products that allow remote access and remote collaboration on a person's computer desktop through a graphical terminal emulator. The most common two scenarios for desktop sharing are: * Remote ...
: similar to above examples.


Implementations

''Implementations on a
local area network A local area network (LAN) is a computer network that interconnects computers within a limited area such as a residence, campus, or building, and has its network equipment and interconnects locally managed. LANs facilitate the distribution of da ...
can be seen with Bonjour Browser.'' * Apple
AirPort An airport is an aerodrome with extended facilities, mostly for commercial Aviation, air transport. They usually consist of a landing area, which comprises an aerially accessible open space including at least one operationally active surf ...
Express Express, The Expresss or EXPRESS may refer to: Arts, entertainment and media Film * ''Express: Aisle to Glory'', a 1998 comedy short film featuring Kal Penn * ''The Express: The Ernie Davis Story'', a 2008 film starring Dennis Quaid * The Expre ...
with firmware version 7.4.1 or 7.4.2 * Apple
AirPort An airport is an aerodrome with extended facilities, mostly for commercial Aviation, air transport. They usually consist of a landing area, which comprises an aerially accessible open space including at least one operationally active surf ...
Extreme with firmware version 7.4.1 or 7.4.2 * Apple
AirPort An airport is an aerodrome with extended facilities, mostly for commercial Aviation, air transport. They usually consist of a landing area, which comprises an aerially accessible open space including at least one operationally active surf ...
Time Capsule A time capsule is a historic treasure trove, cache of goods or information, usually intended as a deliberate method of communication with future people, and to help future archaeologists, anthropologists, or historians. The preservation of holy ...
*
Apple TV Apple TV is a digital media player and a microconsole developed and marketed by Apple. It is a small piece of networking hardware that sends received media data such as video and audio to a TV or external display. Its media services include ...
(all generations) *
HomePod The HomePod is a series of smart speakers developed by Apple Inc., Apple. Designed to work with the Apple Music subscription service, the HomePod incorporates beamforming and eight speakers and is sold in two colors: white and midnight. It is s ...
(2018) *
HomePod mini The HomePod Mini (stylized as HomePod mini) is a smart speaker developed by Apple. It utilizes Apple's Siri digital assistant. Roughly a 10 cm sphere, it was released on November 16, 2020 as a smaller and less expensive version of Apple's Home ...
(2020) * Computers running
Mac OS X Snow Leopard Mac OS X Snow Leopard (version 10.6) (also referred to as OS X Snow Leopard) is the seventh major release of macOS, Apple's desktop and server operating system for Macintosh computers. Snow Leopard was publicly unveiled on June 8, 2009, at A ...
act as Bonjour sleep proxy servers when Internet sharing is enabled.Apple Inc.
Worldwide Developers Conference The Worldwide Developers Conference (WWDC) is an information technology conference held annually by Apple Inc. The conference is currently held at Apple Park in California. The event is used to showcase new software and technologies in the macO ...
(WWDC) 2009, Session 508, ''Zero Configuration Networking Using Bonjour''


References


External links

* , see ''Mosaics'' tab for figures * , see ''Mosaics'' tab for figures * {{Cite patent, country=US, number=7447757, see ''Mosaics'' tab for figures
Fscklog.com: Snow Leopard und 2009er Macs: Wake on WLAN (German, Deutsch)

Macrumors.com: A Closer Look at Snow Leopard's Wake on Demand Feature

opensource.apple.com: Open-source mDNS implementation including the sleep proxy service

UC San Diego: SleepServer: A Software-Only Approach for Reducing the Energy Consumption of PCs within Enterprise Environments
22 June 2010.
Usenix USENIX is an American 501(c)(3) nonprofit membership organization based in Berkeley, California and founded in 1975 that supports advanced computing systems, operating system (OS), and computer networking research. It organizes several confe ...
2010.
Microsoft Research: Sleepless In Seattle No Longer
22 June 2010.
Usenix USENIX is an American 501(c)(3) nonprofit membership organization based in Berkeley, California and founded in 1975 that supports advanced computing systems, operating system (OS), and computer networking research. It organizes several confe ...
2010. * Stuart Cheshire has a page describing steps fo
troubleshooting Sleep Proxy Service
Apple Inc. software Computer configuration Domain Name System Link protocols Network protocols Windows communication and services