Find the answer to your Linux question:
Results 1 to 2 of 2
Hi all. Very newbish question here. I created the following crontab: 0 0 * * * /sbin/netdown 0 5 * * * /sbin/netup netdown contains: #!/bin/bash /sbin/ifdown eth0 netup contains: ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Just Joined!
    Join Date
    Jul 2008
    Posts
    1

    Question Crontab disables eth0 as I want, but eth0 restarts itself???


    Hi all. Very newbish question here. I created the following crontab:

    0 0 * * * /sbin/netdown
    0 5 * * * /sbin/netup

    netdown contains:

    #!/bin/bash
    /sbin/ifdown eth0

    netup contains:

    #!/bin/bash
    /sbin/ifup eth0

    Now, my question is, crontab runs the ifdown script and it works perfectly, but about a minute and a half later eth0 wakes itself back up. I want it to stay down until the netup script is scheduled to run. What is causing it to reactivate itself?

    Thanks in advance.

  2. #2
    Just Joined!
    Join Date
    May 2008
    Posts
    37
    various DEs have networkmanagers

    check your services like:

    chkconfig --list

    see what network services are running. a program starting itself up is usually from a daemon which should be listed there and is most likely a networkmanager.

    also in case you didn't know you can just put the command straight in cron

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •