January 2018

In XX month XX, I started raspberry pie 3b, a treasure 300, the list is as follows:

  • Board 199
  • Power 35 (actually I have 5v2a charger and rechargeable treasure).
  • Hot chicken wireless keyboard 30
  • Acrylic shell 15
  • Fan and fan hot piece about 10 pieces.

Strangely enough, E14, a homemade board I bought, sent RS in England.

Of course, there must be a memory card, I have a 8g, but I still went to the dog east to buy three mulberry 64G Evo, 130 OK, do not care about the appearance of the fan keyboard can not, and then buy a 16G card, 300 within the affirmation can be done.

Let's keep on track

At ordinary times, I have to go to work. When I left home, I bought a bunch of spicy chicken with my family at 300 and put it at home.

As a user who once used ngrok, ngrok is really spicy chicken.

Installation configuration is quite troublesome, after configuration is completed, there are various problems, connection failure, drop line, XXX problem.

Fight to use other people's ngrok free service (here is not advertising), there are also dropped issues, user experience is not good, give up!

But after starting school, I chose to see ngrok. The problem of the server is fine, but there are still many problems to be solved. FRP Up


Domestic conscience software (I just want to blow it), simple configuration, easy to use, easy to deploy, and low resource consumption (I have no money to collect).

The key is to have Chinese document !!! Chinese language!!! Chinese!!! Middle!!!

0x0

Here I use the virtual machine, I am now in the company, sent to the home, if I restart FRP, I will drop the line, then there will be no later operation.

Virtual machine configuration (here is equivalent to raspberry pie).

  • CentOS Linux release 7.4.1708 (Core)
  • Kernel version 3.10.0-693.11.6.el7.x86_64
  • Architecture x86_64
  • Memory 512M
  • CPU2 core

Server configuration
Goose factory Hongkong 1 Yuan machine

  • CentOS Linux release 7.4.1708 (Core)
  • Kernel version 3.10.0-514.21.1.el7.x86_64
  • Architecture x86_64
  • Memory 1G
  • CPU1 core
  • Bandwidth 1M

In their Release Page select the version you want to use.

Here I use it. Frp_0.15.1_linux_amd64.tar.gz This bag, if you want to use the raspberry sent 3B version, the official arm package is used to be problematic, my pie is archlinux system. The compiled client package is frpc-0.15.1-raspberrypi.zip here. If you want to install archlinuxarm, you can read my article.

The preparations are over.

Of course, all of these operations are done when you can use existing binary files.

0x1

Note: the next operation is operated by root users. Other users should judge the sudo command by themselves.

 WGet --no-check-certificate https://github.com/fatedier/frp/releases/download/v0.15.1/frp_0.15.1_linux_amd64.tar.gz

tar -xvf frp_0.15.1_linux_amd64.tar.gz

cd frp_0.15.1_linux_amd64

ls -al / / like ll command

The files after decompression should be the following sauce.

 FRP unzip file list

Client

Delete the following files

 RM FRPs frps_full.ini frps.ini LICENSE

Client retained files
 Client retained files

Server side

Delete the following files

 RM FRPC frpc_full.ini frpc.ini LICENSE

File retained by server
 File retained by server

      • -

Reminder

FRP X _full.ini The configuration is all permitted by the government. FRP X .ini Based configuration ( Suggested use Or you don't know where you are wrong.

Here X represents the C of the client and the s of the server.

0x2

Here I use Basic configuration file

Server side Need to open Seven thousand Monitoring FRP services, Six thousand Monitor and forward client SSH services

The server open port is executed as follows

Pong friends using iptables

 Iptables -A INPUT -p TCP --dport 7000 -j ACCEPT
iptables -A INPUT -p INPUT 6000

Pong friends using firewalld

 Firewall-cmd --zone=public --add-port=7000/tcp --permanent
firewall-cmd --zone=public --add-port=6000/tcp --permanent
firewall-cmd --reload

0x3

The foundation is ready to start running FRP.

Server side

We perform the following operation and start running the FRPs server.

 ./frps -c./frps.ini

The running state is as follows: (1) what security problems are there?
 Open FRPs server

Client

We need to configure the server IP address to penetrate into the external network, so we need to use it. Nano , VI , VIM The editor modifies the configuration file. Server_addr

 [common]
server_addr = your server ip
server_port = 7000

The modification can be saved and the following operation is performed.

 ./frpc -c./frpc.ini

Look! ID has been allocated, SSH has successfully surrogate.
 Successful connection

At this point, if you look back at the console of the server, you will also have successful news.

0x4

You can now test whether SSH can successfully connect to the virtual machine.

It can be seen very clearly that there are two online users. Pts/0 The user is executing the commands before us.
 Beautiful

FRP has been successfully run here.

But...

We can't keep the terminal open. Here I share my startup stop script.

The script is not applicable. Write it yourself.

0x?

It's been a long time since the last time this tutorial was published. It's also said that it is necessary to send SSH's password free landing. The login of public keys on several servers is different.

Good night Love you!

This page loaded in 0.000878 seconds