Gamingforce Interactive Forums
85240 35212

Go Back   Exploding Garrmondo Weiner Interactive Swiss Army Penis > Garrmondo Network > Help Desk
Register FAQ GFWiki Community Donate Arcade ChocoJournal Calendar

Notices

Welcome to the Exploding Garrmondo Weiner Interactive Swiss Army Penis.
GFF is a community of gaming and music enthusiasts. We have a team of dedicated moderators, constant member-organized activities, and plenty of custom features, including our unique journal system. If this is your first visit, be sure to check out the FAQ or our GFWiki. You will have to register before you can post. Membership is completely free (and gets rid of the pesky advertisement unit underneath this message).


Problems automatically running a batch file
Reply
 
Thread Tools
KrazyTaco
urrrrrr


Member 753

Level 13.94

Mar 2006


Reply With Quote
Old Jun 9, 2006, 12:19 AM #1 of 17
Problems automatically running a batch file

First, let me explain the story.

I have a sister who's 15 years old. My parents and myself are both worried about her, due to the fact that lately she has been up later than everyone else (till around 12 AM) on the computer/internet. None of us believe she is mature or responsible enough to be left alone down here on the computer that late into the night. Please don't ask me to go any further or start a debate with me on why she needs to be allowed to grow up or what have you. Basically, my parents want me to make it so that she cannot use the computer past 10 PM. All of the networking hardware is in my room, and this computer that my sister uses gets the connection to the internet wireleslly. For the past few days I have simply been unplugging the router's power to shut down our connection. There are two problems though
1) This kills my internet also
2) My sister can hop onto the other network that is floating around here somewhere, it's very slow, but she can and does use it when I disconnect ours

So now I'm stepping up a bit and am trying to just shut down the entire computer after a certain point. I have created a batch file that gives the user 30 seconds warning and then shuts down.
(shutdown -s incase you were wondering). My problem is I cannot get this file to run as a scheduled task (I would like it to take effect every night at 10 PM) locally. Whenever I try, Windows gives me a "Access is denied" error even though Im logged on as an administrator and have supplied an admin password to the task. Preferrably though, I would like to somehow get it to run remotely, and give control of execution to me at my computer.

Is there a way to place the batch file on the target computer and then remotely run it on said computer from my own computer? Better yet, is their a piece of software than can remotely shut down computers? I've tried this one piece of software that was free to download whos name has slipped my mind, but it didn't work, it would alwats cause an error whenever I told it to shutdown (Probably for the same reason Windows cant do it for whatever reason)

Jam it back in, in the dark.
Little Shithead
prettiest miku


Member 90

Level 33.52

Mar 2006


Reply With Quote
Old Jun 9, 2006, 12:48 AM #2 of 17
You can remotely shut down computers with the -m //computername switch on the shutdown command.

So, you could have it entirely run on your computer. Best thing, it won't be nearly as easy to find and "accidentally" delete.

There's nowhere I can't reach.
Duminas
Something


Member 29

Level 13.21

Mar 2006


Reply With Quote
Old Jun 9, 2006, 12:57 AM Local time: Jun 8, 2006, 09:57 PM #3 of 17
Merv, I thought it was /m \\COMPUTER_NAME?
It's been too long since I've used Windows, but that's what all my online references say. And if she's not an administrator, you could disable her right to alter the file (since in Scheduled Tasks, it'll run as whoever you set it up with).

Beyond that, you can try the below.
The first line kills her account (makes it impossible to log in with it), and the second shuts down the box with some extra switches.
Code:
net user ACCOUNT_NAME /active:no
shutdown /s /f /t:30 /c "Shutting down in 30 seconds. Please save your files."
Of course, you might want to test that shutdown call to see if it actually works. Check out shutdown /? to see what those switches are doing. Though, if she found shutdown /a, you might be a bit screwed there~

To enable the account again, another scheduled task that calls as below would work fine:
Code:
net user ACCOUNT_NAME /active:yes


This thing is sticky, and I don't like it. I don't appreciate it.


Need help using an FTP client? Look no further! ««
Little Shithead
prettiest miku


Member 90

Level 33.52

Mar 2006


Reply With Quote
Old Jun 9, 2006, 12:59 AM #4 of 17
Originally Posted by Duminas
Merv, I thought it was /m \\COMPUTER_NAME?
Yeah, it is.

I got confused because I have my region settings set to Japanese, so \ shows up as a yen sign, even in command prompts.

How ya doing, buddy?
KrazyTaco
urrrrrr


Member 753

Level 13.94

Mar 2006


Reply With Quote
Old Jun 9, 2006, 07:11 AM #5 of 17
I can't remember exactly which command I used at the prompt before, but I know it was a shutdown command and I know I had the syntax at one point because it attempted to shutdown the computer downstairs. The only problem as mentioned though, is that when it attempts this, it gives me an "Access Denied" error (Im using a certain application in this example, but it's the same results using plain vanilla CMD).


I was speaking idiomatically.
Lukage
High Chocobo


Member 570

Level 40.69

Mar 2006


Reply With Quote
Old Jun 9, 2006, 05:28 PM Local time: Jun 9, 2006, 05:28 PM #6 of 17
Katie, you know what I think about your sister.

What about...

psshutdown \\computer -u user -p psswd

so:

psshutdown \\family -u KTsHotSis -p lolomgbbq

Source: http://www.sysinternals.com/Utilities/PsShutdown.html

What kind of toxic man-thing is happening now?
KrazyTaco
urrrrrr


Member 753

Level 13.94

Mar 2006


Reply With Quote
Old Jun 9, 2006, 08:20 PM #7 of 17
Originally Posted by Lukage
Katie, you know what I think about your sister.

What about...

psshutdown \\computer -u user -p psswd

so:

psshutdown \\family -u KTsHotSis -p lolomgbbq

Source: http://www.sysinternals.com/Utilities/PsShutdown.html
Lol no pics 4 u ~

Erm, anyways, (Username, Password obviously blacked out)


It's still giving me a denied access message. I just wish I knew why, I tried logging on as both admin accounts on that computer.

FELIPE NO
Duminas
Something


Member 29

Level 13.21

Mar 2006


Reply With Quote
Old Jun 9, 2006, 08:51 PM Local time: Jun 9, 2006, 05:51 PM #8 of 17
Do both computers have the same Workgroup set? If not, I believe remote shutdown attempts will always fail. Further, is the computer actually named "FAMILY"? Check in System Properties to make sure (enter it in the command as displayed--I don't think Windows cares, but you never know).

Next, when the other machine is on, get its IP. I will assume 192.168.0.100, so alter that as necessary below. Then, enter this into Explorer's address bar (as in the File Manager) and hit Enter:

Quote:
\\192.168.0.100\C$
This might take awhile, but it would connect to the other computer and grant you access to it's C drive. I think that you must be logged in with an account name and password pair that exists on the target machine as well as yours, but I am not sure about if XP still requires this. If it fails, create an account on the other machine to match yours and reboot both, then see if it works (you need to wait about 2 minutes before trying, and both must be Administrators, obviously enough).

If that works, try running your shutdown command again using the IP address instead of the computer's name?

What, you don't want my bikini-clad body?


Need help using an FTP client? Look no further! ««
Excrono
HD-497


Member 141

Level 14.84

Mar 2006


Reply With Quote
Old Jun 9, 2006, 09:23 PM Local time: Jun 9, 2006, 08:23 PM #9 of 17
Normally this would work fine in a domain environment as your admin password would be globally recognized by the managed system (as it would be looking to Active Directory to authenticate). Since it is merely a workgroup however, the remote system isn't recognizing YOURSYSTEM\Administrator account, and instead needs the FAMILY\Administrator account to perform the remote shutdown. One way to go about getting around this would be to add the YOUISYSTEM\Administrator account (or another account on your system that is a member) to the FAMILY\Administrators group on your sister's PC. I'm not sure if this would work though, or if Windows would even allow you go add a user account from another machine.

How ya doing, buddy?
Duminas
Something


Member 29

Level 13.21

Mar 2006


Reply With Quote
Old Jun 9, 2006, 09:27 PM Local time: Jun 9, 2006, 06:27 PM #10 of 17
That's why I mentioned the account name/passwords being equal.

Back on Windows 98, I was required to use accounts with the same username and password pair to share files and devices amongst them. Even 98->XP seemed to need this.

Technically speaking, I don't think Windows XP even cares about computer names on workgroup logins like this. Again, not sure though.

There's nowhere I can't reach.


Need help using an FTP client? Look no further! ««
BlueMikey
TREAT?!?


Member 12

Level 35.70

Feb 2006


Reply With Quote
Old Jun 9, 2006, 10:04 PM Local time: Jun 9, 2006, 08:04 PM #11 of 17
This may sound stupid, but I don't see it mentioned, so I figured it's worth asking. My router has the ability to shut off specific computers at certain times. Are you sure your router doesn't? Then you could just take apart the other connection if it is wired, disconnect the jack at the wall.

How ya doing, buddy?
and Brandy does her best to understand

Last edited by BlueMikey; Jun 9, 2006 at 10:11 PM.
Duminas
Something


Member 29

Level 13.21

Mar 2006


Reply With Quote
Old Jun 9, 2006, 10:07 PM Local time: Jun 9, 2006, 07:07 PM #12 of 17
From what I gathered of the first post, the Family computer is connected through Wireless. If you just knocked the connection off (or shut the box down), she'd be able to kick it back on and connect to that other, slow network, would she not?

Or did I just completely misunderstand you? Interesting router feature, though--I've never seen that before.

I am a dolphin, do you want me on your body?


Need help using an FTP client? Look no further! ««
BlueMikey
TREAT?!?


Member 12

Level 35.70

Feb 2006


Reply With Quote
Old Jun 9, 2006, 10:18 PM Local time: Jun 9, 2006, 08:18 PM #13 of 17
I always thought that this was a fairly standard feature, I mean, my router is a few years old and it's Microsoft.



And whatever the other network is, I'd suggest to just get rid of it, it sounds fairly worthless anyway, or just disable that computer's ability completely to get onto it.

I was speaking idiomatically.
and Brandy does her best to understand
KrazyTaco
urrrrrr


Member 753

Level 13.94

Mar 2006


Reply With Quote
Old Jun 10, 2006, 12:41 AM #14 of 17
No, you have it right Mikey. The wireless router is in my room upstairs, and the computer downstairs get's it's signal wireleslly. So even when I do shut down the router, my sister can still connect to any other network in range.

So anyways, a couple things.
For one, I have confirmed the computer is called "family."
Second of all, no I don't believe my router allows me tt block entire networks. I think I can block certain computers from accessing the network on a schedule, but I'm not entirely sure how to set it, unfourtanately (I really hate the Dlink admin tool, it makes no real sense)
I tried creating a matching admin account on the computer downstairs, but the shutdown command still didn't do anything, access denied and all.
Going on your suggestion though Duminas, I tried accessing it through Explorer. I was able to pull up the computer, but the login screen that spawned forced me to log on as Family\Guest. There was no way to change which user I logged on as, the field was gray (I have guest disabled on that computer). Could that be a cause for all the problems?

What kind of toxic man-thing is happening now?
Duminas
Something


Member 29

Level 13.21

Mar 2006


Reply With Quote
Old Jun 10, 2006, 04:59 AM Local time: Jun 10, 2006, 01:59 AM #15 of 17
I don't think that'd be the cause of the problems, no. If you got in with \\address\C$ on a guest account, that's a bit of a security issue. Beyond that, I don't really know what to tell you. Does Task Scheduler recognise that batch file I posted earlier? If so, why not give it a shot, since it'd kick her off and kill the account. :P

For help with your router's configuration, check out http://www.portforward.com and see if they have documentation to help you.

How ya doing, buddy?


Need help using an FTP client? Look no further! ««
CapturedPenguin
Spidey Sense


Member 40

Level 9.94

Mar 2006


Reply With Quote
Old Jun 10, 2006, 07:23 AM #16 of 17
Just out of curiosity, are both of these computers Home Editions of XP?

What, you don't want my bikini-clad body?

KrazyTaco
urrrrrr


Member 753

Level 13.94

Mar 2006


Reply With Quote
Old Jun 10, 2006, 10:15 AM #17 of 17
One of them is running XP home, mine is running XP proffesional.

Also Duminas, I didn't actually get into the computer. It chose for me to logon as a guest but still requires a password (And I've ever set a password for that account) so I was unable to actually logon through Explorer.

Jam it back in, in the dark.
Reply


Exploding Garrmondo Weiner Interactive Swiss Army Penis > Garrmondo Network > Help Desk > Problems automatically running a batch file

Forum Jump


All times are GMT -5. The time now is 04:29 PM.


Powered by vBulletin® Version 3.8.9
Copyright ©2000 - 2025, vBulletin Solutions, Inc.