2016年4月25日 星期一
2016年4月20日 星期三
Tiny Core Linux 使用 ipxe 設定摘要
Tiny Core Linux
download tinycore.iso
mount -o loop tinycore.iso /mnt
cp /mnt/vmlinuz core.gz /var/www/html
ipxe 設定
dhcp
kernel http://192.168.10.1/_tinycore/vmlinuz quiet cde
initrd http://192.168.10.1/_tinycore/core.gz
boot
或
dhcp
kernel http://192.168.10.1/_tinycore4/vmlinuz
initrd http://192.168.10.1/_tinycore4/core.gz
imgargs vmlinuz quiet cde
boot
download tinycore.iso
mount -o loop tinycore.iso /mnt
cp /mnt/vmlinuz core.gz /var/www/html
ipxe 設定
dhcp
kernel http://192.168.10.1/_tinycore/vmlinuz quiet cde
initrd http://192.168.10.1/_tinycore/core.gz
boot
或
dhcp
kernel http://192.168.10.1/_tinycore4/vmlinuz
initrd http://192.168.10.1/_tinycore4/core.gz
imgargs vmlinuz quiet cde
boot
2016年4月19日 星期二
pxelinux 預設載入 ipxe
pxelinux.cfg/default 內容
DEFAULT ipxe.krn dhcp && chain http://192.168.10.1/a.php?mac=${netX/mac}&ip=${netX/ip}&uuid=${uuid}
DEFAULT ipxe
LABEL ipxe
KERNEL ipxe.krn dhcp && chain http://192.168.10.1/a.php?mac=${netX/mac}&ip=${netX/ip}&uuid=${uuid}
DEFAULT ipxe.krn dhcp && chain http://192.168.10.1/a.php?mac=${netX/mac}&ip=${netX/ip}&uuid=${uuid}
DEFAULT ipxe
LABEL ipxe
KERNEL ipxe.krn dhcp && chain http://192.168.10.1/a.php?mac=${netX/mac}&ip=${netX/ip}&uuid=${uuid}
2016年3月10日 星期四
LEAF安裝PPTP Server
載入相關 module
ppp_generic
ppp_mppe
pppoe
pppox
pptp
gre
安裝設定 accelppp
apkg -i accelppp
pppscrpt
libpcre
libcrpto
libssl
編輯 /etc/accel-ppp.conf 內容如下
[modules]
log_syslog
pptp
l2tp
pppoe
auth_mschap_v2
auth_mschap_v1
auth_chap_md5
auth_pap
ippool
chap-secrets
[core]
log-error=/var/log/accel-ppp/core.log
thread-count=4
[ppp]
verbose=1
min-mtu=1280
mtu=1400
mru=1400
ipv4=require
ipv6=deny
[lcp]
echo-interval=30
echo-failure=3
[pptp]
verbose=1
[pppoe]
interface=eth0
verbose=1
[l2tp]
verbose=1
[dns]
#dns1=172.16.0.1
dns2=8.8.8.8
[client-ip-range]
192.168.9.0/24
#disable
[ip-pool]
gw-ip-address=192.168.2.1
192.168.2.2-255
[log]
log-emerg=/var/log/accel-ppp/emerg.log
#syslog=accel-pppd,daemon
copy=1
level=3
[chap-secrets]
gw-ip-address=192.168.0.1
chap-secrets=/etc/ppp/chap-secrets
[cli]
telnet=127.0.0.1:2000
tcp=127.0.0.1:2001
#password=123
編輯帳號密碼檔 /etc/ppp/chap-secrets
user * user *
usera * user *
帳號密碼設定檔 共四欄
# 第一欄為連線帳號,
# 第二欄要設定成/etc/accel-ppp.conf 中的name
# 第三欄為密碼
# 第四欄為連線IP
設定 shorewall
編輯 /etc/shorewall/rules加入
ACCEPT net fw tcp 1723
ACCEPT net fw udp 1701
Ping(ACCEPT) vpn fw
編輯 /etc/shorewall/zones 加入
vpn ipv4
編輯 /etc/shorewall/interfaces 加入
vpn ppp+
編輯 /etc/shorewall/policy 加入
vpn loc ACCEPT
/etc/shorewall/masq
eth0 192.168.2.0/24
reboot
相關資源
https://accel-ppp.org/wiki/doku.php?id=configsoho
http://shorewall.net/PPTP.htm
ppp_generic
ppp_mppe
pppoe
pppox
pptp
gre
安裝設定 accelppp
apkg -i accelppp
pppscrpt
libpcre
libcrpto
libssl
編輯 /etc/accel-ppp.conf 內容如下
[modules]
log_syslog
pptp
l2tp
pppoe
auth_mschap_v2
auth_mschap_v1
auth_chap_md5
auth_pap
ippool
chap-secrets
[core]
log-error=/var/log/accel-ppp/core.log
thread-count=4
[ppp]
verbose=1
min-mtu=1280
mtu=1400
mru=1400
ipv4=require
ipv6=deny
[lcp]
echo-interval=30
echo-failure=3
[pptp]
verbose=1
[pppoe]
interface=eth0
verbose=1
[l2tp]
verbose=1
[dns]
#dns1=172.16.0.1
dns2=8.8.8.8
[client-ip-range]
192.168.9.0/24
#disable
[ip-pool]
gw-ip-address=192.168.2.1
192.168.2.2-255
[log]
log-emerg=/var/log/accel-ppp/emerg.log
#syslog=accel-pppd,daemon
copy=1
level=3
[chap-secrets]
gw-ip-address=192.168.0.1
chap-secrets=/etc/ppp/chap-secrets
[cli]
telnet=127.0.0.1:2000
tcp=127.0.0.1:2001
#password=123
編輯帳號密碼檔 /etc/ppp/chap-secrets
user * user *
usera * user *
帳號密碼設定檔 共四欄
# 第一欄為連線帳號,
# 第二欄要設定成/etc/accel-ppp.conf 中的name
# 第三欄為密碼
# 第四欄為連線IP
設定 shorewall
編輯 /etc/shorewall/rules加入
ACCEPT net fw tcp 1723
ACCEPT net fw udp 1701
Ping(ACCEPT) vpn fw
編輯 /etc/shorewall/zones 加入
vpn ipv4
編輯 /etc/shorewall/interfaces 加入
vpn ppp+
編輯 /etc/shorewall/policy 加入
vpn loc ACCEPT
/etc/shorewall/masq
eth0 192.168.2.0/24
reboot
相關資源
https://accel-ppp.org/wiki/doku.php?id=configsoho
http://shorewall.net/PPTP.htm
訂閱:
文章 (Atom)