2232588429
V2EX  ›  问与答

在 debian 里配置 PPTP,里面的 pptpd.conf 如果配置错了该怎么重装呢?

  •  
  •   2232588429 · Aug 10, 2014 · 5333 views
    This topic created in 4501 days ago, the information mentioned may be changed or developed.
    在debian里配置PPTP,如果没有备份,里面的pptpd.conf配置错了该怎么重装呢?有没有快捷的办法?能不能直接卸载掉pptpd再装?
    9 replies  •  2014-08-10 10:41:12 +08:00
    xzl380
    xzl380
    Aug 10, 2014
    1
    aptitude purge
    2232588429
    2232588429
    OP
    Aug 10, 2014
    2
    @fangpeishi 谢谢,这个命令后面加包的名字就行吧?
    jasontse
    jasontse
    Aug 10, 2014 via iPad
    3
    apt-get remove --purge pptpd
    2232588429
    2232588429
    OP
    Aug 10, 2014
    4
    @jasontse 请问怎么使用了aptitude purge这个命令后发现sysctl.conf和chap-secrets配置文件还是以前的?
    jasontse
    jasontse
    Aug 10, 2014 via iPad❤️2
    5
    @2232588429
    sysctl.conf 是系统文件不属于 pptpd 软件包,chap-secrets 则是 pppd 软件包中的文件,pppd 是 pptpd 的依赖。如果要彻底卸载 pptpd 的一切依赖使用命令
    apt-get autoremove --purge pptpd
    Jarvanh
    Jarvanh
    Aug 10, 2014
    6
    @jasontse 谢谢。搞定

    root@default:~# apt-get autoremove --purge pptpd
    Reading package lists... Done
    Building dependency tree
    Reading state information... Done
    The following packages will be REMOVED:
    bcrelay* ppp* pptpd*
    0 upgraded, 0 newly installed, 3 to remove and 15 not upgraded.
    After this operation, 1503 kB disk space will be freed.
    Do you want to continue [Y/n]? y
    (Reading database ... 33197 files and directories currently installed.)
    Removing pptpd ...
    Stopping PPTP: pptpd.
    Purging configuration files for pptpd ...
    insserv: warning: script 'K01amh-start' missing LSB tags and overrides
    insserv: warning: script 'amh-start' missing LSB tags and overrides
    Removing bcrelay ...
    Removing ppp ...
    Stopping all PPP connections...done.
    Purging configuration files for ppp ...
    insserv: warning: script 'K01amh-start' missing LSB tags and overrides
    insserv: warning: script 'amh-start' missing LSB tags and overrides
    Processing triggers for man-db ...


    root@default:~# apt-get autoremove --purge pptpd
    Reading package lists... Done
    Building dependency tree
    Reading state information... Done
    Package pptpd is not installed, so not removed
    0 upgraded, 0 newly installed, 0 to remove and 15 not upgraded.
    2232588429
    2232588429
    OP
    Aug 10, 2014
    7
    @jasontse 谢谢,另外想请教,添加转发规则这一步是需要新建一个空白文件写入规则还是直接在命令行输入iptables -t nat -A POSTROUTING -s 192.168.0.0/24 -j SNAT --to-source **.**.**.**呢?
    jasontse
    jasontse
    Aug 10, 2014 via iPad
    8
    @2232588429 直接执行
    2232588429
    2232588429
    OP
    Aug 10, 2014
    9
    @jasontse 汗,刚发现那个教程好像是centos环境的,我是debian系统应该不是这么弄吧?是不是最适合用一键安装包?
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Privacy   ·   Solana   ·   1948 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 23ms · UTC 02:28 · PVG 10:28 · LAX 18:28 · JFK 21:28
    ♥ Do have faith in what you're doing.