QNAP TS-101 NAS Shutdown script problems
#1
Hi folks,

I am working on a shutdown script to shut down my QQNAP TS-101 via my XBMC on a Xbox.

This is my script (modified from a script of Zach Morris):

# Shutdown QNAP TS-101
#
# Adjust admin username, password and ip_address as required


import urllib,urllib2 , re
from string import split, replace, find

# The url in which to use
Base_URL = "http://Administrator:******@192.168.0.20:8080/cgi-bin/misc/misc.cgi?count=1233044386&SHUTDOWN="

# Open a 'Socket' to the URL
WebSock = urllib.urlopen(Base_URL)
# Read contents of URL
WebHTML = WebSock.read()
# Close the connection to the URL
WebSock.close()

What I am having trouble with is the BASE_URL line. The count number (here it is 1233044386) changes on every login. What is it for? Why does it change? I tried: "http://Administrator:******@192.168.0.20:8080/cgi-bin/misc/misc.cgi?SHUTDOWN="
with no success. I a not exactly a cgi god. Can anyone of youguys give me a hint on a http:// line that does a reliable shutdown on my TS-101? Then I can do the rest.

Greets,

WOnken
Reply

Logout Mark Read Team Forum Stats Members Help
QNAP TS-101 NAS Shutdown script problems0