|
ru.linux- RU.LINUX --------------------------------------------------------------------- From : yx 2:5020/400 07 Aug 2001 03:34:17 To : Oleg Deribas Subject : Re: Multilink PPP -------------------------------------------------------------------------------- Oleg Deribas <Oleg.Deribas@f13.n461.z2.fidonet.org> wrote: > Ситуация такая - linux 2.4.x с обеих сторон, но на одной из машин - два > малтилинка, глядящих в разные стороны. Как указать каждому модему имя бандла к > которому он должен присоединяться? > Т.е. я посмотрел в исходниках pppd - там есть недокументированная > опция bundle, > но что-то результатов она не дает. Что я туда не прописывал - pppd все равно > говорит created bundle ppp0. Может есть какие-то правила по которым пишется > имя bundle? > % man pppd ..skip bundle name Set the bundle name for multilink to name. This value is concatenated to the Endpoint Discriminator for purposes of distinguishing links that belong to separate bundles. This option can be used to insert external identification information (such as Caller*ID, Calling Party Identification, or ANI) into the bundling process. This option is avail- able only on platforms with Multilink PPP support (HAVE_MULTILINK). endpoint endpoint-value Set the Endpoint Discriminator, which is normally used for RFC 1990 Multilink PPP operation. The endpoint-value consists of a class identifier and a class-dependent value. The class identifier is one of "null", "local", "IP", "MAC", "magic", "phone", or a decimal integer. If present, the class-depen- dent value is separated from the identifier by a colon (':') or period ('.'). This value may be a standard dotted-decimal IP address for class "IP", an optionally colon or dot separated hex Ethernet address for class "MAC" (must have 6 numbers), or an arbitrary string of bytes specified in hex with optional colon or dot separators between bytes. This option is available on all platforms for interoperability reasons. ..skip MULTILINK ..skip tiple bundles between the local system and the peer. Pppd uses a TDB database in /var/run/pppd.tdb to match up links. для просмотра pppd.tdb было: % pwd ~/ppp-2.4.x/pppd/ % cat >tdbdump.c #include <stdlib.h> #include <stdio.h> #include <fcntl.h> #include <unistd.h> #include <string.h> #include <fcntl.h> #include <sys/mman.h> #include <sys/stat.h> #include <sys/time.h> #include "tdb.h" static int print_rec(TDB_CONTEXT *tdb, TDB_DATA key, TDB_DATA dbuf, void *p) { printf("key \"%*.*s\"\t:\tvalue \"%*.*s\"\n", (int)key.dsize, (int)key.dsize, key.dptr, (int)dbuf.dsize, (int)dbuf.size, dbuf.dptr); return 0; } main(int ac, char **av) { TDB_CONTEXT *tdb; if (ac!=2) { fprintf(stderr,"Usage: %s database\n",av[0]); exit(1); } if ((tdb=tdb_open(av[1],0,0,O_RDONLY,0600))==0) { perror(av[1]); exit(1); } tdb_traverse(tdb,print_rec,NULL); exit(0); } ^D % cc -o tdbdump tdbdump.c tdb.c % ./tdbdump /var/run/pppd.tdb ..skip bye. -- Vladimir Yakovetsky rcvd [LCP ConfReq id=0x1 <asyncmap 0x0> <auth pap> <magic 0xe5f4b3d1> <pcomp> <accomp> <mrru 1500> <endpoint [phone:02.16.27.01]>] --- ifmail v.2.15dev5 * Origin: <Customer of IP Telecom Ltd.> (2:5020/400) Вернуться к списку тем, сортированных по: возрастание даты уменьшение даты тема автор
Архивное /ru.linux/2018895beeff5.html, оценка из 5, голосов 10
|