Results 1 to 2 of 2

Thread: Proxy Script

Hybrid View

  1. #1

    Unhappy Proxy Script

    Hi dear,
    i want to create a script that will automatically detect my /var size of linux partition in redhat and then it should automatically stop service and should remove all the files in squid cache. i don't know how to check that partition is filled or not??? can any one help me

    Scenarion of Script
    1>Check that /var is fill or not??
    2> if (yes)
    {Remove squid cache files}
    3>else
    {should check again}

    Regards.
    Muhammad Asif

  2. #2
    Moderator
    Good Guru
    Schotty's Avatar
    Join Date
    Jul 2001
    Location
    Milwaukee, WI
    Posts
    5,760
    Quote Originally Posted by asi.linux
    Hi dear,
    i want to create a script that will automatically detect my /var size of linux partition in redhat and then it should automatically stop service and should remove all the files in squid cache. i don't know how to check that partition is filled or not??? can any one help me

    Scenarion of Script
    1>Check that /var is fill or not??
    2> if (yes)
    {Remove squid cache files}
    3>else
    {should check again}

    Regards.
    Muhammad Asif
    I would run a cron job that checks for the size free and if its too small runs another job that stops needed services, clears the caches, and then restarts the services. I would include (from personal experience here) samba in that shutdown script as well, since I have had it bork out due to lack of free space once, and I thought my computer fried due to the sluggishness even after freeing the space. What was needed was a stop a wait and then a restart (took a 5 min pause to ensure that it did indeed speed my machine up).

Similar Threads

  1. changing Firefox proxy config by script
    By xylex_blaiste in forum Programming
    Replies: 2
    Last Post: 02-26-2007, 07:54 AM
  2. Proxy
    By Devil in forum Linux - Hardware, Networking & Security
    Replies: 3
    Last Post: 11-15-2006, 03:30 AM
  3. proxy
    By ammad in forum Linux - Hardware, Networking & Security
    Replies: 2
    Last Post: 06-05-2005, 11:44 PM
  4. Probs in a script called from another script
    By Outlaw in forum Programming
    Replies: 1
    Last Post: 03-12-2004, 02:54 PM
  5. Proxy and Intranet...
    By Sonic Revenge in forum Linux - Software, Applications & Programming
    Replies: 3
    Last Post: 05-22-2002, 05:11 PM

Bookmarks

Posting Permissions

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