NASLite Network Attached Storage

www.serverelements.com
Task-specific simplicity with low hardware requirements.
It is currently Thu Mar 28, 2024 7:28 am

All times are UTC - 5 hours [ DST ]




Post new topic Reply to topic  [ 31 posts ]  Go to page Previous  1, 2, 3  Next
Author Message
 Post subject: automated shutdown
PostPosted: Sun Jul 23, 2006 7:09 pm 
Offline

Joined: Sun Jul 23, 2006 6:59 pm
Posts: 3
Location: west coast
Thank you for your work creating this script, it works perfectly. Now I need another ups and I'm worry free.

Thanks again......................(works fine with v2.0) :D


Top
 Profile  
 
 Post subject:
PostPosted: Sat Aug 05, 2006 11:40 am 
Offline

Joined: Sat Aug 05, 2006 11:20 am
Posts: 1
Works a pip mate...thanks! I did have to do a workaround to execute the .vbs file as my Belkin Bulldog software seems to only work with .bat files. I just created a .bat file with a "start nasshutdown.vbs" as the content and used that.
:D


Top
 Profile  
 
PostPosted: Tue Aug 22, 2006 6:55 am 
Offline

Joined: Sat Aug 05, 2006 5:26 pm
Posts: 18
Location: Germany
Hi George,

again thanks for your work to share it to other users!
I still have problems with w98se to run telnet. It says:

11fCONSOLE SCREEN TOO SMALL
11fMINIMUM 80 x 24 REQUIRED
11fRESIZE TO ACCOMMODATE

When I use putty all works properly - but not your script.
Can you rewrite it for putty?

Thanks, Roland


Top
 Profile  
 
 Post subject:
PostPosted: Tue Aug 22, 2006 12:01 pm 
Offline

Joined: Sat Nov 19, 2005 6:39 pm
Posts: 633
Location: California
Hello Roland:

I see you also reported this problem in http://www.serverelements.com/phpBB2/viewtopic.php?t=1144.

Did the manual solution (resizing with the Layout tab) help ? Ofcourse, for the automated script this would not be a good solution.

Unfortunately I no longer have a Win98SE system, so I am unable to test. Also, it has been so long since I used it ... not sure if I can be of help. What you might want to look at is whether a Microsoft Command Console ( I think it used to be called "MS-DOS Prompt" ) can have its default settings changed so that every new instance of a command console starts up with those parameters. including the larger window you need.

Sorry I can not help further.

:) Georg


Top
 Profile  
 
 Post subject:
PostPosted: Mon Sep 18, 2006 1:27 pm 
Offline

Joined: Tue May 30, 2006 2:15 pm
Posts: 138
Location: UK / FRANCE 44290
looks like a great little script and I'm sure it works. however on my set up, Ad_Aware flashed and then all sorts of unrelated apps opened up!!! Positive this Ad-Aware's doing but as it goes berserk, i have not had chance to modify it! Anyone else got round spy-ware alerts?

Jeff


Top
 Profile  
 
 Post subject:
PostPosted: Tue Nov 14, 2006 11:42 am 
Offline

Joined: Tue May 30, 2006 2:15 pm
Posts: 138
Location: UK / FRANCE 44290
georg - eliminated SpyBot and your script runs a treat! Brilliant - thanks. Jeff


Top
 Profile  
 
 Post subject:
PostPosted: Tue Nov 14, 2006 8:43 pm 
Offline

Joined: Sat Nov 19, 2005 6:39 pm
Posts: 633
Location: California
jeffjohn, thanks for posting that update. Glad you like it.
:) Georg


Top
 Profile  
 
 Post subject:
PostPosted: Tue Nov 28, 2006 5:11 pm 
Offline

Joined: Tue May 30, 2006 2:15 pm
Posts: 138
Location: UK / FRANCE 44290
Mamba - could you kindly list your whole script for me. My UPS is a BELKIN 500VA F6H350ukUNV; do all their products require a .BAT script, do you know?

many thanks Jeffjohn


Top
 Profile  
 
 Post subject:
PostPosted: Tue Feb 13, 2007 1:34 pm 
Offline

Joined: Tue Apr 12, 2005 11:28 am
Posts: 25
George, the script works great.

If you have a APC UPS with USB connection, or a other UPS with software not allowing you to start this script, you can use PTFBPro, yea i know it costs money, but it works! go to: http://www.pushthefreakinbutton.com/ , with this utility you can monitor windows they pop up in windows and then based on different rules (window name, window content, window location) can run a application, in our case the shut down script. You must create with PTFB a macro script (not the button function), triggered by the window from your UPS software, when it pops up and says "running on battery" or similar. At normal you will have set your UPS to shut down after 5 minutes (and not maximum runtime), that it can also handle a repeated power outage, the window will only pop up after a few seconds, so a short power spike should not create the window and also not a power down of the NAS. It's not perfect, but it works.

//Wolfgang


Top
 Profile  
 
 Post subject:
PostPosted: Tue Feb 13, 2007 3:21 pm 
Offline

Joined: Sun Dec 10, 2006 11:48 pm
Posts: 81
Mamba wrote:
Works a pip mate...thanks! I did have to do a workaround to execute the .vbs file as my Belkin Bulldog software seems to only work with .bat files. I just created a .bat file with a "start nasshutdown.vbs" as the content and used that.
:D


Starting to play around with Vista and discovered that the Bulldog software isn't compatible. So far, Belkin doesn't have a Vista compatible update. So, for now, I'm back to manually shutting NAS down :(


Top
 Profile  
 
 Post subject: shutdown with .bat files
PostPosted: Wed Feb 14, 2007 5:04 am 
Offline

Joined: Tue May 30, 2006 2:15 pm
Posts: 138
Location: UK / FRANCE 44290
Interested in .bat shutdown scripts for my Belkin UPS, as described by Mamba; could someone post the full script method of running the .vbs file within a .bat command, please? jeffjohn


Top
 Profile  
 
 Post subject:
PostPosted: Wed Feb 14, 2007 2:51 pm 
Offline

Joined: Sat Nov 19, 2005 6:39 pm
Posts: 633
Location: California
Hello jeffjohn:

Use the below as contents of a BAT file that runs VBS file.

Don't forget that firewalls (like ZoneAlarm) may require you to interactively approve execution of "telnet" or similar commands. This may create a stumbling block until you set up your firewall to automatically allow all operations needed for the remote shutdown.

Hope this works for you.

:) Georg


@echo off
rem -------------------------------------------------------------------
rem
rem NAS_SHUT.BAT
rem
rem Apparently some applications can not start VBS directly; they
rem can only execute ".bat" (or ".exe").
rem -------------------------------------------------------------------


rem -------------------------------------------------------------------
rem Also, some applications have trouble with long folder names.
rem Try to locate the VBS in a folder using short names. If
rem supplying the full folder name as a second argument to the
rem "csript" command does not work, try the steps in section A first.
rem -------------------------------------------------------------------


rem -------------------------------------------------------------------
rem SECTION A: Change to the drive and folder that contains the VBS.
rem -------------------------------------------------------------------
rem
n:
cd \byo\shutdown\final7
rem

rem -------------------------------------------------------------------
rem SECTION B: Substitute proper path to "csript.exe" if necessary.
rem -------------------------------------------------------------------

echo.
echo Running remote shutdown for NASLite
echo.

c:\windows\system32\cscript.exe nas_shut.vbs

echo.
echo Shutdown is DONE !
echo.
pause


Top
 Profile  
 
 Post subject:
PostPosted: Wed Feb 14, 2007 3:34 pm 
Offline

Joined: Tue May 30, 2006 2:15 pm
Posts: 138
Location: UK / FRANCE 44290
many thanks georg ; currently on vacation in France but will give script a run when I get back. Many thanks jeffjohn.


Top
 Profile  
 
 Post subject:
PostPosted: Thu Mar 15, 2007 2:04 am 
Offline

Joined: Sat Nov 19, 2005 6:39 pm
Posts: 633
Location: California
Check out the new post at http://www.serverelements.com/phpBB2/viewtopic.php?p=8888.

The new script is a major update and feature extension to my original (now one-year-old script -- which is still working even in NASLite+ v2.04).

:) Georg


Top
 Profile  
 
PostPosted: Fri Apr 13, 2007 11:01 am 
Offline

Joined: Sun Feb 18, 2007 1:12 am
Posts: 6
I have seen the post on the vbs script to shutdown Naslite, however those folks that want a solution for your linux box should look at installing "expect" scripting tool. It allows automated interatction with ftp, telnet , etc. There is also autoexpect which does all the hard work of scripting for you. It runs in the background while you telnet to NASlite , shut it down then exit. It records the steps then saves in script format to a file ready to be run. Next all you do is have the UPS software run the file on power faliure.

FYI, I just bought OPTI-UPS Enhanced Series (Output: 1400VA/980W) from Altex, but Newegg has them too for $135. I have a 5u Ubuntu Webserver and NASLITE server connected to it, it reads as Load being 20%. I thought i was going to need 2 UPS, but not so, this UPS handles both quite easily with pwr to spare. I have them running headless with no monitor, but I think the UPS could handle the monitor easily. In addition Opti-UPS has linux software on there cd that was easy to install on Ubuntu. It has a web interface for monitoring and configuring. I configured it to run the script i created with autoexpect. So far just doing some test, and so far its working.


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 31 posts ]  Go to page Previous  1, 2, 3  Next

All times are UTC - 5 hours [ DST ]


Who is online

Users browsing this forum: No registered users and 10 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB® Forum Software © phpBB Group