Re: running expect from cron
On Tue, 21 Jan 2003 15:27:14 +0200 Elena Egorova <jeg@satgatellc.com>
wrote:
>> Хмм.. Действительно, для этой задачи, возможно, такой вариант будет
>> лучше. Однако, иногда всё равно возникает необходимость пользоваться
>> expect'ом и запускать его из крона - например, недавно я писал
>> скрипт, который обходит маршрутизаторы телнетом и собирает с них
>> конфиги раз в неделю. Других способов кроме expect'а я в данном
>> случае не вижу..
> Copying a Running Configuration File from the Router to the TFTP
> Server Step-by Step Instructions
> 1. Create a new file, router-config, in the TFTP server's /tftpboot
> directory. On UNIX, use the syntax: touch <filename> touch router-config
> 2. Change the permissions of the file to 777 using the syntax:
> chmod <permissions> <filename> chmod 777 router-config
> 3. From the management station command line, using the MIB
> objectwriteNet enter the following:
> % snmpset 172.16.99.20 private .1.3.6.1.4.1.9.2.1.55.171.68.191.135 s
> router-config enterprises.9.2.1.55.171.68.191.135 = "router-config"
Этот вариант я отбросил из-за необходимости наличия tftp сервера, да и к
тому же включать SNMP на цисках не секьюрно.
--
Alexey Zagarin
Aquarius Consulting
Phone: +7 (095) 745-3663 *170
E-Mail: alexey@aqc.ru
Reply to: