Please help me to answer the questions in attached
files.

Note: forwarded message attached.


=====
Max Zhang
Electrical Engineer
Greater China Personal Communications Sector R&D Center
Beijing Breach
Direct Line 86-10-65642336
__________________________________________________
Do You Yahoo!?
Talk to your friends online with Yahoo! Messenger.
http://im.yahoo.com


Dear All

This letter devide in to 4 parts
        I. What I want to do and problem I meeted
       II. The questions I want to ask
      III. The setup information of my machine


I. What I want to do and problem I meet

I have a linux box which can access the intelnet
through ether card. Now I want to make it as a PPP
server to offer a path for another Win 95 machine to
access the intelnet. The structure is like the chart
below.
 
 192.1.2.33                        192.1.2.17
+-----------+      PPP link       +----------+
|    Win 95 | ------------------- |  Linux   |
+-----------+                     +----------+
                                        |          
Ethernet 192.1.2.X

-----------------------+---------------+-----------------
 
                        |
                  +-----------+
                  | other PC  |
                  +-----------+
                   192.1.2.20

I follow the instructions in the file included in Red
Hat distribution 5.2
"/usr/doc/ppp-2.3.5/README.linux". The instructions
are in the charpter "setting up a machine for incoming
PPP connections". I attached the this chapter in my
file. 

The problem Now I have is:
I can access the Linux(192.1.2.17) but can not go any
further ( for example: 192.1.2.20) on my win 95
machine. When I ping, telnet or ftp to linux. But when
I ping 192.1.2.20, there is no response. 


II. The questions I want to ask

1. How can I see whether the Linux forward the package
from PPP0 to eth0 when I ping "other PC" on "win 95"?
2. How can I see whether the linux forward the package
from eth0 to PPP0 when I ping "win 95" from "other
PC"?
3. Do I need some other setting to make eth0 to
recieve packege to both "linux" and "win 95"?
4. Do I give out all the informations you need to see
where I go wrong?


III. The setup of my machine is :

kernel 2.2.8
pppd 2.3.5
ipchains 1.3.8

I haven't change default setting of ipchains. 
My ipfwadm command is dispeared when I upgrade the
kernel from 2.0.36.to 2.2.8.

/proc/sys/net/ipv4/ip_forward 1
result of command " ipchain -L"
Chain input (policy ACCEPT):
Chain forward (policy ACCEPT):
Chain output (policy ACCEPT):
 
the important items of the kernel .config are listed
below: 

   CONFIG_NET=y
   #
   # Networking options
   #
   CONFIG_PACKET=y
   CONFIG_NETLINK=y
   CONFIG_RTNETLINK=y
   CONFIG_NETLINK_DEV=y
   CONFIG_FIREWALL=y
   CONFIG_FILTER=y
   CONFIG_UNIX=y
   CONFIG_INET=y
   # CONFIG_IP_MULTICAST is not set
   # CONFIG_IP_ADVANCED_ROUTER is not set
   # CONFIG_IP_PNP is not set
   CONFIG_IP_FIREWALL=y
   # CONFIG_IP_FIREWALL_NETLINK is not set
   CONFIG_IP_ALWAYS_DEFRAG=y
   CONFIG_IP_TRANSPARENT_PROXY=y
   CONFIG_IP_MASQUERADE=y
   #
   # Protocol-specific masquerading support will be
built as modules.
   #
   CONFIG_IP_MASQUERADE_ICMP=y
   #
   # Protocol-specific masquerading support will be
built as modules.
   #
   # CONFIG_IP_ROUTER is not set
   # CONFIG_NET_IPIP is not set
   # CONFIG_NET_IPGRE is not set
   # CONFIG_IP_ALIAS is not set
   # CONFIG_SYN_COOKIES is not set
   #
   # (it is safe to leave these untouched)
   #
   # CONFIG_INET_RARP is not set
   CONFIG_SKB_LARGE=y

Best Regards
Max Zhang


__________________________________________________
Do You Yahoo!?
Talk to your friends online with Yahoo! Messenger.
http://im.yahoo.com

SETTING UP A MACHINE FOR INCOMING PPP CONNECTIONS

Suppose you want to permit another machine to call yours up and start
a PPP session.  This is possible using Linux PPP.

One way is to create an account named, say, 'ppp', with the login
shell being a short script that starts pppd.  For example, the passwd
entry might look like this:

  ppp:(encrypted password):102:50:PPP client login:/home/ppp:/usr/sbin/pppd

In addition, you would edit the file ~ppp/.ppprc to have the following
pieces of information:

-detach
modem
crtscts
lock
:192.1.2.33

Here we will insist that the remote machine use IP address 192.1.2.33,
while the local PPP interface will use the IP address associated with
this machine's hostname in /etc/hosts.  The '-detach' option is required
for a server. It tells the pppd process not to terminate until the modem
is disconnected. Should it fork, the init process would restart the getty
process and the this would cause a severe conflict over the port.

The 'modem' option indicates that the connection is via a switched circuit
(using a modem) and that the pppd process should monitor the DCD signal
from the modem.

The 'crtscts' option tells the pppd process to use hardware RTS/CTS flow
control for the modem.

The 'lock' option tells pppd to lock the tty device. This will use the UUCP
style locking file in the lock directory.

This setup is sufficient if you just want to connect two machines so
that they can talk to one another.  If you want to use Linux PPP to
connect a single machine to an entire network, or to connect two
networks together, then you need to arrange for packets to be routed
from the networks to the PPP link.  Setting up a link between networks
is beyond the scope of this document; you should examine the routing
options in the manual page for pppd carefully and find out about
routed, etc.

Let's consider just the first case.  Suppose you have a Linux machine
attached to an Ethernet, and you want to allow its PPP peer to be able
to communicate with hosts on that Ethernet.  To do this, you should
have the remote machine use an IP address that would normally appear
to be on the local Ethernet segment and you should give the 'proxyarp'
option to pppd on the server.  Suppose, for example, we have this
setup:

 192.1.2.33                        192.1.2.17
+-----------+      PPP link       +----------+
| chelseapc | ------------------- |  billpc  |
+-----------+                     +----------+
                                        |           Ethernet 
                            ----------------------------------- 192.1.2.x 

Here the PPP and Ethernet interfaces of billpc will have IP address
192.1.2.17.  (It's OK for one or more PPP interfaces on a machine to
share an IP address with an Ethernet interface.)  There is an
appropriate entry in /etc/passwd on billpc to allow chelseapc to call
in. It will run pppd when the user signs on to the system and pppd will
take the options from the user option file.

In addition, you would edit the file ~ppp/.ppprc to have the following
piece of information:

-detach
modem
crtscts
lock
192.1.2.17:192.1.2.33
proxyarp

When the link comes up, pppd will enter a "proxy arp" entry for
chelseapc into the arp table on billpc.  What this means effectively
is that billpc will pretend to the other machines on the 192.1.2.x
Ethernet that its Ethernet interface is ALSO the interface for
chelseapc (192.1.2.33) as well as billpc (192.1.2.17).  In practice
this means that chelseapc can communicate just as if it was directly
connected to the Ethernet.



Reply via email to