From: Evgeny <evgeny@cstula.ru> To: Community ALTLinux <community@lists.altlinux.org> Subject: [Comm] Остановить/Поднять ppp из crontab Date: Thu, 01 Sep 2011 08:48:18 +0400 Message-ID: <4E5F0E92.90109@cstula.ru> (raw) Всем доброго утра. Сервер Ковчег p5. Он подключается к московскому виндовому серверу pptp. Если подключение не разрывать совсем, то московский сервер рвёт его сам раз в сутки. Мой же сервер не понимает, что соединения нет и ppp1 продолжает висеть. Я решил на ночь отключать это соединение, а утром подключаться снова. В /etc/crontab добавил 2 задания: #start ppp1 03 7 * * * root /sbin/ifup ppp1 #stop ppp1 11 21 * * * root /sbin/ifdown ppp1 Есть скрипт /etc/net/ifaces/ppp1/ifup-post, в котором: #!/bin/sh route add -net 10.5.0.0 netmask 255.255.248.0 dev ppp1 Тут словил проблему. При поднятии ppp1 из crontab скрипт ifup-post - не выполняется (нет роута после поднятия через crontab). Если руками написать ifup ppp1, то всё замечательно отрабатывается. Что я сделал не так?
next reply other threads:[~2011-09-01 4:48 UTC|newest] Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top 2011-09-01 4:48 Evgeny [this message] 2011-09-01 6:12 ` Andrey Liakhovets 2011-09-01 9:18 ` Evgeny 2011-09-01 10:49 ` Sergey 2011-09-01 17:14 ` Евгений 2011-09-01 17:30 ` Евгений 2011-09-01 19:13 ` Yury Bushmelev 2011-09-02 3:10 ` Евгений 2011-09-02 1:18 ` Alexei Takaseev 2011-09-02 4:48 ` Roman Savochenko 2011-09-05 15:24 ` Michael A. Kangin
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=4E5F0E92.90109@cstula.ru \ --to=evgeny@cstula.ru \ --cc=community@lists.altlinux.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: link
ALT Linux Community general discussions This inbox may be cloned and mirrored by anyone: git clone --mirror http://lore.altlinux.org/community/0 community/git/0.git # If you have public-inbox 1.1+ installed, you may # initialize and index your mirror using the following commands: public-inbox-init -V2 community community/ http://lore.altlinux.org/community \ mandrake-russian@linuxteam.iplabs.ru community@lists.altlinux.org community@lists.altlinux.ru community@lists.altlinux.com public-inbox-index community Example config snippet for mirrors. Newsgroup available over NNTP: nntp://lore.altlinux.org/org.altlinux.lists.community AGPL code for this site: git clone https://public-inbox.org/public-inbox.git