Categories
程序员 网络撷翠

TCP/UDP/Unicast/Multicast

Multicasting
I simplified the TCP/IP/UDP discussion up there a little when I implied that IP (and hence UDP and TCP) would route packets from one device on a network to another device. More accurately, IP routes packets from one IP address to another IP address. The trick with multicasting, or sending the same packets of data at the same time to many devices is that certain IP addresses can be designated as multicast address and assigned to many devices at the same time.

The first thing to know about IP multicasting is that there only exists UDP multicasting. There’s no such thing as TCP multicast. Why not? See, the point of multicast is to be efficient with the network and send the same data packet to as many different, possibly unknown computers. But each TCP connection can potentially require retransmission of different lost packets, or different delays or ordered arrival and assembly of packets. So managing and sending all that for each possible device would be resource-intensive even if it were possible, which would defeat much of the point of using multicast. (And it’s not possible anyway because multicast can’t know where the outbound packets actually wind up.)

Oh, and via back-formation, regular non-multicast UDP (and TCP) messages are called unicast.

The next thing to know is that multicast will often not be sent over a router to another network. There are a few reasons why:

 

    • A low TTL for most multicast packets: All IP packets have a time-to-live, or TTL. Unlike with DNS records, TTL on IP packets refers to the maximum number of network hops that a packet can make to get to its destination. Unicast packets typically are allowed to cross about 30 networks (i.e., get routed by, or “hop”, 29 routers). Getting across the internet rarely takes more than 15 hops, so the limit is really just to kill packets if they get stuck in loops in badly configured networks. But most applications that send multicast set the TTL to a low number, often zero (where the message doesn’t even leave the originating device),

 

    • one (so it will go only to computers on the local net), or two (where it will cross a single router). It’s quite rare to have an application that is intended to multicast to unknown machines over an entire campus network, much less the entire Internet.

 

    • High TTL thresholds set on most routers: Many network routers, particularly WAN routers and internet gateway routers, have a higher TTL threshold set, such that they won’t send out multicast packets whose TTL is below (say) 15. This is intended to prevent accidental leakage of multicast off a local network.

 

    • Routers are simply not configured to route multicast at all, or only configured for specific addresses, or otherwise blocking multicast packets.

UDP multicast might seem a bit exotic, but it’s actually more common that you think. It’s not used for web video sites like YouTube, since those need to send a video at a time each user demands, rather than at the same time for all users, and it’s not used for VoIP traffic. However, it is used for a lot for discovery and automatic confguration in apps like Skype, iTunes, and uPnP. It’s also used in a few places in the WCI portal.

From https://blogs.oracle.com/lmukadam/entry/tcp_udp_unicast_multicast_i_th

Categories
生活 网络撷翠 色驴

Next adventure: Kayak/Canoe?

This one looks good for family use (2 adult + 1 child):

Eco Tandem Kayak - Green

 

Or are we better off going with something like  (1 adult + 1 child) so we will have two?

 

Complete Kayak/Canoe 101: http://www.rei.com/expertadvice/articles/kayak.html

Categories
生活 网络撷翠

转贴:火锅底料制法

From http://www.cchere.com/article/1822730.

Categories
网络撷翠

Wuthering Heights

I am not ashamed to admit The Voice Australia brought this song to my attention.

And this is the most beautifully creept music video I’ve ever seen, by Kate Bush.

Categories
生活 网络撷翠

List of Camping sites

Camp at Bear Gully

Categories
网络撷翠

Randomizer/Straw Drawer

List Randomizer: http://www.random.org/

Straw Drawer: http://www.dsrw.org/~dlg/web/straws.php

 

Categories
程序员 网络撷翠

Discuz X2.0:如何限制游客访问主题和回复帖内容?

适用版本: discuz X2
修改 \template\default\forum\viewthread_node_body.htm

Categories
DIY 网络撷翠

Staining Radiata Pine – the secret to success

Most of the info below came from various places over the Internet:

http://www.woodworkforums.com/f9/staining-radiata-pine-whats-secret-success-659/

Categories
网络撷翠

【转贴】谜语的猜法及常用谜格

[来源:汤滨青年网]

一、谜语的源流

Categories
网络撷翠

【转帖】走向质变的中美关系

源自http://bbs.wforum.com/wmf/bbsviewer.php?trd_id=84497

《环球财经》副社长 彭晓光——- 走向质变的中美关系