hoge_tunif='gif0'Here, the prefix like `hoge' and `fuga' is the labels which is specified by -e option of dtcpclient. That is, dtcpclient with `-e hoge' option use gif0 which is specified by `hoge_tunif', and dtcpclient with `-e fuga' option use gif1 which is specified by `fuga_tunif'.
fuga_tunif='gif1'
You can specify multiple lines in dtcpclient.auth. Each line is constructed by server name, user name and password.
There is one more issue to run multiple dtcpclient. The pidfile in which prosess-id is recorded conflicts with each other. You can avoid this problem by specifying -f option to dtcpclient.
For example, when you want to connect to tcp.hoge.example.org and dtcp.fuga.example.org, your settings will be like as follows:
- /usr/local/etc/dtcpclient.auth:
- dtcp.hoge.example.org:user:password
dtcp.fuga.example.org:user:password- /usr/local/etc/dtcpclient_script.conf:
- hoge_tunif='gif0'
hoge_static_routes='default,3ffe:505::/32'
fuga_tunif='gif1'
fuga_static_routes='2001:200:300::/40'
- the command line of dtcpclient:
- dtcpclient -Dl -t network -u user -e hoge -f /var/run/dtcpclient_hoge.pid dtcp.hoge.example.org
dtcpclient -Dl -t network -u user -e fuga -f /var/run/dtcpclient_fuga.pid dtcp.fuga.example.org