Old 11-11-2003, 09:14 AM   #1
ddeca
Member
ioFTPD Foundation User
 
Join Date: Aug 2003
Posts: 73
Default Need a little script..

The only way i can make sitewho.exe to work on the bot is if i start the bot trough ioFTPD with site command

So what i need is a little script that runs in scheduler and checks if windrop is running (ioUptime already does that) and if it not site exec command

If i put all my effort in it i might be able to figure out a solution myself, but since we got so good progammers here i think they will do it in 5 min or so

TIA ddeca
ddeca is offline   Reply With Quote
Old 11-11-2003, 10:51 AM   #2
Mouton
Posse Member
Ultimate Scripter
ioFTPD Administrator
 
Join Date: Dec 2002
Posts: 1,956
Default

No programming involved, unless u call creating a .bat file programming...

OnFtpLogin = ..\windrop\restart.bat

restart.bat:
cd c:\ioftpd\windrop
pslist eggdrop.exe > nul
if errorlevel 1 goto restart
goto end

:restart
hiderun eggdrop.exe -nt eggdrop.conf

:end
Mouton is offline   Reply With Quote
Old 11-11-2003, 09:29 PM   #3
ddeca
Member
ioFTPD Foundation User
 
Join Date: Aug 2003
Posts: 73
Default

THX Mouton..

Nice tip... Made the bat like this

The ECHO is just there to tell me what's get executed

Code:
@echo off
CD c:\windrop
    pslist eggdrop > nul
    IF ERRORLEVEL 1 GOTO con
ECHO BOT STILL RUNNING (DiD NOTHiNG)
GOTO END

:CON
CD c:\windrop
start hidewndw /r /n 'c:\windrop\eggdrop.exe -nt eggdrop.conf'
ECHO BOT DOWN (RESTARTiNG iT)

:END
The .BAT file works perfekt as
site command ("SITE BOT")
and in
dos (c:\ioftpd\scripts\bot.bat)
and as
OnFtpLogIn = EXEC ..\scripts\bot.bat

but not in Schedular... really pisses me of any one have an ide ??
tryed this 3 options...and no1 starts the damn script
(and I did restart ioFTPD and the whole box NOT only rehased it)

Check1_Bot = 0,20,40 * * * EXEC bot
Check2_Bot = 0,20,40 * * * EXEC bot.bat
Check3_Bot = 0,20,40 * * * EXEC ..\scripts\bot.bat

[scripts]
bot = EXEC ..\scripts\bot.bat


Is there away of debug the SCHEDUALR ??
To se what is exec or in this case not excute

TIA ddeca
ddeca is offline   Reply With Quote
Old 11-11-2003, 10:12 PM   #4
wooolF[RM]
Senior Member
ioFTPD Foundation User
 
Join Date: Oct 2003
Posts: 411
Default

I would use it as :

CheckBotStatus = 0,5,10,15,20,25,30,35,40,45,50,55 * * * EXEC ..\scripts\bot.bat

rest... rest should be working...

u can try to replace bot.bat with this one:
Code:
echo TEST
pause
exit 0
then you should be able to see new DOS window popup every 5 mins with text "TEST" and prompting u to press any key (to exit)... if u get this to work, then sheduler works just fine.

also it's a good idea to rehash your config (and I would also recommend to restart ftpd (just to be 100% sure))
wooolF[RM] is offline   Reply With Quote
Old 11-11-2003, 10:25 PM   #5
neoxed
Too much time...
FlashFXP Beta Tester
ioFTPD Scripter
 
Join Date: May 2003
Posts: 1,326
Default

Quote:
Originally posted by wooolF[RM]
also it's a good idea to rehash your config (and I would also recommend to restart ftpd (just to be 100% sure))
Changes to the scheduler require you to restart NOT rehash for changes to take effect.
neoxed is offline   Reply With Quote
Old 11-12-2003, 04:18 AM   #6
schmacko
Junior Member
 
Join Date: Jun 2003
Posts: 19
Default

Quote:
Originally posted by ddeca
...and no1 starts the damn script
(and I did restart ioFTPD and the whole box NOT only rehased it)
:P
schmacko is offline   Reply With Quote
Old 11-12-2003, 06:54 AM   #7
ddeca
Member
ioFTPD Foundation User
 
Join Date: Aug 2003
Posts: 73
Default

I guess the Schedular is ****ed up...

Does'nt execute any .bat or .cmd file...
so now i need a TCL script that starts my bat file or something...

Anyone ???

//ddeca
ddeca is offline   Reply With Quote
Old 11-12-2003, 07:54 AM   #8
wooolF[RM]
Senior Member
ioFTPD Foundation User
 
Join Date: Oct 2003
Posts: 411
Default

since we know that sheduler works fine with EXE files, u can convert your bat to exe file (look for it at google.com), it's easy as 1-2-3 and takes no time
Also exe files arre kinda faster then BATs

G'luck
wooolF[RM] is offline   Reply With Quote
Old 11-12-2003, 09:47 AM   #9
ddeca
Member
ioFTPD Foundation User
 
Join Date: Aug 2003
Posts: 73
Default

thx for trying...

But that didnt do the trick either.. I GIVE UP

I will have it in "onFtpLogin" instead even tho it is a crappy sulotion


//ddeca
ddeca is offline   Reply With Quote
Old 11-12-2003, 11:20 AM   #10
wooolF[RM]
Senior Member
ioFTPD Foundation User
 
Join Date: Oct 2003
Posts: 411
Default

if u use ioBanana u can use on_release_complete=bot.bat
wooolF[RM] is offline   Reply With Quote
Old 11-12-2003, 01:47 PM   #11
ddeca
Member
ioFTPD Foundation User
 
Join Date: Aug 2003
Posts: 73
Default

Okey i fixed it

So easy and strange...

I made a BAT file that starts the other bat file

Dunno why it cant execute the bat directly but now it works


Thx for your efforts

//ddeca
ddeca is offline   Reply With Quote
Old 11-12-2003, 10:26 PM   #12
schmacko
Junior Member
 
Join Date: Jun 2003
Posts: 19
Default

Quote:
Originally posted by ddeca
The .BAT file works perfekt as
site command ("SITE BOT")
and in
dos (c:\ioftpd\scripts\bot.bat)
and as
OnFtpLogIn = EXEC ..\scripts\bot.bat
workin here in dos..
not workin the other ways for some reason :/
schmacko is offline   Reply With Quote
Old 12-29-2003, 04:55 AM   #13
freak007
Member
ioFTPD Foundation User
 
Join Date: Jun 2003
Posts: 69
Default

i have the same problem as schmacko. The complete bat only works when i execute the file in dos mode. But when i try to execute it over ioftpd with Scheduler or OnFtpLogin or site command it does not work correctly. The bat will be executed but only echo commands.

The line to start the eggdrop will not be executed, could someone tell me why ? Please i need help.

Quote:
This is my bat file:

@echo off
cd c:\ioftpd\sitebot
pslist eggdrop > nul
if errorlevel 1 goto restart
goto end

:restart
cd c:\ioftpd\sitebot
echo Sitebot wird gestartet !!!
hiderun eggdrop -nt eggdrop.conf

:end
Thx for all your help

freak007
freak007 is offline   Reply With Quote
Old 12-29-2003, 10:14 AM   #14
Mouton
Posse Member
Ultimate Scripter
ioFTPD Administrator
 
Join Date: Dec 2002
Posts: 1,956
Default

What's the site command or Scheduler line u used ?
That'S probably wrong.
Mouton is offline   Reply With Quote
Old 12-29-2003, 11:23 AM   #15
freak007
Member
ioFTPD Foundation User
 
Join Date: Jun 2003
Posts: 69
Default

bot = EXEC ..\sitebot\restart.bat
freak007 is offline   Reply With Quote
Reply

Tags
bot, command, effort, running, site

Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
upload pause on small files silverhaze General Discussion 3 12-02-2004 11:17 AM


All times are GMT -5. The time now is 07:00 PM.

Parts of this site powered by vBulletin Mods & Addons from DragonByte Technologies Ltd. (Details)