Inactive [ADMN] AutoShutdown 2.2 - Stop/Restart/Shut down at the same time every day [1248]

Discussion in 'Inactive/Unsupported Plugins' started by matjam, Jul 13, 2011.

  1. Offline

    matjam

    AutoShutdown: Automatically Shutdown/Stop your server at a set time every day.
    Version: v2.2

    I have moved the information for this plugin to BukkitDev.

    This thread will still be used to discuss any possible future changes, and to provide some examples.

    Example config.yml
    config.yml (open)
    Code:
    #A list of times in 24h format separated by comma to schedule a shutdown for.
    shutdowntimes: 2:00,14:00
    
    # Reason to give for kicking user on shutdown.
    kickreason: Scheduled Shutdown.
    
    # Seconds before the shutdown to broadcast a warning message.
    warntimes: 900,600,300,240,180,120,60,45,30,15,14,13,12,11,10,9,8,7,6,5,4,3,2,1
    
    # When doing an immediate shutdown, how many seconds grace should be given.
    gracetime: 30
    
    # Should we bother kicking users? (recommended)
    kickonshutdown: true
    

    Example restart scripts
    Windows (open)
    Code:
    :begin
    
    "c:\Program Files\Java\jdk1.6.0_23\bin\java.exe" -Xms1024M -Xmx2048M -jar craftbukkit-0.0.1-SNAPSHOT.jar
    
    goto begin
    
    named as run.bat, run from the cmd.exe prompt. Set ms and mx size to what you feel is suitable.

    Path to the java.exe will need to be set.
    Unix (open)
    Code:
    #!/bin/bash
    
    while true
    do
            echo starting minecraft server ...
            java -Xms1024M -Xmx4096M -jar craftbukkit.jar nogui
    
            echo sleeping ...
    
            # Do backups or something useful here
    
            sleep 5
    done
    
    named as run.sh, run from a screen session.
     
  2. Offline

    kuledaniel

    awesome but if i have close the server bat do it running or?
     
  3. Offline

    matjam

    If you're asking if the plugin lets you run the server as a windows background service, no. There are ways to do that though, take a look at this: http://jslwin.sourceforge.net/
     
  4. Offline

    vander_fr

    Nice plugin, I'am going to test it on my server.

    Can we set more than one restart in a day ?
    A popular MC server with a lot of plugins need multiples restarts per day to deal with memory leaks and stuff...
     
  5. Offline

    matjam

    That's a good feature request, and fairly easy to implement I guess. Will take a look tonight :)
     
    trumpetkid2011 likes this.
  6. Offline

    Djrowling

    I believe the link is broken, this looks very good btw!
    EDIT: It is not broken :D
     
  7. Offline

    kahlilnc

    Works with a control panel?
     
  8. Offline

    SwedishN00B

    I might be a little bit stupid but I donĀ“t understand how to install this plugin...
    I downloaded the zip-file but there is no jar-file in it. How do I do?
     
  9. Offline

    matjam

    it's a jar file, if it downloaded as a zip, just rename it to AutoShutdown.jar
     
  10. Offline

    SwedishN00B

    Thanks, it was that simple!
    By the way, the plugin works nice. Just what I have been looking for!
     
  11. Offline

    Aortal

    Quick question. When this shuts down a server does it allow time for the console to save the map?
     
  12. Offline

    matjam

    It uses the same code for shutting down that the "stop" command uses. I also do a save-all just in case before issuing stop anyway.
     
  13. Offline

    frozone2008

    link dont work
     
  14. Offline

    riyyi

    Please update the link I realy need this.
     
  15. Offline

    Aza24

    Can you add SuperPerms support? Because I really need this.
     
  16. Offline

    Denney

    Second the SuperPerms support.
     
  17. Offline

    PhantomServer

    My SmartScreen Filter says its a virus, please add a mirror
     
  18. Offline

    matjam

    Updated to support SuperPerms, removed legacy Permissions support. Updated to latest bukkit recommended build. Hosting it on my own server, rather than anyhub.
     
  19. It would be great if you could build in a second time for AutoShutdown.
    The plugin in it's actual version works great and how it should be.
    I created a batch for a backup routine but i want to split the backup tasks / i want to use a second backup task per day and so i need a second shutdown time.
    Would be great if you could provide it :)
     
  20. Offline

    matjam

    Yep, working on it.

    I learned a lot when I went to write Cron, so I'm integrating those lessons into AS2.0. It's not a major rewrite but the current version of AS probably won't work for the newer CB build, so I recommend you not use it. Cron can fulfil the same function as AS, though it's not quite as functional yet.

    Released 2.0 without the multi shutdown time functionality, as I think its important to have a working AS for now.

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: May 17, 2016
  21. can i somhow make my figur as a op for it i am the op but it say i dont got the permissions so is there a trick??
     
  22. I mentioned the problem with newer CB versions ;)
    With the last RB there was an timer-error.

    Do you forgot to edit the config file?
    There is no line to edit the second shutdown :)

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: May 17, 2016
  23. Offline

    matjam

    er? read what I wrote? :p "without" not "with".

    New version supports it now though, updating main post.
     
  24. Omg -_-
    I'm really sry ^^
     
  25. Offline

    Tolerance

    Please fix title:
    [ADMIN] to [ADMN]
     
  26. Offline

    BackHandReaper

    Complaint!
    I am the owner of my server and in permissions i have all commands possible, im op. And also added the nodes seperatly
    Still doesn't work when i try /as or /as now
     
  27. Offline

    Dustin545

    could you help me on like teamviewer on how to get the auto restart working
     
  28. Offline

    matjam

    Sorted.

    it is /as set now.

    Also, you need the autoshutdown.admin node, and a superperms compatible permissions plugin.

    No, sorry. There is a .bat there and a unix bash script. It's not hard. You must be running it from a .bat anyway, just put a loop around the command like I've done.
     
  29. Offline

    matjam

    2.2 released with the ability to schedule new times within the game, and some bugfixes.

    Can't currently *remove* a scheduled shutdown time. Thats next. If 2.1 is working for you, suggest waiting for next version.
     
  30. Offline

    remypas

    Any way to change the text 'Server is Shutting Down in 10 minutes' (or whatever time) to Server is restarting in xxxx

    It looks a bit more friendly.

    Brilliantly simple plugin btw :)
     

Share This Page