赵小福

赵小福

PCDN stands for Peace and Collaborative Development Network.

PCDN (P2P CDN) Peer-to-Peer Content Delivery Network, you can probably guess what it does from the name. Conventional CDN services are mainly provided by large companies, using CDN servers distributed nationwide to provide access to static resources. Alibaba Cloud provides PCDN services, if you're interested, you can take a look at Alibaba Cloud PCDN.

Imagine this scenario: Your neighbor is watching Tencent Video at home. Typically, this video is stored on Tencent's servers. If many people are watching this video at the same time, Tencent's servers will be under a lot of pressure (mainly disk read pressure and bandwidth pressure).

And if this server is far away from your home, besides the server pressure, isn't bandwidth transmission also a waste? At this time, if your computer at home acts as a CDN node and caches this video in advance, when someone nearby accesses this resource, it will be accessed from your computer first, thus saving the resources of the manufacturer's server.

But why do we do this, surely it's because someone pays us, I'm willing to be a CDN node only if someone pays me. I use Wangxin Cloud (just for fun, playing around), let me explain how to deploy it:

Prerequisites#

First, you need to have a server (which is a computer, an idle cloud server will also work) and basic knowledge of Docker.

Personal opinion: This is just for fun, don't expect to make much money from it. Using your own computer as a CDN node requires it to be powered on 24/7, which consumes electricity, hard disk space, and network resources.

Disclaimer#

This article is not a tutorial on how to make money. The original intention of writing this article is to share interesting tools, software, ideas, etc. Welcome like-minded friends who love to explore and tinker together.

Installing Docker#

curl -fsSL https://get.docker.com -o get-docker.sh
sudo sh get-docker.sh

Pulling Docker images and starting#

docker run -d --name=wxedge \
  --restart=always --privileged --net=host \
  --tmpfs /run --tmpfs /tmp \
  -v /data/wxedge_storage:/storage:rw  \
  onething1/wxedge

Note: /data/wxedge_storage needs to be changed to your own local path (but it's also fine if you don't change it)

Multiple instances#

docker run -d -e LISTEN_ADDR=":28888" --name=wxedge2 \
  --restart=always --privileged --net=host \
  --tmpfs /run --tmpfs /tmp \
  -v /home/zyhahaha/wxy:/storage:rw  \
  onething1/wxedge
Register for Wangxin Cloud: This is a referral link, both the inviter and the invitee can receive coupons
https://act.walk-live.com/acts/invite?inviteid=51845cd2

Install Wangxin Cloud:
You can download it from the app store or register and download it through the above link.

Official website:
https://www.onethingcloud.com/

Final step#

After installing the app, access it through the browser

http://your_server_IP:18888

The following interface will appear, then use the app to scan the QR code on the browser to add the device.

Open the browser IP:18888

Scan with the app

Device list

Special reminder#

Do not buy any of the products recommended on the app, including various hardware devices, just like the previous "Wanke Cloud". If you want to play, play with the X86 Docker version (officially called "Container Magic Cube"), which is the deployment method introduced in this article. You don't need to buy any devices, just use an idle server to run it.

Docker Hub#

https://hub.docker.com/r/onething1/wxedge

Ruanyifeng's Docker tutorial#

https://ruanyifeng.com/blog/2018/02/docker-tutorial.html

Loading...
Ownership of this post data is guaranteed by blockchain and smart contracts to the creator alone.