The VPN server in Linux appears pty read or GRE write failed problem

Source: Internet
Author: User
Tags system log

When the REHL department builds a pptp vpn server connection (619 errors). Check the system log [cat / var / log / messages | grep pptpd] and find that the following log content will appear every time the connection fails:


GRE: read (fd = 6, buffer = 80504c0, len = 8196) from PTY failed: status = -1 error = Input / output error, usually caused by unexpected termination of pppd, check option syntax and pppd logs
CTRL: PTY read or GRE write failed (pty, gre) = (6,7)
CTRL: Reaping child PPP [13354]
CTRL: Client XXX.XXX.XXX.XXX control connection finished

So turn on the debug mode, modify the / etc / ppp / pptp-options file, find


#Cancel the following line before #
debug
#carried out
service pptpd restart

Cancel the comment before the line and restart the pptpd service to enter debug mode

After analyzing the logs, it was found that the logwtmp version was inconsistent with the pptpd version, so opened the /etc/pptpd.conf file and found

logwtmp

After commenting out logwtmp, restart pptpd and everything will return to normal after connecting again.
By default, the proxyarp (in / etc / ppp / pptp-options) function is enabled. After each abnormal disconnection, execute the following command:

#windows
arp -d
#linux
sudo arp -d -a


Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.