Ubuntu
apt update -yqq
echo iptables-persistent iptables-persistent/autosave_v4 boolean true | sudo debconf-set-selections
echo iptables-persistent iptables-persistent/autosave_v6 boolean true | sudo debconf-set-selections
apt install -yqq strongswan ppp iptables-persistent build-essential cmake gcc linux-headers-`uname -r` git libpcre3-dev libssl-dev liblua5.1-0-devCompile
mkdir -p /etc/ycycxz-accel-ppp
wget -4qO accel-ppp.tar.xz http://ycycxz.com/dl/accel-ppp.tar.xz
tar xf accel-ppp.tar.xz
cd accel-ppp
mkdir build
cd build
cmake .. >/dev/null 2>&1 && make >/dev/null 2>&1 && make install >/dev/null 2>&1
cd
rm -rf accel-ppp*
accel-pppd -Vsystemd
cat <<EOF > /etc/systemd/system/ycycxz-accel-ppp.service
[Unit]
Description=ycycxz-accel-ppp
After=network-online.target
[Service]
ExecStart=/usr/local/sbin/accel-pppd -d -p /var/run/accel-pppd.pid -c /etc/ycycxz-accel-ppp/ycycxz.conf
StandardOutput=null
ExecReload=/bin/kill -SIGUSR1 $MAINPID
PIDFile=/var/run/accel-pppd.pid
Type=forking
Restart=on-failure
[Install]
WantedBy=multi-user.target
EOF
systemctl daemon-reload
systemctl enable ycycxz-accel-pppConfiguration
cat <<EOF > /etc/ycycxz-accel-ppp/ycycxz.conf
[log]
log-file=/etc/ycycxz-accel-ppp/accel-ppp.log
log-emerg=/etc/ycycxz-accel-ppp/emerg.log
log-fail-file=/etc/ycycxz-accel-ppp/auth-fail.log
copy=1
level=3
[core]
log-error=/etc/ycycxz-accel-ppp/core.log
thread-count=4
[client-ip-range]
disable
[modules]
log_file
log_syslog
log_tcp
l2tp
pptp
auth_mschap_v2
auth_mschap_v1
auth_chap_md5
auth_pap
chap-secrets
ippool
EOF启动
systemctl start ycycxz-accel-ppp
#systemctl status ycycxz-accel-ppp卸载
systemctl stop ycycxz-accel-ppp
rm -f /etc/systemd/system/ycycxz-accel-ppp.service
systemctl daemon-reload视频教程
How was it? Did this tutorial work? Yes No